[Libreoffice-commits] core.git: include/svtools svtools/source

Noel Grandin noel.grandin at collabora.co.uk
Fri Aug 18 16:43:33 UTC 2017


 include/svtools/tabbar.hxx        |    7 -------
 svtools/source/control/tabbar.cxx |   21 +--------------------
 2 files changed, 1 insertion(+), 27 deletions(-)

New commits:
commit fd2c6137ea45e0587a56bf219b1e5d8fb72cce03
Author: Noel Grandin <noel.grandin at collabora.co.uk>
Date:   Fri Aug 18 14:45:17 2017 +0200

    WB_TOPBORDER,WB_3DTAB are dead
    
    since
    
        commit 8ab086b6cc054501bfbf7ef6fa509c393691e860
        initial import
    
    Change-Id: Icbbf01de92c6dab4f9f94052cda784326a051ad8
    Reviewed-on: https://gerrit.libreoffice.org/41295
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>

diff --git a/include/svtools/tabbar.hxx b/include/svtools/tabbar.hxx
index 5be67be2efec..8cef7ff434d6 100644
--- a/include/svtools/tabbar.hxx
+++ b/include/svtools/tabbar.hxx
@@ -36,8 +36,6 @@ WB_MINSCROLL    - The tabs can be scrolled via 2 additional buttons
 WB_RANGESELECT  - Connected ranges can be selected
 WB_MULTISELECT  - single tabs can be selected
 WB_BORDER       - a border is drawn in the top and in the bottom
-WB_TOPBORDER    - a border is drawn in the top
-WB_3DTAB        - the tabs and the border are drawn in 3D
 WB_DRAG         - A StartDrag handler is called by the TabBar, if drag
                   and drop should be started. In addition, drag and drop
                   is activated in the TabBar with EnableDrop().
@@ -45,9 +43,6 @@ WB_SIZEABLE     - a Split handler is called by the TabBar, if the user
                   wants to change the width of the TabBar
 WB_STDTABBAR    - WB_BORDER
 
-If the TabBar should be used for example as Property bar, the WinBits
-WB_TOPBORDER and WB_3DTAB should be set instead of WB_BORDER.
-
 
 Allowed PageBits
 -----------------
@@ -268,8 +263,6 @@ class Button;
 
 #define WB_RANGESELECT      ((WinBits)0x00200000)
 #define WB_MULTISELECT      ((WinBits)0x00400000)
-#define WB_TOPBORDER        ((WinBits)0x04000000)
-#define WB_3DTAB            ((WinBits)0x08000000)
 #define WB_MINSCROLL        ((WinBits)0x20000000)
 #define WB_INSERTTAB        ((WinBits)0x40000000)
 #define WB_STDTABBAR        WB_BORDER
diff --git a/svtools/source/control/tabbar.cxx b/svtools/source/control/tabbar.cxx
index a1d5218786a9..8ca68320d8eb 100644
--- a/svtools/source/control/tabbar.cxx
+++ b/svtools/source/control/tabbar.cxx
@@ -78,18 +78,11 @@ public:
         WinBits nWinStyle = mrParent.GetStyle();
 
         // draw extra line if above and below border
-        if ((nWinStyle & WB_BORDER) || (nWinStyle & WB_TOPBORDER))
+        if (nWinStyle & WB_BORDER)
         {
             Size aOutputSize(mrParent.GetOutputSizePixel());
             tools::Rectangle aOutRect = mrParent.GetPageArea();
 
-            // also draw border in 3D for 3D-tabs
-            if (nWinStyle & WB_3DTAB)
-            {
-                mrRenderContext.SetLineColor(mrStyleSettings.GetShadowColor());
-                mrRenderContext.DrawLine(Point(aOutRect.Left(), 0), Point(aOutputSize.Width(), 0));
-            }
-
             // draw border (line above and line below)
             mrRenderContext.SetLineColor(mrStyleSettings.GetDarkShadowColor());
             mrRenderContext.DrawLine(aOutRect.TopLeft(), Point(aOutputSize.Width() - 1, aOutRect.Top()));
@@ -552,9 +545,6 @@ void TabBar::ImplInit( WinBits nWinStyle )
     mbMirrored      = false;
     mbScrollAlwaysEnabled = false;
 
-    if ( nWinStyle & WB_3DTAB )
-        mnOffY++;
-
     ImplInitControls();
 
     if (mpImpl->mpFirstButton)
@@ -645,15 +635,6 @@ void TabBar::ImplGetColors(const StyleSettings& rStyleSettings,
         rFaceTextColor = rStyleSettings.GetButtonTextColor();
     rSelectColor = rStyleSettings.GetActiveTabColor();
     rSelectTextColor = rStyleSettings.GetWindowTextColor();
-
-    // For 3D-tabs the selection- and face-colours are swapped,
-    // as the selected tabs should appear in 3D
-    if (mnWinStyle & WB_3DTAB)
-    {
-        using std::swap;
-        swap(rFaceColor, rSelectColor);
-        swap(rFaceTextColor, rSelectTextColor);
-    }
 }
 
 bool TabBar::ImplCalcWidth()


More information about the Libreoffice-commits mailing list