[PATCH 2/7] Allow reordering of tabs



This can be useful when many diffs are open in tabs.  For example,
say diffA, diffB, and diffC are open in tabs, and diffA and diffC
have similar changes.  To quickly compare the changes in diffA
to diffC it is convenient to have the 2 tabs next to each other
so that they can quickly be toggled between.  Allowing reordering
lets the user move the diffA tab to be next to the diffC tab for
quick comparison.

Signed-off-by: Peter Tyser <ptyser gmail com>
---
 meld/meldapp.py |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/meld/meldapp.py b/meld/meldapp.py
index 23e0d0f..c408b24 100644
--- a/meld/meldapp.py
+++ b/meld/meldapp.py
@@ -500,6 +500,9 @@ class MeldApp(gnomeglade.Component):
         if self.notebook.get_n_pages() > 1:
             self.notebook.set_property("show-tabs", True)
 
+        # Allow reordering of tabs
+        self.notebook.set_tab_reorderable(page.widget, True);
+
     def append_dirdiff(self, dirs, auto_compare=False):
         assert len(dirs) in (1,2,3)
         doc = dirdiff.DirDiff(self.prefs, len(dirs))
-- 
1.7.1.13.gcfb88



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]