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:
authorJoshua Leung <aligorith@gmail.com>2015-09-19 02:43:45 +0300
committerJoshua Leung <aligorith@gmail.com>2015-09-19 02:43:45 +0300
commit5b02f2a0a2902441fef2e891ec56ff17cb12d5ed (patch)
treee45bfe0b1274ba459530ed289ff6c5d899280ab5 /source/blender/makesrna/intern/rna_wm.c
parentf7250246d7fe420893cb904c9619dc0e9e7562ef (diff)
Added support for tablet pen and eraser events to be added to keymaps
Added two new event types that will fire only when using a stylus or its eraser. The use case for this is to allow artists to be able to set up their keymaps so that they can just draw and erase directly using their tablet without holding down any keys.
Diffstat (limited to 'source/blender/makesrna/intern/rna_wm.c')
-rw-r--r--source/blender/makesrna/intern/rna_wm.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/makesrna/intern/rna_wm.c b/source/blender/makesrna/intern/rna_wm.c
index aa4bfe0462e..978aa5f9571 100644
--- a/source/blender/makesrna/intern/rna_wm.c
+++ b/source/blender/makesrna/intern/rna_wm.c
@@ -86,6 +86,9 @@ static EnumPropertyItem event_mouse_type_items[] = {
{ACTIONMOUSE, "ACTIONMOUSE", 0, "Action", ""},
{SELECTMOUSE, "SELECTMOUSE", 0, "Select", ""},
{0, "", 0, NULL, NULL},
+ {TABLET_STYLUS, "PEN", 0, "Pen", ""},
+ {TABLET_ERASER, "ERASER", 0, "Eraser", ""},
+ {0, "", 0, NULL, NULL},
{MOUSEMOVE, "MOUSEMOVE", 0, "Move", ""},
{MOUSEPAN, "TRACKPADPAN", 0, "Mouse/Trackpad Pan", ""},
{MOUSEZOOM, "TRACKPADZOOM", 0, "Mouse/Trackpad Zoom", ""},
@@ -180,6 +183,9 @@ EnumPropertyItem event_type_items[] = {
{ACTIONMOUSE, "ACTIONMOUSE", 0, "Action Mouse", "MBA"},
{SELECTMOUSE, "SELECTMOUSE", 0, "Select Mouse", "MBS"},
{0, "", 0, NULL, NULL},
+ {TABLET_STYLUS, "PEN", 0, "Pen", ""},
+ {TABLET_ERASER, "ERASER", 0, "Eraser", ""},
+ {0, "", 0, NULL, NULL},
{MOUSEMOVE, "MOUSEMOVE", 0, "Mouse Move", "MsMov"},
{INBETWEEN_MOUSEMOVE, "INBETWEEN_MOUSEMOVE", 0, "In-between Move", "MsSubMov"},
{MOUSEPAN, "TRACKPADPAN", 0, "Mouse/Trackpad Pan", "MsPan"},