[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [40499] branches/bmesh/blender: svn merge ^/trunk/blender -r40491:40498

Campbell Barton ideasman42 at gmail.com
Fri Sep 23 15:55:06 CEST 2011


Revision: 40499
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=40499
Author:   campbellbarton
Date:     2011-09-23 13:55:06 +0000 (Fri, 23 Sep 2011)
Log Message:
-----------
svn merge ^/trunk/blender -r40491:40498

Revision Links:
--------------
    http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=40491

Modified Paths:
--------------
    branches/bmesh/blender/release/scripts/modules/addon_utils.py
    branches/bmesh/blender/release/scripts/startup/bl_operators/wm.py
    branches/bmesh/blender/release/scripts/startup/bl_ui/__init__.py
    branches/bmesh/blender/release/scripts/startup/bl_ui/space_userpref.py
    branches/bmesh/blender/source/blender/blenkernel/intern/DerivedMesh.c

Property Changed:
----------------
    branches/bmesh/blender/
    branches/bmesh/blender/release/
    branches/bmesh/blender/source/blender/editors/space_outliner/


Property changes on: branches/bmesh/blender
___________________________________________________________________
Modified: svn:mergeinfo
   - /trunk/blender:39992-40492
   + /trunk/blender:39992-40498


Property changes on: branches/bmesh/blender/release
___________________________________________________________________
Modified: svn:mergeinfo
   - /trunk/blender/release:31524-40492
   + /trunk/blender/release:31524-40498

Modified: branches/bmesh/blender/release/scripts/modules/addon_utils.py
===================================================================
--- branches/bmesh/blender/release/scripts/modules/addon_utils.py	2011-09-23 13:47:29 UTC (rev 40498)
+++ branches/bmesh/blender/release/scripts/modules/addon_utils.py	2011-09-23 13:55:06 UTC (rev 40499)
@@ -33,6 +33,7 @@
 
 error_duplicates = False
 error_encoding = False
+addons_fake_modules = {}
 
 
 def paths():

Modified: branches/bmesh/blender/release/scripts/startup/bl_operators/wm.py
===================================================================
--- branches/bmesh/blender/release/scripts/startup/bl_operators/wm.py	2011-09-23 13:47:29 UTC (rev 40498)
+++ branches/bmesh/blender/release/scripts/startup/bl_operators/wm.py	2011-09-23 13:55:06 UTC (rev 40499)
@@ -26,9 +26,6 @@
                        FloatProperty,
                        EnumProperty,
                        )
-                       
-import addon_utils
-import os
 
 from rna_prop_ui import rna_idprop_ui_prop_get, rna_idprop_ui_prop_clear
 
@@ -758,6 +755,7 @@
 
     def execute(self, context):
         import sys
+        import os
         import subprocess
 
         filepath = bpy.path.abspath(self.filepath)
@@ -1102,6 +1100,7 @@
     bl_label = "Default Application Configuration"
 
     def execute(self, context):
+        import os
 
         context.window_manager.keyconfigs.active = context.window_manager.keyconfigs.default
 
@@ -1123,6 +1122,7 @@
             )
 
     def execute(self, context):
+        import os
         bpy.utils.keyconfig_set(self.filepath)
 
         filepath = self.filepath.replace("keyconfig", "interaction")
@@ -1150,6 +1150,7 @@
     bl_label = "Copy Previous Settings"
 
     def execute(self, context):
+        import os
         import shutil
         ver = bpy.app.version
         ver_old = ((ver[0] * 100) + ver[1]) - 1
@@ -1608,6 +1609,8 @@
             )
 
     def execute(self, context):
+        import addon_utils
+
         mod = addon_utils.enable(self.module)
 
         if mod:
@@ -1637,6 +1640,8 @@
             )
 
     def execute(self, context):
+        import addon_utils
+
         addon_utils.disable(self.module)
         return {'FINISHED'}
 
@@ -1690,6 +1695,7 @@
                     os.remove(f_full)
 
     def execute(self, context):
+        import addon_utils
         import traceback
         import zipfile
         import shutil
@@ -1725,7 +1731,7 @@
         del pyfile_dir
         # done checking for exceptional case
 
-        addons_old = {mod.__name__ for mod in addon_utils.modules(USERPREF_PT_addons._addons_fake_modules)}
+        addons_old = {mod.__name__ for mod in addon_utils.modules(addon_utils.addons_fake_modules)}
 
         #check to see if the file is in compressed format (.zip)
         if zipfile.is_zipfile(pyfile):
@@ -1774,7 +1780,7 @@
                 traceback.print_exc()
                 return {'CANCELLED'}
 
-        addons_new = {mod.__name__ for mod in addon_utils.modules(USERPREF_PT_addons._addons_fake_modules)} - addons_old
+        addons_new = {mod.__name__ for mod in addon_utils.modules(addon_utils.addons_fake_modules)} - addons_old
         addons_new.discard("modules")
 
         # disable any addons we may have enabled previously and removed.
