Fix manipulator handles getting added each refresh
The same manipulator map handler would accumulate, slowing down interactions.
This commit is contained in:
parent
ac0da72a60
commit
122706db9c
Notes:
blender-bot
2023-02-14 06:27:47 +01:00
Referenced by commit 49c0ad1188
, Revert "Fix manipulator handles getting added each refresh"
|
@ -680,8 +680,9 @@ static void image_main_region_init(wmWindowManager *wm, ARegion *ar)
|
|||
.regionid = RGN_TYPE_WINDOW,
|
||||
};
|
||||
ar->manipulator_map = WM_manipulatormap_new_from_type(&wmap_params);
|
||||
|
||||
WM_manipulatormap_add_handlers(ar, ar->manipulator_map);
|
||||
}
|
||||
WM_manipulatormap_add_handlers(ar, ar->manipulator_map);
|
||||
|
||||
/* mask polls mode */
|
||||
keymap = WM_keymap_find(wm->defaultconf, "Mask Editing", 0, 0);
|
||||
|
|
|
@ -649,9 +649,9 @@ static void node_main_region_init(wmWindowManager *wm, ARegion *ar)
|
|||
if (ar->manipulator_map == NULL) {
|
||||
ar->manipulator_map = WM_manipulatormap_new_from_type(
|
||||
&(const struct wmManipulatorMapType_Params){SPACE_NODE, RGN_TYPE_WINDOW});
|
||||
}
|
||||
|
||||
WM_manipulatormap_add_handlers(ar, ar->manipulator_map);
|
||||
WM_manipulatormap_add_handlers(ar, ar->manipulator_map);
|
||||
}
|
||||
|
||||
/* own keymaps */
|
||||
keymap = WM_keymap_find(wm->defaultconf, "Node Generic", SPACE_NODE, 0);
|
||||
|
|
|
@ -494,9 +494,9 @@ static void view3d_main_region_init(wmWindowManager *wm, ARegion *ar)
|
|||
if (ar->manipulator_map == NULL) {
|
||||
ar->manipulator_map = WM_manipulatormap_new_from_type(
|
||||
&(const struct wmManipulatorMapType_Params) {SPACE_VIEW3D, RGN_TYPE_WINDOW});
|
||||
}
|
||||
|
||||
WM_manipulatormap_add_handlers(ar, ar->manipulator_map);
|
||||
WM_manipulatormap_add_handlers(ar, ar->manipulator_map);
|
||||
}
|
||||
|
||||
/* object ops. */
|
||||
|
||||
|
|
Loading…
Reference in New Issue