[Libreoffice-commits] core.git: 4 commits - cui/AllLangResTarget_cui.mk cui/Library_cui.mk cui/source cui/uiconfig cui/UIConfig_cui.mk extras/source include/svx sc/source sd/source svx/source

Jan Holesovsky kendy at collabora.com
Sun Sep 29 05:50:22 PDT 2013


 cui/AllLangResTarget_cui.mk                    |    1 
 cui/Library_cui.mk                             |    1 
 cui/UIConfig_cui.mk                            |    3 
 cui/source/factory/dlgfact.cxx                 |    6 
 cui/source/inc/cuires.hrc                      |   16 +
 cui/source/inc/dbregister.hxx                  |   14 -
 cui/source/inc/internationaloptions.hxx        |   51 -----
 cui/source/options/connpooloptions.cxx         |  133 +++++++--------
 cui/source/options/connpooloptions.hrc         |   41 ----
 cui/source/options/connpooloptions.hxx         |   27 +--
 cui/source/options/connpooloptions.src         |  120 ++------------
 cui/source/options/dbregister.cxx              |   41 ++--
 cui/source/options/dbregister.hrc              |   34 ---
 cui/source/options/dbregister.src              |   67 -------
 cui/source/options/internationaloptions.cxx    |  141 ----------------
 cui/source/options/internationaloptions.src    |   81 ---------
 cui/source/options/optfltr.cxx                 |   55 +++---
 cui/source/options/optfltr.hrc                 |   36 ----
 cui/source/options/optfltr.hxx                 |    5 
 cui/source/options/optfltr.src                 |   76 ++------
 cui/source/options/treeopt.cxx                 |   17 -
 cui/source/options/treeopt.src                 |    1 
 cui/uiconfig/ui/connpooloptions.ui             |  213 +++++++++++++++++++++++++
 cui/uiconfig/ui/dbregisterpage.ui              |  129 +++++++++++++++
 cui/uiconfig/ui/optfltrembedpage.ui            |   94 +++++++++++
 extras/source/glade/libreoffice-catalog.xml.in |    4 
 include/svx/dialogs.hrc                        |    3 
 sc/source/ui/app/scmod.cxx                     |   11 -
 sd/source/ui/app/sdmod2.cxx                    |    2 
 svx/source/src/app.hrc                         |    3 
 30 files changed, 641 insertions(+), 785 deletions(-)

New commits:
commit 33ad001fe6c19fed72129b24b3dd85d8eff05baf
Author: Jan Holesovsky <kendy at collabora.com>
Date:   Sun Sep 29 14:42:38 2013 +0200

    Convert connpooloptions to .ui + adapt code.
    
    Change-Id: Idf76635180f73716f3d476975d9738edad464348

