[meld] dirdiff: Add apply-text-filters property to dirdiff for new preference



commit 8c16ef0bc9afe9c149c496359e7a420a8b20f35c
Author: Kai Willadsen <kai willadsen gmail com>
Date:   Tue Feb 10 06:24:25 2015 +1000

    dirdiff: Add apply-text-filters property to dirdiff for new preference

 meld/dirdiff.py |   11 +++++++++++
 1 files changed, 11 insertions(+), 0 deletions(-)
---
diff --git a/meld/dirdiff.py b/meld/dirdiff.py
index 4f30c77..ec52356 100644
--- a/meld/dirdiff.py
+++ b/meld/dirdiff.py
@@ -251,9 +251,18 @@ class DirDiff(melddoc.MeldDoc, gnomeglade.Component):
         ('folder-shallow-comparison', 'shallow-comparison'),
         ('folder-time-resolution', 'time-resolution'),
         ('folder-status-filters', 'status-filters'),
+        ('folder-filter-text', 'apply-text-filters'),
         ('ignore-blank-lines', 'ignore-blank-lines'),
     )
 
+    apply_text_filters = GObject.property(
+        type=bool,
+        nick="Apply text filters",
+        blurb=(
+            "Whether text filters and other text sanitisation preferences "
+            "should be applied when comparing file contents"),
+        default=False,
+    )
     ignore_blank_lines = GObject.property(
         type=bool,
         nick="Ignore blank lines",
@@ -419,6 +428,7 @@ class DirDiff(melddoc.MeldDoc, gnomeglade.Component):
         self.connect("notify::shallow-comparison", self.update_comparator)
         self.connect("notify::time-resolution", self.update_comparator)
         self.connect("notify::ignore-blank-lines", self.update_comparator)
+        self.connect("notify::apply-text-filters", self.update_comparator)
 
         self.state_filters = []
         for s in self.state_actions:
@@ -462,6 +472,7 @@ class DirDiff(melddoc.MeldDoc, gnomeglade.Component):
         comparison_args = {
             'shallow-comparison': self.props.shallow_comparison,
             'time-resolution': self.props.time_resolution,
+            'apply-text-filters': self.props.apply_text_filters,
             'ignore_blank_lines': self.props.ignore_blank_lines,
         }
         self.file_compare = functools.partial(


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