[Libreoffice-commits] core.git: vcl/source

Caolán McNamara caolanm at redhat.com
Tue Nov 8 21:18:51 UTC 2016


 vcl/source/window/event.cxx |    7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

New commits:
commit 13203033fb41a8e585660134655c314691303fa4
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Tue Nov 8 21:15:54 2016 +0000

    Resolves: tdf#103783 do consider parent of WB_DIALOGCONTROL widgets...
    
    for tab cycling, given the problem of tdf#103783
    
    regression from...
    
    commit fd40e3ea09a481a2e97452d2244ecdfd6c3508c1
    Author: Caolán McNamara <caolanm at redhat.com>
    Date:   Tue Nov 1 16:34:22 2016 +0000
    
        lock tab-cycling inside the WB_DIALOGCONTROL widget
    
        activate the color selector in the toolbar in the sidebar panel, press tab
        to cycle between its widgets, when it hits the bottom it will
        not return to the first widget, but escape out of the floating
        window into the next sibling of the toolbar
    
    but only check the Parent, not RealParent
    
    Change-Id: I9577a0a9f3a622373c195e77ca43d17511b4154d

diff --git a/vcl/source/window/event.cxx b/vcl/source/window/event.cxx
index 7eb98cf..ca1439f 100644
--- a/vcl/source/window/event.cxx
+++ b/vcl/source/window/event.cxx
@@ -169,9 +169,14 @@ bool Window::Notify( NotifyEvent& rNEvt )
     // manage the dialogs
     if ( (GetStyle() & (WB_DIALOGCONTROL | WB_NODIALOGCONTROL)) == WB_DIALOGCONTROL )
     {
+        // if the parent also has dialog control activated, the parent takes over control
         if ( (rNEvt.GetType() == MouseNotifyEvent::KEYINPUT) || (rNEvt.GetType() == MouseNotifyEvent::KEYUP) )
         {
-            bRet = ImplDlgCtrl(*rNEvt.GetKeyEvent(), rNEvt.GetType() == MouseNotifyEvent::KEYINPUT);
+            if ( ImplIsOverlapWindow() ||
+                 ((getNonLayoutParent(this)->GetStyle() & (WB_DIALOGCONTROL | WB_NODIALOGCONTROL)) != WB_DIALOGCONTROL) )
+            {
+                bRet = ImplDlgCtrl( *rNEvt.GetKeyEvent(), rNEvt.GetType() == MouseNotifyEvent::KEYINPUT );
+            }
         }
         else if ( (rNEvt.GetType() == MouseNotifyEvent::GETFOCUS) || (rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS) )
         {


More information about the Libreoffice-commits mailing list