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:
authorJulian Eisel <julian@blender.org>2021-11-04 17:59:06 +0300
committerJulian Eisel <julian@blender.org>2021-11-04 18:02:54 +0300
commit37b862fa6cd25bd85de22857a1980a5d2fed3aac (patch)
tree1f70f71cc05f904d21a6c71676f60362f3a3f61b /source/blender/windowmanager/WM_types.h
parentdb43d19c163f999cbbe2e524ace7e29d345a1227 (diff)
Cleanup: Remove operator context override for drop-box operators
Drop-boxes should act on the context determined through the exact cursor location. There should be no need to override that, basically by the nature of how drop-boxes work. So Campbell and I agreed on removing this. If we wanted to support it, we'd have to restore the operator context when drawing drop-boxes, see https://developer.blender.org/T92501#1247581.
Diffstat (limited to 'source/blender/windowmanager/WM_types.h')
-rw-r--r--source/blender/windowmanager/WM_types.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/windowmanager/WM_types.h b/source/blender/windowmanager/WM_types.h
index 27c8aa532f2..2bb50d5efbe 100644
--- a/source/blender/windowmanager/WM_types.h
+++ b/source/blender/windowmanager/WM_types.h
@@ -1079,6 +1079,10 @@ typedef struct wmDrag {
/**
* Dropboxes are like keymaps, part of the screen/area/region definition.
* Allocation and free is on startup and exit.
+ *
+ * The operator is polled and invoked with the current context (#WM_OP_INVOKE_DEFAULT), there is no
+ * way to override that (by design, since dropboxes should act on the exact mouse position). So the
+ * drop-boxes are supposed to check the required area and region context in their poll.
*/
typedef struct wmDropBox {
struct wmDropBox *next, *prev;
@@ -1120,10 +1124,6 @@ typedef struct wmDropBox {
struct IDProperty *properties;
/** RNA pointer to access properties. */
struct PointerRNA *ptr;
-
- /** Default invoke. */
- short opcontext;
-
} wmDropBox;
/**