Exemplo n.º 1
0
        public void Run()
        {
            var poof_file = DockServices.Paths.SystemDataFolder.GetChild("poof.png");

            if (!poof_file.Exists)
            {
                return;
            }

            poof = new Pixbuf(poof_file.Path);

            window = new Gtk.Window(Gtk.WindowType.Toplevel);
            window.AppPaintable = true;
            window.Resizable    = false;
            window.KeepAbove    = true;
            window.CanFocus     = false;
            window.TypeHint     = WindowTypeHint.Splashscreen;
            window.SetCompositeColormap();

            window.Realized += delegate { window.GdkWindow.SetBackPixmap(null, false); };

            window.SetSizeRequest(size, size);
            window.ExposeEvent += HandleExposeEvent;

            GLib.Timeout.Add(30, delegate {
                if (AnimationState == 1)
                {
                    window.Hide();
                    window.Destroy();
                    poof.Dispose();
                    return(false);
                }
                else
                {
                    window.QueueDraw();
                    return(true);
                }
            });

            window.Move(x, y);
            window.ShowAll();
            run_time = DateTime.UtcNow;
        }
Exemplo n.º 2
0
		public HoverTextManager ()
		{
			SetLight ();
			
			window = new Gtk.Window (Gtk.WindowType.Popup);
			
			window.AppPaintable = true;
			window.AcceptFocus = false;
			window.Decorated = false;
			window.DoubleBuffered = true;
			window.SkipPagerHint = true;
			window.SkipTaskbarHint = true;
			window.Resizable = false;
			window.CanFocus = false;
			window.TypeHint = WindowTypeHint.Dock;
			window.Stick ();
			
			window.SetCompositeColormap ();
			window.ExposeEvent += HandleWindowExposeEvent;
						
			DockServices.Theme.ThemeChanged += DockyControllerThemeChanged;
		}
Exemplo n.º 3
0
        public HoverTextManager()
        {
            SetLight();

            window = new Gtk.Window(Gtk.WindowType.Popup);

            window.AppPaintable    = true;
            window.AcceptFocus     = false;
            window.Decorated       = false;
            window.DoubleBuffered  = true;
            window.SkipPagerHint   = true;
            window.SkipTaskbarHint = true;
            window.Resizable       = false;
            window.CanFocus        = false;
            window.TypeHint        = WindowTypeHint.Dock;
            window.Stick();

            window.SetCompositeColormap();
            window.ExposeEvent += HandleWindowExposeEvent;

            DockServices.Theme.ThemeChanged += DockyControllerThemeChanged;
        }
Exemplo n.º 4
0
		public void Run ()
		{
			var poof_file = DockServices.Paths.SystemDataFolder.GetChild ("poof.png");
			if (!poof_file.Exists)
				return;
			
			poof = new Pixbuf (poof_file.Path);
			
			window = new Gtk.Window (Gtk.WindowType.Toplevel);
			window.AppPaintable = true;
			window.Resizable = false;
			window.KeepAbove = true;
			window.CanFocus = false;
			window.TypeHint = WindowTypeHint.Splashscreen;
			window.SetCompositeColormap ();
			
			window.Realized += delegate { window.GdkWindow.SetBackPixmap (null, false); };
			
			window.SetSizeRequest (size, size);
			window.ExposeEvent += HandleExposeEvent;
			
			GLib.Timeout.Add (30, delegate {
				if (AnimationState == 1) {
					window.Hide ();
					window.Destroy ();
					poof.Dispose ();
					return false;
				} else {
					window.QueueDraw ();
					return true;
				}
			});
			
			window.Move (x, y);
			window.ShowAll ();
			run_time = DateTime.UtcNow; 
		}