chiark / gitweb /
RC1
[cura.git] / Cura / gui / splashScreen.py
1 __copyright__ = "Copyright (C) 2013 David Braam - Released under terms of the AGPLv3 License"
2
3 import wx._core #We only need the core here, which speeds up the import. As we want to show the splashscreen ASAP.
4
5 from Cura.util.resources import getPathForImage
6
7 class splashScreen(wx.SplashScreen):
8         def __init__(self, callback):
9                 self.callback = callback
10                 bitmap = wx.Bitmap(getPathForImage('splash.png'))
11                 super(splashScreen, self).__init__(bitmap, wx.SPLASH_CENTRE_ON_SCREEN, 0, None)
12                 wx.CallAfter(self.DoCallback)
13
14         def DoCallback(self):
15                 self.callback()
16                 self.Destroy()