[meld] Fix auto-merge



commit 8804edfbe0dfa84f096d916fbb4e8710caa73a4c
Author: Piotr Piastucki <the_leech users berlios de>
Date:   Sun Feb 27 23:01:27 2011 +0100

    Fix auto-merge
    
    This commit fixes auto-merge mode by using correct set of text buffers
    in file comparison.

 meld/filemerge.py |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/meld/filemerge.py b/meld/filemerge.py
index 48f56bf..aaf7113 100644
--- a/meld/filemerge.py
+++ b/meld/filemerge.py
@@ -61,14 +61,14 @@ class FileMerge(filediff.FileDiff):
         if buf == self.hidden_textbuffer:
             buf = self.textbuffer[1]
             yesno = True
-        pane = self.textbuffer.index(buf)
-        self.bufferdata[pane].writable = yesno
-        self.recompute_label()
+        filediff.FileDiff.set_buffer_writable(self, buf, yesno)
 
     def _merge_files(self):
         yield _("[%s] Computing differences") % self.label_text
         panetext = []
-        for b in self.textbuffer[:self.num_panes]:
+        textbuffer = self.textbuffer[:]
+        textbuffer[1] = self.hidden_textbuffer
+        for b in textbuffer[:self.num_panes]:
             start, end = b.get_bounds()
             text = unicode(b.get_text(start, end, False), 'utf8')
             panetext.append(text)



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