diff --git a/cui/UIConfig_cui.mk b/cui/UIConfig_cui.mk
index 05ae93b..3090851 100644
--- a/cui/UIConfig_cui.mk
+++ b/cui/UIConfig_cui.mk
@@ -37,6 +37,7 @@ $(eval $(call gb_UIConfig_add_uifiles,cui,\
 	cui/uiconfig/ui/formatnumberdialog \
 	cui/uiconfig/ui/gradientpage \
 	cui/uiconfig/ui/colorconfigwin \
+	cui/uiconfig/ui/connpooloptions \
 	cui/uiconfig/ui/dbregisterpage \
 	cui/uiconfig/ui/effectspage \
 	cui/uiconfig/ui/hatchpage \
diff --git a/cui/source/inc/cuires.hrc b/cui/source/inc/cuires.hrc
index 5e23c48..0b8cf5a 100644
--- a/cui/source/inc/cuires.hrc
+++ b/cui/source/inc/cuires.hrc
@@ -448,6 +448,12 @@
 #define RID_SVXSTR_TYPE                                     (RID_SVX_START + 1244)
 #define RID_SVXSTR_PATH                                     (RID_SVX_START + 1245)
 
+#define RID_SVXSTR_DRIVER_NAME                              (RID_SVX_START + 1246)
+#define RID_SVXSTR_POOLED_FLAG                              (RID_SVX_START + 1247)
+#define RID_SVXSTR_POOL_TIMEOUT                             (RID_SVX_START + 1248)
+#define RID_SVXSTR_YES                                      (RID_SVX_START + 1249)
+#define RID_SVXSTR_NO                                       (RID_SVX_START + 1250)
+
 #endif
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/source/options/connpooloptions.cxx b/cui/source/options/connpooloptions.cxx
index bf64607..d154b0f 100644
--- a/cui/source/options/connpooloptions.cxx
+++ b/cui/source/options/connpooloptions.cxx
@@ -18,7 +18,6 @@
  */
 
 #include "connpooloptions.hxx"
-#include "connpooloptions.hrc"
 #include <svtools/editbrowsebox.hxx>
 #include <vcl/field.hxx>
 #include "connpoolsettings.hxx"
@@ -27,16 +26,12 @@
 #include "helpid.hrc"
 #include <dialmgr.hxx>
 
-//........................................................................
+using ::svt::EditBrowseBox;
+
 namespace offapp
 {
-//........................................................................
-
-    //====================================================================
-    //= DriverListControl
-    //====================================================================
-    typedef ::svt::EditBrowseBox DriverListControl_Base;
-    class DriverListControl : public DriverListControl_Base
+    /// Widget for the Connection Pool options page
+    class DriverListControl : public EditBrowseBox
     {
         using Window::Update;
     protected:
@@ -50,7 +45,7 @@ namespace offapp
         Link                                    m_aRowChangeHandler;
 
     public:
-        DriverListControl( Window* _pParent, const ResId& _rId);
+        DriverListControl(Window* _pParent);
 
         virtual void Init();
                 void Update(const DriverPoolingSettings& _rSettings);
@@ -94,11 +89,11 @@ namespace offapp
     };
 
     //--------------------------------------------------------------------
-    DriverListControl::DriverListControl( Window* _pParent, const ResId& _rId)
-        :DriverListControl_Base(_pParent, _rId, EBBF_NOROWPICTURE, BROWSER_AUTO_VSCROLL | BROWSER_AUTO_HSCROLL | BROWSER_HIDECURSOR | BROWSER_AUTOSIZE_LASTCOL)
+    DriverListControl::DriverListControl(Window* _pParent)
+        :EditBrowseBox(_pParent, EBBF_NOROWPICTURE, BROWSER_AUTO_VSCROLL | BROWSER_AUTO_HSCROLL | BROWSER_HIDECURSOR | BROWSER_AUTOSIZE_LASTCOL)
         ,m_aSeekRow(m_aSettings.end())
-        ,m_sYes(ResId(STR_YES,*_rId.GetResMgr()))
-        ,m_sNo(ResId(STR_NO,*_rId.GetResMgr()))
+        ,m_sYes(CUI_RES(RID_SVXSTR_YES))
+        ,m_sNo(CUI_RES(RID_SVXSTR_NO))
     {
         SetStyle((GetStyle() & ~WB_HSCROLL) | WB_AUTOHSCROLL);
 
@@ -106,6 +101,11 @@ namespace offapp
         GetDataWindow().SetHelpId(HID_OFA_CONNPOOL_DRIVERLIST);
     }
 
+    extern "C" SAL_DLLPUBLIC_EXPORT Window* SAL_CALL makeDriverListControl(Window *pParent, VclBuilder::stringmap &)
+    {
+        return new DriverListControl(pParent);
+    }
+
     //--------------------------------------------------------------------
     sal_Bool DriverListControl::IsTabAllowed(sal_Bool /*_bForward*/) const
     {
@@ -134,21 +134,21 @@ namespace offapp
     //--------------------------------------------------------------------
     void DriverListControl::Init()
     {
-        DriverListControl_Base::Init();
+        EditBrowseBox::Init();
 
         Size aColWidth = LogicToPixel(Size(160, 0), MAP_APPFONT);
-        InsertDataColumn(1, String(CUI_RES(STR_DRIVER_NAME)), aColWidth.Width());
+        InsertDataColumn(1, String(CUI_RES(RID_SVXSTR_DRIVER_NAME)), aColWidth.Width());
         aColWidth = LogicToPixel(Size(30, 0), MAP_APPFONT);
-        InsertDataColumn(2, String(CUI_RES(STR_POOLED_FLAG)), aColWidth.Width());
+        InsertDataColumn(2, String(CUI_RES(RID_SVXSTR_POOLED_FLAG)), aColWidth.Width());
         aColWidth = LogicToPixel(Size(60, 0), MAP_APPFONT);
-        InsertDataColumn(3, String(CUI_RES(STR_POOL_TIMEOUT)), aColWidth.Width());
+        InsertDataColumn(3, String(CUI_RES(RID_SVXSTR_POOL_TIMEOUT)), aColWidth.Width());
             // Attention: the resource of the string is local to the resource of the enclosing dialog!
     }
 
     //--------------------------------------------------------------------
     void DriverListControl::CursorMoved()
     {
-        DriverListControl_Base::CursorMoved();
+        EditBrowseBox::CursorMoved();
 
         // call the row change handler
         if ( m_aRowChangeHandler.IsSet() )
@@ -238,7 +238,7 @@ namespace offapp
     {
         if (STATE_CHANGE_ENABLE == nStateChange)
             Window::Invalidate(INVALIDATE_UPDATE);
-        DriverListControl_Base::StateChanged( nStateChange );
+        EditBrowseBox::StateChanged( nStateChange );
     }
 
     //--------------------------------------------------------------------
@@ -277,7 +277,7 @@ namespace offapp
     //--------------------------------------------------------------------
     sal_Bool DriverListControl::SeekRow( long _nRow )
     {
-        DriverListControl_Base::SeekRow(_nRow);
+        EditBrowseBox::SeekRow(_nRow);
 
         if (_nRow < m_aSettings.size())
             m_aSeekRow = m_aSettings.begin() + _nRow;
@@ -317,24 +317,26 @@ namespace offapp
     //====================================================================
     //--------------------------------------------------------------------
     ConnectionPoolOptionsPage::ConnectionPoolOptionsPage(Window* _pParent, const SfxItemSet& _rAttrSet)
-        :SfxTabPage(_pParent, CUI_RES(RID_OFAPAGE_CONNPOOLOPTIONS ), _rAttrSet)
-        ,m_aFrame               (this,              CUI_RES(FL_POOLING))
-        ,m_aEnablePooling       (this,      CUI_RES(CB_POOL_CONNS))
-        ,m_aDriversLabel        (this,      CUI_RES(FT_DRIVERS))
-        ,m_pDriverList(new DriverListControl(this, CUI_RES(CTRL_DRIVER_LIST)))
-        ,m_aDriverLabel         (this,      CUI_RES(FT_DRIVERLABEL))
-        ,m_aDriver              (this,      CUI_RES(FT_DRIVER))
-        ,m_aDriverPoolingEnabled(this,      CUI_RES(CB_DRIVERPOOLING))
-        ,m_aTimeoutLabel        (this,      CUI_RES(FT_TIMEOUT))
-        ,m_aTimeout             (this,      CUI_RES(NF_TIMEOUT))
+        : SfxTabPage(_pParent, "ConnPoolPage", "cui/ui/connpooloptions.ui", _rAttrSet)
     {
+        get(m_pEnablePooling, "connectionpooling");
+        get(m_pDriversLabel, "driverslabel");
+        get(m_pDriverList, "driverlist");
+        get(m_pDriverLabel, "driverlabel");
+        get(m_pDriver, "driver");
+        get(m_pDriverPoolingEnabled, "enablepooling");
+        get(m_pTimeoutLabel, "timeoutlabel");
+        get(m_pTimeout, "timeout");
+
+        Size aControlSize(248, 100);
+        aControlSize = LogicToPixel(aControlSize, MAP_APPFONT);
+        m_pDriverList->set_width_request(aControlSize.Width());
+        m_pDriverList->set_height_request(aControlSize.Height());
         m_pDriverList->Init();
         m_pDriverList->Show();
 
-        FreeResource();
-
-        m_aEnablePooling.SetClickHdl( LINK(this, ConnectionPoolOptionsPage, OnEnabledDisabled) );
-        m_aDriverPoolingEnabled.SetClickHdl( LINK(this, ConnectionPoolOptionsPage, OnEnabledDisabled) );
+        m_pEnablePooling->SetClickHdl( LINK(this, ConnectionPoolOptionsPage, OnEnabledDisabled) );
+        m_pDriverPoolingEnabled->SetClickHdl( LINK(this, ConnectionPoolOptionsPage, OnEnabledDisabled) );
 
         m_pDriverList->SetRowChangeHandler( LINK(this, ConnectionPoolOptionsPage, OnDriverRowChanged) );
     }
@@ -346,20 +348,14 @@ namespace offapp
     }
 
     //--------------------------------------------------------------------
-    ConnectionPoolOptionsPage::~ConnectionPoolOptionsPage()
-    {
-        delete m_pDriverList;
-    }
-
-    //--------------------------------------------------------------------
     void ConnectionPoolOptionsPage::implInitControls(const SfxItemSet& _rSet, sal_Bool /*_bFromReset*/)
     {
         // the enabled flag
         SFX_ITEMSET_GET( _rSet, pEnabled, SfxBoolItem, SID_SB_POOLING_ENABLED, sal_True );
         OSL_ENSURE(pEnabled, "ConnectionPoolOptionsPage::implInitControls: missing the Enabled item!");
-        m_aEnablePooling.Check(pEnabled ? pEnabled->GetValue() : sal_True);
+        m_pEnablePooling->Check(pEnabled ? pEnabled->GetValue() : sal_True);
 
-        m_aEnablePooling.SaveValue();
+        m_pEnablePooling->SaveValue();
 
         // the settings for the single drivers
         SFX_ITEMSET_GET( _rSet, pDriverSettings, DriverPoolingSettingsItem, SID_SB_DRIVER_TIMEOUTS, sal_True );
@@ -373,14 +369,14 @@ namespace offapp
         m_pDriverList->saveValue();
 
         // reflect the new settings
-        OnEnabledDisabled(&m_aEnablePooling);
+        OnEnabledDisabled(m_pEnablePooling);
     }
 
     //--------------------------------------------------------------------
     long ConnectionPoolOptionsPage::Notify( NotifyEvent& _rNEvt )
     {
         if (EVENT_LOSEFOCUS == _rNEvt.GetType())
-            if (m_aTimeout.IsWindowOrChild(_rNEvt.GetWindow()))
+            if (m_pTimeout->IsWindowOrChild(_rNEvt.GetWindow()))
                 commitTimeoutField();
 
         return SfxTabPage::Notify(_rNEvt);
@@ -393,9 +389,9 @@ namespace offapp
 
         sal_Bool bModified = sal_False;
         // the enabled flag
-        if (m_aEnablePooling.GetSavedValue() != m_aEnablePooling.IsChecked())
+        if (m_pEnablePooling->GetSavedValue() != m_pEnablePooling->IsChecked())
         {
-            _rSet.Put(SfxBoolItem(SID_SB_POOLING_ENABLED, m_aEnablePooling.IsChecked()), SID_SB_POOLING_ENABLED);
+            _rSet.Put(SfxBoolItem(SID_SB_POOLING_ENABLED, m_pEnablePooling->IsChecked()), SID_SB_POOLING_ENABLED);
             bModified = sal_True;
         }
 
@@ -426,23 +422,23 @@ namespace offapp
     IMPL_LINK( ConnectionPoolOptionsPage, OnDriverRowChanged, const void*, _pRowIterator )
     {
         sal_Bool bValidRow = (NULL != _pRowIterator);
-        m_aDriverPoolingEnabled.Enable(bValidRow && m_aEnablePooling.IsChecked());
-        m_aTimeoutLabel.Enable(bValidRow);
-        m_aTimeout.Enable(bValidRow);
+        m_pDriverPoolingEnabled->Enable(bValidRow && m_pEnablePooling->IsChecked());
+        m_pTimeoutLabel->Enable(bValidRow);
+        m_pTimeout->Enable(bValidRow);
 
         if (!bValidRow)
         {   // positioned on an invalid row
-            m_aDriver.SetText(String());
+            m_pDriver->SetText(String());
         }
         else
         {
             const DriverPooling *pDriverPos = static_cast<const DriverPooling*>(_pRowIterator);
 
-            m_aDriver.SetText(pDriverPos->sName);
-            m_aDriverPoolingEnabled.Check(pDriverPos->bEnabled);
-            m_aTimeout.SetText(OUString::number(pDriverPos->nTimeoutSeconds));
+            m_pDriver->SetText(pDriverPos->sName);
+            m_pDriverPoolingEnabled->Check(pDriverPos->bEnabled);
+            m_pTimeout->SetText(OUString::number(pDriverPos->nTimeoutSeconds));
 
-            OnEnabledDisabled(&m_aDriverPoolingEnabled);
+            OnEnabledDisabled(m_pDriverPoolingEnabled);
         }
 
         return 0L;
@@ -453,7 +449,7 @@ namespace offapp
     {
         if (DriverPooling* pCurrentDriver = m_pDriverList->getCurrentRow())
         {
-            pCurrentDriver->nTimeoutSeconds = static_cast<long>(m_aTimeout.GetValue());
+            pCurrentDriver->nTimeoutSeconds = static_cast<long>(m_pTimeout->GetValue());
             m_pDriverList->updateCurrentRow();
         }
     }
@@ -461,36 +457,33 @@ namespace offapp
     //--------------------------------------------------------------------
     IMPL_LINK( ConnectionPoolOptionsPage, OnEnabledDisabled, const CheckBox*, _pCheckBox )
     {
-        sal_Bool bGloballyEnabled = m_aEnablePooling.IsChecked();
-        sal_Bool bLocalDriverChanged = &m_aDriverPoolingEnabled == _pCheckBox;
+        sal_Bool bGloballyEnabled = m_pEnablePooling->IsChecked();
+        sal_Bool bLocalDriverChanged = m_pDriverPoolingEnabled == _pCheckBox;
 
-        if (&m_aEnablePooling == _pCheckBox)
+        if (m_pEnablePooling == _pCheckBox)
         {
-            m_aDriversLabel.Enable(bGloballyEnabled);
+            m_pDriversLabel->Enable(bGloballyEnabled);
             m_pDriverList->Enable(bGloballyEnabled);
-            m_aDriverLabel.Enable(bGloballyEnabled);
-            m_aDriver.Enable(bGloballyEnabled);
-            m_aDriverPoolingEnabled.Enable(bGloballyEnabled);
+            m_pDriverLabel->Enable(bGloballyEnabled);
+            m_pDriver->Enable(bGloballyEnabled);
+            m_pDriverPoolingEnabled->Enable(bGloballyEnabled);
         }
         else
             OSL_ENSURE(bLocalDriverChanged, "ConnectionPoolOptionsPage::OnEnabledDisabled: where did this come from?");
 
-        m_aTimeoutLabel.Enable(bGloballyEnabled && m_aDriverPoolingEnabled.IsChecked());
-        m_aTimeout.Enable(bGloballyEnabled && m_aDriverPoolingEnabled.IsChecked());
+        m_pTimeoutLabel->Enable(bGloballyEnabled && m_pDriverPoolingEnabled->IsChecked());
+        m_pTimeout->Enable(bGloballyEnabled && m_pDriverPoolingEnabled->IsChecked());
 
         if (bLocalDriverChanged)
         {
             // update the list
-            m_pDriverList->getCurrentRow()->bEnabled = m_aDriverPoolingEnabled.IsChecked();
+            m_pDriverList->getCurrentRow()->bEnabled = m_pDriverPoolingEnabled->IsChecked();
             m_pDriverList->updateCurrentRow();
         }
 
         return 0L;
     }
 
-//........................................................................
-}   // namespace offapp
-//........................................................................
-
+} // namespace offapp
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/source/options/connpooloptions.hrc b/cui/source/options/connpooloptions.hrc
deleted file mode 100644
index 84a0a4d..0000000
--- a/cui/source/options/connpooloptions.hrc
+++ /dev/null
@@ -1,41 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#ifndef _OFFAPP_CONNPOOLOPTIONS_HRC_
-#define _OFFAPP_CONNPOOLOPTIONS_HRC_
-
-#define FL_POOLING               1
-#define CB_POOL_CONNS            2
-#define FT_DRIVERS               3
-#define CTRL_DRIVER_LIST         4
-#define FT_DRIVERLABEL           5
-#define FT_DRIVER                6
-#define CB_DRIVERPOOLING         7
-#define FT_TIMEOUT               8
-#define NF_TIMEOUT               9
-
-#define STR_DRIVER_NAME         1
-#define STR_POOLED_FLAG         2
-#define STR_POOL_TIMEOUT        3
-#define STR_YES                 4
-#define STR_NO                  5
-
-#endif // _OFFAPP_CONNPOOLOPTIONS_HRC_
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/source/options/connpooloptions.hxx b/cui/source/options/connpooloptions.hxx
index d2677a5..27e95bc 100644
--- a/cui/source/options/connpooloptions.hxx
+++ b/cui/source/options/connpooloptions.hxx
@@ -27,11 +27,8 @@
 #include <vcl/field.hxx>
 #include <svx/databaseregistrationui.hxx>
 
-//........................................................................
 namespace offapp
 {
-//........................................................................
-
     //====================================================================
     //= ConnectionPoolOptionsPage
     //====================================================================
@@ -41,15 +38,14 @@ namespace offapp
         using TabPage::ActivatePage;
 
     protected:
-        FixedLine               m_aFrame;
-        CheckBox                m_aEnablePooling;
-        FixedText               m_aDriversLabel;
+        CheckBox*               m_pEnablePooling;
+        FixedText*              m_pDriversLabel;
         DriverListControl*      m_pDriverList;
-        FixedText               m_aDriverLabel;
-        FixedText               m_aDriver;
-        CheckBox                m_aDriverPoolingEnabled;
-        FixedText               m_aTimeoutLabel;
-        NumericField            m_aTimeout;
+        FixedText*              m_pDriverLabel;
+        FixedText*              m_pDriver;
+        CheckBox*               m_pDriverPoolingEnabled;
+        FixedText*              m_pTimeoutLabel;
+        NumericField*           m_pTimeout;
 
     protected:
         ConnectionPoolOptionsPage(Window* _pParent, const SfxItemSet& _rAttrSet);
@@ -57,12 +53,10 @@ namespace offapp
     public:
         static SfxTabPage*  Create(Window* _pParent, const SfxItemSet& _rAttrSet);
 
-        ~ConnectionPoolOptionsPage();
-
     protected:
         virtual long        Notify( NotifyEvent& _rNEvt );
 
-        virtual sal_Bool        FillItemSet(SfxItemSet& _rSet);
+        virtual sal_Bool    FillItemSet(SfxItemSet& _rSet);
         virtual void        Reset(const SfxItemSet& _rSet);
         virtual void        ActivatePage( const SfxItemSet& _rSet);
 
@@ -75,11 +69,8 @@ namespace offapp
         void commitTimeoutField();
     };
 
-//........................................................................
-}   // namespace offapp
-//........................................................................
+} // namespace offapp
 
 #endif // _OFFAPP_CONNPOOLOPTIONS_HXX_
 
-
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/source/options/connpooloptions.src b/cui/source/options/connpooloptions.src
index f084fac..5f44107 100644
--- a/cui/source/options/connpooloptions.src
+++ b/cui/source/options/connpooloptions.src
@@ -17,111 +17,27 @@
  *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
  */
 
-#include "connpooloptions.hrc"
 #include <cuires.hrc>
 
-#define PAGE_SIZE_X     TP_WIDTH
-#define PAGE_SIZE_Y     TP_HEIGHT
-
-#define LIST_SIZE_Y     100
-
-TabPage RID_OFAPAGE_CONNPOOLOPTIONS
+String RID_SVXSTR_DRIVER_NAME
 {
-    HelpID = "cui:TabPage:RID_OFAPAGE_CONNPOOLOPTIONS";
-    OutputSize = TRUE ;
-    Pos = MAP_APPFONT ( 0 , 0 ) ;
-    Size = MAP_APPFONT ( PAGE_SIZE_X, PAGE_SIZE_Y ) ;
-    SVLook = TRUE ;
-    Hide = TRUE ;
-
-    FixedLine FL_POOLING
-    {
-        Pos = MAP_APPFONT( 4, 3 );
-        Size = MAP_APPFONT( PAGE_SIZE_X - 8, 8 );
-        Text [ en-US ] = "Connection pool";
-    };
-    CheckBox CB_POOL_CONNS
-    {
-        HelpID = "cui:CheckBox:RID_OFAPAGE_CONNPOOLOPTIONS:CB_POOL_CONNS";
-        Pos = MAP_APPFONT( 7, 15 );
-        Size = MAP_APPFONT( PAGE_SIZE_X - 14, 10 );
-        Text [ en-US ] = "Connection pooling enabled";
-    };
-    FixedText FT_DRIVERS
-    {
-        Pos = MAP_APPFONT( 17, 28 );
-        Size = MAP_APPFONT( PAGE_SIZE_X - 14 - 8, 8 );
-        Text [ en-US ] = "Drivers known in %PRODUCTNAME";
-    };
-    Control CTRL_DRIVER_LIST
-    {
-        Pos = MAP_APPFONT( 17, 39 );
-        Size = MAP_APPFONT( PAGE_SIZE_X - 14 - 8, LIST_SIZE_Y );
-        TabStop = TRUE;
-        Border = TRUE;
-        SVLook = TRUE;
-    };
-    FixedText FT_DRIVERLABEL
-    {
-        Pos = MAP_APPFONT( 17, 39 + LIST_SIZE_Y + 4 );
-        Size = MAP_APPFONT( 70, 8 );
-        Text [ en-US ] = "Current driver:";
-    };
-    FixedText FT_DRIVER
-    {
-        Pos = MAP_APPFONT( 17 + 70 + 3, 39 + LIST_SIZE_Y + 4 );
-        Size = MAP_APPFONT( PAGE_SIZE_X - ( 15 + 70 + 3 ) - 7, 8 );
-    };
-    CheckBox CB_DRIVERPOOLING
-    {
-        HelpID = "cui:CheckBox:RID_OFAPAGE_CONNPOOLOPTIONS:CB_DRIVERPOOLING";
-        Pos = MAP_APPFONT( 17, 39 + LIST_SIZE_Y + 4 + 8 + 3 );
-        Size = MAP_APPFONT( PAGE_SIZE_X - 23, 10 );
-        Text [ en-US ] = "Enable pooling for this driver";
-    };
-    FixedText FT_TIMEOUT
-    {
-        Pos = MAP_APPFONT( 27, 39 + LIST_SIZE_Y + 4 + 8 + 3 + 10 + 3 + 2 );
-        Size = MAP_APPFONT( 100, 8 );
-        Text [ en-US ] = "Timeout (seconds)";
-    };
-    NumericField NF_TIMEOUT
-    {
-        HelpID = "cui:NumericField:RID_OFAPAGE_CONNPOOLOPTIONS:NF_TIMEOUT";
-        Pos = MAP_APPFONT( 27 + 100 + 3, 39 + LIST_SIZE_Y + 4 + 8 + 3 + 10 + 3 );
-        Size = MAP_APPFONT( 40, 12 );
-        SvLook = TRUE;
-        Border = TRUE;
-        Right = TRUE;
-        Spin = TRUE;
-        Repeat = TRUE;
-        Minimum = 30;
-        Maximum = 600;
-        StrictFormat = TRUE;
-        DecimalDigits = 0;
-        SpinSize = 1;
-    };
-
-    String STR_DRIVER_NAME
-    {
-        Text [ en-US ] = "Driver name";
-    };
-    String STR_POOLED_FLAG
-    {
-        Text [ en-US ] = "Pool";
-    };
-    String STR_POOL_TIMEOUT
-    {
-        Text [ en-US ] = "Timeout";
-    };
-    String STR_YES
-    {
-        Text [ en-US ] = "Yes";
-    };
-    String STR_NO
-    {
-        Text [ en-US ] = "No";
-    };
+    Text [ en-US ] = "Driver name";
+};
+String RID_SVXSTR_POOLED_FLAG
+{
+    Text [ en-US ] = "Pool";
+};
+String RID_SVXSTR_POOL_TIMEOUT
+{
+    Text [ en-US ] = "Timeout";
+};
+String RID_SVXSTR_YES
+{
+    Text [ en-US ] = "Yes";
+};
+String RID_SVXSTR_NO
+{
+    Text [ en-US ] = "No";
 };
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/uiconfig/ui/connpooloptions.ui b/cui/uiconfig/ui/connpooloptions.ui
new file mode 100644
index 0000000..2c2c7e4
--- /dev/null
+++ b/cui/uiconfig/ui/connpooloptions.ui
@@ -0,0 +1,213 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+  <!-- interface-requires gtk+ 3.0 -->
+  <object class="GtkAdjustment" id="adjustment1">
+    <property name="lower">30</property>
+    <property name="upper">600</property>
+    <property name="value">60</property>
+    <property name="step_increment">1</property>
+    <property name="page_increment">10</property>
+  </object>
+  <object class="GtkGrid" id="ConnPoolPage">
+    <property name="visible">True</property>
+    <property name="can_focus">False</property>
+    <property name="border_width">6</property>
+    <property name="row_spacing">12</property>
+    <child>
+      <object class="GtkFrame" id="frame1">
+        <property name="visible">True</property>
+        <property name="can_focus">False</property>
+        <property name="hexpand">True</property>
+        <property name="label_xalign">0</property>
+        <property name="shadow_type">none</property>
+        <child>
+          <object class="GtkAlignment" id="alignment1">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="margin_top">6</property>
+            <property name="hexpand">True</property>
+            <property name="top_padding">6</property>
+            <property name="left_padding">12</property>
+            <child>
+              <object class="GtkBox" id="box1">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="orientation">vertical</property>
+                <property name="spacing">12</property>
+                <child>
+                  <object class="GtkCheckButton" id="connectionpooling">
+                    <property name="label" translatable="yes">Connection pooling enabled</property>
+                    <property name="use_action_appearance">False</property>
+                    <property name="visible">True</property>
+                    <property name="can_focus">True</property>
+                    <property name="receives_default">False</property>
+                    <property name="use_action_appearance">False</property>
+                    <property name="use_underline">True</property>
+                    <property name="xalign">0</property>
+                    <property name="draw_indicator">True</property>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">0</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkBox" id="box2">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="margin_left">12</property>
+                    <property name="orientation">vertical</property>
+                    <property name="spacing">12</property>
+                    <child>
+                      <object class="GtkLabel" id="driverslabel">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="xalign">0</property>
+                        <property name="label" translatable="yes">Drivers known in %PRODUCTNAME</property>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">0</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="cuilo-DriverListControl" id="driverlist">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">1</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="GtkBox" id="box3">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="spacing">12</property>
+                        <child>
+                          <object class="GtkLabel" id="driverlabel">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="xalign">0</property>
+                            <property name="label" translatable="yes">Current driver:</property>
+                          </object>
+                          <packing>
+                            <property name="expand">False</property>
+                            <property name="fill">True</property>
+                            <property name="position">0</property>
+                          </packing>
+                        </child>
+                        <child>
+                          <object class="GtkLabel" id="driver">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="hexpand">True</property>
+                            <property name="xalign">0</property>
+                          </object>
+                          <packing>
+                            <property name="expand">False</property>
+                            <property name="fill">True</property>
+                            <property name="position">1</property>
+                          </packing>
+                        </child>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">2</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="GtkCheckButton" id="enablepooling">
+                        <property name="label" translatable="yes">Enable pooling for this driver</property>
+                        <property name="use_action_appearance">False</property>
+                        <property name="visible">True</property>
+                        <property name="can_focus">True</property>
+                        <property name="receives_default">False</property>
+                        <property name="use_action_appearance">False</property>
+                        <property name="xalign">0</property>
+                        <property name="draw_indicator">True</property>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">3</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="GtkBox" id="box4">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="margin_left">12</property>
+                        <property name="spacing">12</property>
+                        <child>
+                          <object class="GtkLabel" id="timeoutlabel">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="xalign">0</property>
+                            <property name="label" translatable="yes">_Timeout (seconds)</property>
+                            <property name="use_underline">True</property>
+                            <property name="mnemonic_widget">timeout</property>
+                          </object>
+                          <packing>
+                            <property name="expand">False</property>
+                            <property name="fill">True</property>
+                            <property name="position">0</property>
+                          </packing>
+                        </child>
+                        <child>
+                          <object class="GtkSpinButton" id="timeout">
+                            <property name="visible">True</property>
+                            <property name="can_focus">True</property>
+                            <property name="invisible_char">●</property>
+                            <property name="invisible_char_set">True</property>
+                            <property name="adjustment">adjustment1</property>
+                          </object>
+                          <packing>
+                            <property name="expand">False</property>
+                            <property name="fill">True</property>
+                            <property name="position">1</property>
+                          </packing>
+                        </child>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">4</property>
+                      </packing>
+                    </child>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">1</property>
+                  </packing>
+                </child>
+              </object>
+            </child>
+          </object>
+        </child>
+        <child type="label">
+          <object class="GtkLabel" id="label1">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Registered databases</property>
+            <attributes>
+              <attribute name="weight" value="bold"/>
+            </attributes>
+          </object>
+        </child>
+      </object>
+      <packing>
+        <property name="left_attach">0</property>
+        <property name="top_attach">0</property>
+        <property name="width">1</property>
+        <property name="height">1</property>
+      </packing>
+    </child>
+  </object>
+</interface>
diff --git a/extras/source/glade/libreoffice-catalog.xml.in b/extras/source/glade/libreoffice-catalog.xml.in
index 82ab41b..b3025e4d 100644
--- a/extras/source/glade/libreoffice-catalog.xml.in
+++ b/extras/source/glade/libreoffice-catalog.xml.in
@@ -527,5 +527,9 @@
                         generic-name="Template Icon View" parent="GtkIconView"
                         icon-name="widget-gtk-iconview"/>
 
+    <glade-widget-class title="Driver List Control" name="cuilo-DriverListControl"
+                        generic-name="DriverListControl" parent="GtkEntry"
+                        icon-name="widget-gtk-combobox"/>
+
   </glade-widget-classes>
 </glade-catalog>
commit b84c89bb2ab5c2ac8e4bf2efff9db2d6cf26c401
Author: Jan Holesovsky <kendy at collabora.com>
Date:   Sun Sep 29 12:14:58 2013 +0200

    Convert dbregister to .ui + adapt code.
    
    Change-Id: I81cef872b6369df425b6cb3bab0eeae3fde2c34c

diff --git a/cui/UIConfig_cui.mk b/cui/UIConfig_cui.mk
index 2fae5da..05ae93b 100644
--- a/cui/UIConfig_cui.mk
+++ b/cui/UIConfig_cui.mk
@@ -37,6 +37,7 @@ $(eval $(call gb_UIConfig_add_uifiles,cui,\
 	cui/uiconfig/ui/formatnumberdialog \
 	cui/uiconfig/ui/gradientpage \
 	cui/uiconfig/ui/colorconfigwin \
+	cui/uiconfig/ui/dbregisterpage \
 	cui/uiconfig/ui/effectspage \
 	cui/uiconfig/ui/hatchpage \
 	cui/uiconfig/ui/hyphenate \
diff --git a/cui/source/inc/cuires.hrc b/cui/source/inc/cuires.hrc
index 0ccdd9c6..5e23c48 100644
--- a/cui/source/inc/cuires.hrc
+++ b/cui/source/inc/cuires.hrc
@@ -445,6 +445,9 @@
 #define RID_SVXSTR_HEADER1                                  (RID_SVX_START + 1242)
 #define RID_SVXSTR_HEADER2                                  (RID_SVX_START + 1243)
 
+#define RID_SVXSTR_TYPE                                     (RID_SVX_START + 1244)
+#define RID_SVXSTR_PATH                                     (RID_SVX_START + 1245)
+
 #endif
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/source/inc/dbregister.hxx b/cui/source/inc/dbregister.hxx
index 9a5c7bf..d89560d 100644
--- a/cui/source/inc/dbregister.hxx
+++ b/cui/source/inc/dbregister.hxx
@@ -44,13 +44,13 @@ namespace svx
     class DbRegistrationOptionsPage : public SfxTabPage
     {
     private:
-        FixedLine           aStdBox;
-        FixedText           aTypeText;
-        FixedText           aPathText;
-        SvSimpleTableContainer aPathCtrl;
-        PushButton          m_aNew;
-        PushButton          m_aEdit;
-        PushButton          m_aDelete;
+        OUString            aTypeText;
+        OUString            aPathText;
+
+        SvSimpleTableContainer* m_pPathCtrl;
+        PushButton*         m_pNew;
+        PushButton*         m_pEdit;
+        PushButton*         m_pDelete;
 
         ::svx::OptHeaderTabListBox* pPathBox;
         SvTreeListEntry*        m_pCurEntry;
diff --git a/cui/source/options/dbregister.cxx b/cui/source/options/dbregister.cxx
index 1e4ce41..4701c7d 100644
--- a/cui/source/options/dbregister.cxx
+++ b/cui/source/options/dbregister.cxx
@@ -18,7 +18,6 @@
  */
 
 #include "dbregister.hxx"
-#include "dbregister.hrc"
 #include "dbregistersettings.hxx"
 #include "connpooloptions.hxx"
 #include <svl/filenotation.hxx>
@@ -104,29 +103,33 @@ short DatabaseRegistrationDialog::Execute()
 
 DbRegistrationOptionsPage::DbRegistrationOptionsPage( Window* pParent, const SfxItemSet& rSet ) :
 
-    SfxTabPage( pParent, CUI_RES( RID_SFXPAGE_DBREGISTER), rSet ),
+    SfxTabPage( pParent, "DbRegisterPage", "cui/ui/dbregisterpage.ui", rSet ),
 
-    aStdBox         ( this, CUI_RES( GB_STD ) ),
-    aTypeText       ( this, CUI_RES( FT_TYPE ) ),
-    aPathText       ( this, CUI_RES( FT_PATH ) ),
-    aPathCtrl       ( this, CUI_RES( LB_PATH ) ),
-    m_aNew          ( this, CUI_RES( BTN_NEW ) ),
-    m_aEdit         ( this, CUI_RES( BTN_EDIT ) ),
-    m_aDelete       ( this, CUI_RES( BTN_DELETE ) ),
+    aTypeText       ( CUI_RES( RID_SVXSTR_TYPE ) ),
+    aPathText       ( CUI_RES( RID_SVXSTR_PATH ) ),
     pPathBox        ( NULL ),
     m_pCurEntry     ( NULL ),
     m_nOldCount     ( 0 ),
     m_bModified     ( sal_False )
 {
-    m_aNew.SetClickHdl( LINK( this, DbRegistrationOptionsPage, NewHdl ) );
-    m_aEdit.SetClickHdl( LINK( this, DbRegistrationOptionsPage, EditHdl ) );
-    m_aDelete.SetClickHdl( LINK( this, DbRegistrationOptionsPage, DeleteHdl ) );
+    get(m_pPathCtrl, "pathctrl");
+    Size aControlSize(248, 147);
+    aControlSize = LogicToPixel(aControlSize, MAP_APPFONT);
+    m_pPathCtrl->set_width_request(aControlSize.Width());
+    m_pPathCtrl->set_height_request(aControlSize.Height());
 
-    Size aBoxSize = aPathCtrl.GetOutputSizePixel();
+    get(m_pNew, "new");
+    get(m_pEdit, "edit");
+    get(m_pDelete, "delete");
 
+    m_pNew->SetClickHdl( LINK( this, DbRegistrationOptionsPage, NewHdl ) );
+    m_pEdit->SetClickHdl( LINK( this, DbRegistrationOptionsPage, EditHdl ) );
+    m_pDelete->SetClickHdl( LINK( this, DbRegistrationOptionsPage, DeleteHdl ) );
+
+    Size aBoxSize = m_pPathCtrl->GetOutputSizePixel();
 
     WinBits nBits = WB_SORT | WB_HSCROLL | WB_CLIPCHILDREN | WB_TABSTOP;
-    pPathBox = new ::svx::OptHeaderTabListBox( aPathCtrl, nBits );
+    pPathBox = new ::svx::OptHeaderTabListBox( *m_pPathCtrl, nBits );
 
     HeaderBar &rBar = pPathBox->GetTheHeaderBar();
 
@@ -134,11 +137,11 @@ DbRegistrationOptionsPage::DbRegistrationOptionsPage( Window* pParent, const Sfx
     rBar.SetEndDragHdl( LINK( this, DbRegistrationOptionsPage, HeaderEndDrag_Impl ) );
     Size aSz;
     aSz.Width() = TAB_WIDTH1;
-    rBar.InsertItem( ITEMID_TYPE, aTypeText.GetText(),
+    rBar.InsertItem( ITEMID_TYPE, aTypeText,
                             LogicToPixel( aSz, MapMode( MAP_APPFONT ) ).Width(),
                             HIB_LEFT | HIB_VCENTER | HIB_CLICKABLE | HIB_UPARROW );
     aSz.Width() = TAB_WIDTH2;
-    rBar.InsertItem( ITEMID_PATH, aPathText.GetText(),
+    rBar.InsertItem( ITEMID_PATH, aPathText,
                             LogicToPixel( aSz, MapMode( MAP_APPFONT ) ).Width(),
                             HIB_LEFT | HIB_VCENTER );
 
@@ -158,8 +161,6 @@ DbRegistrationOptionsPage::DbRegistrationOptionsPage( Window* pParent, const Sfx
     rBar.SetHelpId( HID_DBPATH_HEADERBAR );
 
     pPathBox->ShowTable();
-
-    FreeResource();
 }
 
 // -----------------------------------------------------------------------
@@ -384,8 +385,8 @@ IMPL_LINK_NOARG(DbRegistrationOptionsPage, PathSelect_Impl)
         bReadOnly = pRegistration->bReadOnly;
     }
 
-    m_aEdit.Enable( !bReadOnly );
-    m_aDelete.Enable( !bReadOnly );
+    m_pEdit->Enable( !bReadOnly );
+    m_pDelete->Enable( !bReadOnly );
     return 0;
 }
 // -----------------------------------------------------------------------------
diff --git a/cui/source/options/dbregister.hrc b/cui/source/options/dbregister.hrc
deleted file mode 100644
index ac3841b..0000000
--- a/cui/source/options/dbregister.hrc
+++ /dev/null
@@ -1,34 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-#ifndef SVX_DBREGISTER_HRC
-#define SVX_DBREGISTER_HRC
-// defines ---------------------------------------------------------------
-
-#define FT_TYPE                 10
-#define FT_PATH                 11
-#define LB_PATH                 12
-#define BTN_NEW             13
-#define BTN_EDIT            14
-#define GB_STD                  15
-#define IMG_LOCK                16
-#define BTN_DELETE              17
-
-#endif // SVX_DBREGISTER_HRC
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/source/options/dbregister.src b/cui/source/options/dbregister.src
index 4e89503..2f8d708 100644
--- a/cui/source/options/dbregister.src
+++ b/cui/source/options/dbregister.src
@@ -17,70 +17,15 @@
  *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
  */
 
-#include "dbregister.hrc"
 #include <cuires.hrc>
-#include <cuires.hrc>
-#include <svx/dialogs.hrc>
 
-// RID_SFXPAGE_PATH -----------------------------------------------------
-#define STD_MASKCOLOR Color { Red=0xffff; Green=0x0000; Blue=0xffff; }
-TabPage RID_SFXPAGE_DBREGISTER
+String RID_SVXSTR_TYPE
 {
-    HelpId = "cui:TabPage:RID_SFXPAGE_DBREGISTER" ;
-    OutputSize = TRUE ;
-    SVLook = TRUE ;
-    Hide = TRUE ;
-    Size = MAP_APPFONT ( TP_WIDTH , TP_HEIGHT ) ;
-    Text [ en-US ] = "Registered databases" ;
-
-    FixedText FT_TYPE
-    {
-        Hide = TRUE;
-        Pos = MAP_APPFONT ( 12 , 14 ) ;
-        Size = MAP_APPFONT ( 40 , 10 ) ;
-        Text [ en-US ] = "Registered name" ;
-    };
-    FixedText FT_PATH
-    {
-        Hide = TRUE;
-        Pos = MAP_APPFONT ( 110 , 14 ) ;
-        Size = MAP_APPFONT ( 40 , 10 ) ;
-        Text [ en-US ] = "Database file" ;
-    };
-    Control LB_PATH
-    {
-        Pos = MAP_APPFONT ( 12 , 14 ) ;
-        Size = MAP_APPFONT ( 236 , 147 ) ;
-        Border = TRUE ;
-        TabStop = TRUE;
-    };
-    PushButton BTN_NEW
-    {
-        HelpID = "cui:PushButton:RID_SFXPAGE_DBREGISTER:BTN_NEW";
-        Pos = MAP_APPFONT ( 47 , 165 ) ;
-        Size = MAP_APPFONT ( 65 , 14 ) ;
-        Text [ en-US ] = "~New..." ;
-    };
-    PushButton BTN_EDIT
-    {
-        HelpID = "cui:PushButton:RID_SFXPAGE_DBREGISTER:BTN_EDIT";
-        Pos = MAP_APPFONT ( 183 , 165 ) ;
-        Size = MAP_APPFONT ( 65 , 14 ) ;
-        Text [ en-US ] = "~Edit..." ;
-    };
-    PushButton BTN_DELETE
-    {
-        HelpID = "cui:PushButton:RID_SFXPAGE_DBREGISTER:BTN_DELETE";
-        Pos = MAP_APPFONT ( 115 , 165 ) ;
-        Size = MAP_APPFONT ( 65 , 14 ) ;
-        Text [ en-US ] = "~Delete" ;
-    };
-    FixedLine GB_STD
-    {
-        Pos = MAP_APPFONT ( 6 , 3 ) ;
-        Size = MAP_APPFONT ( 248 , 8 ) ;
-        Text [ en-US ] = "Registered databases" ;
-    };
+    Text [ en-US ] = "Registered name" ;
+};
+String RID_SVXSTR_PATH
+{
+    Text [ en-US ] = "Database file" ;
 };
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/uiconfig/ui/dbregisterpage.ui b/cui/uiconfig/ui/dbregisterpage.ui
new file mode 100644
index 0000000..f555953
--- /dev/null
+++ b/cui/uiconfig/ui/dbregisterpage.ui
@@ -0,0 +1,129 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+  <!-- interface-requires gtk+ 3.0 -->
+  <!-- interface-requires LibreOffice 1.0 -->
+  <object class="GtkGrid" id="DbRegisterPage">
+    <property name="visible">True</property>
+    <property name="can_focus">False</property>
+    <property name="border_width">6</property>
+    <property name="row_spacing">12</property>
+    <child>
+      <object class="GtkFrame" id="frame1">
+        <property name="visible">True</property>
+        <property name="can_focus">False</property>
+        <property name="hexpand">True</property>
+        <property name="label_xalign">0</property>
+        <property name="shadow_type">none</property>
+        <child>
+          <object class="GtkAlignment" id="alignment1">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="margin_top">6</property>
+            <property name="hexpand">True</property>
+            <property name="top_padding">6</property>
+            <property name="left_padding">12</property>
+            <child>
+              <object class="GtkBox" id="box1">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="orientation">vertical</property>
+                <property name="spacing">12</property>
+                <child>
+                  <object class="svtlo-SvSimpleTableContainer" id="pathctrl">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <child internal-child="selection">
+                      <object class="GtkTreeSelection" id="Simple Table Container-selection1"/>
+                    </child>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">0</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkBox" id="box2">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="halign">end</property>
+                    <property name="spacing">12</property>
+                    <child>
+                      <object class="GtkButton" id="new">
+                        <property name="label" translatable="yes">_New...</property>
+                        <property name="use_action_appearance">False</property>
+                        <property name="visible">True</property>
+                        <property name="can_focus">True</property>
+                        <property name="receives_default">True</property>
+                        <property name="use_action_appearance">False</property>
+                        <property name="use_underline">True</property>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">0</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="GtkButton" id="delete">
+                        <property name="label" translatable="yes">_Delete</property>
+                        <property name="use_action_appearance">False</property>
+                        <property name="visible">True</property>
+                        <property name="can_focus">True</property>
+                        <property name="receives_default">True</property>
+                        <property name="use_action_appearance">False</property>
+                        <property name="use_underline">True</property>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">1</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="GtkButton" id="edit">
+                        <property name="label" translatable="yes">_Edit...</property>
+                        <property name="use_action_appearance">False</property>
+                        <property name="visible">True</property>
+                        <property name="can_focus">True</property>
+                        <property name="receives_default">True</property>
+                        <property name="use_action_appearance">False</property>
+                        <property name="use_underline">True</property>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">2</property>
+                      </packing>
+                    </child>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">1</property>
+                  </packing>
+                </child>
+              </object>
+            </child>
+          </object>
+        </child>
+        <child type="label">
+          <object class="GtkLabel" id="label1">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Registered databases</property>
+            <attributes>
+              <attribute name="weight" value="bold"/>
+            </attributes>
+          </object>
+        </child>
+      </object>
+      <packing>
+        <property name="left_attach">0</property>
+        <property name="top_attach">0</property>
+        <property name="width">1</property>
+        <property name="height">1</property>
+      </packing>
+    </child>
+  </object>
+</interface>
commit ffe69acb222f1b4773a6fad20429ee1bc44fd985
Author: Jan Holesovsky <kendy at collabora.com>
Date:   Sun Sep 29 10:49:07 2013 +0200

    Kill internationaloptions page, it has been unused for years.
    
    Change-Id: Ia528bf60a8af81b17ca18ad5eb305bed59818d05

diff --git a/cui/AllLangResTarget_cui.mk b/cui/AllLangResTarget_cui.mk
index 119a1d6..147979a 100644
--- a/cui/AllLangResTarget_cui.mk
+++ b/cui/AllLangResTarget_cui.mk
@@ -49,7 +49,6 @@ $(eval $(call gb_SrsTarget_add_files,cui/res,\
     cui/source/options/connpooloptions.src \
     cui/source/options/dbregister.src \
     cui/source/options/doclinkdialog.src \
-    cui/source/options/internationaloptions.src \
     cui/source/options/optchart.src \
     cui/source/options/optcolor.src \
     cui/source/options/optdict.src \
diff --git a/cui/Library_cui.mk b/cui/Library_cui.mk
index 809319a..19d2345 100644
--- a/cui/Library_cui.mk
+++ b/cui/Library_cui.mk
@@ -134,7 +134,6 @@ $(eval $(call gb_Library_add_exception_objects,cui,\
     cui/source/options/dbregistersettings \
     cui/source/options/doclinkdialog \
     cui/source/options/fontsubs \
-    cui/source/options/internationaloptions \
 	cui/source/options/optaboutconfig \
     cui/source/options/optaccessibility \
     cui/source/options/optasian \
diff --git a/cui/source/factory/dlgfact.cxx b/cui/source/factory/dlgfact.cxx
index 75f61fd..4807897 100644
--- a/cui/source/factory/dlgfact.cxx
+++ b/cui/source/factory/dlgfact.cxx
@@ -36,7 +36,6 @@
 #include "textanim.hxx"
 #include "autocdlg.hxx"
 #include "treeopt.hxx"
-#include "internationaloptions.hxx"
 #include "labdlg.hxx"
 #include "hangulhanjadlg.hxx"
 #include "showcols.hxx"
@@ -1706,11 +1705,6 @@ CreateTabPage AbstractDialogFactory_Impl::GetTabPageCreatorFunc( sal_uInt16 nId
 {
     switch ( nId )
     {
-        case RID_OFA_TP_INTERNATIONAL:
-            return ::offapp::InternationalOptionsPage::CreateSc;
-        case RID_OFA_TP_INTERNATIONAL_SD:
-        case RID_OFA_TP_INTERNATIONAL_IMPR:
-            return offapp::InternationalOptionsPage::CreateSd;
         case RID_SVXPAGE_TEXTANIMATION :
             return SvxTextAnimationPage::Create;
         case RID_SVXTABPAGE_GALLERY_GENERAL :
diff --git a/cui/source/inc/internationaloptions.hxx b/cui/source/inc/internationaloptions.hxx
deleted file mode 100644
index 917dea9..0000000
--- a/cui/source/inc/internationaloptions.hxx
+++ /dev/null
@@ -1,51 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#ifndef _OFFAPP_INTERNATIONALOPTIONS_HXX_
-#define _OFFAPP_INTERNATIONALOPTIONS_HXX_
-
-#include <sfx2/tabdlg.hxx>
-#include <vcl/fixed.hxx>
-
-namespace offapp
-{
-    class InternationalOptionsPage : public SfxTabPage
-    {
-    private:
-        struct IMPL;
-        IMPL*               m_pImpl;
-
-    protected:
-                            InternationalOptionsPage( Window* _pParent, const SfxItemSet& _rAttrSet );
-
-        virtual sal_Bool        FillItemSet( SfxItemSet& _rSet );
-        virtual void        Reset( const SfxItemSet& _rSet );
-
-    public:
-        virtual             ~InternationalOptionsPage();
-
-        static SfxTabPage*  CreateSd( Window* _pParent, const SfxItemSet& _rAttrSet );
-        static SfxTabPage*  CreateSc( Window* _pParent, const SfxItemSet& _rAttrSet );
-    };
-
-}   // /namespace offapp
-
-#endif
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/source/options/internationaloptions.cxx b/cui/source/options/internationaloptions.cxx
deleted file mode 100644
index d1d3412..0000000
--- a/cui/source/options/internationaloptions.cxx
+++ /dev/null
@@ -1,141 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#include "internationaloptions.hxx"
-#include "internationaloptions.hrc"
-#include <svl/eitem.hxx>
-#include <cuires.hrc>
-#include "helpid.hrc"
-#include <dialmgr.hxx>
-#include <svx/dialogs.hrc>
-
-namespace offapp
-{
-
-    struct InternationalOptionsPage::IMPL
-    {
-        FixedLine           m_aFL_DefaultTextDirection;
-        RadioButton         m_aRB_TxtDirLeft2Right;
-        RadioButton         m_aRB_TxtDirRight2Left;
-        FixedLine           m_aFL_SheetView;
-        CheckBox            m_aCB_ShtVwRight2Left;
-        CheckBox            m_aCB_ShtVwCurrentDocOnly;
-
-        sal_Bool                m_bEnable_SheetView_Opt : 1;
-
-        inline              IMPL( Window* _pParent );
-
-        inline void         EnableOption_SheetView( sal_Bool _bEnable = sal_True );
-        void                ShowOption_SheetView( sal_Bool _bShow = sal_True );
-
-        sal_Bool                FillItemSet( SfxItemSet& _rSet );
-        void                Reset( const SfxItemSet& _rSet );
-    };
-
-    inline InternationalOptionsPage::IMPL::IMPL( Window* _pParent ) :
-        m_aFL_DefaultTextDirection  ( _pParent, CUI_RES( FL_DEFTXTDIRECTION ) )
-        ,m_aRB_TxtDirLeft2Right     ( _pParent, CUI_RES( RB_TXTDIR_LEFT2RIGHT ) )
-        ,m_aRB_TxtDirRight2Left     ( _pParent, CUI_RES( RB_TXTDIR_RIGHT2LEFT ) )
-        ,m_aFL_SheetView            ( _pParent, CUI_RES( FL_SHEETVIEW ) )
-        ,m_aCB_ShtVwRight2Left      ( _pParent, CUI_RES( CB_SHTVW_RIGHT2LEFT ) )
-        ,m_aCB_ShtVwCurrentDocOnly  ( _pParent, CUI_RES( CB_SHTVW_CURRENTDOCONLY ) )
-
-        ,m_bEnable_SheetView_Opt    ( sal_False )
-    {
-        ShowOption_SheetView( m_bEnable_SheetView_Opt );
-    }
-
-    inline void InternationalOptionsPage::IMPL::EnableOption_SheetView( sal_Bool _bEnable )
-    {
-        if( m_bEnable_SheetView_Opt != _bEnable )
-        {
-            ShowOption_SheetView( _bEnable );
-
-            m_bEnable_SheetView_Opt = _bEnable;
-        }
-    }
-
-    void InternationalOptionsPage::IMPL::ShowOption_SheetView( sal_Bool _bShow )
-    {
-        m_aFL_SheetView.Show( _bShow );
-        m_aCB_ShtVwRight2Left.Show( _bShow );
-        m_aCB_ShtVwCurrentDocOnly.Show( _bShow );
-    }
-
-    sal_Bool InternationalOptionsPage::IMPL::FillItemSet( SfxItemSet& _rSet )
-    {
-        DBG_ASSERT( _rSet.GetPool(), "-InternationalOptionsPage::FillItemSet(): no pool gives rums!" );
-
-        // handling of DefaultTextDirection stuff
-        _rSet.Put(  SfxBoolItem(    _rSet.GetPool()->GetWhich( SID_ATTR_PARA_LEFT_TO_RIGHT ),
-                                    m_aRB_TxtDirLeft2Right.IsChecked() ),
-                    SID_ATTR_PARA_LEFT_TO_RIGHT );
-
-        return sal_True;
-    }
-
-    void InternationalOptionsPage::IMPL::Reset( const SfxItemSet& _rSet )
-    {
-        // handling of DefaultTextDirection stuff
-        const SfxBoolItem*  pLeft2RightItem = static_cast< const SfxBoolItem* >( GetItem( _rSet, SID_ATTR_PARA_LEFT_TO_RIGHT ) );
-
-        DBG_ASSERT( pLeft2RightItem, "+InternationalOptionsPage::Reset(): SID_ATTR_PARA_LEFT_TO_RIGHT not set!" );
-
-        sal_Bool                bLeft2Right = pLeft2RightItem? pLeft2RightItem->GetValue() : sal_True;
-        m_aRB_TxtDirLeft2Right.Check( bLeft2Right );
-
-    }
-
-    InternationalOptionsPage::InternationalOptionsPage( Window* _pParent, const SfxItemSet& _rAttrSet ) :
-        SfxTabPage  ( _pParent, CUI_RES( RID_OFA_TP_INTERNATIONAL ), _rAttrSet )
-
-        ,m_pImpl    ( new IMPL( this ) )
-    {
-        FreeResource();
-    }
-
-    SfxTabPage* InternationalOptionsPage::CreateSd( Window* _pParent, const SfxItemSet& _rAttrSet )
-    {
-        return new InternationalOptionsPage( _pParent, _rAttrSet );
-    }
-
-    SfxTabPage* InternationalOptionsPage::CreateSc( Window* _pParent, const SfxItemSet& _rAttrSet )
-    {
-        InternationalOptionsPage*   p = new InternationalOptionsPage( _pParent, _rAttrSet );
-        return p;
-    }
-
-    InternationalOptionsPage::~InternationalOptionsPage()
-    {
-        DELETEZ( m_pImpl );
-    }
-
-    sal_Bool InternationalOptionsPage::FillItemSet( SfxItemSet& _rSet )
-    {
-        return m_pImpl->FillItemSet( _rSet );
-    }
-
-    void InternationalOptionsPage::Reset( const SfxItemSet& _rSet )
-    {
-        m_pImpl->Reset( _rSet );
-    }
-
-}   // namespace offapp
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/source/options/internationaloptions.src b/cui/source/options/internationaloptions.src
deleted file mode 100644
index 7a6d7ed..0000000
--- a/cui/source/options/internationaloptions.src
+++ /dev/null
@@ -1,81 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#include "internationaloptions.hrc"
-#include "helpid.hrc"
-#include <cuires.hrc>
-#include <svx/dialogs.hrc>
-
-TabPage RID_OFA_TP_INTERNATIONAL
-{
-    HelpID = "cui:TabPage:RID_OFA_TP_INTERNATIONAL";
-    OutputSize = TRUE ;
-    Size = MAP_APPFONT ( PAGE_SIZE_X, PAGE_SIZE_Y ) ;
-    SVLook = TRUE ;
-    Hide = TRUE ;
-
-    FixedLine FL_DEFTXTDIRECTION
-    {
-        Pos = MAP_APPFONT( COL_0, ROW_0 );
-        Size = MAP_APPFONT( WIDTH2END( COL_0 ), HEIGHT_FL );
-        Text [ en-US ] = "Default text direction";
-    };
-
-    RadioButton RB_TXTDIR_LEFT2RIGHT
-    {
-        HelpID = "cui:RadioButton:RID_OFA_TP_INTERNATIONAL:RB_TXTDIR_LEFT2RIGHT";
-        Pos = MAP_APPFONT( COL_1, ROW_1 );
-        Size = MAP_APPFONT( WIDTH2END( COL_1 ), HEIGHT_RB );
-        Group = TRUE;
-        Text [ en-US ] = "~Left-to-right";
-    };
-
-    RadioButton RB_TXTDIR_RIGHT2LEFT
-    {
-        HelpID = "cui:RadioButton:RID_OFA_TP_INTERNATIONAL:RB_TXTDIR_RIGHT2LEFT";
-        Pos = MAP_APPFONT( COL_1, ROW_2 );
-        Size = MAP_APPFONT( WIDTH2END( COL_1 ), HEIGHT_RB );
-        Text [ en-US ] = "~Right-to-left";
-    };
-
-    FixedLine FL_SHEETVIEW
-    {
-        Pos = MAP_APPFONT( COL_0, ROW_3 );
-        Size = MAP_APPFONT( WIDTH2END( COL_0 ), HEIGHT_FL );
-        Text [ en-US ] = "Sheet view";
-    };
-
-    CheckBox CB_SHTVW_RIGHT2LEFT
-    {
-        HelpID = "cui:CheckBox:RID_OFA_TP_INTERNATIONAL:CB_SHTVW_RIGHT2LEFT";
-        Pos = MAP_APPFONT( COL_1, ROW_4 );
-        Size = MAP_APPFONT( WIDTH2END( COL_1 ), HEIGHT_CB );
-        Text [ en-US ] = "Right-~to-left";
-    };
-
-    CheckBox CB_SHTVW_CURRENTDOCONLY
-    {
-        HelpID = "cui:CheckBox:RID_OFA_TP_INTERNATIONAL:CB_SHTVW_CURRENTDOCONLY";
-        Pos = MAP_APPFONT( COL_2, ROW_5 );
-        Size = MAP_APPFONT( WIDTH2END( COL_2 ), HEIGHT_CB );
-        Text [ en-US ] = "~Current document only";
-    };
-};
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/source/options/treeopt.cxx b/cui/source/options/treeopt.cxx
index 3602995..3239304 100644
--- a/cui/source/options/treeopt.cxx
+++ b/cui/source/options/treeopt.cxx
@@ -398,7 +398,6 @@ static OptionsMapping_Impl const OptionsMap_Impl[] =
     { "Calc",               NULL,                   SID_SC_EDITOPTIONS },
     { "Calc",               "General",              SID_SC_TP_LAYOUT },
     { "Calc",               "View",                 SID_SC_TP_CONTENT },
-    { "Calc",               "International",        RID_OFA_TP_INTERNATIONAL },
     { "Calc",               "Calculate",            SID_SC_TP_CALC },
     { "Calc",               "Formula",              SID_SC_TP_FORMULA },
     { "Calc",               "SortLists",            SID_SC_TP_USERLISTS },
@@ -1679,10 +1678,8 @@ void OfaTreeOptionsDialog::Initialize( const Reference< XFrame >& _xFrame )
                     nPageId = (sal_uInt16)rCalcArray.GetValue(i);
                     if ( lcl_isOptionHidden( nPageId, aOptionsDlgOpt ) )
                         continue;
-//                  if( bCTL || nId != RID_OFA_TP_INTERNATIONAL )
-//                  #103755# if an international tabpage is need one day, this should be used again... ;-)
-                    if ( nPageId != RID_OFA_TP_INTERNATIONAL )
-                        AddTabPage( nPageId, rCalcArray.GetString( i ), nGroup );
+
+                    AddTabPage( nPageId, rCalcArray.GetString( i ), nGroup );
                 }
             }
         }
@@ -1699,15 +1696,14 @@ void OfaTreeOptionsDialog::Initialize( const Reference< XFrame >& _xFrame )
                 ResStringArray& rImpressArray = aDlgResource.GetImpressArray();
                 setGroupName( "Impress", rImpressArray.GetString(0) );
                 nGroup = AddGroup( rImpressArray.GetString( 0 ), pSdMod, pSdMod, SID_SD_EDITOPTIONS );
-                const sal_Bool bCTL = aLanguageOptions.IsCTLFontEnabled();
                 const sal_uInt16 nCount = static_cast< const sal_uInt16 >( rImpressArray.Count() );
                 for ( i = 1; i < nCount; ++i )
                 {
                     nPageId = (sal_uInt16)rImpressArray.GetValue(i);
                     if ( lcl_isOptionHidden( nPageId, aOptionsDlgOpt ) )
                         continue;
-                    if ( bCTL || nPageId != RID_OFA_TP_INTERNATIONAL_IMPR )
-                        AddTabPage( nPageId, rImpressArray.GetString(i), nGroup );
+
+                    AddTabPage( nPageId, rImpressArray.GetString(i), nGroup );
                 }
             }
         }
@@ -1723,15 +1719,14 @@ void OfaTreeOptionsDialog::Initialize( const Reference< XFrame >& _xFrame )
                 ResStringArray& rDrawArray = aDlgResource.GetDrawArray();
                 setGroupName( "Draw", rDrawArray.GetString(0) );
                 nGroup = AddGroup( rDrawArray.GetString( 0 ), pSdMod, pSdMod, SID_SD_GRAPHIC_OPTIONS );
-                const sal_Bool bCTL = aLanguageOptions.IsCTLFontEnabled();
                 const sal_uInt16 nCount = static_cast< const sal_uInt16 >( rDrawArray.Count() );
                 for ( i = 1; i < nCount; ++i )
                 {
                     nPageId = (sal_uInt16)rDrawArray.GetValue(i);
                     if ( lcl_isOptionHidden( nPageId, aOptionsDlgOpt ) )
                         continue;
-                    if ( bCTL || nPageId != RID_OFA_TP_INTERNATIONAL_SD )
-                        AddTabPage( nPageId, rDrawArray.GetString(i), nGroup );
+
+                    AddTabPage( nPageId, rDrawArray.GetString(i), nGroup );
                 }
             }
         }
diff --git a/cui/source/options/treeopt.src b/cui/source/options/treeopt.src
index a8bb91f..f5f6a66 100644
--- a/cui/source/options/treeopt.src
+++ b/cui/source/options/treeopt.src
@@ -179,7 +179,6 @@ Resource RID_OFADLG_OPTIONS_TREE_PAGES
             < "General" ;           SID_SC_TP_LAYOUT            ;> ;
             < "Defaults" ;          RID_SC_TP_DEFAULTS          ;> ;
             < "View" ;          SID_SC_TP_CONTENT           ;> ;
-            < "International" ;     RID_OFA_TP_INTERNATIONAL    ;> ;
             < "Calculate" ;         SID_SC_TP_CALC              ;> ;
             < "Formula" ;       SID_SC_TP_FORMULA ;> ;
             < "Sort Lists" ;        SID_SC_TP_USERLISTS         ;> ;
diff --git a/include/svx/dialogs.hrc b/include/svx/dialogs.hrc
index a8f19a2..4c1ba17 100644
--- a/include/svx/dialogs.hrc
+++ b/include/svx/dialogs.hrc
@@ -146,9 +146,6 @@
 #define SID_SD_TP_CONTENTS              (RID_OFA_START + 225)
 #define SID_SD_TP_SNAP                  (RID_OFA_START + 227)
 #define SID_SD_TP_MISC                  (RID_OFA_START + 231)
-#define RID_OFA_TP_INTERNATIONAL_SD     (RID_OFA_START + 253)
-#define RID_OFA_TP_INTERNATIONAL_IMPR   (RID_OFA_START + 254)
-#define RID_OFA_TP_INTERNATIONAL        (RID_OFA_START + 252) // calc
 #define RID_SC_TP_DEFAULTS              (RID_OFA_START + 253)
 
 //---------------------------------------------------------------------
diff --git a/sc/source/ui/app/scmod.cxx b/sc/source/ui/app/scmod.cxx
index 00a9748..6c2cd27 100644
--- a/sc/source/ui/app/scmod.cxx
+++ b/sc/source/ui/app/scmod.cxx
@@ -2206,17 +2206,6 @@ SfxTabPage*  ScModule::CreateTabPage( sal_uInt16 nId, Window* pParent, const Sfx
                     pRet = (*ScTpDefaultsOptionsCreate)( pParent, rSet);
             }
             break;
-
-        case RID_OFA_TP_INTERNATIONAL:
-        {
-            SfxAbstractDialogFactory* pSfxFact = SfxAbstractDialogFactory::Create();
-            if ( pSfxFact )
-            {
-                ::CreateTabPage fnCreatePage = pSfxFact->GetTabPageCreatorFunc( nId );
-                if ( fnCreatePage )
-                    pRet = (*fnCreatePage)( pParent, rSet );
-            }
-        }
     }
 
     OSL_ENSURE( pRet, "ScModule::CreateTabPage(): no valid ID for TabPage!" );
diff --git a/sd/source/ui/app/sdmod2.cxx b/sd/source/ui/app/sdmod2.cxx
index 1851498..083abc5 100644
--- a/sd/source/ui/app/sdmod2.cxx
+++ b/sd/source/ui/app/sdmod2.cxx
@@ -765,8 +765,6 @@ SfxTabPage* SdModule::CreateTabPage( sal_uInt16 nId, Window* pParent, const SfxI
                 }
             }
             break;
-            case RID_OFA_TP_INTERNATIONAL_SD:
-            case RID_OFA_TP_INTERNATIONAL_IMPR:
             case RID_SVXPAGE_TEXTANIMATION :
             {
                 SfxAbstractDialogFactory* pSfxFact = SfxAbstractDialogFactory::Create();
diff --git a/svx/source/src/app.hrc b/svx/source/src/app.hrc
index 1b7ab6c..e94b4f3 100644
--- a/svx/source/src/app.hrc
+++ b/svx/source/src/app.hrc
@@ -110,9 +110,6 @@
 #define OFA_TP_HELPERPROG               (RID_OFA_START + 249)
 #define OFA_TP_MEMORY                   (RID_OFA_START + 250)
 #define RID_SW_TP_STD_FONT_CTL          (RID_OFA_START + 251)
-#define RID_OFA_TP_INTERNATIONAL        (RID_OFA_START + 252)       // 4 SC & ID 4 resource
-#define RID_OFA_TP_INTERNATIONAL_SD     (RID_OFA_START + 253)       // 4 SD
-#define RID_OFA_TP_INTERNATIONAL_IMPR   (RID_OFA_START + 254)       // 4 impress
 #define RID_SW_TP_OPTCOMPATIBILITY_PAGE (RID_OFA_START + 255)
 #define RID_SW_TP_OPTCAPTION_PAGE       (RID_OFA_START + 256)
 #define SID_SC_TP_FORMULA               (RID_OFA_START + 257)
commit ed25f39a72e02a5f30652f9ad55fcfe5551c3026
Author: Jan Holesovsky <kendy at collabora.com>
Date:   Sun Sep 29 09:15:47 2013 +0200

    Convert optfltr page to .ui + adapt code.
    
    Change-Id: I4a854862059b531fa8e07c5cd938f776408e8c81

diff --git a/cui/UIConfig_cui.mk b/cui/UIConfig_cui.mk
index 04a842a..2fae5da 100644
--- a/cui/UIConfig_cui.mk
+++ b/cui/UIConfig_cui.mk
@@ -70,6 +70,7 @@ $(eval $(call gb_UIConfig_add_uifiles,cui,\
 	cui/uiconfig/ui/optchartcolorspage \
 	cui/uiconfig/ui/optemailpage \
 	cui/uiconfig/ui/optfltrpage \
+	cui/uiconfig/ui/optfltrembedpage \
 	cui/uiconfig/ui/optfontspage \
 	cui/uiconfig/ui/optgeneralpage \
 	cui/uiconfig/ui/opthtmlpage \
diff --git a/cui/source/inc/cuires.hrc b/cui/source/inc/cuires.hrc
index 53d7cc6..0ccdd9c6 100644
--- a/cui/source/inc/cuires.hrc
+++ b/cui/source/inc/cuires.hrc
@@ -438,6 +438,13 @@
 #define RID_SVXSTR_LINGU_DICS_EDIT_DIC                      (RID_SVX_START + 1236)
 #define RID_SVXSTR_LINGU_OPTIONS_EDIT                       (RID_SVX_START + 1237)
 
+#define RID_SVXSTR_CHG_MATH                                 (RID_SVX_START + 1238)
+#define RID_SVXSTR_CHG_WRITER                               (RID_SVX_START + 1239)
+#define RID_SVXSTR_CHG_CALC                                 (RID_SVX_START + 1240)
+#define RID_SVXSTR_CHG_IMPRESS                              (RID_SVX_START + 1241)
+#define RID_SVXSTR_HEADER1                                  (RID_SVX_START + 1242)
+#define RID_SVXSTR_HEADER2                                  (RID_SVX_START + 1243)
+
 #endif
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/source/options/optfltr.cxx b/cui/source/options/optfltr.cxx
index 384fccd..3243842 100644
--- a/cui/source/options/optfltr.cxx
+++ b/cui/source/options/optfltr.cxx
@@ -20,7 +20,6 @@
 #include <unotools/moduleoptions.hxx>
 #include <unotools/fltrcfg.hxx>
 #include "optfltr.hxx"
-#include "optfltr.hrc"
 #include <cuires.hrc>
 #include "helpid.hrc"
 #include <dialmgr.hxx>
@@ -129,38 +128,40 @@ void OfaMSFilterTabPage::Reset( const SfxItemSet& )
     aPBasicStgCB->SaveValue();
 }
 
-OfaMSFilterTabPage2::OfaMSFilterTabPage2( Window* pParent,
-                                        const SfxItemSet& rSet )
-    : SfxTabPage( pParent, CUI_RES( RID_OFAPAGE_MSFILTEROPT2 ), rSet ),
-    m_aCheckLBContainer(this, CUI_RES( CLB_SETTINGS)),
-    aCheckLB(m_aCheckLBContainer),
-    aHeader1FT          ( this, CUI_RES( FT_HEADER1_EXPLANATION )),
-    aHeader2FT          ( this, CUI_RES( FT_HEADER2_EXPLANATION )),
-    sHeader1            ( CUI_RES( ST_HEADER1 )),
-    sHeader2            ( CUI_RES( ST_HEADER2 )),
-    sChgToFromMath      ( CUI_RES( ST_CHG_MATH  )),
-    sChgToFromWriter    ( CUI_RES( ST_CHG_WRITER )),
-    sChgToFromCalc      ( CUI_RES( ST_CHG_CALC )),
-    sChgToFromImpress   ( CUI_RES( ST_CHG_IMPRESS )),
+OfaMSFilterTabPage2::OfaMSFilterTabPage2( Window* pParent, const SfxItemSet& rSet ) :
+    SfxTabPage( pParent, "OptFilterPage", "cui/ui/optfltrembedpage.ui", rSet ),
+    sHeader1(CUI_RES(RID_SVXSTR_HEADER1)),
+    sHeader2(CUI_RES(RID_SVXSTR_HEADER2)),
+    sChgToFromMath(CUI_RES(RID_SVXSTR_CHG_MATH)),
+    sChgToFromWriter(CUI_RES(RID_SVXSTR_CHG_WRITER)),
+    sChgToFromCalc(CUI_RES(RID_SVXSTR_CHG_CALC)),
+    sChgToFromImpress(CUI_RES(RID_SVXSTR_CHG_IMPRESS)),
     pCheckButtonData(0)
 {
-    FreeResource();
+    get(m_pCheckLBContainer, "checklbcontainer");
+    Size aControlSize(248, 55);
+    aControlSize = LogicToPixel(aControlSize, MAP_APPFONT);
+    m_pCheckLBContainer->set_width_request(aControlSize.Width());
+    m_pCheckLBContainer->set_height_request(aControlSize.Height());
+
+    m_pCheckLB = new MSFltrSimpleTable(*m_pCheckLBContainer);
 
     static long aStaticTabs[] = { 3, 0, 20, 40 };
-    aCheckLB.SvSimpleTable::SetTabs( aStaticTabs );
+    m_pCheckLB->SvSimpleTable::SetTabs( aStaticTabs );
 
     String sHeader( sHeader1 );
     (( sHeader += '\t' ) += sHeader2 ) += '\t';
-    aCheckLB.InsertHeaderEntry( sHeader, HEADERBAR_APPEND,
+    m_pCheckLB->InsertHeaderEntry( sHeader, HEADERBAR_APPEND,
                     HIB_CENTER | HIB_VCENTER | HIB_FIXEDPOS | HIB_FIXED );
 
-    aCheckLB.SetHelpId( HID_OFAPAGE_MSFLTR2_CLB );
-    aCheckLB.SetStyle( aCheckLB.GetStyle()|WB_HSCROLL| WB_VSCROLL );
+    m_pCheckLB->SetHelpId( HID_OFAPAGE_MSFLTR2_CLB );
+    m_pCheckLB->SetStyle( m_pCheckLB->GetStyle()|WB_HSCROLL| WB_VSCROLL );
 }
 
 OfaMSFilterTabPage2::~OfaMSFilterTabPage2()
 {
     delete pCheckButtonData;
+    delete m_pCheckLB;
 }
 
 SfxTabPage* OfaMSFilterTabPage2::Create( Window* pParent,
@@ -225,8 +226,8 @@ void OfaMSFilterTabPage2::Reset( const SfxItemSet& )
 {
     SvtFilterOptions& rOpt = SvtFilterOptions::Get();
 
-    aCheckLB.SetUpdateMode(sal_False);
-    aCheckLB.Clear();
+    m_pCheckLB->SetUpdateMode(sal_False);
+    m_pCheckLB->Clear();
 
     SvtModuleOptions aModuleOpt;
 
@@ -270,11 +271,11 @@ void OfaMSFilterTabPage2::Reset( const SfxItemSet& )
                     pItem->SetStateChecked();
                 else
                     pItem->SetStateUnchecked();
-                aCheckLB.InvalidateEntry( pEntry );
+                m_pCheckLB->InvalidateEntry( pEntry );
             }
         }
     }
-    aCheckLB.SetUpdateMode( sal_True );
+    m_pCheckLB->SetUpdateMode( sal_True );
 }
 
 void OfaMSFilterTabPage2::InsertEntry( const OUString& _rTxt, sal_IntPtr _nType )
@@ -282,7 +283,7 @@ void OfaMSFilterTabPage2::InsertEntry( const OUString& _rTxt, sal_IntPtr _nType
     SvTreeListEntry* pEntry = new SvTreeListEntry;
 
     if( !pCheckButtonData )
-        pCheckButtonData = new SvLBoxButtonData( &aCheckLB );
+        pCheckButtonData = new SvLBoxButtonData( m_pCheckLB );
 
     pEntry->AddItem( new SvLBoxContextBmp( pEntry, 0, Image(), Image(), 0));
     pEntry->AddItem( new SvLBoxButton( pEntry, SvLBoxButtonKind_enabledCheckbox,
@@ -292,17 +293,17 @@ void OfaMSFilterTabPage2::InsertEntry( const OUString& _rTxt, sal_IntPtr _nType
     pEntry->AddItem( new SvLBoxString( pEntry, 0, _rTxt ) );
 
     pEntry->SetUserData( (void*)_nType );
-    aCheckLB.Insert( pEntry );
+    m_pCheckLB->Insert( pEntry );
 }
 
 SvTreeListEntry* OfaMSFilterTabPage2::GetEntry4Type( sal_IntPtr _nType ) const
 {
-    SvTreeListEntry* pEntry = aCheckLB.First();
+    SvTreeListEntry* pEntry = m_pCheckLB->First();
     while ( pEntry )
     {
         if ( _nType == sal_IntPtr( pEntry->GetUserData() ) )
             return pEntry;
-        pEntry = aCheckLB.Next( pEntry );
+        pEntry = m_pCheckLB->Next( pEntry );
     }
     return NULL;
 }
diff --git a/cui/source/options/optfltr.hrc b/cui/source/options/optfltr.hrc
deleted file mode 100644
index f1bf33a..0000000
--- a/cui/source/options/optfltr.hrc
+++ /dev/null
@@ -1,36 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-#ifndef _SVX_OPTFLTR_HRC
-#define _SVX_OPTFLTR_HRC
-
-// defines ------------------------------------------------------------------
-
-#define CLB_SETTINGS    1
-#define ST_CHG_MATH     1
-#define ST_CHG_WRITER   2
-#define ST_CHG_CALC     3
-#define ST_CHG_IMPRESS  4
-#define ST_HEADER1      5
-#define ST_HEADER2      6
-#define FT_HEADER1_EXPLANATION  1
-#define FT_HEADER2_EXPLANATION  2
-
-#endif
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/source/options/optfltr.hxx b/cui/source/options/optfltr.hxx
index 81a9650..9340ec3 100644
--- a/cui/source/options/optfltr.hxx
+++ b/cui/source/options/optfltr.hxx
@@ -73,9 +73,8 @@ class OfaMSFilterTabPage2 : public SfxTabPage
         }
     };
 
-    SvSimpleTableContainer m_aCheckLBContainer;
-    MSFltrSimpleTable aCheckLB;
-    FixedText aHeader1FT, aHeader2FT;
+    SvSimpleTableContainer* m_pCheckLBContainer;
+    MSFltrSimpleTable* m_pCheckLB;
     String sHeader1, sHeader2;
     String sChgToFromMath,
            sChgToFromWriter,
diff --git a/cui/source/options/optfltr.src b/cui/source/options/optfltr.src
index f1d3ae3..628b26d 100644
--- a/cui/source/options/optfltr.src
+++ b/cui/source/options/optfltr.src
@@ -17,63 +17,31 @@
  *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
  */
 
-#include "optfltr.hrc"
 #include <cuires.hrc>
 
-// RID_OFAPAGE_MSFILTEROPT2 -----------------------------------------------------
-TabPage RID_OFAPAGE_MSFILTEROPT2
+String RID_SVXSTR_HEADER1
 {
-    HelpID = "cui:TabPage:RID_OFAPAGE_MSFILTEROPT2";
-    OutputSize = TRUE ;
-    Size = MAP_APPFONT ( TP_WIDTH , TP_HEIGHT ) ;
-    SVLook = TRUE ;
-    Hide = TRUE ;
-
-    Control CLB_SETTINGS
-    {
-        Pos = MAP_APPFONT ( 6 , 6 ) ;
-        Size = MAP_APPFONT ( 248 , 147 ) ;
-        Border = TRUE ;
-        TabStop = TRUE ;
-    };
-    String ST_HEADER1
-    {
-        Text [ en-US ] = "[L]";
-    };
-    String ST_HEADER2
-    {
-        Text [ en-US ] = "[S]";
-    };
-    FixedText FT_HEADER1_EXPLANATION
-    {
-        Pos = MAP_APPFONT ( 6 , 160 ) ;
-        Size = MAP_APPFONT ( 248 , 8 ) ;
-        Text [ en-US ] = "[L]: Load and convert the object";
-    };
-    FixedText FT_HEADER2_EXPLANATION
-    {
-        Pos = MAP_APPFONT ( 6 , 171 ) ;
-        Size = MAP_APPFONT ( 248 , 8 ) ;
-        Text [ en-US ] = "[S]: Convert and save the object";
-    };
-    String ST_CHG_MATH
-    {
-        Text [ en-US ] = "MathType to %PRODUCTNAME Math or reverse";
-    };
-    String ST_CHG_WRITER
-    {
-        Text [ en-US ] = "WinWord to %PRODUCTNAME Writer or reverse";
-    };
-    String ST_CHG_CALC
-    {
-        Text [ en-US ] = "Excel to %PRODUCTNAME Calc or reverse";
-    };
-    String ST_CHG_IMPRESS
-    {
-        Text [ en-US ] = "PowerPoint to %PRODUCTNAME Impress or reverse";
-    };
+    Text [ en-US ] = "[L]";
+};
+String RID_SVXSTR_HEADER2
+{
+    Text [ en-US ] = "[S]";
+};
+String RID_SVXSTR_CHG_MATH
+{
+    Text [ en-US ] = "MathType to %PRODUCTNAME Math or reverse";
+};
+String RID_SVXSTR_CHG_WRITER
+{
+    Text [ en-US ] = "WinWord to %PRODUCTNAME Writer or reverse";
+};
+String RID_SVXSTR_CHG_CALC
+{
+    Text [ en-US ] = "Excel to %PRODUCTNAME Calc or reverse";
+};
+String RID_SVXSTR_CHG_IMPRESS
+{
+    Text [ en-US ] = "PowerPoint to %PRODUCTNAME Impress or reverse";
 };
-
- // ******************************************************************* EOF
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/uiconfig/ui/optfltrembedpage.ui b/cui/uiconfig/ui/optfltrembedpage.ui
new file mode 100644
index 0000000..07ddc5c
--- /dev/null
+++ b/cui/uiconfig/ui/optfltrembedpage.ui
@@ -0,0 +1,94 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+  <!-- interface-requires gtk+ 3.0 -->
+  <!-- interface-requires LibreOffice 1.0 -->
+  <object class="GtkGrid" id="OptFilterPage">
+    <property name="visible">True</property>
+    <property name="can_focus">False</property>
+    <property name="border_width">6</property>
+    <property name="row_spacing">12</property>
+    <child>
+      <object class="GtkFrame" id="frame1">
+        <property name="visible">True</property>
+        <property name="can_focus">False</property>
+        <property name="hexpand">True</property>
+        <property name="label_xalign">0</property>
+        <property name="shadow_type">none</property>
+        <child>
+          <object class="GtkAlignment" id="alignment1">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="margin_top">6</property>
+            <property name="hexpand">True</property>
+            <property name="top_padding">6</property>
+            <property name="left_padding">12</property>
+            <child>
+              <object class="GtkBox" id="box1">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="orientation">vertical</property>
+                <property name="spacing">12</property>
+                <child>
+                  <object class="svtlo-SvSimpleTableContainer" id="checklbcontainer">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <child internal-child="selection">
+                      <object class="GtkTreeSelection" id="Simple Table Container-selection1"/>
+                    </child>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">0</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkLabel" id="label2">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="xalign">0</property>
+                    <property name="label" translatable="yes">[L]: Load and convert the object</property>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">1</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkLabel" id="label3">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="xalign">0</property>
+                    <property name="label" translatable="yes">[S]: Convert and save the object</property>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">2</property>
+                  </packing>
+                </child>
+              </object>
+            </child>
+          </object>
+        </child>
+        <child type="label">
+          <object class="GtkLabel" id="label1">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Embedded objects</property>
+            <attributes>
+              <attribute name="weight" value="bold"/>
+            </attributes>
+          </object>
+        </child>
+      </object>
+      <packing>
+        <property name="left_attach">0</property>
+        <property name="top_attach">0</property>
+        <property name="width">1</property>
+        <property name="height">1</property>
+      </packing>
+    </child>
+  </object>
+</interface>


More information about the Libreoffice-commits mailing list