Commit: 9599ed3ba7627054ce2e8543da90f86b8ff36c23
Author: Julian Eisel
Date:   Fri Apr 13 10:30:47 2018 +0200
Branches: blender2.8
https://developer.blender.org/rB9599ed3ba7627054ce2e8543da90f86b8ff36c23

UI: Activate (unused) tab button-type on press instead of release

Even if we want to support drag & drop, seems like most other apps that
support drag & drop for tabs activate the tab first anyway.

===================================================================

M       source/blender/editors/interface/interface_handlers.c

===================================================================

diff --git a/source/blender/editors/interface/interface_handlers.c 
b/source/blender/editors/interface/interface_handlers.c
index b95bf466186..11f78967315 100644
--- a/source/blender/editors/interface/interface_handlers.c
+++ b/source/blender/editors/interface/interface_handlers.c
@@ -3879,7 +3879,7 @@ static int ui_do_but_KEYEVT(
 static int ui_do_but_TAB(bContext *C, uiBut *but, uiHandleButtonData *data, 
const wmEvent *event)
 {
        if (data->state == BUTTON_STATE_HIGHLIGHT) {
-               if (ELEM(event->type, LEFTMOUSE, PADENTER, RETKEY) && 
event->val == KM_RELEASE) {
+               if (ELEM(event->type, LEFTMOUSE, PADENTER, RETKEY) && 
event->val == KM_PRESS) {
                        button_activate_state(C, but, BUTTON_STATE_EXIT);
                        return WM_UI_HANDLER_CONTINUE;
                }

_______________________________________________
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
https://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to