Giter VIP home page Giter VIP logo

Comments (4)

davidbritch avatar davidbritch commented on August 15, 2024 1

Hi @EdwardMcFlurry

By default, an Android MediaController hides itself after 3 seconds. In order to make it visible throughout video playback you'll have to override the MediaController.Hide method:

    public class MyMediaController : MediaController
    {
        public MyMediaController(Context context) : base(context)
        {
        }
 
        public override void Hide()
        {
        }
 
        public void HideController()
        {
            base.Hide();
        }
    }

Having an empty Hide method ensures that the transport controls never fade out. Then, instead of creating a new MediaController, create a new MyMediaController:

_mediaController = new MyMediaController(_context);

The problem this creates is that in some scenarios the transport controls will still be showing even when you navigate away from the page. That's the purpose of the HideController method - it forces the transport controls to disappear. You just need to call this method at an appropriate point in the page lifecycle.

from dotnet-maui-videoplayer.

EdwardMcFlurry avatar EdwardMcFlurry commented on August 15, 2024

Hi @davidbritch

Thank you so much for the response and I'll give it a try and see if it won't be ideal for my scenario or perhaps at least look for ways of having the thumbnails for Android.

😀

from dotnet-maui-videoplayer.

99067718 avatar 99067718 commented on August 15, 2024

You tricked me with the bottom image, I tried to click the play button.

from dotnet-maui-videoplayer.

EdwardMcFlurry avatar EdwardMcFlurry commented on August 15, 2024

@99067718 I'm sorry 😂 for the trick...

from dotnet-maui-videoplayer.

Related Issues (13)

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.