[pygobject/gsoc2009: 29/160] Make DynamicImporter.load_module to look for registered modules first
- From: Simon van der Linden <svdlinden src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [pygobject/gsoc2009: 29/160] Make DynamicImporter.load_module to look for registered modules first
- Date: Fri, 14 Aug 2009 21:24:31 +0000 (UTC)
commit 139b1e7749b3cfcd32122117970f630a96596819
Author: Simon van der Linden <svdlinden src gnome org>
Date: Wed Jul 8 17:05:12 2009 +0200
Make DynamicImporter.load_module to look for registered modules first
girepository/importer.py | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/girepository/importer.py b/girepository/importer.py
index 143a24f..0433241 100644
--- a/girepository/importer.py
+++ b/girepository/importer.py
@@ -36,6 +36,10 @@ class DynamicImporter(object):
return DynamicImporter(name, path)
def load_module(self, name):
+ module = repository.get_module(name)
+ if module is not None:
+ return module
+
from .module import DynamicModule
module_name = 'girepository.overrides.%s' % (name,)
try:
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]