merged tag ooo/OOO330_m14
[LibreOffice.git] / extensions / source / propctrlr / listselectiondlg.hxx
blobc741f1e08945c56f8032adb6e5adda5613fac1e0
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2000, 2010 Oracle and/or its affiliates.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * This file is part of OpenOffice.org.
11 * OpenOffice.org is free software: you can redistribute it and/or modify
12 * it under the terms of the GNU Lesser General Public License version 3
13 * only, as published by the Free Software Foundation.
15 * OpenOffice.org is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU Lesser General Public License version 3 for more details
19 * (a copy is included in the LICENSE file that accompanied this code).
21 * You should have received a copy of the GNU Lesser General Public License
22 * version 3 along with OpenOffice.org. If not, see
23 * <http://www.openoffice.org/license.html>
24 * for a copy of the LGPLv3 License.
26 ************************************************************************/
28 #ifndef EXTENSIONS_SOURCE_PROPCTRLR_LISTSELECTIONDLG_HXX
29 #define EXTENSIONS_SOURCE_PROPCTRLR_LISTSELECTIONDLG_HXX
31 #include <vcl/dialog.hxx>
32 #include <vcl/fixed.hxx>
33 #ifndef _SV_BUTTON_HXX
34 #include <vcl/button.hxx>
35 #endif
36 #include <vcl/lstbox.hxx>
38 /** === begin UNO includes === **/
39 #include <com/sun/star/beans/XPropertySet.hpp>
40 /** === end UNO includes === **/
42 //........................................................................
43 namespace pcr
45 //........................................................................
47 //====================================================================
48 //= ListSelectionDialog
49 //====================================================================
50 class ListSelectionDialog : public ModalDialog
52 private:
53 FixedText m_aLabel;
54 ListBox m_aEntries;
55 OKButton m_aOK;
56 CancelButton m_aCancel;
57 HelpButton m_aHelp;
59 ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >
60 m_xListBox;
61 ::rtl::OUString m_sPropertyName;
63 public:
64 ListSelectionDialog(
65 Window* _pParent,
66 const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >& _rxListBox,
67 const ::rtl::OUString& _rPropertyName,
68 const String& _rPropertyUIName
71 // Dialog overridables
72 virtual short Execute();
74 private:
75 void initialize( );
76 void commitSelection();
78 void fillEntryList ( const ::com::sun::star::uno::Sequence< ::rtl::OUString >& _rListEntries );
80 void selectEntries ( const ::com::sun::star::uno::Sequence< sal_Int16 >& /* [in ] */ _rSelection );
81 void collectSelection( ::com::sun::star::uno::Sequence< sal_Int16 >& /* [out] */ _rSelection );
84 //........................................................................
85 } // namespacepcr
86 //........................................................................
88 #endif // EXTENSIONS_SOURCE_PROPCTRLR_LISTSELECTIONDLG_HXX