[Libreoffice-commits] core.git: accessibility/source cui/source fpicker/source framework/source include/tools include/vcl sc/source sfx2/source svtools/source svx/source sw/source toolkit/source vcl/osx vcl/source vcl/unx vcl/win vcl/workben

Noel Grandin noel.grandin at collabora.co.uk
Tue Feb 14 10:44:30 UTC 2017


 accessibility/source/extended/accessiblelistbox.cxx           |    2 
 accessibility/source/helper/acc_factory.cxx                   |   18 
 accessibility/source/standard/vclxaccessiblebutton.cxx        |    2 
 accessibility/source/standard/vclxaccessibletabcontrol.cxx    |    2 
 accessibility/source/standard/vclxaccessibletabpagewindow.cxx |    2 
 accessibility/source/standard/vclxaccessibletoolbox.cxx       |    4 
 cui/source/customize/cfg.cxx                                  |    2 
 cui/source/dialogs/cuifmsearch.cxx                            |    2 
 fpicker/source/office/OfficeControlAccess.cxx                 |   18 
 framework/source/helper/persistentwindowstate.cxx             |    2 
 framework/source/helper/tagwindowasmodified.cxx               |    2 
 framework/source/helper/titlebarupdate.cxx                    |    6 
 framework/source/layoutmanager/helpers.cxx                    |    6 
 framework/source/layoutmanager/layoutmanager.cxx              |    4 
 framework/source/layoutmanager/toolbarlayoutmanager.cxx       |   22 
 framework/source/loadenv/loadenv.cxx                          |    2 
 framework/source/services/frame.cxx                           |    2 
 framework/source/uielement/addonstoolbarmanager.cxx           |    2 
 framework/source/uielement/progressbarwrapper.cxx             |    8 
 framework/source/uielement/subtoolbarcontroller.cxx           |    4 
 framework/source/uielement/toolbarmanager.cxx                 |    2 
 include/tools/wintypes.hxx                                    |  177 ++---
 include/vcl/layout.hxx                                        |    4 
 sc/source/ui/app/inputwin.cxx                                 |    2 
 sfx2/source/appl/childwin.cxx                                 |    4 
 sfx2/source/appl/workwin.cxx                                  |    8 
 sfx2/source/notebookbar/ContextVBox.cxx                       |    2 
 sfx2/source/notebookbar/PriorityHBox.cxx                      |    2 
 sfx2/source/sidebar/ControllerFactory.cxx                     |    2 
 svtools/source/contnr/treelistbox.cxx                         |    2 
 svtools/source/control/ruler.cxx                              |    2 
 svtools/source/dialogs/wizardmachine.cxx                      |   16 
 svtools/source/uno/popupwindowcontroller.cxx                  |    2 
 svtools/source/uno/statusbarcontroller.cxx                    |    4 
 svx/source/accessibility/svxpixelctlaccessiblecontext.cxx     |    4 
 svx/source/dialog/dlgctrl.cxx                                 |    8 
 svx/source/sidebar/PanelLayout.cxx                            |    2 
 svx/source/tbxctrls/SvxColorValueSet.cxx                      |    2 
 svx/source/tbxctrls/verttexttbxctrl.cxx                       |    3 
 sw/source/ui/index/cnttab.cxx                                 |   40 -
 sw/source/uibase/dbui/dbui.cxx                                |    2 
 toolkit/source/awt/vclxaccessiblecomponent.cxx                |    6 
 toolkit/source/awt/vclxcontainer.cxx                          |    2 
 toolkit/source/awt/vclxtoolkit.cxx                            |  339 ++++------
 toolkit/source/awt/vclxwindow.cxx                             |  172 ++---
 toolkit/source/awt/vclxwindow1.cxx                            |    2 
 toolkit/source/awt/vclxwindows.cxx                            |   32 
 toolkit/source/helper/unowrapper.cxx                          |  130 +--
 vcl/osx/a11yfocustracker.cxx                                  |   12 
 vcl/source/app/help.cxx                                       |    2 
 vcl/source/control/button.cxx                                 |   70 +-
 vcl/source/control/combobox.cxx                               |    2 
 vcl/source/control/ctrl.cxx                                   |    2 
 vcl/source/control/edit.cxx                                   |   42 -
 vcl/source/control/fixed.cxx                                  |    8 
 vcl/source/control/group.cxx                                  |    2 
 vcl/source/control/imp_listbox.cxx                            |    2 
 vcl/source/control/listbox.cxx                                |    4 
 vcl/source/control/menubtn.cxx                                |    2 
 vcl/source/control/morebtn.cxx                                |    2 
 vcl/source/control/notebookbar.cxx                            |    2 
 vcl/source/control/scrbar.cxx                                 |    4 
 vcl/source/control/slider.cxx                                 |    2 
 vcl/source/control/spinbtn.cxx                                |    2 
 vcl/source/control/spinfld.cxx                                |   22 
 vcl/source/control/tabctrl.cxx                                |    2 
 vcl/source/edit/vclmedit.cxx                                  |    2 
 vcl/source/uitest/uiobject.cxx                                |   10 
 vcl/source/window/accessibility.cxx                           |  242 +++----
 vcl/source/window/brdwin.cxx                                  |   76 +-
 vcl/source/window/btndlg.cxx                                  |    8 
 vcl/source/window/builder.cxx                                 |   32 
 vcl/source/window/debug.cxx                                   |    2 
 vcl/source/window/decoview.cxx                                |    4 
 vcl/source/window/dialog.cxx                                  |   40 -
 vcl/source/window/dlgctrl.cxx                                 |   28 
 vcl/source/window/dockingarea.cxx                             |    2 
 vcl/source/window/dockmgr.cxx                                 |    2 
 vcl/source/window/dockwin.cxx                                 |    4 
 vcl/source/window/event.cxx                                   |    6 
 vcl/source/window/floatwin.cxx                                |    4 
 vcl/source/window/introwin.cxx                                |    2 
 vcl/source/window/layout.cxx                                  |   18 
 vcl/source/window/legacyaccessibility.cxx                     |   60 -
 vcl/source/window/menubarwindow.cxx                           |    4 
 vcl/source/window/msgbox.cxx                                  |    2 
 vcl/source/window/settings.cxx                                |    4 
 vcl/source/window/split.cxx                                   |    2 
 vcl/source/window/splitwin.cxx                                |    2 
 vcl/source/window/stacking.cxx                                |    4 
 vcl/source/window/status.cxx                                  |    2 
 vcl/source/window/syschild.cxx                                |    4 
 vcl/source/window/syswin.cxx                                  |   14 
 vcl/source/window/tabdlg.cxx                                  |    8 
 vcl/source/window/tabpage.cxx                                 |    8 
 vcl/source/window/taskpanelist.cxx                            |    2 
 vcl/source/window/toolbox.cxx                                 |   12 
 vcl/source/window/window.cxx                                  |   48 -
 vcl/source/window/window2.cxx                                 |    4 
 vcl/source/window/window3.cxx                                 |    4 
 vcl/source/window/winproc.cxx                                 |    6 
 vcl/source/window/wrkwin.cxx                                  |    6 
 vcl/unx/gtk/a11y/atkfactory.cxx                               |    2 
 vcl/unx/gtk/a11y/atkutil.cxx                                  |    8 
 vcl/unx/gtk/a11y/atkwindow.cxx                                |   14 
 vcl/win/window/salframe.cxx                                   |    2 
 vcl/workben/vcldemo.cxx                                       |    2 
 107 files changed, 987 insertions(+), 988 deletions(-)

New commits:
commit 8c00536d87010b14a95e9c81f2f5f1d683e5fa70
Author: Noel Grandin <noel.grandin at collabora.co.uk>
Date:   Mon Feb 13 19:08:14 2017 +0200

    Convert WindowType to scoped enum
    
    Change-Id: I85cfe02f28729e13f2c0dd3d91cd89e6f3e3b6a9
    Reviewed-on: https://gerrit.libreoffice.org/34219
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>

