Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2018-05-22 15:00:44 +0300
committerCampbell Barton <ideasman42@gmail.com>2018-05-22 16:31:06 +0300
commit96a7ed8a159fec97ab19a6d19ffe6201a4ee2b35 (patch)
treead7164dbc343e62551de15e96c3bdb4841560453 /source/blender/makesdna/DNA_workspace_types.h
parent298f8042efe12b4a8861a83c860b3adb0d56f1f6 (diff)
Tool System: store operator properties in the tool
This replaces last-used property use which wasn't reliable since properties were not considered 'set' - causing them to be ignored.
Diffstat (limited to 'source/blender/makesdna/DNA_workspace_types.h')
-rw-r--r--source/blender/makesdna/DNA_workspace_types.h13
1 files changed, 12 insertions, 1 deletions
diff --git a/source/blender/makesdna/DNA_workspace_types.h b/source/blender/makesdna/DNA_workspace_types.h
index 24fa0e06d90..ca9186e16bf 100644
--- a/source/blender/makesdna/DNA_workspace_types.h
+++ b/source/blender/makesdna/DNA_workspace_types.h
@@ -56,11 +56,13 @@
#
#
typedef struct bToolRef_Runtime {
- /* One of these must be defined. */
int cursor;
+
+ /* One of these 3 must be defined. */
char keymap[64];
char manipulator_group[64];
char data_block[64];
+
/* index when a tool is a member of a group */
int index;
} bToolRef_Runtime;
@@ -82,6 +84,15 @@ typedef struct bToolRef {
*/
int mode;
+ /**
+ * Use for tool options, each group's name must match a tool name:
+ *
+ * {"Tool Name": {"SOME_OT_operator": {...}, ..}, ..}
+ *
+ * This is done since different tools may call the same operators with their own options.
+ */
+ IDProperty *properties;
+
/** Variables needed to operate the tool. */
bToolRef_Runtime *runtime;
} bToolRef;