Beispiel #1
0
 def __init__(self, pinMenuToConfigure, color="yellow"):
     BaseButton.__init__(self, "config", color)
     self.__configMenu = ConfigMenu(pinMenuToConfigure)
     self.add_description(
             "Opens a configuration menu to add a new button. Types:\n" +
             "   1. MenuButton: Container for further buttons\n" +
             "   2. ActionButton: executes a command in the associated terminal as supprocess\n" +
             "   3. DirectoryButton: Jumps to directories in the associated terminal\n" +
             "2+3: * you can specify placeholders, e.g.: $(aName)\n" +
             "       will open an additional dialog that asks for 'aName'\n" +
             "     * you can use environment variables (windows: %VARIABLE%)\n" +
             "       there are a couple of environment variables available:\n" +
             "       PINIT_ROOT_DIR:   root directory of your pinit instance\n" +
             "       PINIT_LAYOUT_DIR: directory of of the associated layout file")
Beispiel #2
0
 def __init__(self, name, submenu, color="sky blue"):
     BaseButton.__init__(self, name, color)
     self.__submenu = submenu
Beispiel #3
0
 def get_storage_description(self):
     d = BaseButton.get_storage_description(self)
     d["submenu"] = self.__submenu.get_storage_description()
     return d
Beispiel #4
0
 def __init__(self, name, directory=None, color="thistle"):
     BaseButton.__init__(self, name, color)
     self.__directory = directory
     self.__pinit_root_dir = os.path.dirname(
         os.path.realpath(__file__ + "/.."))
Beispiel #5
0
 def get_storage_description(self):
     d = BaseButton.get_storage_description(self)
     d["directory"] = self.__directory
     return d
Beispiel #6
0
 def __init__(self, mainMenu, color="thistle"):
     BaseButton.__init__(self, "save", color)
     self.__mainMenu = mainMenu
     self.__storageManager = StorageManager()
     self.add_description("saves current setup to: " +
                          StorageManager.FILENAME)
Beispiel #7
0
 def __init__(self, name, cmd=None, color="thistle"):
     BaseButton.__init__(self, name, color)
     self.__cmd = cmd
Beispiel #8
0
 def get_storage_description(self):
     d = BaseButton.get_storage_description(self)
     d["cmd"] = self.__cmd
     return d