aboutsummaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorKai Huuhko <kai.huuhko@gmail.com>2015-05-04 08:38:27 +0300
committerKai Huuhko <kai.huuhko@gmail.com>2015-05-04 08:38:27 +0300
commit94779d1640981bca3af79bd6ff5cd77edd138567 (patch)
treefc5600b61992f2487b36ed7ea7e8d8354241109b /examples
parentelm.Toolbar: Note earlier changes to events and update example (diff)
downloadpython-efl-94779d1640981bca3af79bd6ff5cd77edd138567.tar.gz
Examples: Fixed ecore_x and dbus examples
Diffstat (limited to 'examples')
-rwxr-xr-xexamples/dbus/test_dbus_spy.py18
-rw-r--r--examples/ecore/x/mplayer_embed.py4
-rw-r--r--examples/ecore/x/window_creation.py2
3 files changed, 13 insertions, 11 deletions
diff --git a/examples/dbus/test_dbus_spy.py b/examples/dbus/test_dbus_spy.py
index fb7fff2..f89b7b8 100755
--- a/examples/dbus/test_dbus_spy.py
+++ b/examples/dbus/test_dbus_spy.py
@@ -20,7 +20,9 @@ from efl.elementary.label import Label
from efl.elementary.panes import Panes
from efl.elementary.popup import Popup
from efl.elementary.separator import Separator
-from efl.elementary.genlist import Genlist, GenlistItem, GenlistItemClass
+from efl.elementary.genlist import Genlist, GenlistItemClass, \
+ ELM_GENLIST_ITEM_GROUP, ELM_GENLIST_ITEM_TREE, \
+ ELM_OBJECT_SELECT_MODE_DISPLAY_ONLY
from efl.dbus_mainloop import DBusEcoreMainLoop
@@ -253,12 +255,12 @@ class NamesList(Genlist):
# add private & public group items
self.public_group = self.item_append(self.itc_g, "Public Services",
- flags=elm.ELM_GENLIST_ITEM_GROUP)
- self.public_group.select_mode_set(elm.ELM_OBJECT_SELECT_MODE_DISPLAY_ONLY)
+ flags=ELM_GENLIST_ITEM_GROUP)
+ self.public_group.select_mode_set(ELM_OBJECT_SELECT_MODE_DISPLAY_ONLY)
self.private_group = self.item_append(self.itc_g, "Private Services",
- flags=elm.ELM_GENLIST_ITEM_GROUP)
- self.private_group.select_mode_set(elm.ELM_OBJECT_SELECT_MODE_DISPLAY_ONLY)
+ flags=ELM_GENLIST_ITEM_GROUP)
+ self.private_group.select_mode_set(ELM_OBJECT_SELECT_MODE_DISPLAY_ONLY)
# populate the genlist
self.populate()
@@ -361,8 +363,8 @@ class DetailList(Genlist):
# objects
for obj in recursive_introspect(bus, name, '/'):
obj_item = self.item_append(self.itc_g, obj,
- flags=elm.ELM_GENLIST_ITEM_GROUP)
- obj_item.select_mode_set(elm.ELM_OBJECT_SELECT_MODE_DISPLAY_ONLY)
+ flags=ELM_GENLIST_ITEM_GROUP)
+ obj_item.select_mode_set(ELM_OBJECT_SELECT_MODE_DISPLAY_ONLY)
# interfaces
for iface in obj.interfaces:
@@ -371,7 +373,7 @@ class DetailList(Genlist):
continue
iface_item = self.item_append(self.itc, iface,
parent_item=obj_item,
- flags=elm.ELM_GENLIST_ITEM_TREE)
+ flags=ELM_GENLIST_ITEM_TREE)
def sort_cb(self, it1, it2):
pri1 = pri2 = 0
diff --git a/examples/ecore/x/mplayer_embed.py b/examples/ecore/x/mplayer_embed.py
index e1a62af..6586ad1 100644
--- a/examples/ecore/x/mplayer_embed.py
+++ b/examples/ecore/x/mplayer_embed.py
@@ -2,7 +2,7 @@
import sys
import efl.ecore
-from efl.ecore.x import Window, on_window_configure_add
+from efl.ecore_x import Window, on_window_configure_add
from subprocess import Popen, PIPE
@@ -39,5 +39,5 @@ def on_configure(event, main_window, sub_window):
on_window_configure_add(on_configure, main_window, sub_window)
efl.ecore.fd_handler_add(
- p.stdout, efl.ecore.ECORE_FD_ALL, handle_read, p.stdout)
+ p.stdout, efl.ecore_x.ECORE_FD_ALL, handle_read, p.stdout)
efl.ecore.main_loop_begin()
diff --git a/examples/ecore/x/window_creation.py b/examples/ecore/x/window_creation.py
index f8275bb..5dc2268 100644
--- a/examples/ecore/x/window_creation.py
+++ b/examples/ecore/x/window_creation.py
@@ -1,7 +1,7 @@
#!/usr/bin/env python
import efl.ecore
-from efl.ecore.x import Window, on_window_configure_add
+from efl.ecore_x import Window, on_window_configure_add
# method 1