[pitivi] widgets: Make the properties parameter mandatory



commit d1670edd47180b8c047b564490790056c1533591
Author: Alexandru Băluț <alexandru balut gmail com>
Date:   Tue Jan 28 09:12:35 2014 +0100

    widgets: Make the properties parameter mandatory

 pitivi/utils/widgets.py |    7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)
---
diff --git a/pitivi/utils/widgets.py b/pitivi/utils/widgets.py
index 449b177..6f9fa6a 100644
--- a/pitivi/utils/widgets.py
+++ b/pitivi/utils/widgets.py
@@ -792,8 +792,9 @@ class GstElementSettingsWidget(Gtk.VBox, Loggable):
         """
         d = {}
         for prop, widget in self.properties.iteritems():
-            if (not prop.flags & GObject.PARAM_WRITABLE
-            or isinstance(widget, DefaultWidget)):
+            if not prop.flags & GObject.PARAM_WRITABLE:
+                continue
+            if isinstance(widget, DefaultWidget):
                 continue
             value = widget.getWidgetValue()
             if value is not None and (value != prop.default_value or with_default):
@@ -839,7 +840,7 @@ class GstElementSettingsDialog(Loggable):
     Dialog window for viewing/modifying properties of a Gst.Element
     """
 
-    def __init__(self, elementfactory, properties={}, parent_window=None, isControllable=True):
+    def __init__(self, elementfactory, properties, parent_window=None, isControllable=True):
         Loggable.__init__(self)
         self.debug("factory: %s, properties: %s", elementfactory, properties)
 


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