[Bf-extensions-cvs] SVN commit: /data/svn/bf-extensions [916] trunk/py/scripts/addons: update for api changes

Campbell Barton ideasman42 at gmail.com
Tue Aug 17 17:59:53 CEST 2010


Revision: 916
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-extensions&revision=916
Author:   campbellbarton
Date:     2010-08-17 17:59:53 +0200 (Tue, 17 Aug 2010)

Log Message:
-----------
update for api changes

Modified Paths:
--------------
    trunk/py/scripts/addons/add_curve_aceous_galore.py
    trunk/py/scripts/addons/add_curve_torus_knots.py
    trunk/py/scripts/addons/add_mesh_BoltFactory/original_script_add_mesh_bolt.py
    trunk/py/scripts/addons/add_mesh_ant_landscape.py
    trunk/py/scripts/addons/add_mesh_solid.py
    trunk/py/scripts/addons/curve_simplify.py

Modified: trunk/py/scripts/addons/add_curve_aceous_galore.py
===================================================================
--- trunk/py/scripts/addons/add_curve_aceous_galore.py	2010-08-17 08:23:46 UTC (rev 915)
+++ trunk/py/scripts/addons/add_curve_aceous_galore.py	2010-08-17 15:59:53 UTC (rev 916)
@@ -1070,8 +1070,8 @@
     ##### EXECUTE #####
     def execute(self, context):
         # turn off undo
-        undo = bpy.context.user_preferences.edit.global_undo
-        bpy.context.user_preferences.edit.global_undo = False
+        undo = bpy.context.user_preferences.edit.use_global_undo
+        bpy.context.user_preferences.edit.use_global_undo = False
 
         # deal with 2D - 3D curve differences
         props = self.properties
@@ -1090,7 +1090,7 @@
         main(context, props, self.align_matrix)
         
         # restore pre operator undo state
-        bpy.context.user_preferences.edit.global_undo = undo
+        bpy.context.user_preferences.edit.use_global_undo = undo
 
         return {'FINISHED'}
 

Modified: trunk/py/scripts/addons/add_curve_torus_knots.py
===================================================================
--- trunk/py/scripts/addons/add_curve_torus_knots.py	2010-08-17 08:23:46 UTC (rev 915)
+++ trunk/py/scripts/addons/add_curve_torus_knots.py	2010-08-17 15:59:53 UTC (rev 916)
@@ -280,8 +280,8 @@
     ##### EXECUTE #####
     def execute(self, context):
         # turn off undo
-        undo = bpy.context.user_preferences.edit.global_undo
-        bpy.context.user_preferences.edit.global_undo = False
+        undo = bpy.context.user_preferences.edit.use_global_undo
+        bpy.context.user_preferences.edit.use_global_undo = False
 
         props = self.properties
 
@@ -292,7 +292,7 @@
         main(context, props, self.align_matrix)
         
         # restore pre operator undo state
-        bpy.context.user_preferences.edit.global_undo = undo
+        bpy.context.user_preferences.edit.use_global_undo = undo
 
         return {'FINISHED'}
 

Modified: trunk/py/scripts/addons/add_mesh_BoltFactory/original_script_add_mesh_bolt.py
===================================================================
--- trunk/py/scripts/addons/add_mesh_BoltFactory/original_script_add_mesh_bolt.py	2010-08-17 08:23:46 UTC (rev 915)
+++ trunk/py/scripts/addons/add_mesh_BoltFactory/original_script_add_mesh_bolt.py	2010-08-17 15:59:53 UTC (rev 916)
@@ -2517,7 +2517,7 @@
         bpy.ops.object.mode_set(mode='EDIT')
     else:
         scene.objects.active = ob_new
-        if context.user_preferences.edit.enter_edit_mode:
+        if context.user_preferences.edit.use_enter_edit_mode:
             bpy.ops.object.mode_set(mode='EDIT')
 
 

Modified: trunk/py/scripts/addons/add_mesh_ant_landscape.py
===================================================================
--- trunk/py/scripts/addons/add_mesh_ant_landscape.py	2010-08-17 08:23:46 UTC (rev 915)
+++ trunk/py/scripts/addons/add_mesh_ant_landscape.py	2010-08-17 15:59:53 UTC (rev 916)
@@ -669,8 +669,8 @@
     # Execute
     def execute(self, context):
         # turn off undo
-        undo = bpy.context.user_preferences.edit.global_undo
-        bpy.context.user_preferences.edit.global_undo = False
+        undo = bpy.context.user_preferences.edit.use_global_undo
+        bpy.context.user_preferences.edit.use_global_undo = False
 
         # deselect all objects
         bpy.ops.object.select_all(action='DESELECT')
@@ -734,7 +734,7 @@
 
         obj = create_mesh_object(context, verts, [], faces, "Landscape", edit, self.align_matrix)
         # restore pre operator undo state
-        bpy.context.user_preferences.edit.global_undo = undo
+        bpy.context.user_preferences.edit.use_global_undo = undo
         return {'FINISHED'}
 
     def invoke(self, context, event):

Modified: trunk/py/scripts/addons/add_mesh_solid.py
===================================================================
--- trunk/py/scripts/addons/add_mesh_solid.py	2010-08-17 08:23:46 UTC (rev 915)
+++ trunk/py/scripts/addons/add_mesh_solid.py	2010-08-17 15:59:53 UTC (rev 916)
@@ -741,7 +741,7 @@
     def execute(self,context):
         # turn off undo for better performance (3 - 5x faster), also makes sure
         #  that mesh ops are undoable and entire script acts as one operator
-        bpy.context.user_preferences.edit.global_undo = False
+        bpy.context.user_preferences.edit.use_global_undo = False
 
         props = self.properties
 
@@ -794,7 +794,7 @@
             bpy.ops.object.mode_set(mode=current_mode)
 
         # turn undo back on
-        bpy.context.user_preferences.edit.global_undo = True 
+        bpy.context.user_preferences.edit.use_global_undo = True 
 
         return {'FINISHED'}
 

Modified: trunk/py/scripts/addons/curve_simplify.py
===================================================================
--- trunk/py/scripts/addons/curve_simplify.py	2010-08-17 08:23:46 UTC (rev 915)
+++ trunk/py/scripts/addons/curve_simplify.py	2010-08-17 15:59:53 UTC (rev 916)
@@ -569,14 +569,14 @@
                 self.properties.keepShort]  #7
 
 
-        bpy.context.user_preferences.edit.global_undo = False
+        bpy.context.user_preferences.edit.use_global_undo = False
 
         bpy.ops.object.mode_set(mode='OBJECT', toggle=True)
         obj = context.active_object
 
         main(context, obj, options)
 
-        bpy.context.user_preferences.edit.global_undo = True
+        bpy.context.user_preferences.edit.use_global_undo = True
 
         #print("-------END-------")
         return {'FINISHED'}




More information about the Bf-extensions-cvs mailing list