Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 1.9, 1.9.1, and 1.9.2

settings: implement tabbed interface to switch "global" and "repo" scope

combobox should be removed, but currently not yet.

Changeset d1f20180e26c

Parent c7beb639a876

by Yuya Nishihara

Changes to one file · Browse files at d1f20180e26c Showing diff from parent c7beb639a876 Diff from another changeset...

 
473
474
475
476
477
478
 
 
 
 
 
 
 
 
 
 
 
479
480
481
 
504
505
506
 
 
 
 
507
508
509
 
473
474
475
 
 
 
476
477
478
479
480
481
482
483
484
485
486
487
488
489
 
512
513
514
515
516
517
518
519
520
521
@@ -473,9 +473,17 @@
  self.settings = s   self.restoreGeometry(s.value('settings/geom').toByteArray())   - # FIXME: use tab widget - self.settingsform = SettingsForm(focus=focus, parent=self) - layout.addWidget(self.settingsform) + self.conftabs = QTabWidget() + layout.addWidget(self.conftabs) + self.conftabs.addTab(SettingsForm(focus=focus, parent=self), + _('User global settings')) + if repo: + self.conftabs.addTab(SettingsForm(focus=focus, parent=self), + _('%s repository settings') % hglib.tounicode(name)) + + # FIXME: workaround to sync tabs with combo; remove this later + self.confcombo.currentIndexChanged.connect(self.conftabs.setCurrentIndex) + self.conftabs.currentChanged.connect(self.confcombo.setCurrentIndex)     BB = QDialogButtonBox   bb = QDialogButtonBox(BB.Ok|BB.Cancel) @@ -504,6 +512,10 @@
  self.applyChanges()   self.refresh()   + @property + def settingsform(self): # FIXME: temporarily added; remove this later + return self.conftabs.currentWidget() +   def refresh(self, *args):   return self.settingsform.refresh() # FIXME