[PATCH 1/4] [gi-demos] dont try and run demos that represent directories
- From: John Stowers <john stowers lists gmail com>
- To: python-hackers-list gnome org
- Subject: [PATCH 1/4] [gi-demos] dont try and run demos that represent directories
- Date: Mon, 7 Mar 2011 00:19:37 +1300
From: John Stowers <john stowers gmail com>
---
demos/gtk-demo/gtk-demo.py | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/demos/gtk-demo/gtk-demo.py b/demos/gtk-demo/gtk-demo.py
index 74c0e69..feeaa1a 100755
--- a/demos/gtk-demo/gtk-demo.py
+++ b/demos/gtk-demo/gtk-demo.py
@@ -215,7 +215,8 @@ class GtkDemoApp(object):
def row_activated_cb(self, view, path, col, store):
treeiter = store.get_iter(path)
demo = store.get_value(treeiter, 1)
- demo.module.main(self)
+ if not demo.isdir:
+ demo.module.main(self)
def create_tree(self):
tree_store = Gtk.TreeStore(str, Demo, Pango.Style)
--
1.7.1
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]