diff options
author | Campbell Barton <ideasman42@gmail.com> | 2014-06-18 10:01:51 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2014-06-18 10:01:51 +0400 |
commit | 3c63eee7b4ee63619375d2ec57cf2d806e46175a (patch) | |
tree | 0f5e08762cc37824c1f3a5094b480ffacae8f45f /source/blender/editors | |
parent | b16bf6c3d4204ba5399f9854f7888630e984fe59 (diff) |
Code cleanup: replace 0 with OB_MODE_OBJECT
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/screen/screen_ops.c | 2 | ||||
-rw-r--r-- | source/blender/editors/util/ed_util.c | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/editors/screen/screen_ops.c b/source/blender/editors/screen/screen_ops.c index 8b6a1b22a5c..eb79b0ca550 100644 --- a/source/blender/editors/screen/screen_ops.c +++ b/source/blender/editors/screen/screen_ops.c @@ -166,7 +166,7 @@ int ED_operator_objectmode(bContext *C) return 0; /* add a check for ob->mode too? */ - if (obact && obact->mode) + if (obact && (obact->mode != OB_MODE_OBJECT)) return 0; return 1; diff --git a/source/blender/editors/util/ed_util.c b/source/blender/editors/util/ed_util.c index 178af8c836a..4dfaed98aab 100644 --- a/source/blender/editors/util/ed_util.c +++ b/source/blender/editors/util/ed_util.c @@ -96,8 +96,8 @@ void ED_editors_init(bContext *C) for (ob = bmain->object.first; ob; ob = ob->id.next) { int mode = ob->mode; - if (mode && (mode != OB_MODE_POSE)) { - ob->mode = 0; + if (!ELEM(mode, OB_MODE_OBJECT, OB_MODE_POSE)) { + ob->mode = OB_MODE_OBJECT; data = ob->data; if (ob == obact && !ob->id.lib && !(data && data->lib)) |