示例#1
0
 def _write_keyboard(self, keyboard):
     if not self._config.has_section('keyboard'):
         self._config.add_section('keyboard')
     self._config.set('keyboard', 'mode', Mode.values()[keyboard.mode])
示例#2
0
 def _write_keyboard(self, keyboard):
     if not self._config.has_section("keyboard"):
         self._config.add_section("keyboard")
     self._config.set("keyboard", "mode", Mode.values()[keyboard.mode])
示例#3
0
 def _read_keyboard(self, keyboard):
     if self._config.has_section('keyboard'):
         mode_name = self._config.get('keyboard', 'mode')
         if mode_name is not None:
             keyboard.mode = Mode.names()[mode_name]
示例#4
0
 def _read_keyboard(self, keyboard):
     if self._config.has_section("keyboard"):
         mode_name = self._config.get("keyboard", "mode")
         if mode_name is not None:
             keyboard.mode = Mode.names()[mode_name]