Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 2.0, 2.0.1, and 2.0.2

stable sync: fix "embedded" behavior to be more explicit (target doesn't apply)

I still think this is potentially confusing because "self.embedded" is True when
the workbench toolbar sync buttons are used and the checkbox still applies.

Changeset 582dc5065fec

Parent 4c5d5c7cb9e1

by Daniel Atallah

Changes to one file · Browse files at 582dc5065fec Showing diff from parent 4c5d5c7cb9e1 Diff from another changeset...

 
77
78
79
 
80
81
82
83
 
84
85
86
 
140
141
142
143
 
144
145
146
 
242
243
244
245
 
246
247
248
 
253
254
255
256
257
258
259
 
303
304
305
306
 
307
308
309
 
77
78
79
80
81
82
83
 
84
85
86
87
 
141
142
143
 
144
145
146
147
 
243
244
245
 
246
247
248
249
 
254
255
256
 
257
258
259
 
303
304
305
 
306
307
308
309
@@ -77,10 +77,11 @@
  self.updateInProgress = False   self.opts = {}   self.cmenu = None + self.embedded = bool(parent)     self.repo.configChanged.connect(self.configChanged)   - if parent: + if self.embedded:   layout.setContentsMargins(2, 2, 2, 2)   else:   self.setWindowTitle(_('TortoiseHg Sync')) @@ -140,7 +141,7 @@
  self.targetcombo.setEnabled(False)   self.targetcheckbox = QCheckBox(_('Target:'))   self.targetcheckbox.toggled.connect(self.targetcombo.setEnabled) - if parent: + if self.embedded:   tb.addSeparator()   tb.addWidget(self.targetcheckbox)   tb.addWidget(self.targetcombo) @@ -242,7 +243,7 @@
  self.postpullbutton.clicked.connect(self.postpullclicked)   self.optionsbutton.pressed.connect(self.editOptions)   - cmd = cmdui.Widget(not parent, self) + cmd = cmdui.Widget(not self.embedded, self)   cmd.commandStarted.connect(self.commandStarted)   cmd.commandFinished.connect(self.commandFinished)   @@ -253,7 +254,6 @@
  layout.addWidget(cmd)   cmd.setVisible(False)   self.cmd = cmd - self.embedded = bool(parent)     self.reload()   if 'default' in self.paths: @@ -303,7 +303,7 @@
  self.targetcombo.setCurrentIndex(index)     def applyTargetOption(self, cmdline): - if self.targetcheckbox.isChecked(): + if self.embedded and self.targetcheckbox.isChecked():   revtext = hglib.fromunicode(self.targetcombo.currentText())   args = revtext.split(': ')   if args[0] == 'rev':