Example #1
0
 def buildSettings(self, profile):
     if profile is None or (profile == "" and PMXProfile.askForProfile()):
         #Select profile
         from prymatex.gui.dialogs.profile import PMXProfileDialog
         profile = PMXProfileDialog.selectProfile(PMXProfile.PMX_PROFILES_FILE)
     elif profile == "":
         #Find default profile in config
         profile = PMXProfile.defaultProfile()
         
     #Settings
     from prymatex.gui.dialogs.settings import PMXSettingsDialog
     if not profile:
         raise ValueError("Invalid Profile")
     self.settings = PMXProfile(profile)
     self.settingsDialog = PMXSettingsDialog(self)
Example #2
0
 def buildSettings(self, profile):
     # TODO Cambiar este metodo a buildProfile
     if profile is None or (profile == "" and not PMXProfile.PMX_PROFILES_DONTASK):
         #Select profile
         from prymatex.gui.dialogs.profile import PMXProfileDialog
         profile = PMXProfileDialog.selectProfile(PMXProfile.PMX_PROFILES_FILE)
     elif profile == "":
         #Find default profile in config
         profile = PMXProfile.PMX_PROFILE_DEFAULT
         
     #Settings
     from prymatex.gui.dialogs.settings import PMXSettingsDialog
     if not profile:
         raise ValueError("Invalid Profile")
     self.profile = PMXProfile(profile)
     
     # Configure application
     self.profile.registerConfigurable(self.__class__)
     self.profile.configure(self)
     
     # TODO Este dialogo no va mas aca
     self.settingsDialog = PMXSettingsDialog(self)
Example #3
0
    def buildSettings(self, profile):
        # TODO Cambiar este metodo a buildProfile
        if profile is None or (profile == ""
                               and not PMXProfile.PMX_PROFILES_DONTASK):
            #Select profile
            from prymatex.gui.dialogs.profile import PMXProfileDialog
            profile = PMXProfileDialog.selectProfile(
                PMXProfile.PMX_PROFILES_FILE)
        elif profile == "":
            #Find default profile in config
            profile = PMXProfile.PMX_PROFILE_DEFAULT

        #Settings
        from prymatex.gui.dialogs.settings import PMXSettingsDialog
        if not profile:
            raise ValueError("Invalid Profile")
        self.profile = PMXProfile(profile)

        # Configure application
        self.profile.registerConfigurable(self.__class__)
        self.profile.configure(self)

        # TODO Este dialogo no va mas aca
        self.settingsDialog = PMXSettingsDialog(self)
Example #4
0
 def switchProfile(self):
     from prymatex.gui.dialogs.profile import PMXProfileDialog
     profile = PMXProfileDialog.switchProfile(PMXProfile.PMX_PROFILES_FILE)
     if profile is not None and profile != self.settings.PMX_PROFILE_NAME:
         self.restart()
Example #5
0
 def switchProfile(self):
     from prymatex.gui.dialogs.profile import PMXProfileDialog
     profile = PMXProfileDialog.switchProfile(PMXProfile.PMX_PROFILES_FILE)
     if profile is not None and profile != self.profile.PMX_PROFILE_NAME:
         self.restart()