diff options
author | Matt Ebb <matt@mke3.net> | 2010-01-04 04:39:37 +0300 |
---|---|---|
committer | Matt Ebb <matt@mke3.net> | 2010-01-04 04:39:37 +0300 |
commit | 3881bb5309a87818b14140c7c6bc88561612adb2 (patch) | |
tree | 99e0427613c7ceb79e61a1de44382e4e21aa5bdf /release/scripts/op | |
parent | a37aa8d11d8881db9e97710e81230b030aa40a22 (diff) |
Fix for previous commit - broke WM_OT_context_set_* operators for non float/int types.
Diffstat (limited to 'release/scripts/op')
-rw-r--r-- | release/scripts/op/wm.py | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/release/scripts/op/wm.py b/release/scripts/op/wm.py index 230a3b8b492..e866769959a 100644 --- a/release/scripts/op/wm.py +++ b/release/scripts/op/wm.py @@ -61,10 +61,15 @@ def context_path_validate(context, path): def execute_context_assign(self, context): if context_path_validate(context, self.properties.path) is Ellipsis: return {'PASS_THROUGH'} - if self.properties.relative: - exec("context.%s+=self.properties.value" % self.properties.path) - else: - exec("context.%s=self.properties.value" % self.properties.path) + + try: + if self.properties.relative: + exec("context.%s+=self.properties.value" % self.properties.path) + return {'FINISHED'} + except AttributeError: + pass # no relative property exists + + exec("context.%s=self.properties.value" % self.properties.path) return {'FINISHED'} |