diff --git a/accessibility/source/extended/accessiblelistbox.cxx b/accessibility/source/extended/accessiblelistbox.cxx
index bfbe9d3..6933f10 100644
--- a/accessibility/source/extended/accessiblelistbox.cxx
+++ b/accessibility/source/extended/accessiblelistbox.cxx
@@ -124,7 +124,7 @@ namespace accessibility
                     if (pBox)
                     {
                         vcl::Window* pParent = static_cast<vcl::Window*>(pBox)->GetParent();
-                        if (pParent && pParent->GetType() == WINDOW_FLOATINGWINDOW)
+                        if (pParent && pParent->GetType() == WindowType::FLOATINGWINDOW)
                         {
                             // MT: ImplGetAppSVData shouldn't be exported from VCL.
                             // In which scenario is this needed?
diff --git a/accessibility/source/helper/acc_factory.cxx b/accessibility/source/helper/acc_factory.cxx
index 7b5d872..287279a 100644
--- a/accessibility/source/helper/acc_factory.cxx
+++ b/accessibility/source/helper/acc_factory.cxx
@@ -73,7 +73,7 @@ namespace {
 inline bool hasFloatingChild(vcl::Window *pWindow)
 {
     vcl::Window * pChild = pWindow->GetAccessibleChildWindow(0);
-    if( pChild && WINDOW_FLOATINGWINDOW == pChild->GetType() )
+    if( pChild && WindowType::FLOATINGWINDOW == pChild->GetType() )
         return true;
 
     return false;
@@ -293,13 +293,13 @@ Reference< XAccessibleContext > AccessibleFactory::createAccessibleContext( VCLX
     {
         WindowType nType = pWindow->GetType();
 
-        if ( nType == WINDOW_MENUBARWINDOW || pWindow->IsMenuFloatingWindow() || pWindow->IsToolbarFloatingWindow() )
+        if ( nType == WindowType::MENUBARWINDOW || pWindow->IsMenuFloatingWindow() || pWindow->IsToolbarFloatingWindow() )
         {
             Reference< XAccessible > xAcc( pWindow->GetAccessible() );
             if ( xAcc.is() )
             {
                 Reference< XAccessibleContext > xCont( xAcc->getAccessibleContext() );
-                if ( pWindow->GetType() == WINDOW_MENUBARWINDOW ||
+                if ( pWindow->GetType() == WindowType::MENUBARWINDOW ||
                     ( xCont.is() && xCont->getAccessibleRole() == AccessibleRole::POPUP_MENU ) )
                 {
                     xContext = xCont;
@@ -307,27 +307,27 @@ Reference< XAccessibleContext > AccessibleFactory::createAccessibleContext( VCLX
             }
         }
 
-        else if ( nType == WINDOW_STATUSBAR )
+        else if ( nType == WindowType::STATUSBAR )
         {
             xContext = static_cast<XAccessibleContext*>(new VCLXAccessibleStatusBar( _pXWindow ));
         }
 
-        else if ( nType == WINDOW_TABCONTROL )
+        else if ( nType == WindowType::TABCONTROL )
         {
             xContext = static_cast<XAccessibleContext*>(new VCLXAccessibleTabControl( _pXWindow ));
         }
 
-        else if ( nType == WINDOW_TABPAGE && pWindow->GetAccessibleParentWindow() && pWindow->GetAccessibleParentWindow()->GetType() == WINDOW_TABCONTROL )
+        else if ( nType == WindowType::TABPAGE && pWindow->GetAccessibleParentWindow() && pWindow->GetAccessibleParentWindow()->GetType() == WindowType::TABCONTROL )
         {
             xContext = new VCLXAccessibleTabPageWindow( _pXWindow );
         }
 
-        else if ( nType == WINDOW_FLOATINGWINDOW )
+        else if ( nType == WindowType::FLOATINGWINDOW )
         {
             xContext = new FloatingWindowAccessible( _pXWindow );
         }
 
-        else if ( nType == WINDOW_BORDERWINDOW && hasFloatingChild( pWindow ) )
+        else if ( nType == WindowType::BORDERWINDOW && hasFloatingChild( pWindow ) )
         {
             // The logic here has to match that of Window::GetAccessibleParentWindow in
             // vcl/source/window/window.cxx to avoid PopupMenuFloatingWindow
@@ -344,7 +344,7 @@ Reference< XAccessibleContext > AccessibleFactory::createAccessibleContext( VCLX
                 xContext = new FloatingWindowAccessible( _pXWindow );
         }
 
-        else if ( ( nType == WINDOW_HELPTEXTWINDOW ) || ( nType == WINDOW_FIXEDLINE ) )
+        else if ( ( nType == WindowType::HELPTEXTWINDOW ) || ( nType == WindowType::FIXEDLINE ) )
         {
            xContext = static_cast<XAccessibleContext*>(new VCLXAccessibleFixedText( _pXWindow ));
         }
diff --git a/accessibility/source/standard/vclxaccessiblebutton.cxx b/accessibility/source/standard/vclxaccessiblebutton.cxx
index c42b397..f644262 100644
--- a/accessibility/source/standard/vclxaccessiblebutton.cxx
+++ b/accessibility/source/standard/vclxaccessiblebutton.cxx
@@ -94,7 +94,7 @@ void VCLXAccessibleButton::FillAccessibleStateSet( utl::AccessibleStateSetHelper
             rStateSet.AddState( AccessibleStateType::PRESSED );
 
         // IA2 CWS: if the button has a popup menu, it should has the state EXPANDABLE
-        if( pButton->GetType() == WINDOW_MENUBUTTON )
+        if( pButton->GetType() == WindowType::MENUBUTTON )
         {
             rStateSet.AddState( AccessibleStateType::EXPANDABLE );
         }
diff --git a/accessibility/source/standard/vclxaccessibletabcontrol.cxx b/accessibility/source/standard/vclxaccessibletabcontrol.cxx
index f2f0310..274af0e 100644
--- a/accessibility/source/standard/vclxaccessibletabcontrol.cxx
+++ b/accessibility/source/standard/vclxaccessibletabcontrol.cxx
@@ -267,7 +267,7 @@ void VCLXAccessibleTabControl::ProcessWindowChildEvent( const VclWindowEvent& rV
             if ( m_pTabControl )
             {
                 vcl::Window* pChild = static_cast< vcl::Window* >( rVclWindowEvent.GetData() );
-                if ( pChild && pChild->GetType() == WINDOW_TABPAGE )
+                if ( pChild && pChild->GetType() == WindowType::TABPAGE )
                 {
                     for ( sal_Int32 i = 0, nCount = m_pTabControl->GetPageCount(); i < nCount; ++i )
                     {
diff --git a/accessibility/source/standard/vclxaccessibletabpagewindow.cxx b/accessibility/source/standard/vclxaccessibletabpagewindow.cxx
index ec89a48..c160ecd 100644
--- a/accessibility/source/standard/vclxaccessibletabpagewindow.cxx
+++ b/accessibility/source/standard/vclxaccessibletabpagewindow.cxx
@@ -41,7 +41,7 @@ VCLXAccessibleTabPageWindow::VCLXAccessibleTabPageWindow( VCLXWindow* pVCLXWindo
     if ( m_pTabPage )
     {
         vcl::Window* pParent = m_pTabPage->GetAccessibleParentWindow();
-        if ( pParent && pParent->GetType() == WINDOW_TABCONTROL )
+        if ( pParent && pParent->GetType() == WindowType::TABCONTROL )
         {
             m_pTabControl = static_cast< TabControl* >( pParent );
             if ( m_pTabControl )
diff --git a/accessibility/source/standard/vclxaccessibletoolbox.cxx b/accessibility/source/standard/vclxaccessibletoolbox.cxx
index 6aa02c6..a4111ae 100644
--- a/accessibility/source/standard/vclxaccessibletoolbox.cxx
+++ b/accessibility/source/standard/vclxaccessibletoolbox.cxx
@@ -452,7 +452,7 @@ void VCLXAccessibleToolBox::HandleSubToolBarEvent( const VclWindowEvent& rVclWin
     if ( pChildWindow
         && pToolBox
         && pToolBox == pChildWindow->GetParent()
-        && pChildWindow->GetType() == WINDOW_TOOLBOX )
+        && pChildWindow->GetType() == WindowType::TOOLBOX )
     {
         sal_Int32 nIndex = pToolBox->GetItemPos( pToolBox->GetCurItemId() );
         Reference< XAccessible > xItem = getAccessibleChild( nIndex );
@@ -602,7 +602,7 @@ void VCLXAccessibleToolBox::ProcessWindowEvent( const VclWindowEvent& rVclWindow
             // if this toolbox is a subtoolbox, we have to release it from its parent
             VclPtr< vcl::Window > pWin = GetAs< vcl::Window >();
             if ( pWin && pWin->GetParent() &&
-                 pWin->GetParent()->GetType() == WINDOW_TOOLBOX )
+                 pWin->GetParent()->GetType() == WindowType::TOOLBOX )
             {
                 VCLXAccessibleToolBox* pParent = static_cast< VCLXAccessibleToolBox* >(
                     pWin->GetParent()->GetAccessible()->getAccessibleContext().get() );
diff --git a/cui/source/customize/cfg.cxx b/cui/source/customize/cfg.cxx
index 17c0249..8cb2bc1 100644
--- a/cui/source/customize/cfg.cxx
+++ b/cui/source/customize/cfg.cxx
@@ -3719,7 +3719,7 @@ void ToolbarSaveInData::SetSystemStyle(
         window = VCLUnoHelper::GetWindow( xWindow ).get();
     }
 
-    if ( window != nullptr && window->GetType() == WINDOW_TOOLBOX )
+    if ( window != nullptr && window->GetType() == WindowType::TOOLBOX )
     {
         ToolBox* toolbox = static_cast<ToolBox*>(window);
 
diff --git a/cui/source/dialogs/cuifmsearch.cxx b/cui/source/dialogs/cuifmsearch.cxx
index 0e16751..06739fa 100644
--- a/cui/source/dialogs/cuifmsearch.cxx
+++ b/cui/source/dialogs/cuifmsearch.cxx
@@ -614,7 +614,7 @@ void FmSearchDialog::EnableSearchUI(bool bEnable)
         if ( m_pPreSearchFocus )
         {
             m_pPreSearchFocus->GrabFocus();
-            if ( WINDOW_EDIT == m_pPreSearchFocus->GetType() )
+            if ( WindowType::EDIT == m_pPreSearchFocus->GetType() )
             {
                 Edit* pEdit = static_cast< Edit* >( m_pPreSearchFocus.get() );
                 pEdit->SetSelection( Selection( 0, pEdit->GetText().getLength() ) );
diff --git a/fpicker/source/office/OfficeControlAccess.cxx b/fpicker/source/office/OfficeControlAccess.cxx
index a8ba821..74ba41a 100644
--- a/fpicker/source/office/OfficeControlAccess.cxx
+++ b/fpicker/source/office/OfficeControlAccess.cxx
@@ -373,7 +373,7 @@ namespace svt
                         }
                         else
                         {
-                            DBG_ASSERT( WINDOW_LISTBOX == pControl->GetType(), "OControlAccess::SetValue: implGetControl returned nonsense!" );
+                            DBG_ASSERT( WindowType::LISTBOX == pControl->GetType(), "OControlAccess::SetValue: implGetControl returned nonsense!" );
                             implDoListboxAction( static_cast< ListBox* >( pControl ), _nControlAction, _rValue );
                         }
                         break;
@@ -597,7 +597,7 @@ namespace svt
 
             case PropFlags::ListItems:
             {
-                DBG_ASSERT( WINDOW_LISTBOX == _pControl->GetType(),
+                DBG_ASSERT( WindowType::LISTBOX == _pControl->GetType(),
                     "OControlAccess::implSetControlProperty: invalid control/property combination!" );
 
                 Sequence< OUString > aItems;
@@ -627,7 +627,7 @@ namespace svt
 
             case PropFlags::SelectedItem:
             {
-                DBG_ASSERT( WINDOW_LISTBOX == _pControl->GetType(),
+                DBG_ASSERT( WindowType::LISTBOX == _pControl->GetType(),
                     "OControlAccess::implSetControlProperty: invalid control/property combination!" );
 
                 OUString sSelected;
@@ -644,7 +644,7 @@ namespace svt
 
             case PropFlags::SelectedItemIndex:
             {
-                DBG_ASSERT( WINDOW_LISTBOX == _pControl->GetType(),
+                DBG_ASSERT( WindowType::LISTBOX == _pControl->GetType(),
                     "OControlAccess::implSetControlProperty: invalid control/property combination!" );
 
                 sal_Int32 nPos = 0;
@@ -661,7 +661,7 @@ namespace svt
 
             case PropFlags::Checked:
             {
-                DBG_ASSERT( WINDOW_CHECKBOX == _pControl->GetType(),
+                DBG_ASSERT( WindowType::CHECKBOX == _pControl->GetType(),
                     "OControlAccess::implSetControlProperty: invalid control/property combination!" );
 
                 bool bChecked = false;
@@ -707,7 +707,7 @@ namespace svt
 
             case PropFlags::ListItems:
             {
-                DBG_ASSERT( WINDOW_LISTBOX == _pControl->GetType(),
+                DBG_ASSERT( WindowType::LISTBOX == _pControl->GetType(),
                     "OControlAccess::implGetControlProperty: invalid control/property combination!" );
 
                 Sequence< OUString > aItems( static_cast< ListBox* >( _pControl )->GetEntryCount() );
@@ -721,7 +721,7 @@ namespace svt
 
             case PropFlags::SelectedItem:
             {
-                DBG_ASSERT( WINDOW_LISTBOX == _pControl->GetType(),
+                DBG_ASSERT( WindowType::LISTBOX == _pControl->GetType(),
                     "OControlAccess::implGetControlProperty: invalid control/property combination!" );
 
                 sal_Int32 nSelected = static_cast< ListBox* >( _pControl )->GetSelectEntryPos();
@@ -734,7 +734,7 @@ namespace svt
 
             case PropFlags::SelectedItemIndex:
             {
-                DBG_ASSERT( WINDOW_LISTBOX == _pControl->GetType(),
+                DBG_ASSERT( WindowType::LISTBOX == _pControl->GetType(),
                     "OControlAccess::implGetControlProperty: invalid control/property combination!" );
 
                 sal_Int32 nSelected = static_cast< ListBox* >( _pControl )->GetSelectEntryPos();
@@ -746,7 +746,7 @@ namespace svt
             break;
 
             case PropFlags::Checked:
-                DBG_ASSERT( WINDOW_CHECKBOX == _pControl->GetType(),
+                DBG_ASSERT( WindowType::CHECKBOX == _pControl->GetType(),
                     "OControlAccess::implGetControlProperty: invalid control/property combination!" );
 
                 aReturn <<= static_cast< CheckBox* >( _pControl )->IsChecked( );
diff --git a/framework/source/helper/persistentwindowstate.cxx b/framework/source/helper/persistentwindowstate.cxx
index 537fa79..59ab70e 100644
--- a/framework/source/helper/persistentwindowstate.cxx
+++ b/framework/source/helper/persistentwindowstate.cxx
@@ -245,7 +245,7 @@ void PersistentWindowState::implst_setWindowStateOnWindow(const css::uno::Refere
 
     // check for system and work window - its necessary to guarantee correct pointer cast!
     bool bSystemWindow = pWindow->IsSystemWindow();
-    bool bWorkWindow   = (pWindow->GetType() == WINDOW_WORKWINDOW);
+    bool bWorkWindow   = (pWindow->GetType() == WindowType::WORKWINDOW);
 
     if (!bSystemWindow && !bWorkWindow)
         return;
diff --git a/framework/source/helper/tagwindowasmodified.cxx b/framework/source/helper/tagwindowasmodified.cxx
index a71b613..b17dc12 100644
--- a/framework/source/helper/tagwindowasmodified.cxx
+++ b/framework/source/helper/tagwindowasmodified.cxx
@@ -90,7 +90,7 @@ void SAL_CALL TagWindowAsModified::modified(const css::lang::EventObject& aEvent
         return;
 
     bool bSystemWindow = pWindow->IsSystemWindow();
-    bool bWorkWindow   = (pWindow->GetType() == WINDOW_WORKWINDOW);
+    bool bWorkWindow   = (pWindow->GetType() == WindowType::WORKWINDOW);
     if (!bSystemWindow && !bWorkWindow)
         return;
 
diff --git a/framework/source/helper/titlebarupdate.cxx b/framework/source/helper/titlebarupdate.cxx
index 15476a1..edacb27 100644
--- a/framework/source/helper/titlebarupdate.cxx
+++ b/framework/source/helper/titlebarupdate.cxx
@@ -168,7 +168,7 @@ void TitleBarUpdate::impl_updateApplicationID(const css::uno::Reference< css::fr
     VclPtr<vcl::Window> pWindow = (VCLUnoHelper::GetWindow( xWindow ));
     if (
         ( pWindow                                 ) &&
-        ( pWindow->GetType() == WINDOW_WORKWINDOW )
+        ( pWindow->GetType() == WindowType::WORKWINDOW )
        )
     {
         WorkWindow* pWorkWindow = static_cast<WorkWindow*>(pWindow.get());
@@ -285,7 +285,7 @@ void TitleBarUpdate::impl_updateIcon(const css::uno::Reference< css::frame::XFra
     VclPtr<vcl::Window> pWindow = (VCLUnoHelper::GetWindow( xWindow ));
     if (
         ( pWindow                                 ) &&
-        ( pWindow->GetType() == WINDOW_WORKWINDOW )
+        ( pWindow->GetType() == WindowType::WORKWINDOW )
        )
     {
         WorkWindow* pWorkWindow = static_cast<WorkWindow*>(pWindow.get());
@@ -319,7 +319,7 @@ void TitleBarUpdate::impl_updateTitle(const css::uno::Reference< css::frame::XFr
     VclPtr<vcl::Window> pWindow = (VCLUnoHelper::GetWindow( xWindow ));
     if (
         ( pWindow                                 ) &&
-        ( pWindow->GetType() == WINDOW_WORKWINDOW )
+        ( pWindow->GetType() == WindowType::WORKWINDOW )
        )
     {
         WorkWindow* pWorkWindow = static_cast<WorkWindow*>(pWindow.get());
diff --git a/framework/source/layoutmanager/helpers.cxx b/framework/source/layoutmanager/helpers.cxx
index 7bf7a3d..92404dd 100644
--- a/framework/source/layoutmanager/helpers.cxx
+++ b/framework/source/layoutmanager/helpers.cxx
@@ -83,7 +83,7 @@ OUString retrieveToolbarNameFromHelpURL( vcl::Window* pWindow )
 {
     OUString aToolbarName;
 
-    if ( pWindow->GetType() == WINDOW_TOOLBOX )
+    if ( pWindow->GetType() == WindowType::TOOLBOX )
     {
         ToolBox* pToolBox = dynamic_cast<ToolBox *>( pWindow );
         if ( pToolBox )
@@ -102,7 +102,7 @@ OUString retrieveToolbarNameFromHelpURL( vcl::Window* pWindow )
 ToolBox* getToolboxPtr( vcl::Window* pWindow )
 {
     ToolBox* pToolbox(nullptr);
-    if ( pWindow->GetType() == WINDOW_TOOLBOX )
+    if ( pWindow->GetType() == WindowType::TOOLBOX )
         pToolbox = dynamic_cast<ToolBox*>( pWindow );
     return pToolbox;
 }
@@ -151,7 +151,7 @@ bool lcl_checkUIElement(const uno::Reference< ui::XUIElement >& xUIElement, awt:
         _rPosSize = _xWindow->getPosSize();
 
         VclPtr<vcl::Window> pWindow = VCLUnoHelper::GetWindow( _xWindow );
-        if ( pWindow->GetType() == WINDOW_TOOLBOX )
+        if ( pWindow->GetType() == WindowType::TOOLBOX )
         {
             ::Size aSize = static_cast<ToolBox*>(pWindow.get())->CalcWindowSizePixel( 1 );
             _rPosSize.Width = aSize.Width();
diff --git a/framework/source/layoutmanager/layoutmanager.cxx b/framework/source/layoutmanager/layoutmanager.cxx
index efec9ec..2f9f881 100644
--- a/framework/source/layoutmanager/layoutmanager.cxx
+++ b/framework/source/layoutmanager/layoutmanager.cxx
@@ -980,7 +980,7 @@ void LayoutManager::implts_setStatusBarPosSize( const ::Point& rPos, const ::Siz
         SolarMutexGuard aGuard;
         VclPtr<vcl::Window> pParentWindow = VCLUnoHelper::GetWindow( xContainerWindow );
         VclPtr<vcl::Window> pWindow = VCLUnoHelper::GetWindow( xWindow );
-        if ( pParentWindow && ( pWindow && pWindow->GetType() == WINDOW_STATUSBAR ))
+        if ( pParentWindow && ( pWindow && pWindow->GetType() == WindowType::STATUSBAR ))
         {
             vcl::Window* pOldParentWindow = pWindow->GetParent();
             if ( pParentWindow != pOldParentWindow )
@@ -1396,7 +1396,7 @@ uno::Reference< ui::XUIElement > LayoutManager::implts_createDockingWindow( cons
 IMPL_LINK( LayoutManager, WindowEventListener, VclWindowEvent&, rEvent, void )
 {
     vcl::Window* pWindow = rEvent.GetWindow();
-    if ( pWindow && pWindow->GetType() == WINDOW_TOOLBOX )
+    if ( pWindow && pWindow->GetType() == WindowType::TOOLBOX )
     {
         SolarMutexClearableGuard aReadLock;
         ToolbarLayoutManager* pToolbarManager( m_xToolbarManager.get() );
diff --git a/framework/source/layoutmanager/toolbarlayoutmanager.cxx b/framework/source/layoutmanager/toolbarlayoutmanager.cxx
index 6ef5632..4f69df8 100644
--- a/framework/source/layoutmanager/toolbarlayoutmanager.cxx
+++ b/framework/source/layoutmanager/toolbarlayoutmanager.cxx
@@ -544,7 +544,7 @@ bool ToolbarLayoutManager::createToolbar( const OUString& rResourceURL )
 
             SolarMutexGuard aGuard;
             VclPtr<vcl::Window> pWindow = VCLUnoHelper::GetWindow( xWindow );
-            if ( pWindow && pWindow->GetType() == WINDOW_TOOLBOX )
+            if ( pWindow && pWindow->GetType() == WindowType::TOOLBOX )
             {
                 ToolBox* pToolbar = static_cast<ToolBox *>(pWindow.get());
                 ToolBoxMenuType nMenuType = pToolbar->GetMenuType();
@@ -829,7 +829,7 @@ bool ToolbarLayoutManager::dockToolbar( const OUString& rResourceURL, ui::Dockin
                     {
                         SolarMutexGuard aGuard;
                         pWindow = VCLUnoHelper::GetWindow( xWindow ).get();
-                        if ( pWindow && pWindow->GetType() == WINDOW_TOOLBOX )
+                        if ( pWindow && pWindow->GetType() == WindowType::TOOLBOX )
                         {
                             pToolBox = static_cast<ToolBox *>(pWindow);
 
@@ -1171,7 +1171,7 @@ void ToolbarLayoutManager::implts_createAddonsToolBars()
                     VclPtr<vcl::Window> pWindow = VCLUnoHelper::GetWindow( xWindow );
                     if ( pWindow->GetText().isEmpty() )
                         pWindow->SetText( aGenericAddonTitle );
-                    if ( pWindow->GetType() == WINDOW_TOOLBOX )
+                    if ( pWindow->GetType() == WindowType::TOOLBOX )
                     {
                         ToolBox* pToolbar = static_cast<ToolBox *>(pWindow.get());
                         pToolbar->SetMenuType();
@@ -1429,7 +1429,7 @@ void ToolbarLayoutManager::implts_setElementData( UIElement& rElement, const uno
                     pWindow->SetText( rElement.m_aUIName );
                 if ( rElement.m_bNoClose )
                     pWindow->SetStyle( pWindow->GetStyle() & ~WB_CLOSEABLE );
-                if ( pWindow->GetType() == WINDOW_TOOLBOX )
+                if ( pWindow->GetType() == WindowType::TOOLBOX )
                     pToolBox = static_cast<ToolBox *>(pWindow);
             }
             if ( pToolBox )
@@ -2480,7 +2480,7 @@ void ToolbarLayoutManager::implts_calcWindowPosSizeOnSingleRowColumn(
             {
                 uno::Reference< awt::XWindow > xWindow = rRowColumnWindowData.aRowColumnWindows[i];
                 VclPtr<vcl::Window> pWindow = VCLUnoHelper::GetWindow( xWindow );
-                if ( pWindow && pWindow->GetType() == WINDOW_TOOLBOX )
+                if ( pWindow && pWindow->GetType() == WindowType::TOOLBOX )
                     aMinSize = static_cast<ToolBox *>(pWindow.get())->CalcMinimumWindowSizePixel();
             }
 
@@ -2642,7 +2642,7 @@ void ToolbarLayoutManager::implts_calcDockingPosSize(
         SolarMutexGuard aGuard;
         pDockingAreaWindow = VCLUnoHelper::GetWindow( xDockingAreaWindow ).get();
         VclPtr<vcl::Window> pDockWindow = VCLUnoHelper::GetWindow( xWindow );
-        if ( pDockWindow && pDockWindow->GetType() == WINDOW_TOOLBOX )
+        if ( pDockWindow && pDockWindow->GetType() == WindowType::TOOLBOX )
             pToolBox = static_cast<ToolBox *>(pDockWindow.get());
 
         aDockingAreaRect = ::Rectangle( pDockingAreaWindow->GetPosPixel(), pDockingAreaWindow->GetSizePixel() );
@@ -3289,7 +3289,7 @@ void SAL_CALL ToolbarLayoutManager::startDocking( const awt::DockingEvent& e )
             SolarMutexGuard aGuard;
 
             VclPtr<vcl::Window> pWindow = VCLUnoHelper::GetWindow( xWindow );
-            if ( pWindow && pWindow->GetType() == WINDOW_TOOLBOX )
+            if ( pWindow && pWindow->GetType() == WindowType::TOOLBOX )
             {
                 ToolBox* pToolBox = static_cast<ToolBox *>(pWindow.get());
                 aUIElement.m_aFloatingData.m_nLines        = pToolBox->GetFloatingLines();
@@ -3382,7 +3382,7 @@ awt::DockingData SAL_CALL ToolbarLayoutManager::docking( const awt::DockingEvent
             // Determine if we have a toolbar and set alignment according to the docking area!
             VclPtr<vcl::Window>  pWindow = VCLUnoHelper::GetWindow( xWindow );
             ToolBox* pToolBox = nullptr;
-            if ( pWindow && pWindow->GetType() == WINDOW_TOOLBOX )
+            if ( pWindow && pWindow->GetType() == WindowType::TOOLBOX )
                 pToolBox = static_cast<ToolBox *>(pWindow.get());
 
             if ( eDockingArea != -1 )
@@ -3537,7 +3537,7 @@ void SAL_CALL ToolbarLayoutManager::endDocking( const awt::EndDockingEvent& e )
         SolarMutexGuard aGuard;
         VclPtr<vcl::Window> pWindow = VCLUnoHelper::GetWindow( uno::Reference< awt::XWindow >( e.Source, uno::UNO_QUERY ));
         ToolBox* pToolBox = nullptr;
-        if ( pWindow && pWindow->GetType() == WINDOW_TOOLBOX )
+        if ( pWindow && pWindow->GetType() == WindowType::TOOLBOX )
             pToolBox = static_cast<ToolBox *>(pWindow.get());
 
         if ( pToolBox )
@@ -3596,7 +3596,7 @@ sal_Bool SAL_CALL ToolbarLayoutManager::prepareToggleFloatingMode( const lang::E
                 {
                     SolarMutexGuard aGuard;
                     VclPtr<vcl::Window> pWindow = VCLUnoHelper::GetWindow( xWindow );
-                    if ( pWindow && pWindow->GetType() == WINDOW_TOOLBOX )
+                    if ( pWindow && pWindow->GetType() == WindowType::TOOLBOX )
                     {
                         ToolBox* pToolBox = static_cast< ToolBox *>( pWindow.get() );
                         aUIDockingElement.m_aFloatingData.m_aPos = AWTPoint(pToolBox->GetPosPixel());
@@ -3635,7 +3635,7 @@ void SAL_CALL ToolbarLayoutManager::toggleFloatingMode( const lang::EventObject&
         xWindow.set( e.Source, uno::UNO_QUERY );
         pWindow = VCLUnoHelper::GetWindow( xWindow ).get();
 
-        if ( pWindow && pWindow->GetType() == WINDOW_TOOLBOX )
+        if ( pWindow && pWindow->GetType() == WindowType::TOOLBOX )
             pToolBox = static_cast<ToolBox *>(pWindow);
     }
 
diff --git a/framework/source/loadenv/loadenv.cxx b/framework/source/loadenv/loadenv.cxx
index 396e9c1..4687489 100644
--- a/framework/source/loadenv/loadenv.cxx
+++ b/framework/source/loadenv/loadenv.cxx
@@ -1646,7 +1646,7 @@ void LoadEnv::impl_applyPersistentWindowState(const css::uno::Reference< css::aw
         return;
 
     bool bSystemWindow = pWindow->IsSystemWindow();
-    bool bWorkWindow   = (pWindow->GetType() == WINDOW_WORKWINDOW);
+    bool bWorkWindow   = (pWindow->GetType() == WindowType::WORKWINDOW);
 
     if (!bSystemWindow && !bWorkWindow)
         return;
diff --git a/framework/source/services/frame.cxx b/framework/source/services/frame.cxx
index de2c2a3..3bdda77 100644
--- a/framework/source/services/frame.cxx
+++ b/framework/source/services/frame.cxx
@@ -3052,7 +3052,7 @@ void Frame::implts_setIconOnWindow()
             VclPtr<vcl::Window> pWindow = VCLUnoHelper::GetWindow( xContainerWindow );
             if(
                 ( pWindow            != nullptr              ) &&
-                ( pWindow->GetType() == WINDOW_WORKWINDOW )
+                ( pWindow->GetType() == WindowType::WORKWINDOW )
                 )
             {
                 WorkWindow* pWorkWindow = static_cast<WorkWindow*>(pWindow.get());
diff --git a/framework/source/uielement/addonstoolbarmanager.cxx b/framework/source/uielement/addonstoolbarmanager.cxx
index 4f8a4f6..0043c25 100644
--- a/framework/source/uielement/addonstoolbarmanager.cxx
+++ b/framework/source/uielement/addonstoolbarmanager.cxx
@@ -356,7 +356,7 @@ void AddonsToolBarManager::FillToolbar( const Sequence< Sequence< PropertyValue
                         if ( pItemWin )
                         {
                             WindowType nType = pItemWin->GetType();
-                            if ( nType == WINDOW_LISTBOX || nType == WINDOW_MULTILISTBOX || nType == WINDOW_COMBOBOX )
+                            if ( nType == WindowType::LISTBOX || nType == WindowType::MULTILISTBOX || nType == WindowType::COMBOBOX )
                                 pItemWin->SetAccessibleName( m_pToolBar->GetItemText( nId ) );
                             m_pToolBar->SetItemWindow( nId, pItemWin );
                         }
diff --git a/framework/source/uielement/progressbarwrapper.cxx b/framework/source/uielement/progressbarwrapper.cxx
index 07f3452..981e7ee 100644
--- a/framework/source/uielement/progressbarwrapper.cxx
+++ b/framework/source/uielement/progressbarwrapper.cxx
@@ -104,7 +104,7 @@ void ProgressBarWrapper::start( const OUString& Text, ::sal_Int32 Range )
     {
         SolarMutexGuard aSolarMutexGuard;
         VclPtr<vcl::Window> pWindow = VCLUnoHelper::GetWindow( xWindow );
-        if ( pWindow && pWindow->GetType() == WINDOW_STATUSBAR )
+        if ( pWindow && pWindow->GetType() == WindowType::STATUSBAR )
         {
             StatusBar* pStatusBar = static_cast<StatusBar *>(pWindow.get());
             if ( !pStatusBar->IsProgressMode() )
@@ -141,7 +141,7 @@ void ProgressBarWrapper::end()
     {
         SolarMutexGuard aSolarMutexGuard;
         VclPtr<vcl::Window> pWindow = VCLUnoHelper::GetWindow( xWindow );
-        if ( pWindow && pWindow->GetType() == WINDOW_STATUSBAR )
+        if ( pWindow && pWindow->GetType() == WindowType::STATUSBAR )
         {
             StatusBar* pStatusBar = static_cast<StatusBar *>(pWindow.get());
             if ( pStatusBar->IsProgressMode() )
@@ -170,7 +170,7 @@ void ProgressBarWrapper::setText( const OUString& Text )
     {
         SolarMutexGuard aSolarMutexGuard;
         VclPtr<vcl::Window> pWindow = VCLUnoHelper::GetWindow( xWindow );
-        if ( pWindow && pWindow->GetType() == WINDOW_STATUSBAR )
+        if ( pWindow && pWindow->GetType() == WindowType::STATUSBAR )
         {
             StatusBar* pStatusBar = static_cast<StatusBar *>(pWindow.get());
             if( pStatusBar->IsProgressMode() )
@@ -222,7 +222,7 @@ void ProgressBarWrapper::setValue( ::sal_Int32 nValue )
     {
         SolarMutexGuard aSolarMutexGuard;
         VclPtr<vcl::Window> pWindow = VCLUnoHelper::GetWindow( xWindow );
-        if ( pWindow && pWindow->GetType() == WINDOW_STATUSBAR )
+        if ( pWindow && pWindow->GetType() == WindowType::STATUSBAR )
         {
             StatusBar* pStatusBar = static_cast<StatusBar *>(pWindow.get());
             if ( !pStatusBar->IsProgressMode() )
diff --git a/framework/source/uielement/subtoolbarcontroller.cxx b/framework/source/uielement/subtoolbarcontroller.cxx
index aa5450f..146051d 100644
--- a/framework/source/uielement/subtoolbarcontroller.cxx
+++ b/framework/source/uielement/subtoolbarcontroller.cxx
@@ -238,7 +238,7 @@ css::uno::Reference< css::awt::XWindow > SubToolBarController::createPopupWindow
                 m_xUIElement = xUIElement;
 
                 VclPtr<vcl::Window> pTbxWindow = VCLUnoHelper::GetWindow( xSubToolBar );
-                if ( pTbxWindow && pTbxWindow->GetType() == WINDOW_TOOLBOX )
+                if ( pTbxWindow && pTbxWindow->GetType() == WindowType::TOOLBOX )
                 {
                     ToolBox* pToolBar = static_cast< ToolBox* >( pTbxWindow.get() );
                     pToolBar->SetParent( pToolBox );
@@ -369,7 +369,7 @@ void SubToolBarController::endPopupMode( const css::awt::EndPopupModeEvent& e )
                 try
                 {
                     VclPtr<vcl::Window> pTbxWindow = VCLUnoHelper::GetWindow( xSubToolBar );
-                    if ( pTbxWindow && pTbxWindow->GetType() == WINDOW_TOOLBOX )
+                    if ( pTbxWindow && pTbxWindow->GetType() == WindowType::TOOLBOX )
                     {
                         css::uno::Any a = xProp->getPropertyValue( aPersistentString );
                         xProp->setPropertyValue( aPersistentString, css::uno::makeAny( false ) );
diff --git a/framework/source/uielement/toolbarmanager.cxx b/framework/source/uielement/toolbarmanager.cxx
index c7af7cf..a42fe2d 100644
--- a/framework/source/uielement/toolbarmanager.cxx
+++ b/framework/source/uielement/toolbarmanager.cxx
@@ -854,7 +854,7 @@ void ToolBarManager::CreateControllers()
                     if ( pItemWin )
                     {
                         WindowType nType = pItemWin->GetType();
-                        if ( nType == WINDOW_LISTBOX || nType == WINDOW_MULTILISTBOX || nType == WINDOW_COMBOBOX )
+                        if ( nType == WindowType::LISTBOX || nType == WindowType::MULTILISTBOX || nType == WindowType::COMBOBOX )
                             pItemWin->SetAccessibleName( m_pToolBar->GetItemText( nId ) );
                         m_pToolBar->SetItemWindow( nId, pItemWin );
                     }
diff --git a/include/tools/wintypes.hxx b/include/tools/wintypes.hxx
index 7324ee0..bf6b4d2 100644
--- a/include/tools/wintypes.hxx
+++ b/include/tools/wintypes.hxx
@@ -23,92 +23,97 @@
 
 // Window-Types
 
-typedef sal_uInt16 WindowType;
-#define WINDOW_BASE                 0x0100
-#define WINDOW_FIRST                (WINDOW_BASE + 0x30)
-#define WINDOW_MESSBOX              (WINDOW_FIRST)
-#define WINDOW_INFOBOX              (WINDOW_FIRST + 0x01)
-#define WINDOW_WARNINGBOX           (WINDOW_FIRST + 0x02)
-#define WINDOW_ERRORBOX             (WINDOW_FIRST + 0x03)
-#define WINDOW_QUERYBOX             (WINDOW_FIRST + 0x04)
-#define WINDOW_WINDOW               (WINDOW_FIRST + 0x05)
-#define WINDOW_SYSWINDOW            (WINDOW_FIRST + 0x06)
-#define WINDOW_WORKWINDOW           (WINDOW_FIRST + 0x07)
-#define WINDOW_CONTAINER            (WINDOW_FIRST + 0x08)
-#define WINDOW_FLOATINGWINDOW       (WINDOW_FIRST + 0x09)
-#define WINDOW_DIALOG               (WINDOW_FIRST + 0x0a)
-#define WINDOW_MODELESSDIALOG       (WINDOW_FIRST + 0x0b)
-#define WINDOW_MODALDIALOG          (WINDOW_FIRST + 0x0c)
-#define WINDOW_SYSTEMDIALOG         (WINDOW_FIRST + 0x0d)
-#define WINDOW_PATHDIALOG           (WINDOW_FIRST + 0x0e)
-#define WINDOW_FILEDIALOG           (WINDOW_FIRST + 0x0f)
-#define WINDOW_PRINTERSETUPDIALOG   (WINDOW_FIRST + 0x10)
-#define WINDOW_PRINTDIALOG          (WINDOW_FIRST + 0x11)
-#define WINDOW_COLORDIALOG          (WINDOW_FIRST + 0x12)
-#define WINDOW_FONTDIALOG           (WINDOW_FIRST + 0x13)
-#define WINDOW_CONTROL              (WINDOW_FIRST + 0x14)
-#define WINDOW_BUTTON               (WINDOW_FIRST + 0x15)
-#define WINDOW_PUSHBUTTON           (WINDOW_FIRST + 0x16)
-#define WINDOW_OKBUTTON             (WINDOW_FIRST + 0x17)
-#define WINDOW_CANCELBUTTON         (WINDOW_FIRST + 0x18)
-#define WINDOW_HELPBUTTON           (WINDOW_FIRST + 0x19)
-#define WINDOW_IMAGEBUTTON          (WINDOW_FIRST + 0x1a)
-#define WINDOW_MENUBUTTON           (WINDOW_FIRST + 0x1b)
-#define WINDOW_MOREBUTTON           (WINDOW_FIRST + 0x1c)
-#define WINDOW_SPINBUTTON           (WINDOW_FIRST + 0x1d)
-#define WINDOW_RADIOBUTTON          (WINDOW_FIRST + 0x1e)
-#define WINDOW_IMAGERADIOBUTTON     (WINDOW_FIRST + 0x1f)
-#define WINDOW_CHECKBOX             (WINDOW_FIRST + 0x20)
-#define WINDOW_TRISTATEBOX          (WINDOW_FIRST + 0x21)
-#define WINDOW_EDIT                 (WINDOW_FIRST + 0x22)
-#define WINDOW_MULTILINEEDIT        (WINDOW_FIRST + 0x23)
-#define WINDOW_COMBOBOX             (WINDOW_FIRST + 0x24)
-#define WINDOW_LISTBOX              (WINDOW_FIRST + 0x25)
-#define WINDOW_MULTILISTBOX         (WINDOW_FIRST + 0x26)
-#define WINDOW_FIXEDTEXT            (WINDOW_FIRST + 0x27)
-#define WINDOW_FIXEDLINE            (WINDOW_FIRST + 0x28)
-#define WINDOW_FIXEDBITMAP          (WINDOW_FIRST + 0x29)
-#define WINDOW_FIXEDIMAGE           (WINDOW_FIRST + 0x2a)
-#define WINDOW_GROUPBOX             (WINDOW_FIRST + 0x2c)
-#define WINDOW_SCROLLBAR            (WINDOW_FIRST + 0x2d)
-#define WINDOW_SCROLLBARBOX         (WINDOW_FIRST + 0x2e)
-#define WINDOW_SPLITTER             (WINDOW_FIRST + 0x2f)
-#define WINDOW_SPLITWINDOW          (WINDOW_FIRST + 0x30)
-#define WINDOW_SPINFIELD            (WINDOW_FIRST + 0x31)
-#define WINDOW_PATTERNFIELD         (WINDOW_FIRST + 0x32)
-#define WINDOW_NUMERICFIELD         (WINDOW_FIRST + 0x33)
-#define WINDOW_METRICFIELD          (WINDOW_FIRST + 0x34)
-#define WINDOW_CURRENCYFIELD        (WINDOW_FIRST + 0x35)
-#define WINDOW_DATEFIELD            (WINDOW_FIRST + 0x36)
-#define WINDOW_TIMEFIELD            (WINDOW_FIRST + 0x37)
-#define WINDOW_PATTERNBOX           (WINDOW_FIRST + 0x38)
-#define WINDOW_NUMERICBOX           (WINDOW_FIRST + 0x39)
-#define WINDOW_METRICBOX            (WINDOW_FIRST + 0x3a)
-#define WINDOW_CURRENCYBOX          (WINDOW_FIRST + 0x3b)
-#define WINDOW_DATEBOX              (WINDOW_FIRST + 0x3c)
-#define WINDOW_TIMEBOX              (WINDOW_FIRST + 0x3d)
-#define WINDOW_LONGCURRENCYFIELD    (WINDOW_FIRST + 0x3e)
-#define WINDOW_LONGCURRENCYBOX      (WINDOW_FIRST + 0x3f)
-#define WINDOW_SCROLLWINDOW         (WINDOW_FIRST + 0x40)
-#define WINDOW_TOOLBOX              (WINDOW_FIRST + 0x41)
-#define WINDOW_DOCKINGWINDOW        (WINDOW_FIRST + 0x42)
-#define WINDOW_STATUSBAR            (WINDOW_FIRST + 0x43)
-#define WINDOW_TABPAGE              (WINDOW_FIRST + 0x44)
-#define WINDOW_TABCONTROL           (WINDOW_FIRST + 0x45)
-#define WINDOW_TABDIALOG            (WINDOW_FIRST + 0x46)
-#define WINDOW_BORDERWINDOW         (WINDOW_FIRST + 0x47)
-#define WINDOW_BUTTONDIALOG         (WINDOW_FIRST + 0x48)
-#define WINDOW_SYSTEMCHILDWINDOW    (WINDOW_FIRST + 0x49)
-#define WINDOW_SLIDER               (WINDOW_FIRST + 0x4a)
-#define WINDOW_MENUBARWINDOW        (WINDOW_FIRST + 0x4b)
-#define WINDOW_TREELISTBOX          (WINDOW_FIRST + 0x4c)
-#define WINDOW_HELPTEXTWINDOW       (WINDOW_FIRST + 0x4d)
-#define WINDOW_INTROWINDOW          (WINDOW_FIRST + 0x4e)
-#define WINDOW_LISTBOXWINDOW        (WINDOW_FIRST + 0x4f)
-#define WINDOW_DOCKINGAREA          (WINDOW_FIRST + 0x50)
-#define WINDOW_RULER                (WINDOW_FIRST + 0x51)
-#define WINDOW_CALCINPUTLINE        (WINDOW_FIRST + 0x52)
-#define WINDOW_LAST                 (WINDOW_CALCINPUTLINE)
+enum class WindowType : sal_uInt16
+{
+    NONE                 = 0,
+    FIRST                = 0x0130,
+    MESSBOX              = FIRST,
+    INFOBOX              ,
+    WARNINGBOX           ,
+    ERRORBOX             ,
+    QUERYBOX             ,
+    WINDOW               ,
+    SYSWINDOW            ,
+    WORKWINDOW           ,
+    CONTAINER            ,
+    FLOATINGWINDOW       ,
+    DIALOG               ,
+    MODELESSDIALOG       ,
+    MODALDIALOG          ,
+    SYSTEMDIALOG         ,
+    PATHDIALOG           ,
+    FILEDIALOG           ,
+    PRINTERSETUPDIALOG   ,
+    PRINTDIALOG          ,
+    COLORDIALOG          ,
+    FONTDIALOG           ,
+    CONTROL              ,
+    BUTTON               ,
+    PUSHBUTTON           ,
+    OKBUTTON             ,
+    CANCELBUTTON         ,
+    HELPBUTTON           ,
+    IMAGEBUTTON          ,
+    MENUBUTTON           ,
+    MOREBUTTON           ,
+    SPINBUTTON           ,
+    RADIOBUTTON          ,
+    IMAGERADIOBUTTON     ,
+    CHECKBOX             ,
+    TRISTATEBOX          ,
+    EDIT                 ,
+    MULTILINEEDIT        ,
+    COMBOBOX             ,
+    LISTBOX              ,
+    MULTILISTBOX         ,
+    FIXEDTEXT            ,
+    FIXEDLINE            ,
+    FIXEDBITMAP          ,
+    FIXEDIMAGE           ,
+    GROUPBOX             ,
+    SCROLLBAR            ,
+    SCROLLBARBOX         ,
+    SPLITTER             ,
+    SPLITWINDOW          ,
+    SPINFIELD            ,
+    PATTERNFIELD         ,
+    NUMERICFIELD         ,
+    METRICFIELD          ,
+    CURRENCYFIELD        ,
+    DATEFIELD            ,
+    TIMEFIELD            ,
+    PATTERNBOX           ,
+    NUMERICBOX           ,
+    METRICBOX            ,
+    CURRENCYBOX          ,
+    DATEBOX              ,
+    TIMEBOX              ,
+    LONGCURRENCYFIELD    ,
+    LONGCURRENCYBOX      ,
+    SCROLLWINDOW         ,
+    TOOLBOX              ,
+    DOCKINGWINDOW        ,
+    STATUSBAR            ,
+    TABPAGE              ,
+    TABCONTROL           ,
+    TABDIALOG            ,
+    BORDERWINDOW         ,
+    BUTTONDIALOG         ,
+    SYSTEMCHILDWINDOW    ,
+    SLIDER               ,
+    MENUBARWINDOW        ,
+    TREELISTBOX          ,
+    HELPTEXTWINDOW       ,
+    INTROWINDOW          ,
+    LISTBOXWINDOW        ,
+    DOCKINGAREA          ,
+    RULER                ,
+    CALCINPUTLINE        ,
+    LAST                 = CALCINPUTLINE,
+    // only used in vclxtoolkit.cxx
+    TOOLKIT_FRAMEWINDOW        = 0x1000,
+    TOOLKIT_SYSTEMCHILDWINDOW  = 0x1001,
+};
 
 // Window-Bits
 
diff --git a/include/vcl/layout.hxx b/include/vcl/layout.hxx
index 3e03ca2..1673605 100644
--- a/include/vcl/layout.hxx
+++ b/include/vcl/layout.hxx
@@ -711,8 +711,8 @@ VCL_DLLPUBLIC bool isLayoutEnabled(const vcl::Window *pWindow);
 inline bool isContainerWindow(const vcl::Window &rWindow)
 {
     WindowType eType = rWindow.GetType();
-    return eType == WINDOW_CONTAINER || eType == WINDOW_SCROLLWINDOW ||
-           (eType == WINDOW_DOCKINGWINDOW && ::isLayoutEnabled(&rWindow));
+    return eType == WindowType::CONTAINER || eType == WindowType::SCROLLWINDOW ||
+           (eType == WindowType::DOCKINGWINDOW && ::isLayoutEnabled(&rWindow));
 }
 
 inline bool isContainerWindow(const vcl::Window *pWindow)
diff --git a/sc/source/ui/app/inputwin.cxx b/sc/source/ui/app/inputwin.cxx
index 5aab050..e44d5ec 100644
--- a/sc/source/ui/app/inputwin.cxx
+++ b/sc/source/ui/app/inputwin.cxx
@@ -104,7 +104,7 @@ ScTextWndBase::ScTextWndBase( vcl::Window* pParent,  WinBits nStyle )
 {
     if ( IsNativeControlSupported( ControlType::Editbox, ControlPart::Entire ) )
     {
-        SetType( WINDOW_CALCINPUTLINE );
+        SetType( WindowType::CALCINPUTLINE );
         SetBorderStyle( WindowBorderStyle::NWF );
     }
 }
diff --git a/sfx2/source/appl/childwin.cxx b/sfx2/source/appl/childwin.cxx
index 84cfd12..9116876 100644
--- a/sfx2/source/appl/childwin.cxx
+++ b/sfx2/source/appl/childwin.cxx
@@ -520,11 +520,11 @@ SfxChildWindowContext::~SfxChildWindowContext()
 
 FloatingWindow* SfxChildWindowContext::GetFloatingWindow(vcl::Window *pParent)
 {
-    if (pParent->GetType() == WINDOW_DOCKINGWINDOW || pParent->GetType() == WINDOW_TOOLBOX)
+    if (pParent->GetType() == WindowType::DOCKINGWINDOW || pParent->GetType() == WindowType::TOOLBOX)
     {
         return static_cast<DockingWindow*>(pParent)->GetFloatingWindow();
     }
-    if (pParent->GetType() == WINDOW_FLOATINGWINDOW)
+    if (pParent->GetType() == WindowType::FLOATINGWINDOW)
     {
         return static_cast<FloatingWindow*>(pParent);
     }
diff --git a/sfx2/source/appl/workwin.cxx b/sfx2/source/appl/workwin.cxx
index 10e3366..f0cdfc4 100644
--- a/sfx2/source/appl/workwin.cxx
+++ b/sfx2/source/appl/workwin.cxx
@@ -747,7 +747,7 @@ SvBorder SfxWorkWindow::Arrange_Impl()
             case SfxChildAlignment::TOOLBOXTOP:
             case SfxChildAlignment::LOWESTTOP:
                 aSize.Width() = aTmp.GetWidth();
-                if ( pCli->pWin->GetType() == WINDOW_SPLITWINDOW )
+                if ( pCli->pWin->GetType() == WindowType::SPLITWINDOW )
                     aSize = static_cast<SplitWindow *>(pCli->pWin.get())->CalcLayoutSizePixel( aSize );
                 bAllowHiding = false;
                 aBorder.Top() += aSize.Height();
@@ -762,7 +762,7 @@ SvBorder SfxWorkWindow::Arrange_Impl()
             case SfxChildAlignment::TOOLBOXBOTTOM:
             case SfxChildAlignment::HIGHESTBOTTOM:
                 aSize.Width() = aTmp.GetWidth();
-                if ( pCli->pWin->GetType() == WINDOW_SPLITWINDOW )
+                if ( pCli->pWin->GetType() == WindowType::SPLITWINDOW )
                     aSize = static_cast<SplitWindow *>(pCli->pWin.get())->CalcLayoutSizePixel( aSize );
                 aBorder.Bottom() += aSize.Height();
                 aPos = aTmp.BottomLeft();
@@ -777,7 +777,7 @@ SvBorder SfxWorkWindow::Arrange_Impl()
             case SfxChildAlignment::LASTLEFT:
             case SfxChildAlignment::TOOLBOXLEFT:
                 aSize.Height() = aTmp.GetHeight();
-                if ( pCli->pWin->GetType() == WINDOW_SPLITWINDOW )
+                if ( pCli->pWin->GetType() == WindowType::SPLITWINDOW )
                     aSize = static_cast<SplitWindow *>(pCli->pWin.get())->CalcLayoutSizePixel( aSize );
                 bAllowHiding = false;
                 aBorder.Left() += aSize.Width();
@@ -792,7 +792,7 @@ SvBorder SfxWorkWindow::Arrange_Impl()
             case SfxChildAlignment::LASTRIGHT:
             case SfxChildAlignment::TOOLBOXRIGHT:
                 aSize.Height() = aTmp.GetHeight();
-                if ( pCli->pWin->GetType() == WINDOW_SPLITWINDOW )
+                if ( pCli->pWin->GetType() == WindowType::SPLITWINDOW )
                     aSize = static_cast<SplitWindow *>(pCli->pWin.get())->CalcLayoutSizePixel( aSize );
                 aBorder.Right() += aSize.Width();
                 aPos = aTmp.TopRight();
diff --git a/sfx2/source/notebookbar/ContextVBox.cxx b/sfx2/source/notebookbar/ContextVBox.cxx
index 8723cc4..8b59cfa 100644
--- a/sfx2/source/notebookbar/ContextVBox.cxx
+++ b/sfx2/source/notebookbar/ContextVBox.cxx
@@ -46,7 +46,7 @@ public:
     {
         for (int nChild = 0; nChild < GetChildCount(); ++nChild)
         {
-            if ( GetChild( nChild )->GetType() == WINDOW_CONTAINER )
+            if ( GetChild( nChild )->GetType() == WindowType::CONTAINER )
             {
                 VclContainer* pChild = static_cast<VclContainer*>( GetChild( nChild ) );
 
diff --git a/sfx2/source/notebookbar/PriorityHBox.cxx b/sfx2/source/notebookbar/PriorityHBox.cxx
index 13ff34f..c1f60ac 100644
--- a/sfx2/source/notebookbar/PriorityHBox.cxx
+++ b/sfx2/source/notebookbar/PriorityHBox.cxx
@@ -126,7 +126,7 @@ public:
             m_nNeededWidth += pChild->GetSizePixel().Width() + spacing;
 
             // Add only containers which have explicitly assigned priority.
-            IPrioritable* pPrioritable = pChild->GetType() == WINDOW_CONTAINER ?
+            IPrioritable* pPrioritable = pChild->GetType() == WindowType::CONTAINER ?
                 dynamic_cast<IPrioritable*>(pChild) : nullptr;
             if (pPrioritable && pPrioritable->GetPriority() != VCL_PRIORITY_DEFAULT)
                 m_aSortedChilds.push_back(pPrioritable);
diff --git a/sfx2/source/sidebar/ControllerFactory.cxx b/sfx2/source/sidebar/ControllerFactory.cxx
index 45d26eb8..0048498 100644
--- a/sfx2/source/sidebar/ControllerFactory.cxx
+++ b/sfx2/source/sidebar/ControllerFactory.cxx
@@ -110,7 +110,7 @@ Reference<frame::XToolbarController> ControllerFactory::CreateToolBoxController(
             if (pItemWindow != nullptr)
             {
                 WindowType nType = pItemWindow->GetType();
-                if (nType == WINDOW_LISTBOX || nType == WINDOW_MULTILISTBOX || nType == WINDOW_COMBOBOX)
+                if (nType == WindowType::LISTBOX || nType == WindowType::MULTILISTBOX || nType == WindowType::COMBOBOX)
                     pItemWindow->SetAccessibleName(pToolBox->GetItemText(nItemId));
                 if (nWidth > 0)
                     pItemWindow->SetSizePixel(Size(nWidth, pItemWindow->GetSizePixel().Height()));
diff --git a/svtools/source/contnr/treelistbox.cxx b/svtools/source/contnr/treelistbox.cxx
index bd87930..fcbdc00 100644
--- a/svtools/source/contnr/treelistbox.cxx
+++ b/svtools/source/contnr/treelistbox.cxx
@@ -357,7 +357,7 @@ SvTreeListBox::SvTreeListBox(vcl::Window* pParent, WinBits nWinStyle) :
     pEdCtrl = nullptr;
     eSelMode = SelectionMode::Single;
     nDragDropMode = DragDropMode::NONE;
-    SetType(WINDOW_TREELISTBOX);
+    SetType(WindowType::TREELISTBOX);
 
     InitTreeView();
 
diff --git a/svtools/source/control/ruler.cxx b/svtools/source/control/ruler.cxx
index 413e92c..874caa5 100644
--- a/svtools/source/control/ruler.cxx
+++ b/svtools/source/control/ruler.cxx
@@ -278,7 +278,7 @@ void Ruler::ImplInit( WinBits nWinBits )
     else
         aDefSize.Width() = nDefHeight;
     SetOutputSizePixel( aDefSize );
-    SetType(WINDOW_RULER);
+    SetType(WindowType::RULER);
 }
 
 Ruler::Ruler( vcl::Window* pParent, WinBits nWinStyle ) :
diff --git a/svtools/source/dialogs/wizardmachine.cxx b/svtools/source/dialogs/wizardmachine.cxx
index e6dd46c..0923538 100644
--- a/svtools/source/dialogs/wizardmachine.cxx
+++ b/svtools/source/dialogs/wizardmachine.cxx
@@ -319,14 +319,14 @@ namespace svt
 
             // is it a button?
             WindowType eType = pChildLoop->GetType();
-            if  (   (WINDOW_BUTTON == eType)
-                ||  (WINDOW_PUSHBUTTON == eType)
-                ||  (WINDOW_OKBUTTON == eType)
-                ||  (WINDOW_CANCELBUTTON == eType)
-                ||  (WINDOW_HELPBUTTON == eType)
-                ||  (WINDOW_IMAGEBUTTON == eType)
-                ||  (WINDOW_MENUBUTTON == eType)
-                ||  (WINDOW_MOREBUTTON == eType)
+            if  (   (WindowType::BUTTON == eType)
+                ||  (WindowType::PUSHBUTTON == eType)
+                ||  (WindowType::OKBUTTON == eType)
+                ||  (WindowType::CANCELBUTTON == eType)
+                ||  (WindowType::HELPBUTTON == eType)
+                ||  (WindowType::IMAGEBUTTON == eType)
+                ||  (WindowType::MENUBUTTON == eType)
+                ||  (WindowType::MOREBUTTON == eType)
                 )
             {
                 pChildLoop->SetStyle(pChildLoop->GetStyle() & ~WB_DEFBUTTON);
diff --git a/svtools/source/uno/popupwindowcontroller.cxx b/svtools/source/uno/popupwindowcontroller.cxx
index 51d7bbc..dd4f6cf 100644
--- a/svtools/source/uno/popupwindowcontroller.cxx
+++ b/svtools/source/uno/popupwindowcontroller.cxx
@@ -196,7 +196,7 @@ Reference< awt::XWindow > SAL_CALL PopupWindowController::createPopupWindow()
                                              FloatWinPopupFlags::NoMouseUpClose;
 
             WinBits nWinBits;
-            if ( pWin->GetType() == WINDOW_DOCKINGWINDOW )
+            if ( pWin->GetType() == WindowType::DOCKINGWINDOW )
                 nWinBits = static_cast< DockingWindow* >( pWin.get() )->GetFloatStyle();
             else
                 nWinBits = pWin->GetStyle();
diff --git a/svtools/source/uno/statusbarcontroller.cxx b/svtools/source/uno/statusbarcontroller.cxx
index 8bb37ea..0b00ac3 100644
--- a/svtools/source/uno/statusbarcontroller.cxx
+++ b/svtools/source/uno/statusbarcontroller.cxx
@@ -279,7 +279,7 @@ void SAL_CALL StatusbarController::statusChanged( const FeatureStateEvent& Event
         return;
 
     VclPtr<vcl::Window> pWindow = VCLUnoHelper::GetWindow( m_xParentWindow );
-    if ( pWindow && pWindow->GetType() == WINDOW_STATUSBAR && m_nID != 0 )
+    if ( pWindow && pWindow->GetType() == WindowType::STATUSBAR && m_nID != 0 )
     {
         OUString   aStrValue;
         StatusBar* pStatusBar = static_cast<StatusBar *>(pWindow.get());
@@ -503,7 +503,7 @@ void StatusbarController::bindListener()
         if ( m_xParentWindow.is() )
         {
             VclPtr< StatusBar > pStatusBar = dynamic_cast< StatusBar* >( VCLUnoHelper::GetWindow( m_xParentWindow ).get() );
-            if ( pStatusBar && pStatusBar->GetType() == WINDOW_STATUSBAR )
+            if ( pStatusBar && pStatusBar->GetType() == WindowType::STATUSBAR )
                 aRect = pStatusBar->GetItemRect( m_nID );
         }
     }
diff --git a/svx/source/accessibility/svxpixelctlaccessiblecontext.cxx b/svx/source/accessibility/svxpixelctlaccessiblecontext.cxx
index 162264f..ed62e56 100644
--- a/svx/source/accessibility/svxpixelctlaccessiblecontext.cxx
+++ b/svx/source/accessibility/svxpixelctlaccessiblecontext.cxx
@@ -90,7 +90,7 @@ uno::Reference< XAccessible > SvxPixelCtlAccessible::getAccessibleParent(  )
 {
     ::osl::MutexGuard   aGuard( m_aMutex );
     vcl::Window *pTabPage = getNonLayoutParent(&mrPixelCtl);
-    if (!pTabPage || WINDOW_TABPAGE != pTabPage->GetType())
+    if (!pTabPage || WindowType::TABPAGE != pTabPage->GetType())
         return uno::Reference< XAccessible >();
     else
         return pTabPage->GetAccessible();
@@ -101,7 +101,7 @@ sal_Int32 SvxPixelCtlAccessible::getAccessibleIndexInParent(  )
     ::osl::MutexGuard   aGuard( m_aMutex );
     sal_uInt16 nIdx = 0;
     vcl::Window *pTabPage = getNonLayoutParent(&mrPixelCtl);
-    if (!pTabPage || WINDOW_TABPAGE != pTabPage->GetType())
+    if (!pTabPage || WindowType::TABPAGE != pTabPage->GetType())
         return -1;
     sal_uInt16 nChildren = pTabPage->GetChildCount();
     for(nIdx = 0; nIdx < nChildren; nIdx++)
diff --git a/svx/source/dialog/dlgctrl.cxx b/svx/source/dialog/dlgctrl.cxx
index 42bde26..c6283ba 100644
--- a/svx/source/dialog/dlgctrl.cxx
+++ b/svx/source/dialog/dlgctrl.cxx
@@ -270,7 +270,7 @@ void SvxRectCtl::MouseButtonDown( const MouseEvent& rMEvt )
             SetActualRP( eRP );
 
             vcl::Window *pTabPage = getNonLayoutParent(this);
-            if (pTabPage && WINDOW_TABPAGE == pTabPage->GetType())
+            if (pTabPage && WindowType::TABPAGE == pTabPage->GetType())
                 static_cast<SvxTabPage*>(pTabPage)->PointChanged( this, eRP );
         }
     }
@@ -355,7 +355,7 @@ void SvxRectCtl::KeyInput( const KeyEvent& rKeyEvt )
             SetActualRP( eNewRP );
 
             vcl::Window *pTabPage = getNonLayoutParent(this);
-            if (pTabPage && WINDOW_TABPAGE == pTabPage->GetType())
+            if (pTabPage && WindowType::TABPAGE == pTabPage->GetType())
                 static_cast<SvxTabPage*>(pTabPage)->PointChanged(this, eRP);
 
             SetFocusRect();
@@ -671,7 +671,7 @@ void SvxRectCtl::SetState( CTL_STATE nState )
     Invalidate();
 
     vcl::Window *pTabPage = getNonLayoutParent(this);
-    if (pTabPage && WINDOW_TABPAGE == pTabPage->GetType())
+    if (pTabPage && WindowType::TABPAGE == pTabPage->GetType())
         static_cast<SvxTabPage*>(pTabPage)->PointChanged(this, eRP);
 }
 
@@ -792,7 +792,7 @@ long SvxPixelCtl::ShowPosition( const Point &pt)
     Invalidate(Rectangle(Point(0,0),aRectSize));
 
     vcl::Window *pTabPage = getNonLayoutParent(this);
-    if (pTabPage && WINDOW_TABPAGE == pTabPage->GetType())
+    if (pTabPage && WindowType::TABPAGE == pTabPage->GetType())
         static_cast<SvxTabPage*>(pTabPage)->PointChanged( this, RectPoint::MM ); // RectPoint ist dummy
 
     return GetFocusPosIndex();
diff --git a/svx/source/sidebar/PanelLayout.cxx b/svx/source/sidebar/PanelLayout.cxx
index 80245dc..4f02866 100644
--- a/svx/source/sidebar/PanelLayout.cxx
+++ b/svx/source/sidebar/PanelLayout.cxx
@@ -85,7 +85,7 @@ void PanelLayout::setPosSizePixel(long nX, long nY, long nWidth, long nHeight, P
     bool bIsLayoutEnabled = isLayoutEnabled(this);
     vcl::Window *pChild = GetWindow(GetWindowType::FirstChild);
 
-    if (bIsLayoutEnabled && pChild->GetType() == WINDOW_SCROLLWINDOW)
+    if (bIsLayoutEnabled && pChild->GetType() == WindowType::SCROLLWINDOW)
     {
         WinBits nStyle = pChild->GetStyle();
         if (nStyle & (WB_AUTOHSCROLL | WB_HSCROLL))
diff --git a/svx/source/tbxctrls/SvxColorValueSet.cxx b/svx/source/tbxctrls/SvxColorValueSet.cxx
index cde72ac..6595544 100644
--- a/svx/source/tbxctrls/SvxColorValueSet.cxx
+++ b/svx/source/tbxctrls/SvxColorValueSet.cxx
@@ -124,7 +124,7 @@ void SvxColorValueSet::Resize()
 {
     vcl::Window *pParent = GetParent();
     //don't do this for the drop down color palettes
-    if (pParent && pParent->GetType() != WINDOW_FLOATINGWINDOW)
+    if (pParent && pParent->GetType() != WindowType::FLOATINGWINDOW)
         layoutToGivenHeight(GetOutputSizePixel().Height(), GetItemCount());
     ValueSet::Resize();
 }
diff --git a/svx/source/tbxctrls/verttexttbxctrl.cxx b/svx/source/tbxctrls/verttexttbxctrl.cxx
index dce2e51..3b1a33d 100644
--- a/svx/source/tbxctrls/verttexttbxctrl.cxx
+++ b/svx/source/tbxctrls/verttexttbxctrl.cxx
@@ -80,8 +80,7 @@ void SvxVertCTLTextTbxCtrl::StateChanged(
     {
         ToolBox& rTbx = GetToolBox();
         vcl::Window* pParent = rTbx.GetParent();
-        WindowType nWinType = pParent->GetType();
-        if(WINDOW_FLOATINGWINDOW == nWinType)
+        if(WindowType::FLOATINGWINDOW == pParent->GetType())
         {
             Size aSize(rTbx.CalcWindowSizePixel());
             rTbx.SetPosSizePixel( Point(), aSize );
diff --git a/sw/source/ui/index/cnttab.cxx b/sw/source/ui/index/cnttab.cxx
index d1c630b..66a8e01 100644
--- a/sw/source/ui/index/cnttab.cxx
+++ b/sw/source/ui/index/cnttab.cxx
@@ -2245,8 +2245,8 @@ IMPL_LINK(SwTOXEntryTabPage, RemoveInsertAuthHdl, Button*, pButton, void)
     else
     {
         Control* pCtrl = m_pTokenWIN->GetActiveControl();
-        OSL_ENSURE(WINDOW_EDIT != pCtrl->GetType(), "Remove should be disabled");
-        if( WINDOW_EDIT != pCtrl->GetType() )
+        OSL_ENSURE(WindowType::EDIT != pCtrl->GetType(), "Remove should be disabled");
+        if( WindowType::EDIT != pCtrl->GetType() )
         {
             //fill it into the ListBox
             const SwFormToken& rToken = static_cast<SwTOXButton*>(pCtrl)->GetFormToken();
@@ -2544,7 +2544,7 @@ IMPL_LINK(SwTOXEntryTabPage, StyleSelectHdl, ListBox&, rBox, void)
     OSL_ENSURE(pCtrl, "no active control?");
     if(pCtrl)
     {
-        if(WINDOW_EDIT == pCtrl->GetType())
+        if(WindowType::EDIT == pCtrl->GetType())
             static_cast<SwTOXEdit*>(pCtrl)->SetCharStyleName(sEntry, nId);
         else
             static_cast<SwTOXButton*>(pCtrl)->SetCharStyleName(sEntry, nId);
@@ -2560,7 +2560,7 @@ IMPL_LINK(SwTOXEntryTabPage, ChapterInfoHdl, ListBox&, rBox, void)
     {
         Control* pCtrl = m_pTokenWIN->GetActiveControl();
         OSL_ENSURE(pCtrl, "no active control?");
-        if(pCtrl && WINDOW_EDIT != pCtrl->GetType())
+        if(pCtrl && WindowType::EDIT != pCtrl->GetType())
             static_cast<SwTOXButton*>(pCtrl)->SetChapterInfo(nPos);
 
         ModifyHdl(nullptr);
@@ -2573,7 +2573,7 @@ IMPL_LINK(SwTOXEntryTabPage, ChapterInfoOutlineHdl, Edit&, rEdit, void)
 
     Control* pCtrl = m_pTokenWIN->GetActiveControl();
     OSL_ENSURE(pCtrl, "no active control?");
-    if(pCtrl && WINDOW_EDIT != pCtrl->GetType())
+    if(pCtrl && WindowType::EDIT != pCtrl->GetType())
         static_cast<SwTOXButton*>(pCtrl)->SetOutlineLevel(nLevel);
 
     ModifyHdl(nullptr);
@@ -2587,7 +2587,7 @@ IMPL_LINK(SwTOXEntryTabPage, NumberFormatHdl, ListBox&, rBox, void)
     {
         Control* pCtrl = m_pTokenWIN->GetActiveControl();
         OSL_ENSURE(pCtrl, "no active control?");
-        if(pCtrl && WINDOW_EDIT != pCtrl->GetType())
+        if(pCtrl && WindowType::EDIT != pCtrl->GetType())
         {
            static_cast<SwTOXButton*>(pCtrl)->SetEntryNumberFormat(nPos);//i89791
         }
@@ -2599,10 +2599,10 @@ IMPL_LINK(SwTOXEntryTabPage, TabPosHdl, Edit&, rEdit, void)
 {
     MetricField* pField = static_cast<MetricField*>(&rEdit);
     Control* pCtrl = m_pTokenWIN->GetActiveControl();
-    OSL_ENSURE(pCtrl && WINDOW_EDIT != pCtrl->GetType() &&
+    OSL_ENSURE(pCtrl && WindowType::EDIT != pCtrl->GetType() &&
         TOKEN_TAB_STOP == static_cast<SwTOXButton*>(pCtrl)->GetFormToken().eTokenType,
                 "no active style::TabStop control?");
-    if( pCtrl && WINDOW_EDIT != pCtrl->GetType() )
+    if( pCtrl && WindowType::EDIT != pCtrl->GetType() )
     {
         static_cast<SwTOXButton*>(pCtrl)->SetTabPosition( static_cast< SwTwips >(
                 pField->Denormalize( pField->GetValue( FUNIT_TWIP ))));
@@ -2613,10 +2613,10 @@ IMPL_LINK(SwTOXEntryTabPage, TabPosHdl, Edit&, rEdit, void)
 IMPL_LINK(SwTOXEntryTabPage, FillCharHdl, Edit&, rBox, void)
 {
     Control* pCtrl = m_pTokenWIN->GetActiveControl();
-    OSL_ENSURE(pCtrl && WINDOW_EDIT != pCtrl->GetType() &&
+    OSL_ENSURE(pCtrl && WindowType::EDIT != pCtrl->GetType() &&
         TOKEN_TAB_STOP == static_cast<SwTOXButton*>(pCtrl)->GetFormToken().eTokenType,
                 "no active style::TabStop control?");
-    if(pCtrl && WINDOW_EDIT != pCtrl->GetType())
+    if(pCtrl && WindowType::EDIT != pCtrl->GetType())
     {
         sal_Unicode cSet;
         if( !rBox.GetText().isEmpty() )
@@ -2632,7 +2632,7 @@ IMPL_LINK(SwTOXEntryTabPage, AutoRightHdl, Button*, pBox, void)
 {
     //the most right style::TabStop is usually right aligned
     Control* pCurCtrl = m_pTokenWIN->GetActiveControl();
-    OSL_ENSURE(WINDOW_EDIT != pCurCtrl->GetType() &&
+    OSL_ENSURE(WindowType::EDIT != pCurCtrl->GetType() &&
             static_cast<SwTOXButton*>(pCurCtrl)->GetFormToken().eTokenType == TOKEN_TAB_STOP,
             "no style::TabStop selected!");
 
@@ -2853,7 +2853,7 @@ void SwTokenWindow::SetActiveControl(Control* pSet)
             pActiveCtrl->GrabFocus();
             //it must be a SwTOXEdit
             const SwFormToken* pFToken;
-            if( WINDOW_EDIT == pActiveCtrl->GetType() )
+            if( WindowType::EDIT == pActiveCtrl->GetType() )
                 pFToken = &static_cast<SwTOXEdit*>(pActiveCtrl.get())->GetFormToken();
             else
                 pFToken = &static_cast<SwTOXButton*>(pActiveCtrl.get())->GetFormToken();
@@ -2977,7 +2977,7 @@ void SwTokenWindow::InsertAtSelection(const OUString& rText, const SwFormToken&
         {
             pControl = *it;
 
-            if( WINDOW_EDIT != pControl->GetType())
+            if( WindowType::EDIT != pControl->GetType())
             {
                 const SwFormToken& rNewToken =
                                 static_cast<const SwTOXButton*>(pControl)->GetFormToken();
@@ -3009,7 +3009,7 @@ void SwTokenWindow::InsertAtSelection(const OUString& rText, const SwFormToken&
                 pControl = *it;
 
                 if( pControl != pActiveCtrl &&
-                    WINDOW_EDIT != pControl->GetType())
+                    WindowType::EDIT != pControl->GetType())
                 {
                     const SwFormToken& rNewToken =
                                     static_cast<const SwTOXButton*>(pControl)->GetFormToken();
@@ -3073,7 +3073,7 @@ void SwTokenWindow::InsertAtSelection(const OUString& rText, const SwFormToken&
 
     Size aControlSize(GetOutputSizePixel());
 
-    if( WINDOW_EDIT == pActiveCtrl->GetType())
+    if( WindowType::EDIT == pActiveCtrl->GetType())
     {
         ++iterActive;
 
@@ -3371,7 +3371,7 @@ OUString SwTokenWindow::GetPattern() const
     {
         const Control *pCtrl = *it;
 
-        const SwFormToken &rNewToken = pCtrl->GetType() == WINDOW_EDIT
+        const SwFormToken &rNewToken = pCtrl->GetType() == WindowType::EDIT
                 ? const_cast<SwTOXEdit*>(static_cast<const SwTOXEdit*>(pCtrl))->GetFormToken()
                 : static_cast<const SwTOXButton*>(pCtrl)->GetFormToken();
 
@@ -3391,7 +3391,7 @@ bool SwTokenWindow::Contains(FormTokenType eSearchFor) const
     {
         const Control *pCtrl = *it;
 
-        const SwFormToken &rNewToken = pCtrl->GetType() == WINDOW_EDIT
+        const SwFormToken &rNewToken = pCtrl->GetType() == WindowType::EDIT
                 ? const_cast<SwTOXEdit*>(static_cast<const SwTOXEdit*>(pCtrl))->GetFormToken()
                 : static_cast<const SwTOXButton*>(pCtrl)->GetFormToken();
 
@@ -3480,7 +3480,7 @@ IMPL_LINK(SwTokenWindow, TbxFocusHdl, Control&, rControl, void)
     SwTOXEdit* pEdit = static_cast<SwTOXEdit*>(&rControl);
     for (VclPtr<Control> const & pCtrl : aControlList)
     {
-        if (pCtrl && pCtrl->GetType() != WINDOW_EDIT)
+        if (pCtrl && pCtrl->GetType() != WindowType::EDIT)
             static_cast<SwTOXButton*>(pCtrl.get())->Check(false);
     }
 
@@ -3531,7 +3531,7 @@ IMPL_LINK(SwTokenWindow, TbxFocusBtnHdl, Control&, rControl, void )
     {
         Control *pControl = it->get();
 
-        if (pControl && WINDOW_EDIT != pControl->GetType())
+        if (pControl && WindowType::EDIT != pControl->GetType())
             static_cast<SwTOXButton*>(pControl)->Check(pBtn == pControl);
     }
 
@@ -3577,7 +3577,7 @@ sal_uInt32 SwTokenWindow::GetControlIndex(FormTokenType eType) const
     for (ctrl_const_iterator it = aControlList.begin(); it != aControlList.end(); ++it)
     {
         const Control* pControl = *it;
-        const SwFormToken& rNewToken = WINDOW_EDIT == pControl->GetType()
+        const SwFormToken& rNewToken = WindowType::EDIT == pControl->GetType()
             ? const_cast<SwTOXEdit*>(static_cast<const SwTOXEdit*>(pControl))->GetFormToken()
             : static_cast<const SwTOXButton*>(pControl)->GetFormToken();
 
diff --git a/sw/source/uibase/dbui/dbui.cxx b/sw/source/uibase/dbui/dbui.cxx
index 75d3d36..931683f 100644
--- a/sw/source/uibase/dbui/dbui.cxx
+++ b/sw/source/uibase/dbui/dbui.cxx
@@ -108,7 +108,7 @@ void CreateMonitor::SetCurrentPosition( sal_Int32 nCurrent )
 CancelableDialog::CancelableDialog( vcl::Window *pParent, bool modal,
         const OUString& rID, const OUString& rUIXMLDescription )
     : Dialog( pParent , rID, rUIXMLDescription,
-              modal ? WINDOW_MODALDIALOG : WINDOW_MODELESSDIALOG )
+              modal ? WindowType::MODALDIALOG : WindowType::MODELESSDIALOG )
     , mbModal( modal )
 {
     get(m_pCancelButton, "cancel");
diff --git a/toolkit/source/awt/vclxaccessiblecomponent.cxx b/toolkit/source/awt/vclxaccessiblecomponent.cxx
index e1396e11..7d3600b 100644
--- a/toolkit/source/awt/vclxaccessiblecomponent.cxx
+++ b/toolkit/source/awt/vclxaccessiblecomponent.cxx
@@ -436,7 +436,7 @@ void VCLXAccessibleComponent::FillAccessibleStateSet( utl::AccessibleStateSetHel
         }
         //If a combobox or list's edit child isn't read-only,EDITABLE state
         //should be set.
-        if( pWindow && pWindow->GetType() == WINDOW_COMBOBOX )
+        if( pWindow && pWindow->GetType() == WindowType::COMBOBOX )
         {
             if( !( pWindow->GetStyle() & WB_READONLY) ||
                 !static_cast<Edit*>(pWindow.get())->IsReadOnly() )
@@ -448,14 +448,14 @@ void VCLXAccessibleComponent::FillAccessibleStateSet( utl::AccessibleStateSetHel
         while( pWindow && pChild )
         {
             VclPtr<vcl::Window> pWinTemp = pChild->GetWindow( GetWindowType::FirstChild );
-            if( pWinTemp && pWinTemp->GetType() == WINDOW_EDIT )
+            if( pWinTemp && pWinTemp->GetType() == WindowType::EDIT )
             {
                 if( !( pWinTemp->GetStyle() & WB_READONLY) ||
                     !static_cast<Edit*>(pWinTemp.get())->IsReadOnly() )
                     rStateSet.AddState( accessibility::AccessibleStateType::EDITABLE );
                 break;
             }
-            if( pChild->GetType() == WINDOW_EDIT )
+            if( pChild->GetType() == WindowType::EDIT )
             {
                 if( !( pChild->GetStyle() & WB_READONLY) ||
                     !static_cast<Edit*>(pChild.get())->IsReadOnly())
diff --git a/toolkit/source/awt/vclxcontainer.cxx b/toolkit/source/awt/vclxcontainer.cxx
index 0f8a3bb..ec437aa 100644
--- a/toolkit/source/awt/vclxcontainer.cxx
+++ b/toolkit/source/awt/vclxcontainer.cxx
@@ -185,7 +185,7 @@ void VCLXContainer::setGroup( const css::uno::Sequence< css::uno::Reference< css
             vcl::Window* pSortBehind = pPrevWin;
             // #57096# Sort all radios consecutively
             bool bNewPrevWin = true;
-            if ( pWin->GetType() == WINDOW_RADIOBUTTON )
+            if ( pWin->GetType() == WindowType::RADIOBUTTON )
             {
                 if ( pPrevRadio )
                 {
diff --git a/toolkit/source/awt/vclxtoolkit.cxx b/toolkit/source/awt/vclxtoolkit.cxx
index b80d260..5feba060 100644
--- a/toolkit/source/awt/vclxtoolkit.cxx
+++ b/toolkit/source/awt/vclxtoolkit.cxx
@@ -124,9 +124,6 @@
 
 #include "helper/unowrapper.hxx"
 
-#define VCLWINDOW_FRAMEWINDOW               0x1000
-#define VCLWINDOW_SYSTEMCHILDWINDOW         0x1001
-
 #if defined(_WIN32)
 #define SYSTEM_DEPENDENT_TYPE css::lang::SystemDependent::SYSTEM_WIN32
 #elif defined(MACOSX)
@@ -308,36 +305,36 @@ public:
 
 };
 
-WinBits ImplGetWinBits( sal_uInt32 nComponentAttribs, sal_uInt16 nCompType )
+WinBits ImplGetWinBits( sal_uInt32 nComponentAttribs, WindowType nCompType )
 {
     WinBits nWinBits = 0;
 
     bool bMessBox = false;
-    if ( ( nCompType == WINDOW_INFOBOX ) ||
-         ( nCompType == WINDOW_MESSBOX ) ||
-         ( nCompType == WINDOW_QUERYBOX ) ||
-         ( nCompType == WINDOW_WARNINGBOX ) ||
-         ( nCompType == WINDOW_ERRORBOX ) )
+    if ( ( nCompType == WindowType::INFOBOX ) ||
+         ( nCompType == WindowType::MESSBOX ) ||
+         ( nCompType == WindowType::QUERYBOX ) ||
+         ( nCompType == WindowType::WARNINGBOX ) ||
+         ( nCompType == WindowType::ERRORBOX ) )
     {
         bMessBox = true;
     }
 
     bool bDecoratedWindow = false;
     if  (   bMessBox
-        ||  ( nCompType == WINDOW_DIALOG )
-        ||  ( nCompType == WINDOW_MODELESSDIALOG )
-        ||  ( nCompType == WINDOW_MODALDIALOG )
-        ||  ( nCompType == WINDOW_SYSTEMDIALOG )
-        ||  ( nCompType == WINDOW_PATHDIALOG )
-        ||  ( nCompType == WINDOW_FILEDIALOG )
-        ||  ( nCompType == WINDOW_PRINTERSETUPDIALOG )
-        ||  ( nCompType == WINDOW_PRINTDIALOG )
-        ||  ( nCompType == WINDOW_COLORDIALOG )
-        ||  ( nCompType == WINDOW_FONTDIALOG )
-        ||  ( nCompType == WINDOW_DOCKINGWINDOW )
-        ||  ( nCompType == WINDOW_TABDIALOG )
-        ||  ( nCompType == WINDOW_BUTTONDIALOG )
-        ||  ( nCompType == WINDOW_SYSTEMCHILDWINDOW )
+        ||  ( nCompType == WindowType::DIALOG )
+        ||  ( nCompType == WindowType::MODELESSDIALOG )
+        ||  ( nCompType == WindowType::MODALDIALOG )
+        ||  ( nCompType == WindowType::SYSTEMDIALOG )
+        ||  ( nCompType == WindowType::PATHDIALOG )
+        ||  ( nCompType == WindowType::FILEDIALOG )
+        ||  ( nCompType == WindowType::PRINTERSETUPDIALOG )
+        ||  ( nCompType == WindowType::PRINTDIALOG )
+        ||  ( nCompType == WindowType::COLORDIALOG )
+        ||  ( nCompType == WindowType::FONTDIALOG )
+        ||  ( nCompType == WindowType::DOCKINGWINDOW )
+        ||  ( nCompType == WindowType::TABDIALOG )
+        ||  ( nCompType == WindowType::BUTTONDIALOG )
+        ||  ( nCompType == WindowType::SYSTEMCHILDWINDOW )
         )
     {
         bDecoratedWindow = true;
@@ -404,7 +401,7 @@ WinBits ImplGetWinBits( sal_uInt32 nComponentAttribs, sal_uInt16 nCompType )
         if( nComponentAttribs & css::awt::VclWindowPeerAttribute::DEF_NO )
             nWinBits |= WB_DEF_NO;
     }
-    if ( nCompType == WINDOW_MULTILINEEDIT || nCompType == WINDOW_DIALOG || nCompType == WINDOW_GROUPBOX )
+    if ( nCompType == WindowType::MULTILINEEDIT || nCompType == WindowType::DIALOG || nCompType == WindowType::GROUPBOX )
     {
         if( nComponentAttribs & css::awt::VclWindowPeerAttribute::AUTOHSCROLL )
             nWinBits |= WB_AUTOHSCROLL;
@@ -438,72 +435,72 @@ struct ComponentInfo
 
 static ComponentInfo aComponentInfos [] =
 {
-    { "buttondialog",       WINDOW_BUTTONDIALOG },
-    { "cancelbutton",       WINDOW_CANCELBUTTON },
-    { "checkbox",           WINDOW_CHECKBOX },
-    { "combobox",           WINDOW_COMBOBOX },
-    { "control",            WINDOW_CONTROL },
-    { "currencybox",        WINDOW_CURRENCYBOX },
-    { "currencyfield",      WINDOW_CURRENCYFIELD },
-    { "datebox",            WINDOW_DATEBOX },
-    { "datefield",          WINDOW_DATEFIELD },
-    { "dialog",             WINDOW_DIALOG },
-    { "dockingarea",        WINDOW_DOCKINGAREA },
-    { "dockingwindow",      WINDOW_DOCKINGWINDOW },
-    { "edit",               WINDOW_EDIT },
-    { "errorbox",           WINDOW_ERRORBOX },
-    { "fixedbitmap",        WINDOW_FIXEDBITMAP },
-    { "fixedimage",         WINDOW_FIXEDIMAGE },
-    { "fixedline",          WINDOW_FIXEDLINE },
-    { "fixedtext",          WINDOW_FIXEDTEXT },
-    { "floatingwindow",     WINDOW_FLOATINGWINDOW },
-    { "framewindow",        VCLWINDOW_FRAMEWINDOW },
-    { "groupbox",           WINDOW_GROUPBOX },
-    { "frame",          WINDOW_GROUPBOX },
-    { "helpbutton",         WINDOW_HELPBUTTON },
-    { "imagebutton",        WINDOW_IMAGEBUTTON },
-    { "infobox",            WINDOW_INFOBOX },
-    { "listbox",            WINDOW_LISTBOX },
-    { "longcurrencybox",    WINDOW_LONGCURRENCYBOX },
-    { "longcurrencyfield",  WINDOW_LONGCURRENCYFIELD },
-    { "menubutton",         WINDOW_MENUBUTTON },
-    { "messbox",            WINDOW_MESSBOX },
-    { "metricbox",          WINDOW_METRICBOX },
-    { "metricfield",        WINDOW_METRICFIELD },
-    { "modaldialog",        WINDOW_MODALDIALOG },
-    { "modelessdialog",     WINDOW_MODELESSDIALOG },
-    { "morebutton",         WINDOW_MOREBUTTON },
-    { "multilineedit",      WINDOW_MULTILINEEDIT },
-    { "multilistbox",       WINDOW_MULTILISTBOX },
-    { "numericbox",         WINDOW_NUMERICBOX },
-    { "numericfield",       WINDOW_NUMERICFIELD },
-    { "okbutton",           WINDOW_OKBUTTON },
-    { "patternbox",         WINDOW_PATTERNBOX },
-    { "patternfield",       WINDOW_PATTERNFIELD },
-    { "pushbutton",         WINDOW_PUSHBUTTON },
-    { "querybox",           WINDOW_QUERYBOX },
-    { "radiobutton",        WINDOW_RADIOBUTTON },
-    { "scrollbar",          WINDOW_SCROLLBAR },
-    { "scrollbarbox",       WINDOW_SCROLLBARBOX },
-    { "animatedimages",     WINDOW_CONTROL },
-    { "spinbutton",         WINDOW_SPINBUTTON },
-    { "spinfield",          WINDOW_SPINFIELD },
-    { "splitter",           WINDOW_SPLITTER },
-    { "splitwindow",        WINDOW_SPLITWINDOW },
-    { "statusbar",          WINDOW_STATUSBAR },
-    { "systemchildwindow",  VCLWINDOW_SYSTEMCHILDWINDOW },
-    { "tabcontrol",         WINDOW_TABCONTROL },
-    { "tabdialog",          WINDOW_TABDIALOG },
-    { "tabpage",            WINDOW_TABPAGE },
-    { "timebox",            WINDOW_TIMEBOX },
-    { "timefield",          WINDOW_TIMEFIELD },
-    { "toolbox",            WINDOW_TOOLBOX },
-    { "tristatebox",        WINDOW_TRISTATEBOX },
-    { "warningbox",         WINDOW_WARNINGBOX },
-    { "window",             WINDOW_WINDOW },
-    { "workwindow",         WINDOW_WORKWINDOW },
-    { "tabpagecontainer",   WINDOW_CONTROL },
-    { "tabpagemodel",       WINDOW_TABPAGE }
+    { "buttondialog",       WindowType::BUTTONDIALOG },
+    { "cancelbutton",       WindowType::CANCELBUTTON },
+    { "checkbox",           WindowType::CHECKBOX },
+    { "combobox",           WindowType::COMBOBOX },
+    { "control",            WindowType::CONTROL },
+    { "currencybox",        WindowType::CURRENCYBOX },
+    { "currencyfield",      WindowType::CURRENCYFIELD },
+    { "datebox",            WindowType::DATEBOX },
+    { "datefield",          WindowType::DATEFIELD },
+    { "dialog",             WindowType::DIALOG },
+    { "dockingarea",        WindowType::DOCKINGAREA },
+    { "dockingwindow",      WindowType::DOCKINGWINDOW },
+    { "edit",               WindowType::EDIT },
+    { "errorbox",           WindowType::ERRORBOX },
+    { "fixedbitmap",        WindowType::FIXEDBITMAP },
+    { "fixedimage",         WindowType::FIXEDIMAGE },
+    { "fixedline",          WindowType::FIXEDLINE },
+    { "fixedtext",          WindowType::FIXEDTEXT },
+    { "floatingwindow",     WindowType::FLOATINGWINDOW },
+    { "framewindow",        WindowType::TOOLKIT_FRAMEWINDOW },
+    { "groupbox",           WindowType::GROUPBOX },
+    { "frame",              WindowType::GROUPBOX },
+    { "helpbutton",         WindowType::HELPBUTTON },
+    { "imagebutton",        WindowType::IMAGEBUTTON },
+    { "infobox",            WindowType::INFOBOX },
+    { "listbox",            WindowType::LISTBOX },
+    { "longcurrencybox",    WindowType::LONGCURRENCYBOX },
+    { "longcurrencyfield",  WindowType::LONGCURRENCYFIELD },
+    { "menubutton",         WindowType::MENUBUTTON },
+    { "messbox",            WindowType::MESSBOX },
+    { "metricbox",          WindowType::METRICBOX },
+    { "metricfield",        WindowType::METRICFIELD },
+    { "modaldialog",        WindowType::MODALDIALOG },
+    { "modelessdialog",     WindowType::MODELESSDIALOG },
+    { "morebutton",         WindowType::MOREBUTTON },
+    { "multilineedit",      WindowType::MULTILINEEDIT },
+    { "multilistbox",       WindowType::MULTILISTBOX },
+    { "numericbox",         WindowType::NUMERICBOX },
+    { "numericfield",       WindowType::NUMERICFIELD },
+    { "okbutton",           WindowType::OKBUTTON },
+    { "patternbox",         WindowType::PATTERNBOX },
+    { "patternfield",       WindowType::PATTERNFIELD },
+    { "pushbutton",         WindowType::PUSHBUTTON },
+    { "querybox",           WindowType::QUERYBOX },
+    { "radiobutton",        WindowType::RADIOBUTTON },
+    { "scrollbar",          WindowType::SCROLLBAR },
+    { "scrollbarbox",       WindowType::SCROLLBARBOX },
+    { "animatedimages",     WindowType::CONTROL },
+    { "spinbutton",         WindowType::SPINBUTTON },
+    { "spinfield",          WindowType::SPINFIELD },
+    { "splitter",           WindowType::SPLITTER },
+    { "splitwindow",        WindowType::SPLITWINDOW },
+    { "statusbar",          WindowType::STATUSBAR },
+    { "systemchildwindow",  WindowType::TOOLKIT_SYSTEMCHILDWINDOW },
+    { "tabcontrol",         WindowType::TABCONTROL },
+    { "tabdialog",          WindowType::TABDIALOG },
+    { "tabpage",            WindowType::TABPAGE },
+    { "timebox",            WindowType::TIMEBOX },
+    { "timefield",          WindowType::TIMEFIELD },
+    { "toolbox",            WindowType::TOOLBOX },
+    { "tristatebox",        WindowType::TRISTATEBOX },
+    { "warningbox",         WindowType::WARNINGBOX },
+    { "window",             WindowType::WINDOW },
+    { "workwindow",         WindowType::WORKWINDOW },
+    { "tabpagecontainer",   WindowType::CONTROL },
+    { "tabpagemodel",       WindowType::TABPAGE }
 };
 
 extern "C"
@@ -515,7 +512,7 @@ static int SAL_CALL ComponentInfoCompare( const void* pFirst, const void* pSecon
 }
 }
 
-sal_uInt16 ImplGetComponentType( const OUString& rServiceName )
+WindowType ImplGetComponentType( const OUString& rServiceName )
 {
     static bool bSorted = false;
     if( !bSorted )
@@ -541,7 +538,7 @@ sal_uInt16 ImplGetComponentType( const OUString& rServiceName )
                         sizeof( ComponentInfo ),
                         ComponentInfoCompare ));
 
-    return pInf ? pInf->nWinType : 0;
+    return pInf ? pInf->nWinType : WindowType::NONE;
 }
 
 
@@ -800,7 +797,7 @@ vcl::Window* VCLXToolkit::ImplCreateWindow( VCLXWindow** ppNewComp,
     aServiceName = aServiceName.toAsciiLowerCase();
 
     VclPtr<vcl::Window> pNewWindow;
-    sal_uInt16 nType = ImplGetComponentType( aServiceName );
+    WindowType nType = ImplGetComponentType( aServiceName );
     bool bFrameControl = false;
     if ( aServiceName == "frame" )
         bFrameControl = true;
@@ -814,19 +811,19 @@ vcl::Window* VCLXToolkit::ImplCreateWindow( VCLXWindow** ppNewComp,
         // Wenn die Component einen Parent braucht, dann NULL zurueckgeben,
         // spaeter mal css::uno::Exception...
         bool bException = true;
-        if  (   ( nType == WINDOW_DIALOG )
-            ||  ( nType == WINDOW_MODALDIALOG )
-            ||  ( nType == WINDOW_MODELESSDIALOG )
-            ||  ( nType == WINDOW_MESSBOX )
-            ||  ( nType == WINDOW_INFOBOX )
-            ||  ( nType == WINDOW_WARNINGBOX )
-            ||  ( nType == WINDOW_ERRORBOX )
-            ||  ( nType == WINDOW_QUERYBOX )
+        if  (   ( nType == WindowType::DIALOG )
+            ||  ( nType == WindowType::MODALDIALOG )
+            ||  ( nType == WindowType::MODELESSDIALOG )
+            ||  ( nType == WindowType::MESSBOX )
+            ||  ( nType == WindowType::INFOBOX )
+            ||  ( nType == WindowType::WARNINGBOX )
+            ||  ( nType == WindowType::ERRORBOX )
+            ||  ( nType == WindowType::QUERYBOX )
             )
             bException = false;
-        else if ( ( nType == WINDOW_WINDOW ) ||
-                  ( nType == WINDOW_WORKWINDOW ) ||
-                  ( nType == VCLWINDOW_FRAMEWINDOW ) )
+        else if ( ( nType == WindowType::WINDOW ) ||
+                  ( nType == WindowType::WORKWINDOW ) ||
+                  ( nType == WindowType::TOOLKIT_FRAMEWINDOW ) )
         {
             if ( rDescriptor.Type == css::awt::WindowClass_TOP )
                 bException = false;
@@ -839,72 +836,72 @@ vcl::Window* VCLXToolkit::ImplCreateWindow( VCLXWindow** ppNewComp,
         }
     }
 
-    if ( nType )
+    if ( nType != WindowType::NONE )
     {
         SolarMutexGuard aVclGuard;
-        switch ( (WindowType)nType )
+        switch ( nType )
         {
-            case WINDOW_CANCELBUTTON:
+            case WindowType::CANCELBUTTON:
                 pNewWindow = VclPtr<CancelButton>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXButton;
             break;
-            case WINDOW_CHECKBOX:
+            case WindowType::CHECKBOX:
                  pNewWindow = VclPtr<CheckBox>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXCheckBox;
             break;
-            case WINDOW_COMBOBOX:
+            case WindowType::COMBOBOX:
                 pNewWindow = VclPtr<ComboBox>::Create( pParent, nWinBits|WB_AUTOHSCROLL );
                 static_cast<ComboBox*>(pNewWindow.get())->EnableAutoSize( false );
                 *ppNewComp = new VCLXComboBox;
             break;
-            case WINDOW_CURRENCYBOX:
+            case WindowType::CURRENCYBOX:
                 pNewWindow = VclPtr<CurrencyBox>::Create( pParent, nWinBits );
             break;
-            case WINDOW_CURRENCYFIELD:
+            case WindowType::CURRENCYFIELD:
                 pNewWindow = VclPtr<CurrencyField>::Create( pParent, nWinBits );
                 static_cast<CurrencyField*>(pNewWindow.get())->EnableEmptyFieldValue( true );
                 *ppNewComp = new VCLXNumericField;
                 static_cast<VCLXFormattedSpinField*>(*ppNewComp)->SetFormatter( static_cast<FormatterBase*>(static_cast<CurrencyField*>(pNewWindow.get())) );
             break;
-            case WINDOW_DATEBOX:
+            case WindowType::DATEBOX:
                 pNewWindow = VclPtr<DateBox>::Create( pParent, nWinBits );
             break;
-            case WINDOW_DATEFIELD:
+            case WindowType::DATEFIELD:
                 pNewWindow = VclPtr<DateField>::Create( pParent, nWinBits );
                 static_cast<DateField*>(pNewWindow.get())->EnableEmptyFieldValue( true );
                 *ppNewComp = new VCLXDateField;
                 static_cast<VCLXFormattedSpinField*>(*ppNewComp)->SetFormatter( static_cast<FormatterBase*>(static_cast<DateField*>(pNewWindow.get())) );
             break;
-            case WINDOW_DOCKINGAREA:
+            case WindowType::DOCKINGAREA:
                 pNewWindow = VclPtr<DockingAreaWindow>::Create( pParent );
             break;
-            case WINDOW_MULTILINEEDIT:
-            case WINDOW_EDIT:
+            case WindowType::MULTILINEEDIT:
+            case WindowType::EDIT:
                 pNewWindow = VclPtr<Edit>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXEdit;
             break;
-            case WINDOW_ERRORBOX:
+            case WindowType::ERRORBOX:
                 pNewWindow = VclPtr<ErrorBox>::Create( pParent, nWinBits, OUString() );
                 *ppNewComp = new VCLXMessageBox;
             break;
-            case WINDOW_FIXEDBITMAP:
+            case WindowType::FIXEDBITMAP:
                 pNewWindow = VclPtr<FixedBitmap>::Create( pParent, nWinBits );
             break;
-            case WINDOW_FIXEDIMAGE:
+            case WindowType::FIXEDIMAGE:
                 pNewWindow = VclPtr<ImageControl>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXImageControl;
             break;
-            case WINDOW_FIXEDLINE:
+            case WindowType::FIXEDLINE:
                 pNewWindow = VclPtr<FixedLine>::Create( pParent, nWinBits );
             break;
-            case WINDOW_FIXEDTEXT:
+            case WindowType::FIXEDTEXT:
                 pNewWindow = VclPtr<FixedText>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXFixedText;
             break;
-            case WINDOW_FLOATINGWINDOW:
+            case WindowType::FLOATINGWINDOW:
                 pNewWindow = VclPtr<FloatingWindow>::Create( pParent, nWinBits );
             break;
-            case WINDOW_GROUPBOX:
+            case WindowType::GROUPBOX:
                 pNewWindow = VclPtr<GroupBox>::Create( pParent, nWinBits );
                 if ( bFrameControl )
                 {
@@ -915,50 +912,50 @@ vcl::Window* VCLXToolkit::ImplCreateWindow( VCLXWindow** ppNewComp,
                 pGroupBox->SetMouseTransparent( false );
                 }
             break;
-            case WINDOW_HELPBUTTON:
+            case WindowType::HELPBUTTON:
                 pNewWindow = VclPtr<HelpButton>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXButton;
             break;
-            case WINDOW_IMAGEBUTTON:
+            case WindowType::IMAGEBUTTON:
                  pNewWindow = VclPtr<ImageButton>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXButton;
             break;
-            case WINDOW_INFOBOX:
+            case WindowType::INFOBOX:
                 pNewWindow = VclPtr<InfoBox>::Create( pParent, OUString() );
                 *ppNewComp = new VCLXMessageBox;
             break;
-            case WINDOW_LISTBOX:
+            case WindowType::LISTBOX:
                 pNewWindow = VclPtr<ListBox>::Create( pParent, nWinBits|WB_SIMPLEMODE|WB_AUTOHSCROLL );
                 static_cast<ListBox*>(pNewWindow.get())->EnableAutoSize( false );
                 *ppNewComp = new VCLXListBox;
             break;
-            case WINDOW_LONGCURRENCYBOX:
+            case WindowType::LONGCURRENCYBOX:
                 pNewWindow = VclPtr<LongCurrencyBox>::Create( pParent, nWinBits );
             break;
-            case WINDOW_LONGCURRENCYFIELD:
+            case WindowType::LONGCURRENCYFIELD:
                 pNewWindow = VclPtr<LongCurrencyField>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXCurrencyField;
                 static_cast<VCLXFormattedSpinField*>(*ppNewComp)->SetFormatter( static_cast<FormatterBase*>(static_cast<LongCurrencyField*>(pNewWindow.get())) );
             break;
-            case WINDOW_MENUBUTTON:
+            case WindowType::MENUBUTTON:
                 pNewWindow = VclPtr<MenuButton>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXButton;
             break;
-            case WINDOW_MESSBOX:
+            case WindowType::MESSBOX:
                 pNewWindow = VclPtr<MessBox>::Create( pParent, nWinBits, OUString(), OUString() );
                 *ppNewComp = new VCLXMessageBox;
             break;
-            case WINDOW_METRICBOX:
+            case WindowType::METRICBOX:
                 pNewWindow = VclPtr<MetricBox>::Create( pParent, nWinBits );
             break;
-            case WINDOW_METRICFIELD:
+            case WindowType::METRICFIELD:
                 pNewWindow = VclPtr<MetricField>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXMetricField;
                 static_cast<VCLXFormattedSpinField*>(*ppNewComp)->SetFormatter( static_cast<FormatterBase*>(static_cast<MetricField*>(pNewWindow.get())) );
             break;
-            case WINDOW_DIALOG:
-            case WINDOW_MODALDIALOG:
-            case WINDOW_MODELESSDIALOG:
+            case WindowType::DIALOG:
+            case WindowType::MODALDIALOG:
+            case WindowType::MODELESSDIALOG:
             {
                 // Modal/Modeless nur durch Show/Execute
                 if ( (pParent == nullptr ) && ( rDescriptor.ParentIndex == -1 ) )
@@ -975,44 +972,44 @@ vcl::Window* VCLXToolkit::ImplCreateWindow( VCLXWindow** ppNewComp,
                     *ppNewComp = new VCLXDialog;
             }
             break;
-            case WINDOW_MOREBUTTON:
+            case WindowType::MOREBUTTON:
                 pNewWindow = VclPtr<MoreButton>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXButton;
             break;
-            case WINDOW_MULTILISTBOX:
+            case WindowType::MULTILISTBOX:
                 pNewWindow = VclPtr<MultiListBox>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXListBox;
             break;
-            case WINDOW_NUMERICBOX:
+            case WindowType::NUMERICBOX:
                 pNewWindow = VclPtr<NumericBox>::Create( pParent, nWinBits );
             break;
-            case WINDOW_NUMERICFIELD:
+            case WindowType::NUMERICFIELD:
                 pNewWindow = VclPtr<NumericField>::Create( pParent, nWinBits );
                 static_cast<NumericField*>(pNewWindow.get())->EnableEmptyFieldValue( true );
                 *ppNewComp = new VCLXNumericField;
                 static_cast<VCLXFormattedSpinField*>(*ppNewComp)->SetFormatter( static_cast<FormatterBase*>(static_cast<NumericField*>(pNewWindow.get())) );
             break;
-            case WINDOW_OKBUTTON:
+            case WindowType::OKBUTTON:
                 pNewWindow = VclPtr<OKButton>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXButton;
             break;
-            case WINDOW_PATTERNBOX:
+            case WindowType::PATTERNBOX:
                 pNewWindow = VclPtr<PatternBox>::Create( pParent, nWinBits );
             break;
-            case WINDOW_PATTERNFIELD:
+            case WindowType::PATTERNFIELD:
                 pNewWindow = VclPtr<PatternField>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXPatternField;
                 static_cast<VCLXFormattedSpinField*>(*ppNewComp)->SetFormatter( static_cast<FormatterBase*>(static_cast<PatternField*>(pNewWindow.get())) );
             break;
-            case WINDOW_PUSHBUTTON:
+            case WindowType::PUSHBUTTON:
                 pNewWindow = VclPtr<PushButton>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXButton;
             break;
-            case WINDOW_QUERYBOX:
+            case WindowType::QUERYBOX:
                 pNewWindow = VclPtr<QueryBox>::Create( pParent, nWinBits, OUString() );
                 *ppNewComp = new VCLXMessageBox;
             break;
-            case WINDOW_RADIOBUTTON:
+            case WindowType::RADIOBUTTON:
                 pNewWindow = VclPtr<RadioButton>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXRadioButton;
 
@@ -1027,74 +1024,74 @@ vcl::Window* VCLXToolkit::ImplCreateWindow( VCLXWindow** ppNewComp,
                 // 07.08.2001 - #87254# - frank.schoenheit at sun.com
                 static_cast<RadioButton*>(pNewWindow.get())->EnableRadioCheck( false );
             break;
-            case WINDOW_SCROLLBAR:
+            case WindowType::SCROLLBAR:
                 pNewWindow = VclPtr<ScrollBar>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXScrollBar;
             break;
-            case WINDOW_SCROLLBARBOX:
+            case WindowType::SCROLLBARBOX:
                 pNewWindow = VclPtr<ScrollBarBox>::Create( pParent, nWinBits );
             break;
-            case WINDOW_SPINBUTTON:
+            case WindowType::SPINBUTTON:
                 pNewWindow = VclPtr<SpinButton>::Create( pParent, nWinBits );
                 *ppNewComp = new ::toolkit::VCLXSpinButton;
             break;
-            case WINDOW_SPINFIELD:
+            case WindowType::SPINFIELD:
                 pNewWindow = VclPtr<SpinField>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXNumericField;
             break;
-            case WINDOW_SPLITTER:
+            case WindowType::SPLITTER:
                 pNewWindow = VclPtr<Splitter>::Create( pParent, nWinBits );
             break;
-            case WINDOW_SPLITWINDOW:
+            case WindowType::SPLITWINDOW:
                 pNewWindow = VclPtr<SplitWindow>::Create( pParent, nWinBits );
             break;
-            case WINDOW_STATUSBAR:
+            case WindowType::STATUSBAR:
                 pNewWindow = VclPtr<StatusBar>::Create( pParent, nWinBits );
             break;
-            case VCLWINDOW_SYSTEMCHILDWINDOW:
+            case WindowType::TOOLKIT_SYSTEMCHILDWINDOW:
                 pNewWindow = VclPtr<SystemChildWindow>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXSystemDependentWindow();
             break;
-            case WINDOW_TABCONTROL:
+            case WindowType::TABCONTROL:
                 pNewWindow = VclPtr<TabControl>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXMultiPage;
             break;
-            case WINDOW_TABDIALOG:
+            case WindowType::TABDIALOG:
                 pNewWindow = VclPtr<TabDialog>::Create( pParent, nWinBits );
             break;
-            case WINDOW_TABPAGE:
+            case WindowType::TABPAGE:
                 {
                     pNewWindow = VclPtr<TabPage>::Create( pParent, nWinBits );
                     *ppNewComp = new VCLXTabPage;
                 }
             break;
-            case WINDOW_TIMEBOX:
+            case WindowType::TIMEBOX:
                 pNewWindow = VclPtr<TimeBox>::Create( pParent, nWinBits );
             break;
-            case WINDOW_TIMEFIELD:
+            case WindowType::TIMEFIELD:
                 pNewWindow = VclPtr<TimeField>::Create( pParent, nWinBits );
                 static_cast<TimeField*>(pNewWindow.get())->EnableEmptyFieldValue( true );
                 *ppNewComp = new VCLXTimeField;
                 static_cast<VCLXFormattedSpinField*>(*ppNewComp)->SetFormatter( static_cast<FormatterBase*>(static_cast<TimeField*>(pNewWindow.get())) );
             break;
-            case WINDOW_TOOLBOX:
+            case WindowType::TOOLBOX:
                 pNewWindow = VclPtr<ToolBox>::Create( pParent, nWinBits );
                 *ppNewComp = new VCLXToolBox;
             break;
-            case WINDOW_TRISTATEBOX:
+            case WindowType::TRISTATEBOX:
                 pNewWindow = VclPtr<TriStateBox>::Create( pParent, nWinBits );
             break;
-            case WINDOW_WARNINGBOX:
+            case WindowType::WARNINGBOX:
                 pNewWindow = VclPtr<WarningBox>::Create( pParent, nWinBits, OUString() );
                 *ppNewComp = new VCLXMessageBox;
             break;
-            case WINDOW_WORKWINDOW:
-            case WINDOW_WINDOW:
-            case VCLWINDOW_FRAMEWINDOW:
-            case WINDOW_DOCKINGWINDOW:
+            case WindowType::WORKWINDOW:
+            case WindowType::WINDOW:
+            case WindowType::TOOLKIT_FRAMEWINDOW:
+            case WindowType::DOCKINGWINDOW:
                 if ( rDescriptor.Type == css::awt::WindowClass_TOP )
                 {
-                    if (nType == WINDOW_DOCKINGWINDOW )
+                    if (nType == WindowType::DOCKINGWINDOW )
                         pNewWindow = VclPtr<DockingWindow>::Create( pParent, nWinBits );
                     else
                     {
@@ -1163,11 +1160,11 @@ vcl::Window* VCLXToolkit::ImplCreateWindow( VCLXWindow** ppNewComp,
                             pNewWindow = VclPtr<WorkWindow>::Create( pParent, nWinBits );
                     }
 
-                    *ppNewComp = new VCLXTopWindow( pNewWindow->GetType() == WINDOW_WORKWINDOW );
+                    *ppNewComp = new VCLXTopWindow( pNewWindow->GetType() == WindowType::WORKWINDOW );
                 }
                 else if ( rDescriptor.Type == css::awt::WindowClass_CONTAINER )
                 {
-                    if (nType == WINDOW_DOCKINGWINDOW )
+                    if (nType == WindowType::DOCKINGWINDOW )
                         pNewWindow = VclPtr<DockingWindow>::Create( pParent, nWinBits );
                     else
                         pNewWindow = VclPtr<vcl::Window>::Create( pParent, nWinBits );
@@ -1175,14 +1172,14 @@ vcl::Window* VCLXToolkit::ImplCreateWindow( VCLXWindow** ppNewComp,
                 }
                 else
                 {
-                    if (nType == WINDOW_DOCKINGWINDOW )
+                    if (nType == WindowType::DOCKINGWINDOW )
                         pNewWindow = VclPtr<DockingWindow>::Create( pParent, nWinBits );
                     else
                         pNewWindow = VclPtr<vcl::Window>::Create( pParent, nWinBits );
                     *ppNewComp = new VCLXWindow;
                 }
             break;
-            case WINDOW_CONTROL:
+            case WindowType::CONTROL:
                 if ( rDescriptor.WindowServiceName.equalsIgnoreAsciiCase(
                         "tabpagecontainer" ) )
                 {
diff --git a/toolkit/source/awt/vclxwindow.cxx b/toolkit/source/awt/vclxwindow.cxx
index 12fd782..272108a 100644
--- a/toolkit/source/awt/vclxwindow.cxx
+++ b/toolkit/source/awt/vclxwindow.cxx
@@ -1140,9 +1140,9 @@ void VCLXWindow::setBackground( sal_Int32 nColor )
         GetWindow()->SetControlBackground( aColor );
 
         WindowType eWinType = GetWindow()->GetType();
-        if ( ( eWinType == WINDOW_WINDOW ) ||
-             ( eWinType == WINDOW_WORKWINDOW ) ||
-             ( eWinType == WINDOW_FLOATINGWINDOW ) )
+        if ( ( eWinType == WindowType::WINDOW ) ||
+             ( eWinType == WindowType::WORKWINDOW ) ||
+             ( eWinType == WindowType::FLOATINGWINDOW ) )
         {
             GetWindow()->Invalidate();
         }
@@ -1487,9 +1487,9 @@ void VCLXWindow::setProperty( const OUString& PropertyName, const css::uno::Any&
             {
                 switch (eWinType)
                 {
-                    case WINDOW_OKBUTTON:
-                    case WINDOW_CANCELBUTTON:
-                    case WINDOW_HELPBUTTON:
+                    case WindowType::OKBUTTON:
+                    case WindowType::CANCELBUTTON:
+                    case WindowType::HELPBUTTON:
                         // Standard Button: overwrite only if not empty.
                         if (!aText.isEmpty())
                             pWindow->SetText( aText );
@@ -1571,13 +1571,13 @@ void VCLXWindow::setProperty( const OUString& PropertyName, const css::uno::Any&
                 switch ( eWinType )
                 {
                     // set dialog color for default
-                    case WINDOW_DIALOG:
-                    case WINDOW_MESSBOX:
-                    case WINDOW_INFOBOX:
-                    case WINDOW_WARNINGBOX:
-                    case WINDOW_ERRORBOX:
-                    case WINDOW_QUERYBOX:
-                    case WINDOW_TABPAGE:
+                    case WindowType::DIALOG:
+                    case WindowType::MESSBOX:
+                    case WindowType::INFOBOX:
+                    case WindowType::WARNINGBOX:
+                    case WindowType::ERRORBOX:
+                    case WindowType::QUERYBOX:
+                    case WindowType::TABPAGE:
                     {
                         Color aColor = pWindow->GetSettings().GetStyleSettings().GetDialogColor();
                         pWindow->SetBackground( aColor );
@@ -1585,11 +1585,11 @@ void VCLXWindow::setProperty( const OUString& PropertyName, const css::uno::Any&
                         break;
                     }
 
-                    case WINDOW_FIXEDTEXT:
-                    case WINDOW_CHECKBOX:
-                    case WINDOW_RADIOBUTTON:
-                    case WINDOW_GROUPBOX:
-                    case WINDOW_FIXEDLINE:
+                    case WindowType::FIXEDTEXT:
+                    case WindowType::CHECKBOX:
+                    case WindowType::RADIOBUTTON:
+                    case WindowType::GROUPBOX:
+                    case WindowType::FIXEDLINE:
                     {
                         // support transparency only for special controls
                         pWindow->SetBackground();
@@ -1622,11 +1622,11 @@ void VCLXWindow::setProperty( const OUString& PropertyName, const css::uno::Any&
                     switch ( eWinType )
                     {
                         // reset paint transparent mode
-                        case WINDOW_FIXEDTEXT:
-                        case WINDOW_CHECKBOX:
-                        case WINDOW_RADIOBUTTON:
-                        case WINDOW_GROUPBOX:
-                        case WINDOW_FIXEDLINE:
+                        case WindowType::FIXEDTEXT:

... etc. - the rest is truncated


More information about the Libreoffice-commits mailing list