コード例 #1
0
        public NowPlayingInterface()
        {
            GtkElementsService service = ServiceManager.Get <GtkElementsService> ();

            primary_window = service.PrimaryWindow;

            Contents = new NowPlayingContents();

            // This is my really sweet hack - it's where the video widget
            // is sent when the source is not active. This keeps the video
            // widget from being completely destroyed, causing problems with
            // its internal windowing and GstXOverlay. It's also conveniently
            // the window that is used to do fullscreen video. Sweeeeeeeeeet.
            video_window         = new FullscreenWindow(service.PrimaryWindow);
            video_window.Hidden += OnFullscreenWindowHidden;
            video_window.Realize();
            video_window.Add(Contents);

            frame = new Hyena.Widgets.RoundedFrame();
            frame.SetFillColor(new Cairo.Color(0, 0, 0));
            frame.DrawBorder = false;
            frame.Show();

            PackStart(frame, true, true, 0);

            fullscreen_adapter = new FullscreenAdapter();
            fullscreen_adapter.SuggestUnfullscreen += OnAdapterSuggestUnfullscreen;
            screensaver = new ScreensaverManager();
        }
コード例 #2
0
        public NowPlayingInterface ()
        {
            GtkElementsService service = ServiceManager.Get<GtkElementsService> ();
            primary_window = service.PrimaryWindow;

            Contents = new NowPlayingContents ();

            // This is my really sweet hack - it's where the video widget
            // is sent when the source is not active. This keeps the video
            // widget from being completely destroyed, causing problems with
            // its internal windowing and GstXOverlay. It's also conveniently
            // the window that is used to do fullscreen video. Sweeeeeeeeeet.
            video_window = new FullscreenWindow (service.PrimaryWindow);
            video_window.Hidden += OnFullscreenWindowHidden;
            video_window.Realize ();
            video_window.Add (Contents);

            frame = new Hyena.Widgets.RoundedFrame ();
            frame.SetFillColor (new Cairo.Color (0, 0, 0));
            frame.DrawBorder = false;
            frame.Show ();

            PackStart (frame, true, true, 0);

            fullscreen_adapter = new FullscreenAdapter ();
            fullscreen_adapter.SuggestUnfullscreen += OnAdapterSuggestUnfullscreen;
            screensaver = new ScreensaverManager ();
        }
コード例 #3
0
        protected void SetupFullscreenHandling()
        {
            GtkElementsService service = ServiceManager.Get <GtkElementsService> ();

            fullscreen_adapter = new FullscreenAdapter();
            screensaver        = new ScreensaverManager();

            video_window         = new FullscreenWindow(service.PrimaryWindow);
            video_window.Hidden += OnFullscreenWindowHidden;
            video_window.Realize();
        }
コード例 #4
0
        public NowPlayingInterface()
        {
            GtkElementsService service = ServiceManager.Get <GtkElementsService> ();

            primary_window = service.PrimaryWindow;

            Contents = new NowPlayingContents();
            Contents.ButtonPressEvent += (o, a) => {
                if (a.Event.Type == Gdk.EventType.TwoButtonPress)
                {
                    var iaservice = ServiceManager.Get <InterfaceActionService> ();
                    var action    = iaservice.ViewActions["FullScreenAction"] as Gtk.ToggleAction;
                    if (action != null && action.Sensitive)
                    {
                        action.Active = !action.Active;
                    }
                }
            };

            // This is my really sweet hack - it's where the video widget
            // is sent when the source is not active. This keeps the video
            // widget from being completely destroyed, causing problems with
            // its internal windowing and GstXOverlay. It's also conveniently
            // the window that is used to do fullscreen video. Sweeeeeeeeeet.
            video_window         = new FullscreenWindow(service.PrimaryWindow);
            video_window.Hidden += OnFullscreenWindowHidden;
            video_window.Realize();
            video_window.Add(Contents);

            frame = new Hyena.Widgets.RoundedFrame();
            frame.SetFillColor(new Cairo.Color(0, 0, 0));
            frame.DrawBorder = false;
            frame.Show();

            PackStart(frame, true, true, 0);

            fullscreen_adapter = new FullscreenAdapter();
            fullscreen_adapter.SuggestUnfullscreen += OnAdapterSuggestUnfullscreen;
            screensaver = new ScreensaverManager();
        }
コード例 #5
0
        protected void SetupFullscreenHandling()
        {
            GtkElementsService service = ServiceManager.Get<GtkElementsService> ();

            fullscreen_adapter = new FullscreenAdapter ();
            screensaver = new ScreensaverManager ();

            video_window = new FullscreenWindow (service.PrimaryWindow);
            video_window.Hidden += OnFullscreenWindowHidden;
            video_window.Realize ();
        }