summaryrefslogtreecommitdiff
path: root/dbaccess
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2014-01-21 09:33:35 +0000
committerCaolán McNamara <caolanm@redhat.com>2014-01-21 12:04:29 +0000
commit9eebbbcbf7a022e252c5f34f091f3e4b398271cc (patch)
tree4e27d83cffdb5947d034b30b6efeb4d2820c5f63 /dbaccess
parent3007e015310c4a46e1249f69aa26e53dad9aafe2 (diff)
convert OTableSubscriptionDialog to SfxSingleTabDialog
Change-Id: I8335012139ccaf58bc18d0779e63a5bc388c9fb4
Diffstat (limited to 'dbaccess')
-rw-r--r--dbaccess/UIConfig_dbaccess.mk1
-rw-r--r--dbaccess/source/ui/dlg/TablesSingleDlg.cxx15
-rw-r--r--dbaccess/source/ui/inc/TablesSingleDlg.hxx2
-rw-r--r--dbaccess/source/ui/inc/dbu_resource.hrc1
-rw-r--r--dbaccess/uiconfig/ui/tablesfilterdialog.ui82
5 files changed, 92 insertions, 9 deletions
diff --git a/dbaccess/UIConfig_dbaccess.mk b/dbaccess/UIConfig_dbaccess.mk
index 702b9a20d83c..7148268fa755 100644
--- a/dbaccess/UIConfig_dbaccess.mk
+++ b/dbaccess/UIConfig_dbaccess.mk
@@ -19,6 +19,7 @@ $(eval $(call gb_UIConfig_add_uifiles,dbaccess, \
dbaccess/uiconfig/ui/querypropertiesdialog \
dbaccess/uiconfig/ui/rowheightdialog \
dbaccess/uiconfig/ui/sortdialog \
+ dbaccess/uiconfig/ui/tablesfilterdialog \
))
# vim: set noet sw=4 ts=4:
diff --git a/dbaccess/source/ui/dlg/TablesSingleDlg.cxx b/dbaccess/source/ui/dlg/TablesSingleDlg.cxx
index f470a5473aa1..f19080e9536e 100644
--- a/dbaccess/source/ui/dlg/TablesSingleDlg.cxx
+++ b/dbaccess/source/ui/dlg/TablesSingleDlg.cxx
@@ -42,10 +42,11 @@ OTableSubscriptionDialog::OTableSubscriptionDialog(Window* pParent
,SfxItemSet* _pItems
,const Reference< XComponentContext >& _rxORB
,const ::com::sun::star::uno::Any& _aDataSourceName)
- :SfxNoLayoutSingleTabDialog(pParent,DLG_TABLE_FILTER,_pItems)
- ,m_pImpl( new ODbDataSourceAdministrationHelper( _rxORB, pParent, this ) )
- ,m_bStopExecution(sal_False)
- ,m_pOutSet(_pItems)
+ : SfxSingleTabDialog(pParent, _pItems, "TablesFilterDialog",
+ "dbaccess/ui/tablesfilterdialog.ui")
+ , m_pImpl( new ODbDataSourceAdministrationHelper( _rxORB, pParent, this ) )
+ , m_bStopExecution(sal_False)
+ , m_pOutSet(_pItems)
{
DBG_CTOR(OTableSubscriptionDialog,NULL);
m_pImpl->setDataSourceOrName(_aDataSourceName);
@@ -55,9 +56,9 @@ OTableSubscriptionDialog::OTableSubscriptionDialog(Window* pParent
m_pImpl->translateProperties(xDatasource, *m_pOutSet);
SetInputSet(m_pOutSet);
- OTableSubscriptionPage* pTabPage = new OTableSubscriptionPage(this,*m_pOutSet,this);
+ OTableSubscriptionPage* pTabPage = new OTableSubscriptionPage(get_content_area(), *m_pOutSet, this);
pTabPage->SetServiceFactory(_rxORB);
- SetTabPage(pTabPage);
+ setTabPage(pTabPage);
}
OTableSubscriptionDialog::~OTableSubscriptionDialog()
@@ -71,7 +72,7 @@ short OTableSubscriptionDialog::Execute()
short nRet = RET_CANCEL;
if ( !m_bStopExecution )
{
- nRet = SfxNoLayoutSingleTabDialog::Execute();
+ nRet = SfxSingleTabDialog::Execute();
if ( nRet == RET_OK )
{
m_pOutSet->Put(*GetOutputItemSet());
diff --git a/dbaccess/source/ui/inc/TablesSingleDlg.hxx b/dbaccess/source/ui/inc/TablesSingleDlg.hxx
index 14c4ec6348bc..ba118439a29b 100644
--- a/dbaccess/source/ui/inc/TablesSingleDlg.hxx
+++ b/dbaccess/source/ui/inc/TablesSingleDlg.hxx
@@ -40,7 +40,7 @@ namespace dbaui
{
class ODbDataSourceAdministrationHelper;
// OTableSubscriptionDialog
- class OTableSubscriptionDialog : public SfxNoLayoutSingleTabDialog, public IItemSetHelper
+ class OTableSubscriptionDialog : public SfxSingleTabDialog, public IItemSetHelper
{
::std::auto_ptr<ODbDataSourceAdministrationHelper> m_pImpl;
sal_Bool m_bStopExecution; // set when the dialog should not be executed
diff --git a/dbaccess/source/ui/inc/dbu_resource.hrc b/dbaccess/source/ui/inc/dbu_resource.hrc
index 2905821f7dba..bbe093ec6b46 100644
--- a/dbaccess/source/ui/inc/dbu_resource.hrc
+++ b/dbaccess/source/ui/inc/dbu_resource.hrc
@@ -98,7 +98,6 @@
#define DLG_DATABASE_TYPE_CHANGE RID_DIALOG_START + 28
#define DLG_DATABASE_WIZARD RID_DIALOG_START + 29
#define DLG_TEXT_CONNECTION_SETTINGS RID_DIALOG_START + 31
-#define DLG_TABLE_FILTER RID_DIALOG_START + 32
//========================================================================
// tab pages
diff --git a/dbaccess/uiconfig/ui/tablesfilterdialog.ui b/dbaccess/uiconfig/ui/tablesfilterdialog.ui
new file mode 100644
index 000000000000..b311189c7ab8
--- /dev/null
+++ b/dbaccess/uiconfig/ui/tablesfilterdialog.ui
@@ -0,0 +1,82 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Generated with glade 3.16.0 on Tue Jan 21 09:32:06 2014 -->
+<interface>
+ <!-- interface-requires gtk+ 3.0 -->
+ <object class="GtkDialog" id="TablesFilterDialog">
+ <property name="can_focus">False</property>
+ <property name="border_width">6</property>
+ <property name="title" translatable="yes">Tables Filter</property>
+ <property name="type_hint">dialog</property>
+ <child internal-child="vbox">
+ <object class="GtkBox" id="dialog-vbox1">
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">12</property>
+ <child internal-child="action_area">
+ <object class="GtkButtonBox" id="dialog-action_area1">
+ <property name="can_focus">False</property>
+ <property name="layout_style">end</property>
+ <child>
+ <object class="GtkButton" id="ok">
+ <property name="label">gtk-ok</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="has_default">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">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="cancel">
+ <property name="label">gtk-cancel</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">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="help">
+ <property name="label">gtk-help</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">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="pack_type">end</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ </child>
+ <action-widgets>
+ <action-widget response="0">ok</action-widget>
+ <action-widget response="0">cancel</action-widget>
+ <action-widget response="0">help</action-widget>
+ </action-widgets>
+ </object>
+</interface>