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

Caolán McNamara caolanm at redhat.com
Tue Apr 28 12:32:10 PDT 2015


 include/vcl/salnativewidgets.hxx              |    5 ++++-
 vcl/source/control/tabctrl.cxx                |    3 +--
 vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx |   10 ++++++++--
 3 files changed, 13 insertions(+), 5 deletions(-)

New commits:
commit 41ffc1ab18d9ea7cc35278970fbe29db70005ab5
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Tue Apr 28 17:32:14 2015 +0100

    introduce a CTRL_TAB_HEADER zone
    
    Change-Id: If2740c91b9080cbbfe738b5235bc8612ab7580ba

diff --git a/include/vcl/salnativewidgets.hxx b/include/vcl/salnativewidgets.hxx
index 4485149..7ec4391 100644
--- a/include/vcl/salnativewidgets.hxx
+++ b/include/vcl/salnativewidgets.hxx
@@ -84,8 +84,11 @@ typedef sal_uInt32      ControlType;
 // the active tab
 #define CTRL_TAB_PANE           55
 
+// The background to the tab area
+#define CTRL_TAB_HEADER         56
+
 // Background of a Tab Pane
-#define CTRL_TAB_BODY           56
+#define CTRL_TAB_BODY           57
 
 // Normal scrollbar, including
 // all parts like slider, buttons
commit 2dbfc83574d3446e4aff6b155db3d521445c3746
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Tue Apr 28 17:22:38 2015 +0100

    trivial clarification
    
    Change-Id: Ic75ad6e2981af607989cecee47ce8d660174cb14

diff --git a/vcl/source/control/tabctrl.cxx b/vcl/source/control/tabctrl.cxx
index 515697e..f9df33f 100644
--- a/vcl/source/control/tabctrl.cxx
+++ b/vcl/source/control/tabctrl.cxx
@@ -1101,7 +1101,6 @@ void TabControl::ImplPaint( const Rectangle& rRect, bool bLayout )
         const ImplControlValue aControlValue;
 
         ControlState nState = ControlState::ENABLED;
-        int part = PART_ENTIRE_CONTROL;
         if ( !IsEnabled() )
             nState &= ~ControlState::ENABLED;
         if ( HasFocus() )
@@ -1113,7 +1112,7 @@ void TabControl::ImplPaint( const Rectangle& rRect, bool bLayout )
             aClipRgn.Intersect( rRect );
 
         if( !aClipRgn.IsEmpty() )
-            bNativeOK = DrawNativeControl( CTRL_TAB_PANE, part, aRect, nState,
+            bNativeOK = DrawNativeControl( CTRL_TAB_PANE, PART_ENTIRE_CONTROL, aRect, nState,
                 aControlValue, OUString() );
     }
     else
commit 2cc92727f50ce3ea52aef6364f6adb2b27c52cb5
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Tue Apr 28 16:56:43 2015 +0100

    gtk3: render notebook pane for tab controls
    
    Change-Id: Ie10163d652a8d918daf0c2b7d807c1658deba742

diff --git a/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx b/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx
index e615df0..acb542f 100644
--- a/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx
+++ b/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx
@@ -929,6 +929,9 @@ bool GtkSalGraphics::drawNativeControl( ControlType nType, ControlPart nPart, co
     case CTRL_TAB_BODY:
         return true;
         break;
+    case CTRL_TAB_PANE:
+        context = mpNoteBookStyle;
+        break;
     case CTRL_TAB_ITEM:
         context = mpNoteBookStyle;
         if (nState & ControlState::SELECTED)
@@ -1537,7 +1540,7 @@ bool GtkSalGraphics::IsNativeControlSupported( ControlType nType, ControlPart nP
 //            return true;
 
         case CTRL_TAB_ITEM:
-//        case CTRL_TAB_PANE:
+        case CTRL_TAB_PANE:
         case CTRL_TAB_BODY:
             if(nPart==PART_ENTIRE_CONTROL || nPart==PART_TABS_DRAW_RTL)
                 return true;
commit abf118c1cc4cf1422c304de9d48981060a7454e9
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Tue Apr 28 16:52:12 2015 +0100

    gtk3: make CTRL_TAB_BODY a successful no-op like gtk2
    
    Change-Id: Icdd065e4c75df65fdcd287802fdb70e5e84be60c

diff --git a/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx b/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx
index 268fd2d..e615df0 100644
--- a/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx
+++ b/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx
@@ -926,6 +926,9 @@ bool GtkSalGraphics::drawNativeControl( ControlType nType, ControlPart nPart, co
             break;
         }
         break;
+    case CTRL_TAB_BODY:
+        return true;
+        break;
     case CTRL_TAB_ITEM:
         context = mpNoteBookStyle;
         if (nState & ControlState::SELECTED)
@@ -1535,7 +1538,7 @@ bool GtkSalGraphics::IsNativeControlSupported( ControlType nType, ControlPart nP
 
         case CTRL_TAB_ITEM:
 //        case CTRL_TAB_PANE:
-//        case CTRL_TAB_BODY:
+        case CTRL_TAB_BODY:
             if(nPart==PART_ENTIRE_CONTROL || nPart==PART_TABS_DRAW_RTL)
                 return true;
             break;


More information about the Libreoffice-commits mailing list