Esempio n. 1
0
    def __init__(self,
                 config_class=config.Config,
                 database_class=dbsqlite.Database,
                 model_class=model.Model):
        # Initialize the gPodder home directory
        util.make_directory(gpodder.home)

        # Open the database and configuration file
        self.db = database_class(gpodder.database_file)
        self.model = model_class(self.db)
        self.config = config_class(gpodder.config_file)

        # Load extension modules and install the extension manager
        gpodder.user_extensions = extensions.ExtensionManager(self)

        # Load installed/configured plugins
        gpodder.load_plugins()

        # Update the current device in the configuration
        self.config.mygpo.device.type = util.detect_device_type()
Esempio n. 2
0
    def __init__(self,
                 config_class=config.Config,
                 database_class=dbsqlite.Database,
                 model_class=model.Model):
        # Initialize the gPodder home directory
        util.make_directory(gpodder.home)

        # Load hook modules and install the hook manager
        gpodder.user_hooks = hooks.HookManager()

        # Load installed/configured plugins
        gpodder.load_plugins()

        # Open the database and configuration file
        self.db = database_class(gpodder.database_file)
        self.model = model_class(self.db)
        self.config = config_class(gpodder.config_file)

        # Update the current device in the configuration
        self.config.mygpo_device_type = util.detect_device_type()
Esempio n. 3
0
    def __init__(self,
                 config_class=config.Config,
                 database_class=dbsqlite.Database,
                 model_class=model.Model):
        # Initialize the gPodder home directory
        util.make_directory(gpodder.home)

        # Open the database and configuration file
        self.db = database_class(gpodder.database_file)
        self.model = model_class(self.db)
        self.config = config_class(gpodder.config_file)

        # Load extension modules and install the extension manager
        gpodder.user_extensions = extensions.ExtensionManager(self)

        # Load installed/configured plugins
        gpodder.load_plugins()

        # Update the current device in the configuration
        self.config.mygpo.device.type = util.detect_device_type()

        # Initialize Flattr integration
        self.flattr = flattr.Flattr(self.config.flattr)