Skip to content

Commit

Permalink
#2540 use a popup window, disable startup notification
Browse files Browse the repository at this point in the history
git-svn-id: https://xpra.org/svn/Xpra/trunk@26814 3bb7dfac-3a0b-4e04-842a-767bc560f471
  • Loading branch information
totaam committed Jun 27, 2020
1 parent 04d1e3b commit b089935
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions src/xpra/client/gtk3/splash_screen.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,10 @@ class SplashScreen(Gtk.Window):

def __init__(self):
self.exit_code = None
super().__init__(type=Gtk.WindowType.TOPLEVEL)
super().__init__(type=Gtk.WindowType.POPUP)
self.connect("delete_event", self.exit)
self.set_title("Splash")
title = "Xpra %s" % __version__
self.set_title("Xpra")
self.set_size_request(320, 160)
self.set_position(Gtk.WindowPosition.CENTER)
self.set_decorated(False)
Expand All @@ -35,9 +36,9 @@ def __init__(self):
if icon:
self.set_icon(icon)
hbox.pack_start(Gtk.Image.new_from_pixbuf(icon), False, False, 20)
self.label = Gtk.Label(label="Xpra %s" % __version__)
self.label.modify_font(Pango.FontDescription("sans 18"))
hbox.pack_start(self.label, True, True, 20)
label = Gtk.Label(label=title)
label.modify_font(Pango.FontDescription("sans 18"))
hbox.pack_start(label, True, True, 20)
vbox.add(hbox)
self.progress_bar = Gtk.ProgressBar()
self.progress_bar.set_size_request(320, 30)
Expand Down Expand Up @@ -131,6 +132,7 @@ def get_pixbuf(self, icon_name):
def main(args):
from xpra.platform import program_context
with program_context("splash", "Splash"):
Gtk.Window.set_auto_startup_notification(False)
w = SplashScreen()
add_close_accel(w, Gtk.main_quit)
return w.run()
Expand Down

0 comments on commit b089935

Please sign in to comment.