コード例 #1
0
    def __init__(self):
        
        (self.options, self.args) = self.get_options().parse_args()
        
        # Run preload.
        self.run_preload()
        
        # initial mainloop setup. The actual loop is started later,
        self.mainloop_init()
        
        #initialize DbusManager
        import dbus_manager
        self.check_result = dbus_manager.check_exit(self.options, self.args)

        if self.check_result == "exit":
            
            # fix from dock start program cursor bus bug
            import gtk
            gtk.gdk.notify_startup_complete()
            
            sys.exit(0)
            
        elif self.check_result == "command":    
            if not self.options.StartAnyway:
                sys.exit(0)
            
        self.dbus = dbus_manager.DeepinMusicDBus()    
        
        #load the rest.
        self.__init()
        
        from widget.instance import mainloop    
        mainloop()
コード例 #2
0
    def __init__(self):
        
        (self.options, self.args) = self.get_options().parse_args()
        
        # Run preload.
        self.run_preload()
        
        # initial mainloop setup. The actual loop is started later,
        self.mainloop_init()
        
        #initialize DbusManager
        import dbus_manager
        self.check_result = dbus_manager.check_exit(self.options, self.args)

        if self.check_result == "exit":
            sys.exit(0)
        elif self.check_result == "command":    
            if not self.options.StartAnyway:
                sys.exit(0)
            
        self.dbus = dbus_manager.DeepinMusicDBus()    
        
        #load the rest.
        self.__init()
        
        from widget.instance import mainloop    
        mainloop()
コード例 #3
0
ファイル: main.py プロジェクト: lovesnow/deepin-music
    def __init__(self):

        (self.options, self.args) = self.get_options().parse_args()

        # Run preload.
        self.run_preload()

        # initial mainloop setup. The actual loop is started later,
        self.mainloop_init()

        #initialize DbusManager
        import dbus_manager
        self.check_result = dbus_manager.check_exit(self.options, self.args)

        if self.check_result == "exit":

            # fix from dock start program cursor bus bug
            import gtk
            gtk.gdk.notify_startup_complete()

            sys.exit(0)

        elif self.check_result == "command":
            if not self.options.StartAnyway:
                sys.exit(0)

        self.dbus = dbus_manager.DeepinMusicDBus()

        import helper
        helper.NEED_RESTORE = False if self.args else True

        #load the rest.
        self.__init()

        from widget.instance import mainloop
        mainloop()