merge the formfield patch from ooo-build
[ooovba.git] / dbaccess / source / ui / inc / queryorder.hxx
blob799e10fc5e8a6cc97562555a45cd2fc3e2b68edf
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: queryorder.hxx,v $
10 * $Revision: 1.10 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
30 #ifndef DBAUI_QUERYORDER_HXX
31 #define DBAUI_QUERYORDER_HXX
33 #ifndef _DIALOG_HXX //autogen
34 #include <vcl/dialog.hxx>
35 #endif
37 #ifndef _LSTBOX_HXX //autogen
38 #include <vcl/lstbox.hxx>
39 #endif
41 #ifndef _EDIT_HXX //autogen
42 #include <vcl/edit.hxx>
43 #endif
45 #ifndef _FIXED_HXX //autogen
46 #include <vcl/fixed.hxx>
47 #endif
49 #ifndef _BUTTON_HXX //autogen
50 #include <vcl/button.hxx>
51 #endif
53 #define DOG_ROWS 3
55 namespace rtl
57 class OUString;
59 namespace com
61 namespace sun
63 namespace star
65 namespace sdb
67 class XSingleSelectQueryComposer;
69 namespace sdbc
71 class XConnection;
73 namespace container
75 class XNameAccess;
77 namespace beans
79 struct PropertyValue;
80 class XPropertySet;
86 //==================================================================
87 // DlgOrderCrit
88 //==================================================================
89 namespace dbaui
91 class DlgOrderCrit : public ModalDialog
93 protected:
94 ListBox aLB_ORDERFIELD1;
95 ListBox aLB_ORDERVALUE1;
96 ListBox aLB_ORDERFIELD2;
97 ListBox aLB_ORDERVALUE2;
98 ListBox aLB_ORDERFIELD3;
99 ListBox aLB_ORDERVALUE3;
100 FixedText aFT_ORDERFIELD;
101 FixedText aFT_ORDERAFTER1;
102 FixedText aFT_ORDERAFTER2;
103 FixedText aFT_ORDEROPER;
104 FixedText aFT_ORDERDIR;
105 OKButton aBT_OK;
106 CancelButton aBT_CANCEL;
107 HelpButton aBT_HELP;
108 FixedLine aFL_ORDER;
109 String aSTR_NOENTRY;
110 ::rtl::OUString m_sOrgOrder;
112 ::com::sun::star::uno::Reference< ::com::sun::star::sdb::XSingleSelectQueryComposer> m_xQueryComposer;
113 ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess> m_xColumns;
114 ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XConnection> m_xConnection;
117 ListBox* m_aColumnList[DOG_ROWS];
118 ListBox* m_aValueList[DOG_ROWS];
120 DECL_LINK( FieldListSelectHdl, ListBox * );
121 void EnableLines();
123 public:
124 DlgOrderCrit( Window * pParent,
125 const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XConnection>& _rxConnection,
126 const ::com::sun::star::uno::Reference< ::com::sun::star::sdb::XSingleSelectQueryComposer>& _rxComposer,
127 const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess>& _rxCols);
129 ~DlgOrderCrit();
130 void BuildOrderPart();
132 ::rtl::OUString GetOrderList( ) const;
133 ::rtl::OUString GetOrignalOrder() const { return m_sOrgOrder; }
135 private:
136 void impl_initializeOrderList_nothrow();
139 #endif // DBAUI_QUERYORDER_HXX