diff options
author | Campbell Barton <ideasman42@gmail.com> | 2010-08-09 05:37:09 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2010-08-09 05:37:09 +0400 |
commit | a6f13f9d7bfef7020d43cb0a8058753e6d7a128d (patch) | |
tree | 09535f0341f93288fc492c3318ba2213291345d9 /release/scripts/op/fcurve_euler_filter.py | |
parent | 7fcbbad5a45acf5b4ef49d16cf6733afd1e481c7 (diff) |
poll() as a python '@staticmethod' was too limiting and didnt allow useful base class poll functions in many cases.
now rna functions that dont have a 'self' are automatically assumed '@classmethods'.
de-duplicated poll functions and made some minor tweaks too.
Diffstat (limited to 'release/scripts/op/fcurve_euler_filter.py')
-rw-r--r-- | release/scripts/op/fcurve_euler_filter.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/release/scripts/op/fcurve_euler_filter.py b/release/scripts/op/fcurve_euler_filter.py index cc973d94e2a..c6f5ddd12e4 100644 --- a/release/scripts/op/fcurve_euler_filter.py +++ b/release/scripts/op/fcurve_euler_filter.py @@ -48,8 +48,8 @@ class DiscontFilterOp(bpy.types.Operator): bl_idname = "graph.euler_filter" bl_label = "Filter out discontinuities in the active fcurves" - @staticmethod - def poll(context): + @classmethod + def poll(cls, context): return context.active_object != None def execute(self, context): |