xref: /trunk/main/cui/source/factory/dlgfact.hxx (revision cdf0e10c)
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 #ifndef _CUI_DLGFACT_HXX
28 #define _CUI_DLGFACT_HXX
29 
30 // include ---------------------------------------------------------------
31 #include <svx/svxdlg.hxx>
32 #include <com/sun/star/container/XNameReplace.hpp>
33 
34 #include "tools/link.hxx"
35 #include <com/sun/star/frame/XFrame.hpp>
36 
37 class SfxTabDialog;
38 class SfxModalDialog;
39 class Dialog;
40 class SfxItemPool;
41 class FmShowColsDialog;
42 class SvxZoomDialog;
43 class FmInputRecordNoDialog;
44 class SvxJSearchOptionsDialog;
45 class FmFormShell;
46 class SvxNewDictionaryDialog;
47 class SvxNameDialog;
48 
49 // #i68101#
50 class SvxObjectNameDialog;
51 class SvxObjectTitleDescDialog;
52 
53 class SvxMessDialog;
54 class SvxMultiPathDialog;
55 class SvxMultiFileDialog;
56 class SvxHpLinkDlg;
57 class FmSearchDialog;
58 class Graphic;
59 class GraphicFilterDialog;
60 class SvxAreaTabDialog;
61 class InsertObjectDialog_Impl;
62 class SvPasteObjectDialog;
63 class SvBaseLinksDlg;
64 class SvxTransformTabDialog;
65 class SvxCaptionTabDialog;
66 class SvxThesaurusDialog;
67 class SvxHyphenWordDialog;
68 
69 namespace svx{
70 class HangulHanjaConversionDialog;
71 }
72 using namespace svx;
73 
74 #define DECL_ABSTDLG_BASE(Class,DialogClass)		\
75 	DialogClass* 		pDlg;                   	\
76 public:												\
77 					Class( DialogClass* p)			\
78 					 : pDlg(p)						\
79 					 {}                             \
80 	virtual			~Class();               		\
81 	virtual	short	Execute() ;
82 //	virtual void	Show( sal_Bool bVisible = sal_True, sal_uInt16 nFlags = 0 )
83 
84 #define IMPL_ABSTDLG_BASE(Class)					\
85 Class::~Class()                    					\
86 {                                                   \
87 	delete pDlg;                                 	\
88 }													\
89 short Class::Execute()                             \
90 {                                                   \
91 	return pDlg->Execute();                      	\
92 }
93 
94 //for GalleryThemeProperties begin
95 class VclAbstractDialog2_Impl : public VclAbstractDialog2
96 {
97     Dialog*         m_pDlg;
98     Link            m_aEndDlgHdl;
99 public:
100                     VclAbstractDialog2_Impl( Dialog* p ) : m_pDlg( p ) {}                             \
101     virtual         ~VclAbstractDialog2_Impl();
102     virtual void    StartExecuteModal( const Link& rEndDialogHdl );
103     virtual long    GetResult();
104 private:
105                     DECL_LINK( EndDialogHdl, Dialog* );
106 };
107 //for GalleryThemeProperties end
108 
109 class VclAbstractDialog_Impl : public VclAbstractDialog
110 {
111 	DECL_ABSTDLG_BASE(VclAbstractDialog_Impl,Dialog)
112 };
113 
114 //for ActualizeProgress begin
115 class VclAbstractRefreshableDialog_Impl : public VclAbstractRefreshableDialog
116 {
117 	DECL_ABSTDLG_BASE(VclAbstractRefreshableDialog_Impl,Dialog)
118 	virtual void        Update() ;
119 	virtual void        Sync() ;
120 };
121 //for ActualizeProgress end
122 
123 class AbstractSfxDialog_Impl : public SfxAbstractDialog
124 {
125 	DECL_ABSTDLG_BASE(AbstractSfxDialog_Impl,SfxModalDialog)
126 	virtual const SfxItemSet* 	GetOutputItemSet() const;
127 
128 		//From class Window.
129     virtual void		SetText( const XubString& rStr );
130     virtual String   	GetText() const ;
131 };
132 
133 class AbstractTabDialog_Impl : public SfxAbstractTabDialog
134 {
135 	DECL_ABSTDLG_BASE(AbstractTabDialog_Impl,SfxTabDialog)
136 	virtual void				SetCurPageId( sal_uInt16 nId );
137 	virtual const SfxItemSet* 	GetOutputItemSet() const;
138 	virtual const sal_uInt16*		GetInputRanges( const SfxItemPool& pItem );	//add by CHINA001
139 	virtual void				SetInputSet( const SfxItemSet* pInSet );   //add by CHINA001
140 		//From class Window.
141     virtual void		SetText( const XubString& rStr ); //add by CHINA001
142     virtual String   	GetText() const; //add by CHINA001
143 };
144 
145 //for SvxDistributeDialog begin
146 class SvxDistributeDialog;
147 class AbstractSvxDistributeDialog_Impl: public AbstractSvxDistributeDialog
148 {
149 	DECL_ABSTDLG_BASE(AbstractSvxDistributeDialog_Impl,SvxDistributeDialog)
150 public:
151 	virtual SvxDistributeHorizontal GetDistributeHor() const;
152 	virtual SvxDistributeVertical GetDistributeVer() const;
153 };
154 //for SvxDistributeDialog end
155 
156 // for HangulHanjaConversionDialog begin
157 class AbstractHangulHanjaConversionDialog_Impl: public AbstractHangulHanjaConversionDialog
158 {
159 	DECL_ABSTDLG_BASE(AbstractHangulHanjaConversionDialog_Impl,HangulHanjaConversionDialog)
160 	virtual void	EndDialog(long nResult = 0);
161     virtual void    EnableRubySupport( sal_Bool _bVal );
162 	virtual void 	SetByCharacter( sal_Bool _bByCharacter ) ;
163 	virtual void	SetConversionDirectionState( sal_Bool _bTryBothDirections, editeng::HangulHanjaConversion::ConversionDirection _ePrimaryConversionDirection );
164 	virtual void 	SetConversionFormat( editeng::HangulHanjaConversion::ConversionFormat _eType );
165     virtual void	SetOptionsChangedHdl( const Link& _rHdl );
166 	virtual void	SetIgnoreHdl( const Link& _rHdl );
167 	virtual void	SetIgnoreAllHdl( const Link& _rHdl ) ;
168 	virtual void	SetChangeHdl( const Link& _rHdl ) ;
169 	virtual void	SetChangeAllHdl( const Link& _rHdl ) ;
170     virtual void	SetClickByCharacterHdl( const Link& _rHdl ) ;
171 	virtual void	SetConversionFormatChangedHdl( const Link& _rHdl ) ;
172 	virtual void	SetFindHdl( const Link& _rHdl );
173 	virtual sal_Bool		GetUseBothDirections( ) const;
174     virtual editeng::HangulHanjaConversion::ConversionDirection    GetDirection( editeng::HangulHanjaConversion::ConversionDirection _eDefaultDirection ) const;
175 	virtual void	SetCurrentString(
176 					const String& _rNewString,
177 					const ::com::sun::star::uno::Sequence< ::rtl::OUString >& _rSuggestions,
178 					bool _bOriginatesFromDocument = true
179 				);
180 	virtual String	GetCurrentString( ) const ;
181 	virtual editeng::HangulHanjaConversion::ConversionFormat    GetConversionFormat( ) const ;
182 	virtual void	FocusSuggestion( );
183 	virtual String	GetCurrentSuggestion( ) const;
184 };
185 
186 class AbstractThesaurusDialog_Impl : public AbstractThesaurusDialog
187 {
188 	DECL_ABSTDLG_BASE(AbstractThesaurusDialog_Impl,SvxThesaurusDialog)
189     virtual String		GetWord();
190 	virtual sal_uInt16	GetLanguage() const;
191 	virtual Window*		GetWindow();
192 };
193 
194 
195 class AbstractHyphenWordDialog_Impl: public AbstractHyphenWordDialog
196 {
197 	DECL_ABSTDLG_BASE(AbstractHyphenWordDialog_Impl,SvxHyphenWordDialog)
198 	virtual void	SelLeft();
199 	virtual void	SelRight();
200 	virtual Window*	GetWindow();
201 };
202 
203 // for FmShowColsDialog begin
204 class FmShowColsDialog;
205 class AbstractFmShowColsDialog_Impl : public AbstractFmShowColsDialog
206 {
207 	DECL_ABSTDLG_BASE(AbstractFmShowColsDialog_Impl,FmShowColsDialog)
208  	virtual void 	SetColumns(const ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexContainer>& xCols);
209 };
210 //for FmShowColsDialog end
211 
212 
213 //for SvxZoomDialog begin
214 class SvxZoomDialog;
215 class AbstractSvxZoomDialog_Impl : public AbstractSvxZoomDialog
216 {
217 	DECL_ABSTDLG_BASE(AbstractSvxZoomDialog_Impl,SvxZoomDialog)
218 	virtual void	SetLimits( sal_uInt16 nMin, sal_uInt16 nMax );
219 	virtual void	HideButton( sal_uInt16 nBtnId );
220 	virtual const SfxItemSet*	GetOutputItemSet() const ;
221 
222 };
223 //for SvxZoomDialog end
224 
225 //for SvxSpellDialog begin
226 namespace svx{ class SpellDialog;}
227 class AbstractSpellDialog_Impl : public AbstractSpellDialog
228 {
229  public:
230     DECL_ABSTDLG_BASE(AbstractSpellDialog_Impl, svx::SpellDialog)
231     virtual void        SetLanguage( sal_uInt16 nLang );
232     virtual sal_Bool    Close();
233     virtual void        Invalidate();
234     virtual Window*     GetWindow();
235     virtual SfxBindings& GetBindings();
236 };
237 
238 //for SearchProgress begin
239 class SearchProgress;
240 class AbstractSearchProgress_Impl : public AbstractSearchProgress
241 {
242 	DECL_ABSTDLG_BASE(AbstractSearchProgress_Impl,SearchProgress)
243 	virtual void        Update() ;
244     virtual void        Sync() ;
245 	virtual void 	SetFileType( const String& rType ) ;
246 	virtual void 	SetDirectory( const INetURLObject& rURL ) ;
247 	virtual PLinkStub	GetLinkStubCleanUpHdl() ;
248 
249 };
250 //for SearchProgress end
251 
252 //for TakeProgress begin
253 class TakeProgress;
254 class AbstractTakeProgress_Impl : public AbstractTakeProgress
255 {
256 	DECL_ABSTDLG_BASE(AbstractTakeProgress_Impl,TakeProgress)
257 	virtual void        Update() ;
258     virtual void        Sync() ;
259 	virtual void 		SetFile( const INetURLObject& rURL ) ;
260 	virtual PLinkStub	GetLinkStubCleanUpHdl() ;
261 
262 };
263 //for TakeProgress end
264 
265 //for TitleDialog begin
266 class TitleDialog;
267 class AbstractTitleDialog_Impl : public AbstractTitleDialog
268 {
269 	DECL_ABSTDLG_BASE(AbstractTitleDialog_Impl,TitleDialog)
270 	virtual String	GetTitle() const ;
271 
272 };
273 //for TitleDialog end
274 
275 //for SvxScriptSelectorDialog begin
276 class SvxScriptSelectorDialog;
277 class AbstractScriptSelectorDialog_Impl : public AbstractScriptSelectorDialog
278 {
279 	DECL_ABSTDLG_BASE(
280 		AbstractScriptSelectorDialog_Impl, SvxScriptSelectorDialog)
281 
282 	virtual String GetScriptURL() const;
283 
284 	virtual void SetRunLabel();
285 };
286 
287 //for GalleryIdDialog begin
288 class GalleryIdDialog;
289 class AbstractGalleryIdDialog_Impl : public AbstractGalleryIdDialog
290 {
291 	DECL_ABSTDLG_BASE(AbstractGalleryIdDialog_Impl,GalleryIdDialog)
292 	virtual sal_uLong	GetId() const ;
293 
294 };
295 //for GalleryIdDialog end
296 
297 //for URLDlg start
298 class URLDlg;
299 class AbstractURLDlg_Impl :public AbstractURLDlg
300 {
301 	DECL_ABSTDLG_BASE(AbstractURLDlg_Impl,URLDlg)
302 	virtual String		GetURL() const;
303 	virtual String		GetAltText() const;
304 	virtual String		GetDesc() const;
305 	virtual String		GetTarget() const;
306 	virtual String		GetName() const;
307 };
308 //for URLDlg end
309 
310 //for SvxHlinkDlgMarkWnd begin
311 class SvxHlinkDlgMarkWnd;
312 class AbstractSvxHlinkDlgMarkWnd_Impl : public AbstractSvxHlinkDlgMarkWnd
313 {
314 	DECL_ABSTDLG_BASE(AbstractSvxHlinkDlgMarkWnd_Impl,SvxHlinkDlgMarkWnd)
315 	virtual void				Hide( sal_uInt16 nFlags = 0 );
316     virtual sal_Bool				IsVisible() const ;
317 	virtual void				Invalidate( sal_uInt16 nFlags = 0 );
318 	virtual void				SetSizePixel( const Size& rNewSize );
319     virtual Size				GetSizePixel() const;
320 	virtual sal_Bool				MoveTo ( Point aNewPos )const;
321 	virtual sal_Bool				ConnectToDialog( sal_Bool bDoit = sal_True )const;
322 	virtual void				RefreshTree ( String aStrURL ) ;
323 	virtual void				SelectEntry ( String aStrMark );
324 	virtual sal_uInt16				SetError( sal_uInt16 nError) ;
325 
326 };
327 //for SvxHlinkDlgMarkWnd end
328 
329 //for SvxSearchSimilarityDialog begin
330 class SvxSearchSimilarityDialog;
331 class AbstractSvxSearchSimilarityDialog_Impl :public AbstractSvxSearchSimilarityDialog
332 {
333 	DECL_ABSTDLG_BASE(AbstractSvxSearchSimilarityDialog_Impl,SvxSearchSimilarityDialog)
334 	virtual sal_uInt16				GetOther();
335 	virtual sal_uInt16				GetShorter();
336 	virtual sal_uInt16				GetLonger();
337 	virtual sal_Bool 				IsRelaxed();
338 };
339 //for SvxSearchSimilarityDialog end
340 
341 //for SvxJSearchOptionsDialog end
342 class SvxJSearchOptionsDialog;
343 class AbstractSvxJSearchOptionsDialog_Impl :public AbstractSvxJSearchOptionsDialog
344 {
345 	DECL_ABSTDLG_BASE(AbstractSvxJSearchOptionsDialog_Impl,SvxJSearchOptionsDialog)
346 	virtual sal_Int32			GetTransliterationFlags() const;
347 };
348 //for SvxJSearchOptionsDialog end
349 
350 class AbstractSvxTransformTabDialog_Impl : public AbstractSvxTransformTabDialog
351 {
352     DECL_ABSTDLG_BASE(AbstractSvxTransformTabDialog_Impl,SvxTransformTabDialog)
353     virtual void SetValidateFramePosLink( const Link& rLink );
354     virtual void                SetCurPageId( sal_uInt16 nId );
355     virtual const SfxItemSet*   GetOutputItemSet() const;
356     virtual const sal_uInt16*       GetInputRanges( const SfxItemPool& pItem );
357     virtual void                SetInputSet( const SfxItemSet* pInSet );
358     virtual void        SetText( const XubString& rStr );
359     virtual String      GetText() const;
360 };
361 class AbstractSvxCaptionDialog_Impl : public AbstractSvxCaptionDialog
362 {
363     DECL_ABSTDLG_BASE(AbstractSvxCaptionDialog_Impl,SvxCaptionTabDialog)
364     virtual void SetValidateFramePosLink( const Link& rLink );
365     virtual void                SetCurPageId( sal_uInt16 nId );
366     virtual const SfxItemSet*   GetOutputItemSet() const;
367     virtual const sal_uInt16*       GetInputRanges( const SfxItemPool& pItem );
368     virtual void                SetInputSet( const SfxItemSet* pInSet );
369     virtual void        SetText( const XubString& rStr );
370     virtual String      GetText() const;
371 };
372 
373 //for FmInputRecordNoDialog end
374 class FmInputRecordNoDialog;
375 class AbstractFmInputRecordNoDialog_Impl :public AbstractFmInputRecordNoDialog
376 {
377 	DECL_ABSTDLG_BASE(AbstractFmInputRecordNoDialog_Impl,FmInputRecordNoDialog)
378     virtual void SetValue(long nNew) ;
379 	virtual long GetValue() const ;
380 };
381 //for FmInputRecordNoDialog end
382 
383 //for SvxNewDictionaryDialog end
384 class SvxNewDictionaryDialog;
385 class AbstractSvxNewDictionaryDialog_Impl :public AbstractSvxNewDictionaryDialog
386 {
387 	DECL_ABSTDLG_BASE(AbstractSvxNewDictionaryDialog_Impl,SvxNewDictionaryDialog)
388     virtual ::com::sun::star::uno::Reference< ::com::sun::star::linguistic2::XDictionary >  GetNewDictionary();
389 };
390 //for SvxNewDictionaryDialog end
391 
392 //for SvxNameDialog end
393 class SvxNameDialog;
394 class AbstractSvxNameDialog_Impl :public AbstractSvxNameDialog
395 {
396 	DECL_ABSTDLG_BASE(AbstractSvxNameDialog_Impl,SvxNameDialog)
397 	virtual void    GetName( String& rName ) ;
398 	virtual void    SetCheckNameHdl( const Link& rLink, bool bCheckImmediately = false ) ;
399     virtual void    SetEditHelpId(const rtl::OString&) ;
400 	//from class Window
401 	virtual void    SetHelpId( const rtl::OString& ) ;
402 	virtual void    SetText( const XubString& rStr ) ;
403 private:
404 	Link aCheckNameHdl;
405 	DECL_LINK( CheckNameHdl, Window*);
406 };
407 //for SvxNameDialog end
408 
409 ///////////////////////////////////////////////////////////////////////////////////////////////
410 // #i68101#
411 
412 // predefines
413 class SvxObjectNameDialog;
414 class SvxObjectTitleDescDialog;
415 
416 class AbstractSvxObjectNameDialog_Impl :public AbstractSvxObjectNameDialog
417 {
418 	DECL_ABSTDLG_BASE(AbstractSvxObjectNameDialog_Impl, SvxObjectNameDialog)
419 	virtual void GetName(String& rName) ;
420 	virtual void SetCheckNameHdl(const Link& rLink, bool bCheckImmediately = false);
421 
422 private:
423 	Link aCheckNameHdl;
424 	DECL_LINK(CheckNameHdl, Window*);
425 };
426 
427 class AbstractSvxObjectTitleDescDialog_Impl :public AbstractSvxObjectTitleDescDialog
428 {
429 	DECL_ABSTDLG_BASE(AbstractSvxObjectTitleDescDialog_Impl, SvxObjectTitleDescDialog)
430 	virtual void GetTitle(String& rName);
431 	virtual void GetDescription(String& rName);
432 };
433 
434 ///////////////////////////////////////////////////////////////////////////////////////////////
435 
436 //for SvxMessDialog end
437 class SvxMessDialog;
438 class AbstractSvxMessDialog_Impl :public AbstractSvxMessDialog
439 {
440 	DECL_ABSTDLG_BASE(AbstractSvxMessDialog_Impl,SvxMessDialog)
441 	virtual void	SetButtonText( sal_uInt16 nBtnId, const String& rNewTxt );
442 };
443 //for SvxMessDialog end
444 
445 //for SvxMultiPathDialog end
446 class SvxMultiPathDialog;
447 class AbstractSvxMultiPathDialog_Impl :public AbstractSvxMultiPathDialog
448 {
449 	DECL_ABSTDLG_BASE(AbstractSvxMultiPathDialog_Impl,SvxMultiPathDialog)
450 	virtual String			GetPath() const;
451 	virtual void			SetPath( const String& rPath );
452     virtual void            EnableRadioButtonMode();
453     virtual void            SetTitle( const String& rNewTitle );
454 };
455 //for SvxMultiPathDialog end
456 
457 //for SvxMultiFileDialog begin
458 class SvxMultiFileDialog;
459 class AbstractSvxMultiFileDialog_Impl :public AbstractSvxMultiFileDialog
460 {
461 	DECL_ABSTDLG_BASE(AbstractSvxMultiFileDialog_Impl,SvxMultiFileDialog)
462 	virtual String			GetFiles() const ;
463 	virtual void			SetFiles( const String& rPath ) ;
464 	//from SvxMultiPathDialog
465 	virtual String			GetPath() const;
466 	virtual void			SetPath( const String& rPath );
467 	virtual void			SetClassPathMode();
468     virtual void            EnableRadioButtonMode();
469     virtual void            SetTitle( const String& rNewTitle );
470 	//From Class Window
471 	virtual void    SetHelpId( const rtl::OString& ) ;
472 
473 };
474 //for SvxMultiFileDialog end
475 
476 //for SvxHpLinkDlg begin
477 class SvxHpLinkDlg;
478 class AbstractSvxHpLinkDlg_Impl :public AbstractSvxHpLinkDlg
479 {
480     DECL_ABSTDLG_BASE(AbstractSvxHpLinkDlg_Impl,SvxHpLinkDlg)
481     virtual Window*     GetWindow();
482     virtual sal_Bool    QueryClose();
483 };
484 //for SvxHpLinkDlg end
485 
486 //for FmSearchDialog begin
487 class FmSearchDialog;
488 class AbstractFmSearchDialog_Impl :public AbstractFmSearchDialog
489 {
490 	DECL_ABSTDLG_BASE(AbstractFmSearchDialog_Impl,FmSearchDialog)
491 	virtual void SetFoundHandler(const Link& lnk) ;
492 	virtual void SetCanceledNotFoundHdl(const Link& lnk);
493 	virtual void SetActiveField(const String& strField);
494 };
495 //for FmSearchDialog end
496 
497 //for GraphicFilterDialog begin
498 class GraphicFilterDialog;
499 class AbstractGraphicFilterDialog_Impl :public AbstractGraphicFilterDialog
500 {
501 	DECL_ABSTDLG_BASE(AbstractGraphicFilterDialog_Impl,GraphicFilterDialog)
502 	virtual Graphic	GetFilteredGraphic( const Graphic& rGraphic, double fScaleX, double fScaleY );
503 };
504 //for GraphicFilterDialog end
505 
506 //add for SvxAreaTabDialog begin
507 class SvxAreaTabDialog;
508 class AbstractSvxAreaTabDialog_Impl :public AbstractSvxAreaTabDialog
509 {
510 	DECL_ABSTDLG_BASE(AbstractSvxAreaTabDialog_Impl,SvxAreaTabDialog)
511 	virtual void				SetCurPageId( sal_uInt16 nId );
512 	virtual const SfxItemSet* 	GetOutputItemSet() const;
513 	virtual const sal_uInt16*		GetInputRanges( const SfxItemPool& pItem );
514 	virtual void				SetInputSet( const SfxItemSet* pInSet );
515 		//From class Window.
516     virtual void		SetText( const XubString& rStr );
517     virtual String   	GetText() const;
518 	virtual void	 DontDeleteColorTable() ;
519 };
520 //add for SvxAreaTabDialog end
521 
522 class AbstractInsertObjectDialog_Impl : public SfxAbstractInsertObjectDialog
523 {
524     DECL_ABSTDLG_BASE(AbstractInsertObjectDialog_Impl, InsertObjectDialog_Impl)
525     virtual com::sun::star::uno::Reference < com::sun::star::embed::XEmbeddedObject > GetObject();
526 	virtual ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream > GetIconIfIconified( ::rtl::OUString* pGraphicMediaType );
527     virtual sal_Bool IsCreateNew();
528 };
529 
530 class AbstractPasteDialog_Impl : public SfxAbstractPasteDialog
531 {
532 public:
533     DECL_ABSTDLG_BASE(AbstractPasteDialog_Impl, SvPasteObjectDialog )
534     virtual void Insert( SotFormatStringId nFormat, const String & rFormatName );
535     virtual void SetObjName( const SvGlobalName & rClass, const String & rObjName );
536     virtual sal_uLong GetFormat( const TransferableDataHelper& aHelper,
537                         const DataFlavorExVector* pFormats=0,
538                         const TransferableObjectDescriptor* pDesc=0 );
539 };
540 
541 class AbstractLinksDialog_Impl : public SfxAbstractLinksDialog
542 {
543 public:
544     DECL_ABSTDLG_BASE(AbstractLinksDialog_Impl, SvBaseLinksDlg )
545 };
546 
547 
548 //add for SvxPostItDialog begin
549 class SvxPostItDialog;
550 class AbstractSvxPostItDialog_Impl :public AbstractSvxPostItDialog
551 {
552 	DECL_ABSTDLG_BASE( AbstractSvxPostItDialog_Impl, SvxPostItDialog )
553 	virtual void				SetText( const XubString& rStr );  //From class Window
554 	virtual const SfxItemSet*   GetOutputItemSet() const;
555 	virtual void                SetPrevHdl( const Link& rLink ) ;
556 	virtual void                SetNextHdl( const Link& rLink ) ;
557 	virtual void				EnableTravel(sal_Bool bNext, sal_Bool bPrev) ;
558 	virtual String				GetNote() ;
559 	virtual void				SetNote(const String& rTxt) ;
560 	virtual void				ShowLastAuthor(const String& rAuthor, const String& rDate) ;
561 	virtual void				DontChangeAuthor() ;
562 	virtual void				HideAuthor() ;
563 	virtual void				SetReadonlyPostIt(sal_Bool bDisable) ;
564 	virtual sal_Bool 				IsOkEnabled() const  ;
565 	virtual Window *			GetWindow();
566 private:
567 	Link aNextHdl;
568 	Link aPrevHdl;
569 	DECL_LINK( NextHdl, Window*);
570 	DECL_LINK( PrevHdl, Window*);
571 };
572 //add for SvxPostItDialog end
573 
574 //for PasswordToOpenModifyDialog begin
575 class PasswordToOpenModifyDialog;
576 class AbstractPasswordToOpenModifyDialog_Impl : public AbstractPasswordToOpenModifyDialog
577 {
578     DECL_ABSTDLG_BASE( AbstractPasswordToOpenModifyDialog_Impl, PasswordToOpenModifyDialog )
579 
580     virtual String  GetPasswordToOpen() const;
581     virtual String  GetPasswordToModify() const;
582     virtual bool    IsRecommendToOpenReadonly() const;
583 };
584 //for PasswordToOpenModifyDialog end
585 
586 
587 //------------------------------------------------------------------------
588 //AbstractDialogFactory_Impl implementations
589 class AbstractDialogFactory_Impl : public SvxAbstractDialogFactory
590 {
591 public:
592 	virtual VclAbstractDialog* 			CreateVclDialog( Window* pParent, sal_uInt32 nResId );
593 	virtual VclAbstractDialog* 			CreateSfxDialog( Window* pParent, const SfxBindings& rBindings, sal_uInt32 nResId );
594 	virtual SfxAbstractDialog*			CreateSfxDialog( sal_uInt32 nResId,
595 											Window* pParent,
596                                             const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& xViewFrame,
597 											const SfxItemSet* pAttrSet=0 );
598 	virtual SfxAbstractDialog*			CreateSfxDialog( Window* pParent,
599 											const SfxItemSet& rAttr,
600 											const SdrView* pView,
601 											sal_uInt32 nResId );
602 	virtual SfxAbstractDialog*				CreateSfxDialog( Window* pParent, //add for SvxMeasureDialog & SvxConnectionDialog
603 																		const SfxItemSet& rAttr,
604 									const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& _rxFrame,
605 																		sal_uInt32 nResId
606 																		);
607 	virtual VclAbstractDialog*          CreateFrameDialog( Window* pParent, const com::sun::star::uno::Reference< com::sun::star::frame::XFrame >& rxFrame, sal_uInt32 nResId, const String& rParameter );
608 	virtual SfxAbstractTabDialog*		CreateTabDialog( sal_uInt32 nResId,
609 											Window* pParent,
610 											const SfxItemSet* pAttrSet,
611 											SfxViewFrame* pViewFrame,
612 											bool bEditFmt=false,
613 											const String *pUserButtonText=0 );
614 	virtual SfxAbstractTabDialog*		CreateTabDialog( sal_uInt32 nResId,
615 											Window* pParent,
616 											const SfxItemSet* pAttrSet,
617                                             const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& xViewFrame,
618 											bool bEditFmt=false,
619 											const String *pUserButtonText=0 );
620 	virtual SfxAbstractTabDialog* 		CreateTextTabDialog( Window* pParent,
621 											const SfxItemSet* pAttrSet,
622 											SdrView* pView,
623 											SdrModel* pModel=0 ); //add for SvxTextTabDialog
624 	virtual SfxAbstractTabDialog*		CreateTabItemDialog( Window* pParent,
625 											const SfxItemSet& rSet,
626 											sal_uInt32 nResId); //add by CHINA001
627     virtual AbstractSvxCaptionDialog*   CreateCaptionDialog( Window* pParent,
628 											const SdrView* pView,
629 											sal_uInt16 nAnchorTypes = 0 );		//add for SvxCaptionTabDialog CHINA001
630 	virtual	AbstractSvxDistributeDialog* 	CreateSvxDistributeDialog(Window* pParent,
631 											const SfxItemSet& rAttr,
632 											SvxDistributeHorizontal eHor = SvxDistributeHorizontalNone,
633 											SvxDistributeVertical eVer = SvxDistributeVerticalNone);
634     virtual SfxAbstractInsertObjectDialog* CreateInsertObjectDialog( Window* pParent, const rtl::OUString& rCommmand,
635             const com::sun::star::uno::Reference < com::sun::star::embed::XStorage >& xStor,
636             const SvObjectServerList* pList = 0 );
637     virtual VclAbstractDialog*          CreateEditObjectDialog( Window* pParent, const rtl::OUString& rCommmand,
638             const com::sun::star::uno::Reference < com::sun::star::embed::XEmbeddedObject >& xObj );
639    virtual  SfxAbstractPasteDialog*         CreatePasteDialog( Window* pParent );
640    virtual  SfxAbstractLinksDialog*         CreateLinksDialog( Window* pParent, sfx2::LinkManager* pMgr, sal_Bool bHTML, sfx2::SvBaseLink* p=0  );
641 
642    virtual AbstractHangulHanjaConversionDialog * CreateHangulHanjaConversionDialog( Window* _pParent,  //add for HangulHanjaConversionDialog CHINA001
643 											editeng::HangulHanjaConversion::ConversionDirection _ePrimaryDirection );
644 	virtual AbstractThesaurusDialog*		CreateThesaurusDialog( Window*, ::com::sun::star::uno::Reference< ::com::sun::star::linguistic2::XThesaurus >  xThesaurus,
645 												const String &rWord, sal_Int16 nLanguage );
646 
647 	virtual AbstractHyphenWordDialog*		CreateHyphenWordDialog( Window*,
648 												const String &rWord, LanguageType nLang,
649 												::com::sun::star::uno::Reference< ::com::sun::star::linguistic2::XHyphenator >  &xHyphen,
650 												SvxSpellWrapper* pWrapper );
651 
652    virtual AbstractFmShowColsDialog * CreateFmShowColsDialog( Window* pParent );  //add for FmShowColsDialog
653    virtual AbstractSvxZoomDialog * CreateSvxZoomDialog( Window* pParent,  //add for SvxZoomDialog
654 											const SfxItemSet& rCoreSet);
655    virtual SfxAbstractTabDialog* CreateSvxBorderBackgroundDlg( Window* pParent, //add for SvxBorderBackgroundDlg
656 											const SfxItemSet& rCoreSet,
657 											sal_Bool bEnableSelector = sal_False) ;
658    virtual AbstractSvxTransformTabDialog* CreateSvxTransformTabDialog( Window* pParent, //add for SvxTransformTabDialog
659 																const SfxItemSet* pAttr,
660 																const SdrView* pView,
661 																sal_uInt16 nAnchorTypes = 0) ;
662 	virtual SfxAbstractTabDialog* CreateSchTransformTabDialog( Window* pParent,  //add for SchTransformTabDialog
663 																const SfxItemSet* pAttr,
664 																const SdrView* pSdrView,
665 																sal_uInt32 nResId,
666 																bool bSizeTabPage = false
667 																 );
668     virtual AbstractSpellDialog *  CreateSvxSpellDialog(
669                             Window* pParent,
670                             SfxBindings* pBindings,
671                             svx::SpellDialogChildWindow* pSpellChildWindow );
672 
673 //STRIP001    virtual AbstractSvxSpellCheckDialog * CreateSvxSpellCheckDialog( Window* pParent, //add for SvxSpellCheckDialog
674 //STRIP001    ::com::sun::star::uno::Reference<
675 //STRIP001    ::com::sun::star::linguistic2::XSpellChecker1 >  &xChecker,
676 //STRIP001    SvxSpellWrapper* pWrapper,
677 //STRIP001    sal_uInt32 nResId);
678 	virtual VclAbstractRefreshableDialog * CreateActualizeProgressDialog( Window* pParent, GalleryTheme* pThm );
679 	virtual AbstractSearchProgress * CreateSearchProgressDialog( Window* pParent,
680 											const INetURLObject& rStartURL);
681 	virtual AbstractTakeProgress * CreateTakeProgressDialog( Window* pParent );
682 	virtual AbstractTitleDialog * CreateTitleDialog( Window* pParent,  //add for TitleDialog
683 		 									const String& rOldText);
684 	virtual AbstractGalleryIdDialog * CreateGalleryIdDialog( Window* pParent,  //add for SvxZoomDialog
685 											GalleryTheme* pThm);
686     virtual VclAbstractDialog2 * CreateGalleryThemePropertiesDialog( Window* pParent,  //add for GalleryThemeProperties
687 											ExchangeData* pData,
688 											SfxItemSet* pItemSet);
689 	virtual AbstractURLDlg * CreateURLDialog( Window* pParent,  //add for URLDlg
690 											const String& rURL, const String& rAltText, const String& rDescription,
691 											const String& rTarget, const String& rName,
692 											TargetList& rTargetList );
693 	virtual AbstractSvxHlinkDlgMarkWnd* CreateSvxHlinkDlgMarkWndDialog( SvxHyperlinkTabPageBase* pParent, sal_uInt32 nResId ); //add for SvxHlinkDlgMarkWnd
694 
695 	virtual VclAbstractDialog* 		CreateSvxSearchAttributeDialog( Window* pParent,
696 											SearchAttrItemList& rLst,
697 											const sal_uInt16* pWhRanges);
698 	virtual AbstractSvxSearchSimilarityDialog * CreateSvxSearchSimilarityDialog( Window* pParent,
699 															sal_Bool bRelax,
700 															sal_uInt16 nOther,
701 															sal_uInt16 nShorter,
702 															sal_uInt16 nLonger); //add for SvxSearchSimilarityDialog
703 	virtual AbstractSvxJSearchOptionsDialog * CreateSvxJSearchOptionsDialog( Window* pParent,
704 															const SfxItemSet& rOptionsSet,
705 															sal_Int32 nInitialFlags);
706 	virtual AbstractFmInputRecordNoDialog * CreateFmInputRecordNoDialog( Window* pParent );
707 	virtual AbstractSvxNewDictionaryDialog* CreateSvxNewDictionaryDialog( Window* pParent,
708 											::com::sun::star::uno::Reference< ::com::sun::star::linguistic2::XSpellChecker1 >  &xSpl,
709 											sal_uInt32 nResId ); //add for SvxNewDictionaryDialog
710 	virtual VclAbstractDialog *		CreateSvxEditDictionaryDialog( Window* pParent,
711 											const String& rName,
712 											::com::sun::star::uno::Reference< ::com::sun::star::linguistic2::XSpellChecker1> &xSpl,
713 											sal_uInt32 nResId);//add for SvxEditDictionaryDialog
714 	virtual AbstractSvxNameDialog *		CreateSvxNameDialog( Window* pParent,
715 											const String& rName, const String& rDesc );
716 	// #i68101#
717 	virtual AbstractSvxObjectNameDialog* CreateSvxObjectNameDialog(Window* pParent, const String& rName );
718 	virtual AbstractSvxObjectTitleDescDialog* CreateSvxObjectTitleDescDialog(Window* pParent, const String& rTitle, const String& rDescription);
719 
720 	virtual AbstractSvxMessDialog *			CreateSvxMessDialog( Window* pParent, sal_uInt32 nResId,
721 											const String& rText, const String& rDesc,
722 											Image* pImg = NULL ); //add for SvxMessDialog
723 	virtual AbstractSvxMultiPathDialog *	CreateSvxMultiPathDialog( Window* pParent, sal_Bool bEmptyAllowed = sal_False ); //add for SvxMultiPathDialog
724 	virtual AbstractSvxMultiFileDialog *	CreateSvxMultiFileDialog( Window* pParent, sal_Bool bEmptyAllowed = sal_False ); //add for SvxMultiFileDialog
725 	virtual AbstractSvxHpLinkDlg *			CreateSvxHpLinkDlg (Window* pParent,  //add for SvxHpLink
726 											SfxBindings* pBindings,
727 											sal_uInt32 nResId);
728 	virtual AbstractFmSearchDialog* 		CreateFmSearchDialog(Window* pParent, //add for FmSearchDialog
729 														const String& strInitialText,
730                                                         const ::std::vector< String >& _rContexts,
731 														sal_Int16 nInitialContext,
732 														const Link& lnkContextSupplier);
733 	virtual AbstractGraphicFilterDialog *	CreateGraphicFilterEmboss (Window* pParent,  //add for GraphicFilterEmboss
734 											const Graphic& rGraphic,
735 											RECT_POINT eLightSource, sal_uInt32 nResId);
736 	virtual AbstractGraphicFilterDialog *	CreateGraphicFilterPosterSepia (Window* pParent,  //add for GraphicFilterPoster & GraphicFilterSepia
737 											const Graphic& rGraphic,
738 											sal_uInt16 nCount,
739 											sal_uInt32 nResId);
740 	virtual AbstractGraphicFilterDialog *	CreateGraphicFilterSolarize (Window* pParent,  //add for GraphicFilterSolarize
741 											const Graphic& rGraphic,
742 											sal_uInt8 nGreyThreshold, sal_Bool bInvert, sal_uInt32 nResId);
743 	virtual AbstractGraphicFilterDialog *	CreateGraphicFilterMosaic (Window* pParent,  //add for GraphicFilterMosaic
744 											const Graphic& rGraphic,
745 											sal_uInt16 nTileWidth, sal_uInt16 nTileHeight, sal_Bool bEnhanceEdges, sal_uInt32 nResId);
746 	virtual AbstractSvxAreaTabDialog* 		CreateSvxAreaTabDialog( Window* pParent,//add for SvxAreaTabDialog
747 															const SfxItemSet* pAttr,
748 															SdrModel* pModel,
749 															const SdrView* pSdrView = NULL ); //add for SvxAreaTabDialog
750 	virtual SfxAbstractTabDialog*			CreateSvxLineTabDialog( Window* pParent, const SfxItemSet* pAttr, //add for SvxLineTabDialog
751 																 SdrModel* pModel,
752 																 const SdrObject* pObj = NULL,
753 																sal_Bool bHasObj = sal_True );
754 	virtual AbstractSvxPostItDialog*		CreateSvxPostItDialog( Window* pParent, //add for SvxPostItDialog
755 																		const SfxItemSet& rCoreSet,
756 																		sal_Bool bPrevNext = sal_False, sal_Bool bRedline = sal_False );
757 
758 	// For TabPage
759 	virtual CreateTabPage				GetTabPageCreatorFunc( sal_uInt16 nId );
760 	virtual CreateSvxDistributePage		GetSvxDistributePageCreatorFunc();
761 
762 	virtual GetTabPageRanges			GetTabPageRangesFunc( sal_uInt16 nId );
763 	virtual DialogGetRanges			GetDialogGetRangesFunc( sal_uInt16 nId ); //add for SvxPostItDialog
764     virtual VclAbstractDialog*    		CreateSvxScriptOrgDialog( Window* pParent, const String& rLanguage );
765 
766     virtual AbstractScriptSelectorDialog*
767 		CreateScriptSelectorDialog(
768 			Window* pParent,
769             sal_Bool bShowSlots,
770             const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& _rxFrame
771         );
772 
773 	virtual VclAbstractDialog* CreateScriptErrorDialog(
774 			Window* pParent, ::com::sun::star::uno::Any aException);
775 
776     virtual VclAbstractDialog*  CreateSvxMacroAssignDlg(
777                 Window* _pParent,
778                 const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& _rxDocumentFrame,
779                 const bool _bUnoDialogMode,
780                 const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameReplace >& _rxEvents,
781                 const sal_uInt16 _nInitiallySelectedEvent
782             );
783 
784 	virtual SfxAbstractTabDialog* CreateSvxFormatCellsDialog( Window* pParent, const SfxItemSet* pAttr, SdrModel* pModel, const SdrObject* pObj = NULL );
785 
786 	virtual SvxAbstractSplittTableDialog* CreateSvxSplittTableDialog( Window* pParent, bool bIsTableVertical, long nMaxVertical, long nMaxHorizontal );
787 
788 	virtual SvxAbstractNewTableDialog* CreateSvxNewTableDialog( Window* pParent ) ;
789 
790 	virtual VclAbstractDialog*          CreateOptionsDialog(
791         Window* pParent, const rtl::OUString& rExtensionId, const rtl::OUString& rApplicationContext );
792 
793 	virtual SvxAbstractInsRowColDlg* CreateSvxInsRowColDlg( Window* pParent, bool bCol, const rtl::OString& sHelpId );
794 
795     virtual AbstractPasswordToOpenModifyDialog *    CreatePasswordToOpenModifyDialog( Window * pParent, sal_uInt16 nMinPasswdLen, sal_uInt16 nMaxPasswdLen, bool bIsPasswordToModify );
796 };
797 
798 #endif
799 
800