@@ -1784,7 +1790,7 @@
 
         # possible the zip contains multiple addons, we could disallow this
         # but for now just use the first
-        for mod in addon_utils.modules(USERPREF_PT_addons._addons_fake_modules):
+        for mod in addon_utils.modules(addon_utils.addons_fake_modules):
             if mod.__name__ in addons_new:
                 info = addon_utils.module_bl_info(mod)
 
@@ -1818,7 +1824,9 @@
 
     @staticmethod
     def path_from_addon(module):
-        for mod in addon_utils.modules(USERPREF_PT_addons._addons_fake_modules):
+        import addon_utils
+
+        for mod in addon_utils.modules(addon_utils.addons_fake_modules):
             if mod.__name__ == module:
                 filepath = mod.__file__
                 if os.path.exists(filepath):
@@ -1829,6 +1837,8 @@
         return None, False
 
     def execute(self, context):
+        import addon_utils
+
         path, isdir = WM_OT_addon_remove.path_from_addon(self.module)
         if path is None:
             self.report('WARNING', "Addon path %r could not be found" % path)
@@ -1868,12 +1878,14 @@
             )
 
     def execute(self, context):
+        import addon_utils
+
         module_name = self.module
 
         # unlikely to fail, module should have already been imported
         try:
             # mod = __import__(module_name)
-            mod = USERPREF_PT_addons.module_get(module_name)
+            mod = addon_utils.addons_fake_modules.get(module_name)
         except:
             import traceback
             traceback.print_exc()

Modified: branches/bmesh/blender/release/scripts/startup/bl_ui/__init__.py
===================================================================
--- branches/bmesh/blender/release/scripts/startup/bl_ui/__init__.py	2011-09-23 13:47:29 UTC (rev 40498)
+++ branches/bmesh/blender/release/scripts/startup/bl_ui/__init__.py	2011-09-23 13:55:06 UTC (rev 40499)
@@ -96,7 +96,7 @@
 
         items_unique = set()
 
-        for mod in addon_utils.modules(space_userpref.USERPREF_PT_addons._addons_fake_modules):
+        for mod in addon_utils.modules(addon_utils.addons_fake_modules):
             info = addon_utils.module_bl_info(mod)
             items_unique.add(info["category"])
 

Modified: branches/bmesh/blender/release/scripts/startup/bl_ui/space_userpref.py
===================================================================
--- branches/bmesh/blender/release/scripts/startup/bl_ui/space_userpref.py	2011-09-23 13:47:29 UTC (rev 40498)
+++ branches/bmesh/blender/release/scripts/startup/bl_ui/space_userpref.py	2011-09-23 13:55:06 UTC (rev 40499)
@@ -891,18 +891,12 @@
     bl_region_type = 'WINDOW'
     bl_options = {'HIDE_HEADER'}
 
-    _addons_fake_modules = {}
-
     @classmethod
     def poll(cls, context):
         userpref = context.user_preferences
         return (userpref.active_section == 'ADDONS')
 
     @staticmethod
-    def module_get(mod_name):
-        return USERPREF_PT_addons._addons_fake_modules[mod_name]
-
-    @staticmethod
     def is_user_addon(mod, user_addon_paths):
         if not user_addon_paths:
             user_script_path = bpy.utils.user_script_path()
@@ -932,7 +926,7 @@
         used_ext = {ext.module for ext in userpref.addons}
 
         # collect the categories that can be filtered on
-        addons = [(mod, addon_utils.module_bl_info(mod)) for mod in addon_utils.modules(USERPREF_PT_addons._addons_fake_modules)]
+        addons = [(mod, addon_utils.module_bl_info(mod)) for mod in addon_utils.modules(addon_utils.addons_fake_modules)]
 
         split = layout.split(percentage=0.2)
         col = split.column()

Modified: branches/bmesh/blender/source/blender/blenkernel/intern/DerivedMesh.c
===================================================================
--- branches/bmesh/blender/source/blender/blenkernel/intern/DerivedMesh.c	2011-09-23 13:47:29 UTC (rev 40498)
+++ branches/bmesh/blender/source/blender/blenkernel/intern/DerivedMesh.c	2011-09-23 13:55:06 UTC (rev 40499)
@@ -1291,7 +1291,7 @@
 				 * data by using generic DM_copy_vert_data() functions.
 				 */
 				if(needMapping || (nextmask & CD_MASK_ORIGINDEX)) {
-					int i, *orig;
+					int i;
 					
 					/* calc */
 					DM_add_vert_layer(dm, CD_ORIGINDEX, CD_CALLOC, NULL);


Property changes on: branches/bmesh/blender/source/blender/editors/space_outliner
___________________________________________________________________
Modified: svn:mergeinfo
   - /branches/soc-2011-pepper/source/blender/editors/space_outliner:36831-38987
/trunk/blender/source/blender/editors/space_outliner:31524-40492
   + /branches/soc-2011-pepper/source/blender/editors/space_outliner:36831-38987
/trunk/blender/source/blender/editors/space_outliner:31524-40498




More information about the Bf-blender-cvs mailing list