GithubHelp home page GithubHelp logo

Comments (12)

kakone avatar kakone commented on July 30, 2024

Yes, you are right. As it's a Windows Runtime Component, you can't inherit from the MediaElement or MediaTransportControls classes. The first workaround would be to remove the sealed keyword and to compile as a class library (perhaps I could do a second nuget package for this).
Other workaround (ugly) : add your custom buttons in another button bar in the Content property of the MediaTransportControls.

from vlc.mediaelement.

touseefbsb avatar touseefbsb commented on July 30, 2024

yeah I did the other work around it works but it doesnt look so good for the user, so 1st work around would be the best, can you please do that and update the respository and nuget package? or perhaps you can guide me how to do it quickly? I mean I am using nuget package right now, but I can download the repo directly from here and if I just remove the sealed keyword from the class will it work fine ? or are there any more steps to follow?

from vlc.mediaelement.

kakone avatar kakone commented on July 30, 2024

I created a new package.
Add this package instead of the Windows Runtime Component package and you should be able to create some custom media transport controls.

from vlc.mediaelement.

touseefbsb avatar touseefbsb commented on July 30, 2024

thnks a lot

from vlc.mediaelement.

touseefbsb avatar touseefbsb commented on July 30, 2024

I just tried to create a simple inherited custom transport control following Microsoft docs and I got a null refrence exception on many objects within VLC namespace. have you tested the class library package to create custom control? if yes then can you please provide me a very basic and simple sample to do so?

from vlc.mediaelement.

kakone avatar kakone commented on July 30, 2024

Yes, I tested it quickly. Here is a sample project : App1.zip (it's follow the documentation using this Generic.xaml file).

from vlc.mediaelement.

touseefbsb avatar touseefbsb commented on July 30, 2024

I tried to compile the sample project you provided but its giving very basic compile time errors for unknown reasons, for example its not even recognizing System namespace that is why it has a lot of compile time errors. Also I checked the refrence node, there is no refrence for vlc media element class library nuget package or no second project of the class library to refrence to.

from vlc.mediaelement.

kakone avatar kakone commented on July 30, 2024

Right click on the Solution and choose 'Restore Nuget Packages', it must restore the VLC.MediaElement.ClassLibrary nuget package and you will see it in the References.

from vlc.mediaelement.

touseefbsb avatar touseefbsb commented on July 30, 2024

Error occurred while restoring NuGet packages: Unable to load package 'Microsoft.Net.Native.SharedLibrary-x64'.

Failed to download package 'Microsoft.Net.Native.SharedLibrary-x64.1.6.1' from 'https://api.nuget.org/v3-flatcontainer/microsoft.net.native.sharedlibrary-x64/1.6.1/microsoft.net.native.sharedlibrary-x64.1.6.1.nupkg'.
The HTTP request to 'GET https://api.nuget.org/v3-flatcontainer/microsoft.net.native.sharedlibrary-x64/1.6.1/microsoft.net.native.sharedlibrary-x64.1.6.1.nupkg' has timed out after 100000ms.

from vlc.mediaelement.

touseefbsb avatar touseefbsb commented on July 30, 2024

these are the errors I recieve when I try to restore nuget packages.

from vlc.mediaelement.

kakone avatar kakone commented on July 30, 2024

Strange error, you seems to have a problem to access nuget.org.
Did you try this workaround ? https://stackoverflow.com/a/44038629

from vlc.mediaelement.

touseefbsb avatar touseefbsb commented on July 30, 2024

i tried it also failed, can you please provide me a project where I dont need to restore packages?

from vlc.mediaelement.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.