- finally a way to force removal of images (Shift+Click on the X)
[blender.git] / release / scripts / op / wm.py
index f033efc6b690a4557e8406a0fff8db2824fd8d50..4325475c1306e9fcb41f82f625183684bcbbd487 100644 (file)
@@ -338,7 +338,10 @@ class WM_OT_context_modal_mouse(bpy.types.Operator):
 
         path_item = self.properties.path_item
         for item, value_orig in self._values.items():
-            exec("item.%s = %s" % (path_item, value_orig + delta))
+            if type(value_orig) == int:
+                exec("item.%s = int(%d)" % (path_item, round(value_orig + delta)))
+            else:
+                exec("item.%s = %f" % (path_item, value_orig + delta))
 
     def _values_restore(self):
         path_item = self.properties.path_item