[X2Go-Commits] pyhoca-gui.git - twofactorauth (branch) updated: 0.1.0.10-239-gd244082

X2Go dev team git-admin at x2go.org
Sat Sep 14 15:56:09 CEST 2013


The branch, twofactorauth has been updated
       via  d244082e8fd6fac9818a79b917885cb0263535ad (commit)
      from  03afe04286a88a0e24a540cdc39feab3a9705124 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
-----------------------------------------------------------------------

Summary of changes:
 debian/changelog       |    1 +
 pyhoca/wxgui/splash.py |   23 ++++++++++++-----------
 2 files changed, 13 insertions(+), 11 deletions(-)

The diff of changes is:
diff --git a/debian/changelog b/debian/changelog
index 1c7abfb..d5acf6d 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -128,6 +128,7 @@ pyhoca-gui (0.1.2.0-0~x2go1) UNRELEASED; urgency=low
       system tray icon (e.g. for branding).
     - Add option --splash-image that allows to name a custom splash image
       that gets shown during application startup.
+    - Only show splash if the splash image file does exist.
   * Depend on Python X2Go 0.1.2.0.
   * Install GNOME icons via dh_links.
   * Install X2Go icons with explicit install paths.
diff --git a/pyhoca/wxgui/splash.py b/pyhoca/wxgui/splash.py
index dda5aaa..1c892c9 100644
--- a/pyhoca/wxgui/splash.py
+++ b/pyhoca/wxgui/splash.py
@@ -43,18 +43,19 @@ class PyHocaGUI_SplashScreen(wx.SplashScreen):
         if os.path.basename(splash_image) == splash_image:
             splash_image = os.path.join(basepath.images_basepath, splash_image)
 
-        splash_wximage = wx.Image(splash_image, wx.BITMAP_TYPE_PNG, )
-        splash_wximage.Rescale(400, int(float(400)/splash_wximage.Width*splash_wximage.Height))
+        if os.path.isfile(splash_image):
+            splash_wximage = wx.Image(splash_image, wx.BITMAP_TYPE_PNG, )
+            splash_wximage.Rescale(400, int(float(400)/splash_wximage.Width*splash_wximage.Height))
 
-        splash_wxbitmap = splash_wximage.ConvertToBitmap()
-        wx.SplashScreen.__init__(self, 
-                                 splash_wxbitmap,
-                                 splashStyle=wx.SPLASH_CENTRE_ON_SCREEN|wx.SPLASH_TIMEOUT,
-                                 milliseconds=5000,
-                                 parent=None,
-                                 style=wx.SIMPLE_BORDER|wx.STAY_ON_TOP|wx.FRAME_NO_TASKBAR
-                                )
-        self.Bind(wx.EVT_CLOSE, self.OnClose)
+            splash_wxbitmap = splash_wximage.ConvertToBitmap()
+            wx.SplashScreen.__init__(self, 
+                                     splash_wxbitmap,
+                                     splashStyle=wx.SPLASH_CENTRE_ON_SCREEN|wx.SPLASH_TIMEOUT,
+                                     milliseconds=5000,
+                                     parent=None,
+                                     style=wx.SIMPLE_BORDER|wx.STAY_ON_TOP|wx.FRAME_NO_TASKBAR
+                                    )
+            self.Bind(wx.EVT_CLOSE, self.OnClose)
 
     def OnClose(self, evt):
         # Make sure the default handler runs too so this window gets


hooks/post-receive
-- 
pyhoca-gui.git (Python X2Go Client (wxPython GUI))

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "pyhoca-gui.git" (Python X2Go Client (wxPython GUI)).




More information about the x2go-commits mailing list