Version 3.6.0.2, tag libreoffice-3.6.0.2
[LibreOffice.git] / dbaccess / source / ui / uno / composerdialogs.hxx
blobacc82ae93cf2672c5cd6629312f855305eb0278a
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*************************************************************************
4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
6 * Copyright 2000, 2010 Oracle and/or its affiliates.
8 * OpenOffice.org - a multi-platform office productivity suite
10 * This file is part of OpenOffice.org.
12 * OpenOffice.org is free software: you can redistribute it and/or modify
13 * it under the terms of the GNU Lesser General Public License version 3
14 * only, as published by the Free Software Foundation.
16 * OpenOffice.org is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 * GNU Lesser General Public License version 3 for more details
20 * (a copy is included in the LICENSE file that accompanied this code).
22 * You should have received a copy of the GNU Lesser General Public License
23 * version 3 along with OpenOffice.org. If not, see
24 * <http://www.openoffice.org/license.html>
25 * for a copy of the LGPLv3 License.
27 ************************************************************************/
29 #ifndef DBACCESS_SOURCE_UI_UNO_COMPOSERDIALOGS_HXX
30 #define DBACCESS_SOURCE_UI_UNO_COMPOSERDIALOGS_HXX
32 /** === begin UNO includes === **/
33 #include <com/sun/star/container/XNameAccess.hpp>
34 #include <com/sun/star/sdbc/XConnection.hpp>
35 #include <com/sun/star/sdb/XSingleSelectQueryComposer.hpp>
36 #include <com/sun/star/beans/XPropertySet.hpp>
37 #include <com/sun/star/sdbc/XRowSet.hpp>
38 /** === end UNO includes === **/
40 #include <svtools/genericunodialog.hxx>
41 #include "moduledbu.hxx"
42 #include "apitools.hxx"
44 //.........................................................................
45 namespace dbaui
47 //.........................................................................
49 //=====================================================================
50 //= ComposerDialog
51 //=====================================================================
52 class ComposerDialog;
53 typedef ::svt::OGenericUnoDialog ComposerDialog_BASE;
54 typedef ::comphelper::OPropertyArrayUsageHelper< ComposerDialog > ComposerDialog_PBASE;
56 class ComposerDialog
57 :public ComposerDialog_BASE
58 ,public ComposerDialog_PBASE
60 OModuleClient m_aModuleClient;
61 protected:
62 // <properties>
63 ::com::sun::star::uno::Reference< ::com::sun::star::sdb::XSingleSelectQueryComposer >
64 m_xComposer;
65 ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XRowSet >
66 m_xRowSet;
67 // </properties>
69 protected:
70 ComposerDialog(const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& _rxORB);
71 ~ComposerDialog();
73 public:
74 DECLARE_IMPLEMENTATION_ID( );
76 DECLARE_PROPERTYCONTAINER_DEFAULTS( );
78 protected:
79 // own overridables
80 virtual Dialog* createComposerDialog(
81 Window* _pParent,
82 const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XConnection >& _rxConnection,
83 const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess >& _rxColumns
84 ) = 0;
86 private:
87 // OGenericUnoDialog overridables
88 virtual Dialog* createDialog(Window* _pParent);
91 //=====================================================================
92 //= RowsetFilterDialog
93 //=====================================================================
94 class RowsetFilterDialog : public ComposerDialog
96 public:
97 RowsetFilterDialog(
98 const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& _rxORB
101 DECLARE_SERVICE_INFO_STATIC( );
103 protected:
104 // own overridables
105 virtual Dialog* createComposerDialog(
106 Window* _pParent,
107 const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XConnection >& _rxConnection,
108 const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess >& _rxColumns
111 // OGenericUnoDialog overridables
112 virtual void executedDialog( sal_Int16 _nExecutionResult );
115 //=====================================================================
116 //= RowsetOrderDialog
117 //=====================================================================
118 class RowsetOrderDialog : public ComposerDialog
120 public:
121 RowsetOrderDialog(
122 const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& _rxORB
125 DECLARE_SERVICE_INFO_STATIC( );
127 protected:
128 // own overridables
129 virtual Dialog* createComposerDialog(
130 Window* _pParent,
131 const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XConnection >& _rxConnection,
132 const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess >& _rxColumns
135 // OGenericUnoDialog overridables
136 virtual void executedDialog( sal_Int16 _nExecutionResult );
139 //.........................................................................
140 } // namespace dbaui
141 //.........................................................................
143 #endif // DBACCESS_SOURCE_UI_UNO_COMPOSERDIALOGS_HXX
146 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */