[Libreoffice-commits] core.git: include/tools rsc/inc rsc/source vcl/source
Noel Grandin
noelgrandin at gmail.com
Fri May 27 08:32:15 UTC 2016
include/tools/rc.h | 6 ------
rsc/inc/rscdb.hxx | 3 +--
rsc/source/parser/rscicpx.cxx | 17 +----------------
rsc/source/parser/rscinit.cxx | 2 +-
vcl/source/window/dockwin.cxx | 33 +--------------------------------
5 files changed, 4 insertions(+), 57 deletions(-)
New commits:
commit c8754b38ce205845aad5cde3c5ad4070ce38f7d5
Author: Noel Grandin <noelgrandin at gmail.com>
Date: Wed May 25 20:06:26 2016 +0200
remove unused RSC_DOCKWINDOW flags
Change-Id: I2e2d82760b10876a7cf2a8cfb375926eb24d23e4
Reviewed-on: https://gerrit.libreoffice.org/25462
Reviewed-by: Noel Grandin <noelgrandin at gmail.com>
Tested-by: Noel Grandin <noelgrandin at gmail.com>
diff --git a/include/tools/rc.h b/include/tools/rc.h
index cd09254..bb6cb3b 100644
--- a/include/tools/rc.h
+++ b/include/tools/rc.h
@@ -137,12 +137,6 @@ namespace o3tl {
#define RSC_TOOLBOX_ITEMIMAGELIST 0x40
#define RSC_TOOLBOX_ITEMLIST 0x80
-// For "DockingWindow" resources:
-#define RSC_DOCKINGWINDOW_XYMAPMODE 0x01
-#define RSC_DOCKINGWINDOW_X 0x02
-#define RSC_DOCKINGWINDOW_Y 0x04
-#define RSC_DOCKINGWINDOW_FLOATING 0x08
-
// For "ImageButtons":
enum class RscImageButtonFlags {
Image = 0x01,
diff --git a/rsc/inc/rscdb.hxx b/rsc/inc/rscdb.hxx
index 1fbbb18..adf801f 100644
--- a/rsc/inc/rscdb.hxx
+++ b/rsc/inc/rscdb.hxx
@@ -205,8 +205,7 @@ class RscTypCont
RscTop * InitClassNumericField( RscTop * pSuper );
RscTop * InitClassMetricField( RscTop * pSuper );
- RscTop * InitClassDockingWindow( RscTop * pSuper,
- RscEnum * pMapUnit );
+ RscTop * InitClassDockingWindow( RscTop * pSuper );
RscTop * InitClassToolBoxItem( RscTop * pSuper, RscTop * pClassBitmap,
RscTop * pClassImage,
RscEnum * pTriState );
diff --git a/rsc/source/parser/rscicpx.cxx b/rsc/source/parser/rscicpx.cxx
index ae3b865..30a56b4 100644
--- a/rsc/source/parser/rscicpx.cxx
+++ b/rsc/source/parser/rscicpx.cxx
@@ -897,8 +897,7 @@ RscTop * RscTypCont::InitClassMetricField( RscTop * pSuper )
return pClassMetricField;
}
-RscTop * RscTypCont::InitClassDockingWindow( RscTop * pSuper,
- RscEnum * pMapUnit )
+RscTop * RscTypCont::InitClassDockingWindow( RscTop * pSuper )
{
Atom nId;
RscTop * pClassDockWindow;
@@ -909,20 +908,6 @@ RscTop * RscTypCont::InitClassDockingWindow( RscTop * pSuper,
pClassDockWindow->SetCallPar( *pWinPar1, *pWinPar2, *pWinParType );
aNmTb.Put( nId, CLASSNAME, pClassDockWindow );
- // initialize variables
- nId = aNmTb.Put( "_FloatingPosMapMode", VARNAME );
- pClassDockWindow->SetVariable( nId, pMapUnit, nullptr, 0,
- RSC_DOCKINGWINDOW_XYMAPMODE );
- nId = aNmTb.Put( "_FloatingPosX", VARNAME );
- pClassDockWindow->SetVariable( nId, &aShort, nullptr, 0,
- RSC_DOCKINGWINDOW_X );
- nId = aNmTb.Put( "_FloatingPosY", VARNAME );
- pClassDockWindow->SetVariable( nId, &aShort, nullptr, 0,
- RSC_DOCKINGWINDOW_Y );
- nId = aNmTb.Put( "FloatingMode", VARNAME );
- pClassDockWindow->SetVariable( nId, &aBool, nullptr, 0,
- RSC_DOCKINGWINDOW_FLOATING );
-
INS_WINBIT(pClassDockWindow,Moveable)
INS_WINBIT(pClassDockWindow,Sizeable)
INS_WINBIT(pClassDockWindow,EnableResizing)
diff --git a/rsc/source/parser/rscinit.cxx b/rsc/source/parser/rscinit.cxx
index eb02f71..6edee4c 100644
--- a/rsc/source/parser/rscinit.cxx
+++ b/rsc/source/parser/rscinit.cxx
@@ -410,7 +410,7 @@ void RscTypCont::Init()
}
}
{
- RscTop* pClassDockingWindow = InitClassDockingWindow( pClassWindow, pMapUnit );
+ RscTop* pClassDockingWindow = InitClassDockingWindow( pClassWindow );
pRoot->Insert( pClassDockingWindow );
RscTop* pClassToolBoxItem = InitClassToolBoxItem( pClassMgr, pClassBitmap,
diff --git a/vcl/source/window/dockwin.cxx b/vcl/source/window/dockwin.cxx
index 984d713..ddcd079 100644
--- a/vcl/source/window/dockwin.cxx
+++ b/vcl/source/window/dockwin.cxx
@@ -380,38 +380,7 @@ void DockingWindow::ImplLoadRes( const ResId& rResId )
{
Window::ImplLoadRes( rResId );
- const sal_uInt32 nMask = ReadLongRes();
-
- if ( (RSC_DOCKINGWINDOW_XYMAPMODE | RSC_DOCKINGWINDOW_X |
- RSC_DOCKINGWINDOW_Y) & nMask )
- {
- // use Sizes of the Resource
- Point aPos;
- MapUnit ePosMap = MAP_PIXEL;
-
- if ( RSC_DOCKINGWINDOW_XYMAPMODE & nMask )
- ePosMap = (MapUnit)ReadLongRes();
-
- if ( RSC_DOCKINGWINDOW_X & nMask )
- {
- aPos.X() = ReadShortRes();
- aPos.X() = ImplLogicUnitToPixelX( aPos.X(), ePosMap );
- }
-
- if ( RSC_DOCKINGWINDOW_Y & nMask )
- {
- aPos.Y() = ReadShortRes();
- aPos.Y() = ImplLogicUnitToPixelY( aPos.Y(), ePosMap );
- }
-
- SetFloatingPos( aPos );
- }
-
- if ( nMask & RSC_DOCKINGWINDOW_FLOATING )
- {
- if ( ReadShortRes() != 0 )
- SetFloatingMode( true );
- }
+ ReadLongRes();
}
DockingWindow::DockingWindow( WindowType nType ) :
More information about the Libreoffice-commits
mailing list