From ee0903f520403c5e03caef287f813e7b062d05ab Mon Sep 17 00:00:00 2001 From: Felix Domke Date: Sat, 17 Jun 2006 16:48:40 +0000 Subject: add some new (currently unused) source/renderer based elements --- lib/python/Tools/CList.py | 7 +++++++ lib/python/Tools/Makefile.am | 3 ++- 2 files changed, 9 insertions(+), 1 deletion(-) create mode 100644 lib/python/Tools/CList.py (limited to 'lib/python/Tools') diff --git a/lib/python/Tools/CList.py b/lib/python/Tools/CList.py new file mode 100644 index 00000000..d820175c --- /dev/null +++ b/lib/python/Tools/CList.py @@ -0,0 +1,7 @@ +class CList(list): + def __getattr__(self, attr): + return CList([getattr(a, attr) for a in self]) + + def __call__(self, *args, **kwargs): + for x in self: + x(*args, **kwargs) diff --git a/lib/python/Tools/Makefile.am b/lib/python/Tools/Makefile.am index 2521cd97..4828e1fb 100644 --- a/lib/python/Tools/Makefile.am +++ b/lib/python/Tools/Makefile.am @@ -3,4 +3,5 @@ installdir = $(LIBDIR)/enigma2/python/Tools install_DATA = \ FuzzyDate.py XMLTools.py Directories.py NumericalTextInput.py \ KeyBindings.py BoundFunction.py ISO639.py Notifications.py __init__.py \ - RedirectOutput.py DreamboxHardware.py Import.py Event.py + RedirectOutput.py DreamboxHardware.py Import.py Event.py CList.py + -- cgit v1.2.3