예제 #1
0
 def load_shortcuts(self):
     shortcuts = []
     for context, name, keystr in iter_shortcuts():
         shortcut = Shortcut(context, name, keystr)
         shortcuts.append(shortcut)
     shortcuts = sorted(shortcuts, key=lambda x: x.context + x.name)
     self.model.shortcuts = shortcuts
     self.model.reset()
     self.adjust_cells()
예제 #2
0
 def load_shortcuts(self):
     shortcuts = []
     for context, name, keystr in iter_shortcuts():
         shortcut = Shortcut(context, name, keystr)
         shortcuts.append(shortcut)
     shortcuts = sorted(shortcuts, key=lambda x: x.context+x.name)
     self.model.shortcuts = shortcuts
     self.model.reset()
     self.adjust_cells()
예제 #3
0
파일: shortcuts.py 프로젝트: ptocca/spyder
 def load_shortcuts(self):
     """Load shortcuts and assign to table model."""
     shortcuts = []
     for context, name, keystr in iter_shortcuts():
         shortcut = Shortcut(context, name, keystr)
         shortcuts.append(shortcut)
     shortcuts = sorted(shortcuts, key=lambda x: x.context+x.name)
     self.source_model.shortcuts = shortcuts
     self.source_model.reset()
     self.adjust_cells()
예제 #4
0
파일: shortcuts.py 프로젝트: Mabai/spyder
 def load_shortcuts(self):
     """Load shortcuts and assign to table model."""
     shortcuts = []
     for context, name, keystr in iter_shortcuts():
         shortcut = Shortcut(context, name, keystr)
         shortcuts.append(shortcut)
     shortcuts = sorted(shortcuts, key=lambda x: x.context + x.name)
     # Store the original order of shortcuts
     for i, shortcut in enumerate(shortcuts):
         shortcut.index = i
     self.source_model.shortcuts = shortcuts
     self.source_model.scores = [0] * len(shortcuts)
     self.source_model.rich_text = [s.name for s in shortcuts]
     self.source_model.reset()
     self.adjust_cells()
     self.sortByColumn(CONTEXT, Qt.AscendingOrder)
예제 #5
0
 def load_shortcuts(self):
     """Load shortcuts and assign to table model."""
     shortcuts = []
     for context, name, keystr in iter_shortcuts():
         shortcut = Shortcut(context, name, keystr)
         shortcuts.append(shortcut)
     shortcuts = sorted(shortcuts, key=lambda x: x.context+x.name)
     # Store the original order of shortcuts
     for i, shortcut in enumerate(shortcuts):
         shortcut.index = i
     self.source_model.shortcuts = shortcuts
     self.source_model.scores = [0]*len(shortcuts)
     self.source_model.rich_text = [s.name for s in shortcuts]
     self.source_model.reset()
     self.adjust_cells()
     self.sortByColumn(CONTEXT, Qt.AscendingOrder)