1 /*************************************************************************
2  *
3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4  *
5  * Copyright 2000, 2010 Oracle and/or its affiliates.
6  *
7  * OpenOffice.org - a multi-platform office productivity suite
8  *
9  * This file is part of OpenOffice.org.
10  *
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.
14  *
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).
20  *
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.
25  *
26  ************************************************************************/
27 
28 #ifndef _SALGTKFOLDERPICKER_HXX_
29 #define _SALGTKFOLDERPICKER_HXX_
30 
31 //_______________________________________________________________________________________________________________________
32 //	includes of other projects
33 //_______________________________________________________________________________________________________________________
34 
35 #ifndef _CPPUHELPER_COMPBASE3_HXX_
36 #include <cppuhelper/implbase3.hxx>
37 #endif
38 
39 #ifndef _SALGTKPICKER_HXX_
40 #include "SalGtkPicker.hxx"
41 #endif
42 
43 #include <memory>
44 
45 #ifndef _RTL_USTRING_H_
46 #include <rtl/ustring.hxx>
47 #endif
48 
49 #include <list>
50 
51 //----------------------------------------------------------
52 // class declaration
53 //----------------------------------------------------------
54 
55 class SalGtkFolderPicker :
56         public SalGtkPicker,
57 	public cppu::WeakImplHelper3<
58 	::com::sun::star::ui::dialogs::XFolderPicker,
59 	::com::sun::star::lang::XServiceInfo,
60         ::com::sun::star::util::XCancellable >
61 {
62 	public:
63 
64 		// constructor
65 		SalGtkFolderPicker( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& xServiceMgr );
66 
67 		//------------------------------------------------------------------------------------
68 		// XExecutableDialog functions
69 		//------------------------------------------------------------------------------------
70 
71 		virtual void SAL_CALL setTitle( const ::rtl::OUString& aTitle )
72 			throw( ::com::sun::star::uno::RuntimeException );
73 
74 		virtual sal_Int16 SAL_CALL execute(  )
75 			throw( ::com::sun::star::uno::RuntimeException );
76 
77 		//------------------------------------------------------------------------------------
78 		// XFolderPicker functions
79 		//------------------------------------------------------------------------------------
80 
81 		virtual void SAL_CALL setDisplayDirectory( const rtl::OUString& rDirectory )
82 			throw( com::sun::star::lang::IllegalArgumentException, com::sun::star::uno::RuntimeException );
83 
84 		virtual rtl::OUString SAL_CALL getDisplayDirectory(  )
85 			throw( com::sun::star::uno::RuntimeException );
86 
87 		virtual rtl::OUString SAL_CALL getDirectory( )
88 			throw( com::sun::star::uno::RuntimeException );
89 
90 		virtual void SAL_CALL setDescription( const rtl::OUString& rDescription )
91 			throw( com::sun::star::uno::RuntimeException );
92 
93 
94 		//------------------------------------------------
95 		// XServiceInfo
96 		//------------------------------------------------
97 
98 		virtual ::rtl::OUString SAL_CALL getImplementationName(	 )
99 			throw(::com::sun::star::uno::RuntimeException);
100 
101 		virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName )
102 			throw(::com::sun::star::uno::RuntimeException);
103 
104 		virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames(  )
105 			throw(::com::sun::star::uno::RuntimeException);
106 
107 		//------------------------------------------------
108 		// XCancellable
109 		//------------------------------------------------
110 
111 		virtual void SAL_CALL cancel( )
112 			throw( ::com::sun::star::uno::RuntimeException );
113 
114 		//------------------------------------------------
115 		// XEventListener
116 		//------------------------------------------------
117 
118 		virtual void SAL_CALL disposing( const ::com::sun::star::lang::EventObject& aEvent )
119 			throw(::com::sun::star::uno::RuntimeException);
120 
121 	private:
122 		// prevent copy and assignment
123 		SalGtkFolderPicker( const SalGtkFolderPicker& );
124 		SalGtkFolderPicker& operator=( const SalGtkFolderPicker& );
125 	private:
126 		// to instanciate own services
127 		::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > m_xServiceMgr;
128 
129 #if 0
130 	public:
131 		 virtual ~SalGtkFolderPicker();
132 #endif
133 };
134 
135 #endif // _SALGTKFOLDERPICKER_HXX_
136