Commits

Steve Borho committed 2cb19a2 Merge

Merge with stable

Comments (0)

Files changed (2)

tortoisehg/hgtk/bugtraq.py

         errormessage = bugtr.OnCommitFinished(0, commonroot, pathlist,
                 logmessage, 0)
         return errormessage
-        
+
     def show_options_dialog(self, options):
         if not self.has_options():
             return ""
         bugtr = self._get_bugtraq_object()
         options = bugtr.ShowOptionsDialog(0, options)
         return options
-    
+
     def has_options(self):
         if not self.supports_bugtraq2_interface():
             return False
     ret = []
     enumerator = cm.EnumClassesOfCategories((CATID_BugTraqProvider,),())
     while 1:
-        clsid = enumerator.Next();
-        if clsid == ():
-            break;
-
+        try:
+            clsid = enumerator.Next()
+            if clsid == ():
+                break
+        except pythoncom.com_error:
+            break
         ret.extend(clsid)
     return ret
 
     pluginclsids = get_issue_plugins()
     keyandnames = [(key, get_plugin_name(key)) for key in pluginclsids]
     return [kn for kn in keyandnames if kn[1] is not None]
-
-

tortoisehg/hgtk/merge.py

         # layout table for advanced options
         table = gtklib.LayoutTable()
         expander.add(table)
-        discard = gtk.CheckButton(_('Discard all changes from merge target '
-                                    '(other) revision'))
-        self.discard = discard
-        table.add_row(discard)
-
+        
         vlist = gtk.ListStore(str,  # tool name
                               bool) # separator
         combo = gtk.ComboBoxEntry(vlist, 0)
         self.mergetool = combo
         combo.set_row_separator_func(lambda model, path: model[path][1])
-        combo.child.set_width_chars(8)
-        lbl = gtk.Label(_('Merge tools:'))
-        lbl.set_alignment(1, 0.5)
-        self.mergelabel = lbl
-        self.action_area.add(lbl)
-        self.action_area.add(combo)
+        combo.child.set_width_chars(16)
+        chtool = gtk.RadioButton(None, _('Use merge tool:'))
+        self.mergelabel = chtool
+        table.add_row(chtool, combo)
         prev = False
         for tool in hglib.mergetools(self.repo.ui):
             cur = tool.startswith('internal:')
         else:
             combo.child.set_text('')
 
+        discard = gtk.RadioButton(chtool,
+            _('Discard all changes from merge target (other) revision'))
+        self.discard = discard
+        table.add_row(discard)
+
         # prepare to show
         if len(self.repo.parents()) == 2:
             self.mergetool.set_sensitive(False)