summaryrefslogtreecommitdiff
path: root/voctogui
diff options
context:
space:
mode:
authorMaZderMind <github@mazdermind.de>2015-06-17 17:26:25 +0200
committerMaZderMind <github@mazdermind.de>2015-06-17 17:26:25 +0200
commit086865a64db5d182ff39bf7015c80b9aba20a2e4 (patch)
tree0ab9d356beb8d7e3bc28cde8b8a8e18d3d12886e /voctogui
parent7432403bd14eb8eb9f0d202f7fe4addb403be559 (diff)
Implement correct Fetching via ID
Diffstat (limited to 'voctogui')
-rw-r--r--voctogui/lib/uibuilder.py4
-rw-r--r--voctogui/ui/voctogui.ui4
2 files changed, 2 insertions, 6 deletions
diff --git a/voctogui/lib/uibuilder.py b/voctogui/lib/uibuilder.py
index 8ce01ab..2d6a85b 100644
--- a/voctogui/lib/uibuilder.py
+++ b/voctogui/lib/uibuilder.py
@@ -15,13 +15,13 @@ class UiBuilder(object):
def find_widget_recursive(self, widget, name):
widget = self._find_widget_recursive(widget, name)
if not widget:
- self.log.error('could find required widget "%s" by name (not ID!) inside the parent %s', name, str(widget))
+ self.log.error('could find required widget "%s" by ID inside the parent %s', name, str(widget))
raise Exception('Widget not found in parent')
return widget
def _find_widget_recursive(self, widget, name):
- if widget.get_name() == name:
+ if Gtk.Buildable.get_name(widget) == name:
return widget
if hasattr(widget, 'get_children'):
diff --git a/voctogui/ui/voctogui.ui b/voctogui/ui/voctogui.ui
index 2443925..75e9bb1 100644
--- a/voctogui/ui/voctogui.ui
+++ b/voctogui/ui/voctogui.ui
@@ -277,7 +277,6 @@
<property name="orientation">vertical</property>
<child>
<object class="GtkDrawingArea" id="video">
- <property name="name">video</property>
<property name="width_request">320</property>
<property name="height_request">180</property>
<property name="visible">True</property>
@@ -298,7 +297,6 @@
<property name="can_focus">False</property>
<child>
<object class="GtkLabel" id="label">
- <property name="name">label</property>
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label" translatable="yes">cam1</property>
@@ -313,7 +311,6 @@
<child>
<object class="GtkButton" id="btn_a">
<property name="label" translatable="yes">a</property>
- <property name="name">btn_a</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
@@ -328,7 +325,6 @@
<child>
<object class="GtkButton" id="btn_b">
<property name="label" translatable="yes">b</property>
- <property name="name">btn_b</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>