Line data Source code
1 : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 : /*
3 : * This file is part of the LibreOffice project.
4 : *
5 : * This Source Code Form is subject to the terms of the Mozilla Public
6 : * License, v. 2.0. If a copy of the MPL was not distributed with this
7 : * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 : *
9 : * This file incorporates work covered by the following license notice:
10 : *
11 : * Licensed to the Apache Software Foundation (ASF) under one or more
12 : * contributor license agreements. See the NOTICE file distributed
13 : * with this work for additional information regarding copyright
14 : * ownership. The ASF licenses this file to you under the Apache
15 : * License, Version 2.0 (the "License"); you may not use this file
16 : * except in compliance with the License. You may obtain a copy of
17 : * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 : */
19 :
20 : #include "align.hxx" //add for SvxAlignmentTabPage
21 : #include "dlgfact.hxx"
22 :
23 : #include <sfx2/basedlgs.hxx>
24 : #include <sfx2/app.hxx>
25 : #include <sfx2/request.hxx>
26 : #include <cuires.hrc>
27 : #include <svx/dialogs.hrc>
28 : #include "numfmt.hxx"
29 : #include "splitcelldlg.hxx"
30 : #include "gallery.hrc"
31 : #include "dstribut.hxx"
32 : #include "cuiimapwnd.hxx"
33 : #include "hlmarkwn.hxx"
34 : #include "cuicharmap.hxx"
35 : #include "srchxtra.hxx"
36 : #include "textanim.hxx"
37 : #include "autocdlg.hxx"
38 : #include "treeopt.hxx"
39 : #include "internationaloptions.hxx"
40 : #include "labdlg.hxx"
41 : #include "hangulhanjadlg.hxx" //add for HangulHanjaConversionDialog
42 : #include "showcols.hxx" //add for FmShowColsDialog
43 : #include "zoom.hxx" //add for SvxZoomDialog
44 : #include "cuigaldlg.hxx" //add for Gallery 6 Dialogs and 1 TabPage
45 : #include "cuiimapwnd.hxx" //add for URLDlg
46 : #include "hlmarkwn.hxx" //add for SvxHlinkDlgMarkWnd
47 : #include "srchxtra.hxx" //add for SvxSearchFormatDialog
48 : #include "transfrm.hxx" //add for SvxTransformTabDialog
49 : #include "bbdlg.hxx" //add for SvxBorderBackgroundDlg
50 : #include "cuisrchdlg.hxx" //add for SvxJSearchOptionsDialog
51 : #include "cuitbxform.hxx" //add for FmInputRecordNoDialog
52 : #include "optdict.hxx" //add for SvxNewDictionaryDialog
53 : #include "dlgname.hxx" //add for SvxNameDialog & SvxMessDialog
54 : #include "multipat.hxx" //add for SvxMultiPathDialog
55 : #include "multifil.hxx" //add for SvxMultiFileDialog
56 : #include "cuihyperdlg.hxx" //add for SvxHpLinkDlg
57 : #include "cuifmsearch.hxx" //add for FmSearchDialog
58 : #include "cuigrfflt.hxx" //add for GraphicFilterDialog
59 : #include "cuitabarea.hxx" //add for SvxAreaTabDialog
60 : #include "cuitabline.hxx" //add for SvxLineTabDialog
61 : #include "measure.hxx" //add for SvxMeasureDialog
62 : #include "connect.hxx" //add for SvxConnectionDialog
63 : #include "dbregister.hxx" // add for DatabaseRegistrationDialog
64 : #include "cuioptgenrl.hxx" //add for SvxGeneralTabPage
65 : #include "optasian.hxx"
66 : #include "insdlg.hxx"
67 : #include "pastedlg.hxx"
68 : #include "linkdlg.hxx"
69 : #include "SpellDialog.hxx"
70 : #include "cfg.hxx" //add for SvxConfigDialog
71 : #include "numpages.hxx" // add for
72 : #include "paragrph.hxx" //add for
73 : #include "tabstpge.hxx" // add for
74 : #include "textattr.hxx" // add for SvxTextAttrPage
75 : #include "backgrnd.hxx" //add for SvxBackgroundTabPage
76 : #include "border.hxx" //add for SvxBorderTabPage
77 : #include "chardlg.hxx" //add for SvxCharNamePage,SvxCharEffectsPage,SvxCharPositionPage,SvxCharTwoLinesPage
78 : #include "page.hxx" //add for SvxPageDescPage
79 : #include "postdlg.hxx" //add for SvxPostItDialog
80 : #include "grfpage.hxx" //add for SvxGrfCropPage
81 : #include "scriptdlg.hxx" // for ScriptOrgDialog
82 : #include "selector.hxx" // for SvxScriptSelectorDialog
83 : #include "macropg.hxx" // for SvxMacroAssignDlg
84 : #include "sdrcelldlg.hxx"
85 : #include "newtabledlg.hxx"
86 : #include "macroass.hxx"
87 : #include "acccfg.hxx"
88 : #include "insrc.hxx"
89 : #include "passwdomdlg.hxx"
90 : #include "hyphen.hxx"
91 : #include "thesdlg.hxx"
92 : #include "about.hxx"
93 : #include "dialmgr.hxx"
94 :
95 : using namespace ::com::sun::star;
96 : using namespace ::com::sun::star::frame;
97 : using namespace ::com::sun::star::container;
98 :
99 : using ::com::sun::star::uno::Reference;
100 :
101 : using namespace svx;
102 : // AbstractTabDialog implementations just forwards everything to the dialog
103 0 : IMPL_ABSTDLG_BASE(CuiAbstractSfxDialog_Impl)
104 0 : IMPL_ABSTDLG_BASE(CuiVclAbstractDialog_Impl)
105 0 : IMPL_ABSTDLG_BASE(VclAbstractRefreshableDialog_Impl);
106 0 : IMPL_ABSTDLG_BASE(CuiAbstractTabDialog_Impl);
107 0 : IMPL_ABSTDLG_BASE(AbstractSvxDistributeDialog_Impl);
108 0 : IMPL_ABSTDLG_BASE(AbstractHangulHanjaConversionDialog_Impl);
109 0 : IMPL_ABSTDLG_BASE(AbstractFmShowColsDialog_Impl);
110 0 : IMPL_ABSTDLG_BASE(AbstractHyphenWordDialog_Impl)
111 0 : IMPL_ABSTDLG_BASE(AbstractThesaurusDialog_Impl)
112 :
113 0 : AbstractSvxZoomDialog_Impl::~AbstractSvxZoomDialog_Impl() \
114 : {
115 0 : delete pDlg;
116 0 : }
117 0 : short AbstractSvxZoomDialog_Impl::Execute()
118 : {
119 0 : return pDlg->Execute();
120 : }
121 :
122 0 : IMPL_ABSTDLG_BASE(AbstractSearchProgress_Impl);
123 0 : IMPL_ABSTDLG_BASE(AbstractTakeProgress_Impl);
124 0 : IMPL_ABSTDLG_BASE(AbstractTitleDialog_Impl);
125 0 : IMPL_ABSTDLG_BASE(AbstractScriptSelectorDialog_Impl);
126 0 : IMPL_ABSTDLG_BASE(AbstractGalleryIdDialog_Impl);
127 0 : IMPL_ABSTDLG_BASE(AbstractURLDlg_Impl);
128 0 : IMPL_ABSTDLG_BASE(AbstractSvxHlinkDlgMarkWnd_Impl);
129 0 : IMPL_ABSTDLG_BASE(AbstractSvxSearchSimilarityDialog_Impl);
130 0 : IMPL_ABSTDLG_BASE(AbstractSvxTransformTabDialog_Impl);
131 0 : IMPL_ABSTDLG_BASE(AbstractSvxCaptionDialog_Impl);
132 0 : IMPL_ABSTDLG_BASE(AbstractSvxJSearchOptionsDialog_Impl);
133 0 : IMPL_ABSTDLG_BASE(AbstractFmInputRecordNoDialog_Impl);
134 0 : IMPL_ABSTDLG_BASE(AbstractSvxNewDictionaryDialog_Impl);
135 0 : IMPL_ABSTDLG_BASE(AbstractSvxNameDialog_Impl);
136 :
137 : // #i68101#
138 0 : IMPL_ABSTDLG_BASE(AbstractSvxObjectNameDialog_Impl);
139 0 : IMPL_ABSTDLG_BASE(AbstractSvxObjectTitleDescDialog_Impl);
140 :
141 0 : IMPL_ABSTDLG_BASE(AbstractSvxMessDialog_Impl);
142 0 : IMPL_ABSTDLG_BASE(AbstractSvxMultiPathDialog_Impl);
143 0 : IMPL_ABSTDLG_BASE(AbstractSvxMultiFileDialog_Impl);
144 0 : IMPL_ABSTDLG_BASE(AbstractSvxHpLinkDlg_Impl);
145 0 : IMPL_ABSTDLG_BASE(AbstractFmSearchDialog_Impl);
146 0 : IMPL_ABSTDLG_BASE(AbstractGraphicFilterDialog_Impl);
147 0 : IMPL_ABSTDLG_BASE(AbstractSvxAreaTabDialog_Impl);
148 0 : IMPL_ABSTDLG_BASE(AbstractPasteDialog_Impl);
149 0 : IMPL_ABSTDLG_BASE(AbstractInsertObjectDialog_Impl);
150 0 : IMPL_ABSTDLG_BASE(AbstractLinksDialog_Impl);
151 0 : IMPL_ABSTDLG_BASE(AbstractSpellDialog_Impl);
152 0 : IMPL_ABSTDLG_BASE(AbstractSvxPostItDialog_Impl);
153 0 : IMPL_ABSTDLG_BASE(AbstractPasswordToOpenModifyDialog_Impl);
154 :
155 : //////////////////////////////////////////////////////////////////////////
156 : // VclAbstractDialog2_Impl
157 : //////////////////////////////////////////////////////////////////////////
158 :
159 : // virtual
160 0 : VclAbstractDialog2_Impl::~VclAbstractDialog2_Impl()
161 : {
162 0 : delete m_pDlg;
163 0 : }
164 :
165 : // virtual
166 0 : void VclAbstractDialog2_Impl::StartExecuteModal( const Link& rEndDialogHdl )
167 : {
168 0 : m_aEndDlgHdl = rEndDialogHdl;
169 : m_pDlg->StartExecuteModal(
170 0 : LINK( this, VclAbstractDialog2_Impl, EndDialogHdl ) );
171 0 : }
172 :
173 : // virtual
174 0 : long VclAbstractDialog2_Impl::GetResult()
175 : {
176 0 : return m_pDlg->GetResult();
177 : }
178 :
179 0 : IMPL_LINK( VclAbstractDialog2_Impl, EndDialogHdl, Dialog*, pDlg )
180 : {
181 0 : if ( pDlg != m_pDlg )
182 : {
183 : SAL_WARN( "cui.factory", "VclAbstractDialog2_Impl::EndDialogHdl(): wrong dialog" );
184 : }
185 :
186 0 : m_aEndDlgHdl.Call( this );
187 0 : m_aEndDlgHdl = Link();
188 :
189 0 : return 0L;
190 : }
191 :
192 : //////////////////////////////////////////////////////////////////////////
193 :
194 0 : void CuiAbstractTabDialog_Impl::SetCurPageId( sal_uInt16 nId )
195 : {
196 0 : pDlg->SetCurPageId( nId );
197 0 : }
198 :
199 0 : void CuiAbstractTabDialog_Impl::SetCurPageId( const OString& rName )
200 : {
201 0 : pDlg->SetCurPageId( rName );
202 0 : }
203 :
204 0 : const SfxItemSet* CuiAbstractTabDialog_Impl::GetOutputItemSet() const
205 : {
206 0 : return pDlg->GetOutputItemSet();
207 : }
208 :
209 0 : const sal_uInt16* CuiAbstractTabDialog_Impl::GetInputRanges(const SfxItemPool& pItem )
210 : {
211 0 : return pDlg->GetInputRanges( pItem );
212 : }
213 :
214 0 : void CuiAbstractTabDialog_Impl::SetInputSet( const SfxItemSet* pInSet )
215 : {
216 0 : pDlg->SetInputSet( pInSet );
217 0 : }
218 : //From class Window.
219 0 : void CuiAbstractTabDialog_Impl::SetText( const OUString& rStr )
220 : {
221 0 : pDlg->SetText( rStr );
222 0 : }
223 0 : OUString CuiAbstractTabDialog_Impl::GetText() const
224 : {
225 0 : return pDlg->GetText();
226 : }
227 :
228 :
229 0 : const SfxItemSet* CuiAbstractSfxDialog_Impl::GetOutputItemSet() const
230 : {
231 0 : return pDlg->GetOutputItemSet();
232 : }
233 :
234 0 : void CuiAbstractSfxDialog_Impl::SetText( const OUString& rStr )
235 : {
236 0 : pDlg->SetText( rStr );
237 0 : }
238 :
239 0 : OUString CuiAbstractSfxDialog_Impl::GetText() const
240 : {
241 0 : return pDlg->GetText();
242 : }
243 :
244 0 : SvxDistributeHorizontal AbstractSvxDistributeDialog_Impl::GetDistributeHor()const
245 : {
246 0 : return pDlg->GetDistributeHor();
247 : }
248 0 : SvxDistributeVertical AbstractSvxDistributeDialog_Impl::GetDistributeVer()const
249 : {
250 0 : return pDlg->GetDistributeVer();
251 : }
252 :
253 0 : void AbstractHangulHanjaConversionDialog_Impl::EndDialog(long nResult)
254 : {
255 0 : pDlg->EndDialog(nResult);
256 0 : }
257 :
258 0 : void AbstractHangulHanjaConversionDialog_Impl::EnableRubySupport( bool _bVal )
259 : {
260 0 : pDlg->EnableRubySupport(_bVal);
261 0 : }
262 :
263 0 : void AbstractHangulHanjaConversionDialog_Impl::SetByCharacter( bool _bByCharacter )
264 : {
265 0 : pDlg->SetByCharacter(_bByCharacter);
266 0 : }
267 :
268 0 : void AbstractHangulHanjaConversionDialog_Impl::SetConversionDirectionState( bool _bTryBothDirections, editeng::HangulHanjaConversion::ConversionDirection _ePrimaryConversionDirection )
269 : {
270 0 : pDlg->SetConversionDirectionState(_bTryBothDirections, _ePrimaryConversionDirection);
271 0 : }
272 :
273 0 : void AbstractHangulHanjaConversionDialog_Impl::SetConversionFormat( editeng::HangulHanjaConversion::ConversionFormat _eType )
274 : {
275 0 : pDlg->SetConversionFormat(_eType);
276 0 : }
277 :
278 0 : void AbstractHangulHanjaConversionDialog_Impl::SetOptionsChangedHdl( const Link& _rHdl )
279 : {
280 0 : pDlg->SetOptionsChangedHdl(_rHdl );
281 0 : }
282 :
283 0 : void AbstractHangulHanjaConversionDialog_Impl::SetIgnoreHdl( const Link& _rHdl )
284 : {
285 0 : pDlg->SetIgnoreHdl(_rHdl );
286 0 : }
287 :
288 0 : void AbstractHangulHanjaConversionDialog_Impl::SetIgnoreAllHdl( const Link& _rHdl )
289 : {
290 0 : pDlg->SetIgnoreAllHdl(_rHdl );
291 0 : }
292 :
293 0 : void AbstractHangulHanjaConversionDialog_Impl::SetChangeHdl( const Link& _rHdl )
294 : {
295 0 : pDlg->SetChangeHdl(_rHdl );
296 0 : }
297 :
298 0 : void AbstractHangulHanjaConversionDialog_Impl::SetChangeAllHdl( const Link& _rHdl )
299 : {
300 0 : pDlg->SetChangeAllHdl(_rHdl );
301 0 : }
302 :
303 0 : void AbstractHangulHanjaConversionDialog_Impl::SetClickByCharacterHdl( const Link& _rHdl )
304 : {
305 0 : pDlg->SetClickByCharacterHdl(_rHdl );
306 0 : }
307 :
308 0 : void AbstractHangulHanjaConversionDialog_Impl::SetConversionFormatChangedHdl( const Link& _rHdl )
309 : {
310 0 : pDlg->SetConversionFormatChangedHdl(_rHdl );
311 0 : }
312 0 : void AbstractHangulHanjaConversionDialog_Impl::SetFindHdl( const Link& _rHdl )
313 : {
314 0 : pDlg->SetFindHdl(_rHdl );
315 0 : }
316 :
317 0 : bool AbstractHangulHanjaConversionDialog_Impl::GetUseBothDirections( ) const
318 : {
319 0 : return pDlg->GetUseBothDirections();
320 : }
321 :
322 0 : editeng::HangulHanjaConversion::ConversionDirection AbstractHangulHanjaConversionDialog_Impl::GetDirection( editeng::HangulHanjaConversion::ConversionDirection _eDefaultDirection ) const
323 : {
324 0 : return pDlg->GetDirection( _eDefaultDirection );
325 : }
326 :
327 0 : void AbstractHangulHanjaConversionDialog_Impl::SetCurrentString(
328 : const String& _rNewString,
329 : const ::com::sun::star::uno::Sequence< OUString >& _rSuggestions,
330 : bool _bOriginatesFromDocument
331 : )
332 : {
333 0 : pDlg->SetCurrentString(_rNewString,_rSuggestions,_bOriginatesFromDocument);
334 0 : }
335 0 : String AbstractHangulHanjaConversionDialog_Impl::GetCurrentString( ) const
336 : {
337 0 : return pDlg->GetCurrentString();
338 : }
339 0 : editeng::HangulHanjaConversion::ConversionFormat AbstractHangulHanjaConversionDialog_Impl::GetConversionFormat( ) const
340 : {
341 0 : return pDlg->GetConversionFormat();
342 : }
343 :
344 0 : void AbstractHangulHanjaConversionDialog_Impl::FocusSuggestion( )
345 : {
346 0 : pDlg->FocusSuggestion();
347 0 : }
348 :
349 0 : String AbstractHangulHanjaConversionDialog_Impl::GetCurrentSuggestion( ) const
350 : {
351 0 : return pDlg->GetCurrentSuggestion();
352 : }
353 :
354 0 : String AbstractThesaurusDialog_Impl::GetWord()
355 : {
356 0 : return pDlg->GetWord();
357 : };
358 :
359 0 : sal_uInt16 AbstractThesaurusDialog_Impl::GetLanguage() const
360 : {
361 0 : return pDlg->GetLanguage();
362 : };
363 :
364 0 : Window* AbstractThesaurusDialog_Impl::GetWindow()
365 : {
366 0 : return pDlg;
367 : }
368 :
369 0 : void AbstractHyphenWordDialog_Impl::SelLeft()
370 : {
371 0 : pDlg->SelLeft();
372 0 : }
373 :
374 0 : void AbstractHyphenWordDialog_Impl::SelRight()
375 : {
376 0 : pDlg->SelRight();
377 0 : }
378 :
379 0 : Window* AbstractHyphenWordDialog_Impl::GetWindow()
380 : {
381 0 : return pDlg;
382 : }
383 :
384 0 : Reference < com::sun::star::embed::XEmbeddedObject > AbstractInsertObjectDialog_Impl::GetObject()
385 : {
386 0 : return pDlg->GetObject();
387 : }
388 :
389 0 : sal_Bool AbstractInsertObjectDialog_Impl::IsCreateNew()
390 : {
391 0 : return pDlg->IsCreateNew();
392 : }
393 :
394 0 : ::Reference< ::com::sun::star::io::XInputStream > AbstractInsertObjectDialog_Impl::GetIconIfIconified( OUString* pGraphicMediaType )
395 : {
396 0 : return pDlg->GetIconIfIconified( pGraphicMediaType );
397 : }
398 :
399 0 : void AbstractPasteDialog_Impl::Insert( SotFormatStringId nFormat, const String & rFormatName )
400 : {
401 0 : pDlg->Insert( nFormat, rFormatName );
402 0 : }
403 :
404 0 : void AbstractPasteDialog_Impl::SetObjName( const SvGlobalName & rClass, const String & rObjName )
405 : {
406 0 : pDlg->SetObjName( rClass, rObjName );
407 0 : }
408 :
409 0 : sal_uLong AbstractPasteDialog_Impl::GetFormat( const TransferableDataHelper& aHelper,
410 : const DataFlavorExVector* pFormats,
411 : const TransferableObjectDescriptor* pDesc )
412 : {
413 0 : return pDlg->GetFormat( aHelper, pFormats, pDesc );
414 : }
415 :
416 0 : void AbstractFmShowColsDialog_Impl::SetColumns(const ::Reference< ::com::sun::star::container::XIndexContainer>& xCols)
417 : {
418 0 : pDlg->SetColumns(xCols);
419 0 : }
420 :
421 0 : void AbstractSvxZoomDialog_Impl::SetLimits( sal_uInt16 nMin, sal_uInt16 nMax )
422 : {
423 0 : pDlg->SetLimits( nMin, nMax );
424 0 : }
425 :
426 0 : void AbstractSvxZoomDialog_Impl::HideButton( sal_uInt16 nBtnId )
427 : {
428 0 : pDlg->HideButton( nBtnId );
429 0 : }
430 :
431 0 : const SfxItemSet* AbstractSvxZoomDialog_Impl::GetOutputItemSet() const
432 : {
433 0 : return pDlg->GetOutputItemSet();
434 : }
435 :
436 0 : void AbstractSpellDialog_Impl::SetLanguage( sal_uInt16 nLang )
437 : {
438 0 : pDlg->SetLanguage(nLang);
439 0 : }
440 :
441 0 : sal_Bool AbstractSpellDialog_Impl::Close()
442 : {
443 0 : return pDlg->Close();
444 : }
445 :
446 0 : void AbstractSpellDialog_Impl::Invalidate()
447 : {
448 0 : pDlg->InvalidateDialog();
449 0 : }
450 :
451 0 : Window* AbstractSpellDialog_Impl::GetWindow()
452 : {
453 0 : return pDlg;
454 : }
455 :
456 0 : SfxBindings& AbstractSpellDialog_Impl::GetBindings()
457 : {
458 0 : return pDlg->GetBindings();
459 : }
460 :
461 0 : void AbstractSearchProgress_Impl::Update()
462 : {
463 0 : pDlg->Update();
464 0 : }
465 :
466 0 : void AbstractSearchProgress_Impl::Sync()
467 : {
468 0 : pDlg->Sync();
469 0 : }
470 :
471 0 : void AbstractSearchProgress_Impl::SetFileType( const String& rType )
472 : {
473 0 : pDlg->SetFileType( rType );
474 0 : }
475 :
476 0 : void AbstractSearchProgress_Impl::SetDirectory( const INetURLObject& rURL )
477 : {
478 0 : pDlg->SetDirectory( rURL );
479 0 : }
480 0 : PLinkStub AbstractSearchProgress_Impl::GetLinkStubCleanUpHdl()
481 : {
482 0 : return SearchProgress::LinkStubCleanUpHdl;
483 : }
484 :
485 0 : void AbstractTakeProgress_Impl::Update()
486 : {
487 0 : pDlg->Update();
488 0 : }
489 :
490 0 : void AbstractTakeProgress_Impl::Sync()
491 : {
492 0 : pDlg->Sync();
493 0 : }
494 :
495 0 : void AbstractTakeProgress_Impl::SetFile( const INetURLObject& rURL )
496 : {
497 0 : pDlg->SetFile( rURL );
498 0 : }
499 :
500 0 : PLinkStub AbstractTakeProgress_Impl::GetLinkStubCleanUpHdl()
501 : {
502 0 : return TakeProgress::LinkStubCleanUpHdl;
503 : }
504 :
505 0 : String AbstractTitleDialog_Impl::GetTitle() const
506 : {
507 0 : return pDlg->GetTitle();
508 : }
509 :
510 0 : sal_uLong AbstractGalleryIdDialog_Impl::GetId() const
511 : {
512 0 : return pDlg->GetId();
513 : }
514 :
515 0 : void VclAbstractRefreshableDialog_Impl::Update()
516 : {
517 0 : pDlg->Update();
518 0 : }
519 :
520 0 : void VclAbstractRefreshableDialog_Impl::Sync()
521 : {
522 0 : pDlg->Sync();
523 0 : }
524 :
525 0 : String AbstractURLDlg_Impl::GetURL() const
526 : {
527 0 : return pDlg->GetURL();
528 : }
529 :
530 0 : String AbstractURLDlg_Impl::GetAltText() const
531 : {
532 0 : return pDlg->GetAltText();
533 : }
534 :
535 0 : String AbstractURLDlg_Impl::GetDesc() const
536 : {
537 0 : return pDlg->GetDesc();
538 : }
539 :
540 0 : String AbstractURLDlg_Impl::GetTarget() const
541 : {
542 0 : return pDlg->GetTarget();
543 : }
544 :
545 0 : String AbstractURLDlg_Impl::GetName() const
546 : {
547 0 : return pDlg->GetName();
548 : }
549 :
550 0 : void AbstractSvxHlinkDlgMarkWnd_Impl::Hide( sal_uInt16 nFlags )
551 : {
552 0 : ((Window*)pDlg)->Hide( nFlags );
553 0 : }
554 :
555 0 : void AbstractSvxHlinkDlgMarkWnd_Impl::SetSizePixel( const Size& rNewSize )
556 : {
557 0 : pDlg->SetSizePixel( rNewSize );
558 0 : }
559 :
560 0 : Size AbstractSvxHlinkDlgMarkWnd_Impl::GetSizePixel() const
561 : {
562 0 : return pDlg->GetSizePixel();
563 : }
564 :
565 0 : sal_Bool AbstractSvxHlinkDlgMarkWnd_Impl::IsVisible( ) const
566 : {
567 0 : return (( Window* )pDlg)->IsVisible();
568 : }
569 :
570 0 : void AbstractSvxHlinkDlgMarkWnd_Impl::Invalidate( sal_uInt16 nFlags )
571 : {
572 0 : (( Window* )pDlg)->Invalidate(nFlags);
573 0 : }
574 :
575 0 : sal_Bool AbstractSvxHlinkDlgMarkWnd_Impl::MoveTo( Point aNewPos )const
576 : {
577 0 : return pDlg->MoveTo(aNewPos);
578 : }
579 :
580 0 : sal_Bool AbstractSvxHlinkDlgMarkWnd_Impl::ConnectToDialog( sal_Bool bDoit )const
581 : {
582 0 : return pDlg->ConnectToDialog(bDoit);
583 : }
584 :
585 0 : void AbstractSvxHlinkDlgMarkWnd_Impl::RefreshTree ( String aStrURL )
586 : {
587 0 : pDlg->RefreshTree(aStrURL);
588 0 : }
589 :
590 0 : void AbstractSvxHlinkDlgMarkWnd_Impl::SelectEntry ( String aStrMark )
591 : {
592 0 : pDlg->SelectEntry(aStrMark);
593 0 : }
594 :
595 0 : sal_uInt16 AbstractSvxHlinkDlgMarkWnd_Impl::SetError( sal_uInt16 nError)
596 : {
597 0 : return pDlg->SetError(nError);
598 : }
599 :
600 0 : sal_uInt16 AbstractSvxSearchSimilarityDialog_Impl::GetOther()
601 : {
602 0 : return pDlg->GetOther();
603 : }
604 :
605 0 : sal_uInt16 AbstractSvxSearchSimilarityDialog_Impl::GetShorter()
606 : {
607 0 : return pDlg->GetShorter();
608 : }
609 :
610 0 : sal_uInt16 AbstractSvxSearchSimilarityDialog_Impl::GetLonger()
611 : {
612 0 : return pDlg->GetLonger();
613 : }
614 :
615 0 : sal_Bool AbstractSvxSearchSimilarityDialog_Impl::IsRelaxed()
616 : {
617 0 : return pDlg->IsRelaxed();
618 : }
619 :
620 : // AbstractSvxTransformTabDialog implementations just forwards everything to the dialog
621 0 : void AbstractSvxTransformTabDialog_Impl::SetCurPageId( sal_uInt16 nId )
622 : {
623 0 : pDlg->SetCurPageId( nId );
624 0 : }
625 :
626 0 : void AbstractSvxTransformTabDialog_Impl::SetCurPageId( const OString& rName )
627 : {
628 0 : pDlg->SetCurPageId( rName );
629 0 : }
630 :
631 0 : const SfxItemSet* AbstractSvxTransformTabDialog_Impl::GetOutputItemSet() const
632 : {
633 0 : return pDlg->GetOutputItemSet();
634 : }
635 : //
636 0 : const sal_uInt16* AbstractSvxTransformTabDialog_Impl::GetInputRanges(const SfxItemPool& pItem )
637 : {
638 0 : return pDlg->GetInputRanges( pItem );
639 : }
640 : //
641 0 : void AbstractSvxTransformTabDialog_Impl::SetInputSet( const SfxItemSet* pInSet )
642 : {
643 0 : pDlg->SetInputSet( pInSet );
644 0 : }
645 : //From class Window.
646 0 : void AbstractSvxTransformTabDialog_Impl::SetText( const OUString& rStr )
647 : {
648 0 : pDlg->SetText( rStr );
649 0 : }
650 0 : OUString AbstractSvxTransformTabDialog_Impl::GetText() const
651 : {
652 0 : return pDlg->GetText();
653 : }
654 0 : void AbstractSvxTransformTabDialog_Impl::SetValidateFramePosLink( const Link& rLink )
655 : {
656 0 : pDlg->SetValidateFramePosLink( rLink );
657 0 : }
658 :
659 : // AbstractSvxCaptionDialog implementations just forwards everything to the dialog
660 0 : void AbstractSvxCaptionDialog_Impl::SetCurPageId( sal_uInt16 nId )
661 : {
662 0 : pDlg->SetCurPageId( nId );
663 0 : }
664 :
665 0 : void AbstractSvxCaptionDialog_Impl::SetCurPageId( const OString& rName )
666 : {
667 0 : pDlg->SetCurPageId( rName );
668 0 : }
669 :
670 0 : const SfxItemSet* AbstractSvxCaptionDialog_Impl::GetOutputItemSet() const
671 : {
672 0 : return pDlg->GetOutputItemSet();
673 : }
674 : //
675 0 : const sal_uInt16* AbstractSvxCaptionDialog_Impl::GetInputRanges(const SfxItemPool& pItem )
676 : {
677 0 : return pDlg->GetInputRanges( pItem );
678 : }
679 : //
680 0 : void AbstractSvxCaptionDialog_Impl::SetInputSet( const SfxItemSet* pInSet )
681 : {
682 0 : pDlg->SetInputSet( pInSet );
683 0 : }
684 : //From class Window.
685 0 : void AbstractSvxCaptionDialog_Impl::SetText( const OUString& rStr )
686 : {
687 0 : pDlg->SetText( rStr );
688 0 : }
689 0 : OUString AbstractSvxCaptionDialog_Impl::GetText() const
690 : {
691 0 : return pDlg->GetText();
692 : }
693 0 : void AbstractSvxCaptionDialog_Impl::SetValidateFramePosLink( const Link& rLink )
694 : {
695 0 : pDlg->SetValidateFramePosLink( rLink );
696 0 : }
697 :
698 0 : sal_Int32 AbstractSvxJSearchOptionsDialog_Impl::GetTransliterationFlags() const
699 : {
700 0 : return pDlg->GetTransliterationFlags();
701 : }
702 :
703 0 : void AbstractFmInputRecordNoDialog_Impl::SetValue(long nNew)
704 : {
705 0 : pDlg->SetValue(nNew);
706 0 : }
707 :
708 0 : long AbstractFmInputRecordNoDialog_Impl::GetValue() const
709 : {
710 0 : return pDlg->GetValue();
711 : }
712 :
713 : ::Reference<
714 0 : ::com::sun::star::linguistic2::XDictionary > AbstractSvxNewDictionaryDialog_Impl::GetNewDictionary()
715 : {
716 0 : return pDlg->GetNewDictionary();
717 : }
718 :
719 0 : void AbstractSvxNameDialog_Impl::GetName( String& rName )
720 : {
721 0 : pDlg->GetName( rName );
722 0 : }
723 :
724 0 : void AbstractSvxNameDialog_Impl::SetCheckNameHdl( const Link& rLink, bool bCheckImmediately )
725 : {
726 0 : aCheckNameHdl = rLink;
727 0 : if( rLink.IsSet() )
728 0 : pDlg->SetCheckNameHdl( LINK(this, AbstractSvxNameDialog_Impl, CheckNameHdl), bCheckImmediately );
729 : else
730 0 : pDlg->SetCheckNameHdl( Link(), bCheckImmediately );
731 0 : }
732 0 : void AbstractSvxNameDialog_Impl::SetEditHelpId(const OString& aHelpId)
733 : {
734 0 : pDlg->SetEditHelpId( aHelpId );
735 0 : }
736 0 : void AbstractSvxNameDialog_Impl::SetHelpId( const OString& aHelpId )
737 : {
738 0 : pDlg->SetHelpId( aHelpId );
739 0 : }
740 0 : void AbstractSvxNameDialog_Impl::SetText( const OUString& rStr )
741 : {
742 0 : pDlg->SetText( rStr );
743 0 : }
744 0 : IMPL_LINK_NOARG(AbstractSvxNameDialog_Impl, CheckNameHdl)
745 : {
746 0 : if( aCheckNameHdl.IsSet() )
747 0 : return aCheckNameHdl.Call(this);
748 0 : return 0;
749 : }
750 :
751 0 : void AbstractSvxObjectNameDialog_Impl::GetName(String& rName)
752 : {
753 0 : pDlg->GetName(rName);
754 0 : }
755 :
756 0 : void AbstractSvxObjectNameDialog_Impl::SetCheckNameHdl(const Link& rLink, bool bCheckImmediately)
757 : {
758 0 : aCheckNameHdl = rLink;
759 :
760 0 : if(rLink.IsSet())
761 : {
762 0 : pDlg->SetCheckNameHdl(LINK(this, AbstractSvxObjectNameDialog_Impl, CheckNameHdl), bCheckImmediately);
763 : }
764 : else
765 : {
766 0 : pDlg->SetCheckNameHdl(Link(), bCheckImmediately);
767 : }
768 0 : }
769 :
770 0 : IMPL_LINK_NOARG(AbstractSvxObjectNameDialog_Impl, CheckNameHdl)
771 : {
772 0 : if(aCheckNameHdl.IsSet())
773 : {
774 0 : return aCheckNameHdl.Call(this);
775 : }
776 :
777 0 : return 0;
778 : }
779 :
780 0 : void AbstractSvxObjectTitleDescDialog_Impl::GetTitle(String& rTitle)
781 : {
782 0 : pDlg->GetTitle(rTitle);
783 0 : }
784 :
785 0 : void AbstractSvxObjectTitleDescDialog_Impl::GetDescription(String& rDescription)
786 : {
787 0 : pDlg->GetDescription(rDescription);
788 0 : }
789 :
790 0 : void AbstractSvxMessDialog_Impl::SetButtonText( sal_uInt16 nBtnId, const String& rNewTxt )
791 : {
792 0 : pDlg->SetButtonText( nBtnId, rNewTxt );
793 0 : }
794 :
795 0 : String AbstractSvxMultiPathDialog_Impl::GetPath() const
796 : {
797 0 : return pDlg->GetPath();
798 : }
799 :
800 0 : void AbstractSvxMultiPathDialog_Impl::SetPath( const String& rPath )
801 : {
802 0 : pDlg->SetPath( rPath );
803 0 : }
804 :
805 0 : void AbstractSvxMultiPathDialog_Impl::EnableRadioButtonMode()
806 : {
807 0 : pDlg->EnableRadioButtonMode();
808 0 : }
809 :
810 0 : void AbstractSvxMultiPathDialog_Impl::SetTitle( const String& rNewTitle )
811 : {
812 0 : pDlg->SetText( rNewTitle );
813 0 : }
814 :
815 0 : String AbstractSvxMultiFileDialog_Impl::GetPath() const
816 : {
817 0 : return pDlg->GetPath();
818 : }
819 :
820 0 : void AbstractSvxMultiFileDialog_Impl::SetPath( const String& rPath )
821 : {
822 0 : pDlg->SetPath( rPath );
823 0 : }
824 :
825 0 : String AbstractSvxMultiFileDialog_Impl::GetFiles() const
826 : {
827 0 : return pDlg->GetFiles();
828 : }
829 :
830 0 : void AbstractSvxMultiFileDialog_Impl::SetFiles( const String& rPath )
831 : {
832 0 : pDlg->SetFiles( rPath );
833 0 : }
834 :
835 0 : void AbstractSvxMultiFileDialog_Impl::SetClassPathMode()
836 : {
837 0 : pDlg->SetClassPathMode();
838 0 : }
839 :
840 0 : void AbstractSvxMultiFileDialog_Impl::EnableRadioButtonMode()
841 : {
842 0 : pDlg->EnableRadioButtonMode();
843 0 : }
844 :
845 0 : void AbstractSvxMultiFileDialog_Impl::SetTitle( const String& rNewTitle )
846 : {
847 0 : pDlg->SetText( rNewTitle );
848 0 : }
849 :
850 0 : void AbstractSvxMultiFileDialog_Impl::SetHelpId( const OString& aHelpId )
851 : {
852 0 : pDlg->SetHelpId( aHelpId );
853 0 : }
854 :
855 0 : Window * AbstractSvxHpLinkDlg_Impl::GetWindow()
856 : {
857 0 : return (Window *)pDlg;
858 : }
859 :
860 0 : sal_Bool AbstractSvxHpLinkDlg_Impl::QueryClose()
861 : {
862 0 : return pDlg->QueryClose();
863 : }
864 :
865 :
866 0 : void AbstractFmSearchDialog_Impl::SetFoundHandler(const Link& lnk)
867 : {
868 0 : pDlg->SetFoundHandler(lnk);
869 0 : }
870 0 : void AbstractFmSearchDialog_Impl::SetCanceledNotFoundHdl(const Link& lnk)
871 : {
872 0 : pDlg->SetCanceledNotFoundHdl(lnk);
873 0 : }
874 0 : void AbstractFmSearchDialog_Impl::SetActiveField(const String& strField)
875 : {
876 0 : pDlg->SetActiveField(strField);
877 0 : }
878 :
879 0 : Graphic AbstractGraphicFilterDialog_Impl::GetFilteredGraphic( const Graphic& rGraphic, double fScaleX, double fScaleY )
880 : {
881 0 : return pDlg->GetFilteredGraphic( rGraphic, fScaleX, fScaleY );
882 : }
883 :
884 : // AbstractSvxAreaTabDialog implementations just forwards everything to the dialog
885 0 : void AbstractSvxAreaTabDialog_Impl::SetCurPageId( sal_uInt16 nId )
886 : {
887 0 : pDlg->SetCurPageId( nId );
888 0 : }
889 :
890 0 : void AbstractSvxAreaTabDialog_Impl::SetCurPageId( const OString& rName )
891 : {
892 0 : pDlg->SetCurPageId( rName );
893 0 : }
894 :
895 0 : const SfxItemSet* AbstractSvxAreaTabDialog_Impl::GetOutputItemSet() const
896 : {
897 0 : return pDlg->GetOutputItemSet();
898 : }
899 :
900 0 : const sal_uInt16* AbstractSvxAreaTabDialog_Impl::GetInputRanges(const SfxItemPool& pItem )
901 : {
902 0 : return pDlg->GetInputRanges( pItem );
903 : }
904 :
905 0 : void AbstractSvxAreaTabDialog_Impl::SetInputSet( const SfxItemSet* pInSet )
906 : {
907 0 : pDlg->SetInputSet( pInSet );
908 0 : }
909 : //From class Window.
910 0 : void AbstractSvxAreaTabDialog_Impl::SetText( const OUString& rStr )
911 : {
912 0 : pDlg->SetText( rStr );
913 0 : }
914 0 : OUString AbstractSvxAreaTabDialog_Impl::GetText() const
915 : {
916 0 : return pDlg->GetText();
917 : }
918 :
919 0 : void AbstractSvxPostItDialog_Impl::SetText( const OUString& rStr )
920 : {
921 0 : pDlg->SetText( rStr );
922 0 : }
923 0 : const SfxItemSet* AbstractSvxPostItDialog_Impl::GetOutputItemSet() const
924 : {
925 0 : return pDlg->GetOutputItemSet();
926 : }
927 0 : void AbstractSvxPostItDialog_Impl::EnableTravel(sal_Bool bNext, sal_Bool bPrev)
928 : {
929 0 : pDlg->EnableTravel( bNext, bPrev );
930 0 : }
931 0 : String AbstractSvxPostItDialog_Impl::GetNote()
932 : {
933 0 : return pDlg->GetNote();
934 : }
935 0 : void AbstractSvxPostItDialog_Impl::SetNote(const String& rTxt)
936 : {
937 0 : pDlg->SetNote( rTxt );
938 0 : }
939 0 : void AbstractSvxPostItDialog_Impl::ShowLastAuthor(const String& rAuthor, const String& rDate)
940 : {
941 0 : pDlg->ShowLastAuthor( rAuthor, rDate );
942 0 : }
943 0 : void AbstractSvxPostItDialog_Impl::DontChangeAuthor()
944 : {
945 0 : pDlg->DontChangeAuthor();
946 0 : }
947 0 : void AbstractSvxPostItDialog_Impl::HideAuthor()
948 : {
949 0 : pDlg->HideAuthor();
950 0 : }
951 0 : void AbstractSvxPostItDialog_Impl::SetReadonlyPostIt(sal_Bool bDisable)
952 : {
953 0 : pDlg->SetReadonlyPostIt( bDisable );
954 0 : }
955 0 : sal_Bool AbstractSvxPostItDialog_Impl::IsOkEnabled() const
956 : {
957 0 : return pDlg->IsOkEnabled();
958 : }
959 0 : void AbstractSvxPostItDialog_Impl::SetNextHdl( const Link& rLink )
960 : {
961 0 : aNextHdl = rLink;
962 0 : if( rLink.IsSet() )
963 0 : pDlg->SetNextHdl( LINK(this, AbstractSvxPostItDialog_Impl, NextHdl ) );
964 : else
965 0 : pDlg->SetNextHdl( Link() );
966 0 : }
967 0 : void AbstractSvxPostItDialog_Impl::SetPrevHdl( const Link& rLink )
968 : {
969 0 : aPrevHdl = rLink;
970 0 : if( rLink.IsSet() )
971 0 : pDlg->SetPrevHdl( LINK(this, AbstractSvxPostItDialog_Impl, PrevHdl ) );
972 : else
973 0 : pDlg->SetPrevHdl( Link() );
974 0 : }
975 0 : IMPL_LINK_NOARG(AbstractSvxPostItDialog_Impl, NextHdl)
976 : {
977 0 : if( aNextHdl.IsSet() )
978 0 : aNextHdl.Call(this);
979 0 : return 0;
980 : }
981 0 : IMPL_LINK_NOARG(AbstractSvxPostItDialog_Impl, PrevHdl)
982 : {
983 0 : if( aPrevHdl.IsSet() )
984 0 : aPrevHdl.Call(this);
985 0 : return 0;
986 : }
987 0 : Window * AbstractSvxPostItDialog_Impl::GetWindow()
988 : {
989 0 : return (Window *)pDlg;
990 : }
991 :
992 0 : String AbstractPasswordToOpenModifyDialog_Impl::GetPasswordToOpen() const
993 : {
994 0 : return pDlg->GetPasswordToOpen();
995 : }
996 0 : String AbstractPasswordToOpenModifyDialog_Impl::GetPasswordToModify() const
997 : {
998 0 : return pDlg->GetPasswordToModify();
999 : }
1000 0 : bool AbstractPasswordToOpenModifyDialog_Impl::IsRecommendToOpenReadonly() const
1001 : {
1002 0 : return pDlg->IsRecommendToOpenReadonly();
1003 : }
1004 :
1005 : // Create dialogs with simplest interface
1006 0 : VclAbstractDialog* AbstractDialogFactory_Impl::CreateVclDialog( Window* pParent, sal_uInt32 nResId )
1007 : {
1008 0 : Dialog* pDlg=NULL;
1009 0 : switch ( nResId )
1010 : {
1011 : case RID_DEFAULTABOUT:
1012 : {
1013 0 : pDlg = new AboutDialog(pParent);
1014 0 : break;
1015 : }
1016 : case SID_OPTIONS_TREEDIALOG :
1017 : case SID_OPTIONS_DATABASES :
1018 : case SID_LANGUAGE_OPTIONS :
1019 : {
1020 0 : bool bActivateLastSelection = false;
1021 0 : if (nResId == SID_OPTIONS_TREEDIALOG)
1022 0 : bActivateLastSelection = true;
1023 0 : Reference< frame::XFrame > xFrame;
1024 0 : OfaTreeOptionsDialog* pOptDlg = new OfaTreeOptionsDialog( pParent, xFrame, bActivateLastSelection );
1025 0 : if (nResId == SID_OPTIONS_DATABASES)
1026 : {
1027 0 : pOptDlg->ActivatePage(SID_SB_DBREGISTEROPTIONS);
1028 : }
1029 0 : else if (nResId == SID_LANGUAGE_OPTIONS)
1030 : {
1031 : //open the tab page "tools/options/languages"
1032 0 : pOptDlg->ActivatePage(OFA_TP_LANGUAGES_FOR_SET_DOCUMENT_LANGUAGE);
1033 : }
1034 0 : pDlg = pOptDlg;
1035 : }
1036 0 : break;
1037 : default:
1038 0 : break;
1039 : }
1040 :
1041 0 : if ( pDlg )
1042 0 : return new CuiVclAbstractDialog_Impl( pDlg );
1043 0 : return 0;
1044 : }
1045 :
1046 : // dialogs that use SfxBindings
1047 0 : VclAbstractDialog* AbstractDialogFactory_Impl::CreateSfxDialog( Window* /*pParent*/, const SfxBindings&, sal_uInt32 )
1048 : {
1049 0 : return 0;
1050 : }
1051 :
1052 0 : VclAbstractDialog* AbstractDialogFactory_Impl::CreateFrameDialog(
1053 : Window* pParent, const Reference< frame::XFrame >& rxFrame,
1054 : sal_uInt32 nResId, const String& rParameter )
1055 : {
1056 0 : Dialog* pDlg = NULL;
1057 0 : if ( SID_OPTIONS_TREEDIALOG == nResId || SID_OPTIONS_DATABASES == nResId )
1058 : {
1059 : // only activate last page if we dont want to activate a special page
1060 0 : bool bActivateLastSelection = ( nResId != SID_OPTIONS_DATABASES && rParameter.Len() == 0 );
1061 0 : OfaTreeOptionsDialog* pOptDlg = new OfaTreeOptionsDialog( pParent, rxFrame, bActivateLastSelection );
1062 0 : if ( nResId == SID_OPTIONS_DATABASES )
1063 0 : pOptDlg->ActivatePage(SID_SB_DBREGISTEROPTIONS);
1064 0 : else if ( rParameter.Len() > 0 )
1065 0 : pOptDlg->ActivatePage( rParameter );
1066 0 : pDlg = pOptDlg;
1067 : }
1068 :
1069 0 : if ( pDlg )
1070 0 : return new CuiVclAbstractDialog_Impl( pDlg );
1071 : else
1072 0 : return NULL;
1073 : }
1074 :
1075 : // TabDialog outside the drawing layer
1076 0 : SfxAbstractTabDialog* AbstractDialogFactory_Impl::CreateTabDialog( sal_uInt32 nResId,
1077 : Window* pParent,
1078 : const SfxItemSet* pAttrSet,
1079 : SfxViewFrame* ,
1080 : bool /*bEditFmt*/,
1081 : const String * )
1082 : {
1083 0 : SfxTabDialog* pDlg=NULL;
1084 0 : switch ( nResId )
1085 : {
1086 : case RID_OFA_AUTOCORR_DLG :
1087 0 : pDlg = new OfaAutoCorrDlg( pParent, pAttrSet );
1088 0 : break;
1089 : case RID_SVXDLG_CUSTOMIZE :
1090 0 : pDlg = new SvxConfigDialog( pParent, pAttrSet );
1091 0 : break;
1092 : default:
1093 0 : break;
1094 : }
1095 :
1096 0 : if ( pDlg )
1097 0 : return new CuiAbstractTabDialog_Impl( pDlg );
1098 0 : return 0;
1099 : }
1100 :
1101 0 : SfxAbstractTabDialog* AbstractDialogFactory_Impl::CreateTabDialog( sal_uInt32 nResId,
1102 : Window* pParent,
1103 : const SfxItemSet* pAttrSet,
1104 : const Reference< frame::XFrame >& xViewFrame,
1105 : bool /*bEditFmt*/,
1106 : const String * )
1107 : {
1108 0 : SfxTabDialog* pDlg=NULL;
1109 0 : switch ( nResId )
1110 : {
1111 : case RID_OFA_AUTOCORR_DLG :
1112 0 : pDlg = new OfaAutoCorrDlg( pParent, pAttrSet );
1113 0 : break;
1114 : case RID_SVXDLG_CUSTOMIZE :
1115 : {
1116 0 : SvxConfigDialog* pDlg1 = new SvxConfigDialog( pParent, pAttrSet );
1117 0 : pDlg1->SetFrame(xViewFrame);
1118 0 : pDlg = (SfxTabDialog*)pDlg1;
1119 : }
1120 0 : break;
1121 : default:
1122 0 : break;
1123 : }
1124 :
1125 0 : if ( pDlg )
1126 0 : return new CuiAbstractTabDialog_Impl( pDlg );
1127 0 : return 0;
1128 : }
1129 :
1130 : // TabDialog that use functionality of the drawing layer
1131 0 : SfxAbstractTabDialog* AbstractDialogFactory_Impl::CreateTextTabDialog( Window* pParent,
1132 : const SfxItemSet* pAttrSet,
1133 : SdrView* pView,
1134 : SdrModel* )
1135 : {
1136 0 : SfxTabDialog* pDlg = new SvxTextTabDialog( pParent, pAttrSet, pView );
1137 0 : return new CuiAbstractTabDialog_Impl( pDlg );
1138 : }
1139 :
1140 : // TabDialog that use functionality of the drawing layer and add AnchorTypes -- for SvxCaptionTabDialog
1141 0 : AbstractSvxCaptionDialog* AbstractDialogFactory_Impl::CreateCaptionDialog( Window* pParent,
1142 : const SdrView* pView,
1143 : sal_uInt16 nAnchorTypes )
1144 : {
1145 0 : SvxCaptionTabDialog* pDlg = new SvxCaptionTabDialog( pParent, pView, nAnchorTypes );
1146 0 : return new AbstractSvxCaptionDialog_Impl( pDlg );
1147 : }
1148 :
1149 0 : AbstractSvxDistributeDialog* AbstractDialogFactory_Impl::CreateSvxDistributeDialog(Window* pParent,
1150 : const SfxItemSet& rAttr,
1151 : SvxDistributeHorizontal eHor ,
1152 : SvxDistributeVertical eVer)
1153 : {
1154 0 : SvxDistributeDialog* pDlg = new SvxDistributeDialog( pParent, rAttr, eHor, eVer);
1155 0 : return new AbstractSvxDistributeDialog_Impl( pDlg );
1156 : }
1157 :
1158 0 : AbstractHangulHanjaConversionDialog* AbstractDialogFactory_Impl::CreateHangulHanjaConversionDialog(Window* pParent,
1159 : editeng::HangulHanjaConversion::ConversionDirection _ePrimaryDirection )
1160 : {
1161 0 : HangulHanjaConversionDialog* pDlg = new HangulHanjaConversionDialog( pParent, _ePrimaryDirection);
1162 0 : return new AbstractHangulHanjaConversionDialog_Impl( pDlg );
1163 : }
1164 :
1165 0 : AbstractThesaurusDialog* AbstractDialogFactory_Impl::CreateThesaurusDialog( Window* pParent,
1166 : ::com::sun::star::uno::Reference< ::com::sun::star::linguistic2::XThesaurus > xThesaurus,
1167 : const String &rWord, sal_Int16 nLanguage )
1168 : {
1169 0 : SvxThesaurusDialog* pDlg = new SvxThesaurusDialog( pParent, xThesaurus, rWord, nLanguage );
1170 0 : return new AbstractThesaurusDialog_Impl( pDlg );
1171 : }
1172 :
1173 0 : AbstractHyphenWordDialog* AbstractDialogFactory_Impl::CreateHyphenWordDialog( Window* pParent,
1174 : const String &rWord, LanguageType nLang,
1175 : ::com::sun::star::uno::Reference< ::com::sun::star::linguistic2::XHyphenator > &xHyphen,
1176 : SvxSpellWrapper* pWrapper )
1177 : {
1178 0 : SvxHyphenWordDialog* pDlg = new SvxHyphenWordDialog( rWord, nLang, pParent, xHyphen, pWrapper );
1179 0 : return new AbstractHyphenWordDialog_Impl( pDlg );
1180 : }
1181 :
1182 0 : AbstractFmShowColsDialog * AbstractDialogFactory_Impl::CreateFmShowColsDialog( Window* pParent )
1183 : {
1184 0 : FmShowColsDialog* pDlg = new FmShowColsDialog( pParent);
1185 0 : return new AbstractFmShowColsDialog_Impl( pDlg );
1186 : }
1187 0 : AbstractSvxZoomDialog * AbstractDialogFactory_Impl::CreateSvxZoomDialog( Window* pParent, //add for SvxZoomDialog
1188 : const SfxItemSet& rCoreSet)
1189 : {
1190 0 : SvxZoomDialog* pDlg = new SvxZoomDialog( pParent, rCoreSet);
1191 0 : return new AbstractSvxZoomDialog_Impl( pDlg );
1192 : }
1193 :
1194 0 : AbstractSpellDialog * AbstractDialogFactory_Impl::CreateSvxSpellDialog(
1195 : Window* pParent,
1196 : SfxBindings* pBindings,
1197 : svx::SpellDialogChildWindow* pSpellChildWindow )
1198 : {
1199 0 : svx::SpellDialog* pDlg = new svx::SpellDialog(pSpellChildWindow, pParent, pBindings);
1200 0 : return new AbstractSpellDialog_Impl(pDlg);
1201 : }
1202 :
1203 0 : VclAbstractRefreshableDialog * AbstractDialogFactory_Impl::CreateActualizeProgressDialog( Window* pParent, GalleryTheme* pThm )
1204 : {
1205 0 : Dialog* pDlg = new ActualizeProgress( pParent, pThm);
1206 0 : return new VclAbstractRefreshableDialog_Impl( pDlg );
1207 : }
1208 :
1209 0 : AbstractSearchProgress * AbstractDialogFactory_Impl::CreateSearchProgressDialog( Window* pParent, //add for SearchProgress
1210 : const INetURLObject& rStartURL )
1211 : {
1212 0 : SearchProgress* pDlg = new SearchProgress( pParent, rStartURL);
1213 0 : return new AbstractSearchProgress_Impl( pDlg );
1214 : }
1215 :
1216 0 : AbstractTakeProgress * AbstractDialogFactory_Impl::CreateTakeProgressDialog( Window* pParent )
1217 : {
1218 0 : TakeProgress* pDlg = new TakeProgress( pParent );
1219 0 : return new AbstractTakeProgress_Impl( pDlg );
1220 : }
1221 :
1222 : VclAbstractDialog*
1223 0 : AbstractDialogFactory_Impl::CreateScriptErrorDialog(
1224 : Window* pParent, ::com::sun::star::uno::Any aException )
1225 : {
1226 0 : return new SvxScriptErrorDialog( pParent, aException );
1227 : }
1228 :
1229 : AbstractScriptSelectorDialog*
1230 0 : AbstractDialogFactory_Impl::CreateScriptSelectorDialog(
1231 : Window* pParent, sal_Bool bShowSlots, const Reference< frame::XFrame >& _rxFrame )
1232 : {
1233 0 : SvxScriptSelectorDialog* pDlg = new SvxScriptSelectorDialog(pParent, bShowSlots, _rxFrame);
1234 0 : return new AbstractScriptSelectorDialog_Impl(pDlg);
1235 : }
1236 :
1237 0 : String AbstractScriptSelectorDialog_Impl::GetScriptURL() const
1238 : {
1239 0 : if (pDlg)
1240 0 : return pDlg->GetScriptURL();
1241 0 : return String();
1242 : }
1243 :
1244 0 : void AbstractScriptSelectorDialog_Impl::SetRunLabel()
1245 : {
1246 0 : if (pDlg)
1247 0 : pDlg->SetRunLabel();
1248 0 : return;
1249 : }
1250 :
1251 0 : VclAbstractDialog * AbstractDialogFactory_Impl::CreateSvxScriptOrgDialog( Window* pParent, //add for SvxScriptOrgDialog
1252 : const String& rLanguage)
1253 : {
1254 0 : Dialog* pDlg=NULL;
1255 :
1256 0 : pDlg = new SvxScriptOrgDialog( pParent, rLanguage);
1257 :
1258 0 : if ( pDlg )
1259 0 : return new CuiVclAbstractDialog_Impl( pDlg );
1260 0 : return 0;
1261 : }
1262 :
1263 0 : AbstractTitleDialog * AbstractDialogFactory_Impl::CreateTitleDialog( Window* pParent, //add for TitleDialog
1264 : const String& rOldText)
1265 : {
1266 0 : TitleDialog* pDlg = new TitleDialog( pParent, rOldText);
1267 0 : return new AbstractTitleDialog_Impl( pDlg );
1268 : }
1269 :
1270 0 : AbstractGalleryIdDialog * AbstractDialogFactory_Impl::CreateGalleryIdDialog( Window* pParent, //add for SvxZoomDialog
1271 : GalleryTheme* pThm )
1272 : {
1273 0 : GalleryIdDialog* pDlg = new GalleryIdDialog( pParent, pThm);
1274 0 : return new AbstractGalleryIdDialog_Impl( pDlg );
1275 : }
1276 :
1277 0 : VclAbstractDialog2 * AbstractDialogFactory_Impl::CreateGalleryThemePropertiesDialog( Window* pParent, //add for GalleryThemeProperties
1278 : ExchangeData* pData,
1279 : SfxItemSet* pItemSet)
1280 : {
1281 0 : Dialog* pDlg = new GalleryThemeProperties( pParent, pData, pItemSet);
1282 0 : return new VclAbstractDialog2_Impl( pDlg );
1283 : }
1284 :
1285 0 : AbstractURLDlg * AbstractDialogFactory_Impl::CreateURLDialog( Window* pParent, //add for URLDlg
1286 : const String& rURL, const String& rAltText, const String& rDescription,
1287 : const String& rTarget, const String& rName,
1288 : TargetList& rTargetList )
1289 : {
1290 0 : URLDlg* pDlg = new URLDlg( pParent, rURL, rAltText, rDescription, rTarget, rName, rTargetList);
1291 0 : return new AbstractURLDlg_Impl( pDlg );
1292 : }
1293 :
1294 0 : AbstractSvxHlinkDlgMarkWnd* AbstractDialogFactory_Impl::CreateSvxHlinkDlgMarkWndDialog( SvxHyperlinkTabPageBase* pParent, sal_uInt32 nResId )
1295 : {
1296 0 : SvxHlinkDlgMarkWnd* pDlg=NULL;
1297 0 : switch ( nResId )
1298 : {
1299 : case RID_SVXFLOAT_HYPERLINK_MARKWND :
1300 0 : pDlg = new SvxHlinkDlgMarkWnd( pParent );
1301 0 : break;
1302 : default:
1303 0 : break;
1304 : }
1305 :
1306 0 : if ( pDlg )
1307 0 : return new AbstractSvxHlinkDlgMarkWnd_Impl( pDlg );
1308 0 : return 0;
1309 : }
1310 :
1311 0 : SfxAbstractDialog* AbstractDialogFactory_Impl::CreateSfxDialog( sal_uInt32,
1312 : Window* pParent,
1313 : const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& ,
1314 : const SfxItemSet* pAttrSet )
1315 : {
1316 0 : SfxModalDialog* pDlg = new SvxCharacterMap( pParent, sal_True, pAttrSet );
1317 0 : return new CuiAbstractSfxDialog_Impl( pDlg );
1318 : }
1319 :
1320 0 : SfxAbstractTabDialog* AbstractDialogFactory_Impl::CreateTabItemDialog( Window* pParent,
1321 : const SfxItemSet& rSet,
1322 : sal_uInt32 nResId)
1323 : {
1324 0 : SfxTabDialog* pDlg=NULL;
1325 0 : switch ( nResId )
1326 : {
1327 : case RID_SVXDLG_SEARCHFORMAT :
1328 0 : pDlg = new SvxSearchFormatDialog( pParent, rSet );
1329 0 : break;
1330 : default:
1331 0 : break;
1332 : }
1333 :
1334 0 : if ( pDlg )
1335 0 : return new CuiAbstractTabDialog_Impl( pDlg );
1336 0 : return 0;
1337 : }
1338 :
1339 0 : VclAbstractDialog* AbstractDialogFactory_Impl::CreateSvxSearchAttributeDialog( Window* pParent,
1340 : SearchAttrItemList& rLst,
1341 : const sal_uInt16* pWhRanges )
1342 : {
1343 0 : Dialog* pDlg = new SvxSearchAttributeDialog( pParent, rLst, pWhRanges);
1344 0 : return new CuiVclAbstractDialog_Impl( pDlg );
1345 : }
1346 :
1347 0 : AbstractSvxSearchSimilarityDialog * AbstractDialogFactory_Impl::CreateSvxSearchSimilarityDialog( Window* pParent,
1348 : sal_Bool bRelax,
1349 : sal_uInt16 nOther,
1350 : sal_uInt16 nShorter,
1351 : sal_uInt16 nLonger)
1352 : {
1353 0 : SvxSearchSimilarityDialog* pDlg = new SvxSearchSimilarityDialog( pParent, bRelax, nOther, nShorter, nLonger );
1354 0 : if ( pDlg )
1355 0 : return new AbstractSvxSearchSimilarityDialog_Impl( pDlg );
1356 0 : return NULL;
1357 : }
1358 :
1359 0 : SfxAbstractTabDialog* AbstractDialogFactory_Impl::CreateSvxBorderBackgroundDlg( Window* pParent,
1360 : const SfxItemSet& rCoreSet,
1361 : sal_Bool bEnableSelector)
1362 : {
1363 0 : SfxTabDialog* pDlg = new SvxBorderBackgroundDlg( pParent, rCoreSet, bEnableSelector);
1364 0 : return new CuiAbstractTabDialog_Impl( pDlg );
1365 : }
1366 :
1367 0 : AbstractSvxTransformTabDialog* AbstractDialogFactory_Impl::CreateSvxTransformTabDialog( Window* pParent,
1368 : const SfxItemSet* pAttr,
1369 : const SdrView* pView,
1370 : sal_uInt16 nAnchorTypes )
1371 : {
1372 0 : SvxTransformTabDialog* pDlg = new SvxTransformTabDialog( pParent, pAttr,pView, nAnchorTypes);
1373 0 : return new AbstractSvxTransformTabDialog_Impl( pDlg );
1374 : }
1375 :
1376 0 : SfxAbstractTabDialog* AbstractDialogFactory_Impl::CreateSchTransformTabDialog( Window* pParent,
1377 : const SfxItemSet* pAttr,
1378 : const SdrView* pSdrView,
1379 : sal_uInt32 nResId,
1380 : bool bSizeTabPage
1381 : )
1382 : {
1383 0 : SfxTabDialog* pDlg=NULL;
1384 0 : switch ( nResId )
1385 : {
1386 : case RID_SCH_TransformTabDLG_SVXPAGE_ANGLE :
1387 : {
1388 0 : pDlg = new SvxTransformTabDialog( pParent, pAttr,pSdrView, bSizeTabPage ? SVX_OBJ_NOPROTECT : SVX_OBJ_NOPROTECT|SVX_OBJ_NORESIZE);
1389 0 : pDlg->RemoveTabPage( RID_SVXPAGE_ANGLE );
1390 0 : pDlg->RemoveTabPage( RID_SVXPAGE_SLANT );
1391 : }
1392 0 : break;
1393 : case RID_SCH_TransformTabDLG_SVXPAGE_SLANT:
1394 : {
1395 0 : pDlg = new SvxTransformTabDialog( pParent, pAttr,pSdrView, bSizeTabPage ? SVX_OBJ_NOPROTECT : SVX_OBJ_NOPROTECT|SVX_OBJ_NORESIZE);
1396 0 : pDlg->RemoveTabPage( RID_SVXPAGE_SLANT );
1397 : }
1398 0 : break;
1399 : default:
1400 0 : break;
1401 : }
1402 :
1403 0 : if ( pDlg )
1404 0 : return new CuiAbstractTabDialog_Impl( pDlg );
1405 0 : return 0;
1406 : }
1407 :
1408 0 : AbstractSvxJSearchOptionsDialog * AbstractDialogFactory_Impl::CreateSvxJSearchOptionsDialog( Window* pParent,
1409 : const SfxItemSet& rOptionsSet,
1410 : sal_Int32 nInitialFlags)
1411 : {
1412 0 : SvxJSearchOptionsDialog* pDlg = new SvxJSearchOptionsDialog( pParent, rOptionsSet, nInitialFlags );
1413 0 : return new AbstractSvxJSearchOptionsDialog_Impl( pDlg );
1414 : }
1415 :
1416 0 : AbstractFmInputRecordNoDialog * AbstractDialogFactory_Impl::CreateFmInputRecordNoDialog( Window* pParent )
1417 : {
1418 0 : FmInputRecordNoDialog* pDlg = new FmInputRecordNoDialog( pParent );
1419 0 : return new AbstractFmInputRecordNoDialog_Impl( pDlg );
1420 : }
1421 :
1422 0 : AbstractSvxNewDictionaryDialog * AbstractDialogFactory_Impl::CreateSvxNewDictionaryDialog( Window* pParent,
1423 : ::Reference< ::com::sun::star::linguistic2::XSpellChecker1 > &xSpl,
1424 : sal_uInt32 nResId )
1425 : {
1426 0 : SvxNewDictionaryDialog* pDlg=NULL;
1427 0 : switch ( nResId )
1428 : {
1429 : case RID_SFXDLG_NEWDICT :
1430 0 : pDlg = new SvxNewDictionaryDialog( pParent, xSpl );
1431 0 : break;
1432 : default:
1433 0 : break;
1434 : }
1435 :
1436 0 : if ( pDlg )
1437 0 : return new AbstractSvxNewDictionaryDialog_Impl( pDlg );
1438 0 : return 0;
1439 : }
1440 :
1441 0 : VclAbstractDialog* AbstractDialogFactory_Impl::CreateSvxEditDictionaryDialog( Window* pParent,
1442 : const String& rName,
1443 : ::Reference< ::com::sun::star::linguistic2::XSpellChecker1> &xSpl,
1444 : sal_uInt32 nResId )
1445 : {
1446 0 : Dialog* pDlg=NULL;
1447 0 : switch ( nResId )
1448 : {
1449 : case RID_SFXDLG_EDITDICT :
1450 0 : pDlg = new SvxEditDictionaryDialog( pParent, rName, xSpl );
1451 0 : break;
1452 : default:
1453 0 : break;
1454 : }
1455 :
1456 0 : if ( pDlg )
1457 0 : return new CuiVclAbstractDialog_Impl( pDlg );
1458 0 : return 0;
1459 : }
1460 :
1461 0 : AbstractSvxNameDialog * AbstractDialogFactory_Impl::CreateSvxNameDialog( Window* pParent,
1462 : const String& rName, const String& rDesc )
1463 : {
1464 0 : SvxNameDialog* pDlg = new SvxNameDialog( pParent, rName, rDesc );
1465 0 : return new AbstractSvxNameDialog_Impl( pDlg );
1466 : }
1467 :
1468 0 : AbstractSvxObjectNameDialog* AbstractDialogFactory_Impl::CreateSvxObjectNameDialog(Window* pParent, const String& rName )
1469 : {
1470 0 : return new AbstractSvxObjectNameDialog_Impl(new SvxObjectNameDialog(pParent, rName));
1471 : }
1472 :
1473 0 : AbstractSvxObjectTitleDescDialog* AbstractDialogFactory_Impl::CreateSvxObjectTitleDescDialog(Window* pParent, const String& rTitle, const String& rDescription)
1474 : {
1475 0 : return new AbstractSvxObjectTitleDescDialog_Impl(new SvxObjectTitleDescDialog(pParent, rTitle, rDescription));
1476 : }
1477 :
1478 0 : AbstractSvxMessDialog * AbstractDialogFactory_Impl::CreateSvxMessDialog( Window* pParent, sal_uInt32,
1479 : const String& rText, const String& rDesc, Image* pImg )
1480 : {
1481 0 : SvxMessDialog* pDlg = new SvxMessDialog( pParent, rText, rDesc, pImg );
1482 0 : return new AbstractSvxMessDialog_Impl( pDlg );
1483 : }
1484 :
1485 0 : AbstractSvxMultiPathDialog * AbstractDialogFactory_Impl::CreateSvxMultiPathDialog( Window* pParent, sal_Bool bEmptyAllowed )
1486 : {
1487 0 : SvxMultiPathDialog* pDlg = new SvxMultiPathDialog( pParent, bEmptyAllowed );
1488 0 : return new AbstractSvxMultiPathDialog_Impl( pDlg );
1489 : }
1490 :
1491 0 : AbstractSvxMultiFileDialog * AbstractDialogFactory_Impl::CreateSvxMultiFileDialog( Window* pParent, sal_Bool bEmptyAllowed )
1492 : {
1493 0 : SvxMultiFileDialog* pDlg = new SvxMultiFileDialog( pParent, bEmptyAllowed );
1494 0 : return new AbstractSvxMultiFileDialog_Impl( pDlg );
1495 : }
1496 :
1497 0 : AbstractSvxHpLinkDlg * AbstractDialogFactory_Impl::CreateSvxHpLinkDlg (Window* pParent, //add for SvxMultiFileDialog
1498 : SfxBindings* pBindings,
1499 : sal_uInt32 nResId)
1500 : {
1501 0 : SvxHpLinkDlg* pDlg=NULL;
1502 0 : switch ( nResId )
1503 : {
1504 : case SID_HYPERLINK_DIALOG :
1505 0 : pDlg = new SvxHpLinkDlg( pParent, pBindings );
1506 0 : break;
1507 : default:
1508 0 : break;
1509 : }
1510 :
1511 0 : if ( pDlg )
1512 0 : return new AbstractSvxHpLinkDlg_Impl( pDlg );
1513 0 : return 0;
1514 : }
1515 :
1516 0 : AbstractFmSearchDialog* AbstractDialogFactory_Impl::CreateFmSearchDialog(Window* pParent, //add for FmSearchDialog
1517 : const OUString& strInitialText,
1518 : const ::std::vector< OUString >& _rContexts,
1519 : sal_Int16 nInitialContext,
1520 : const Link& lnkContextSupplier)
1521 : {
1522 0 : FmSearchDialog* pDlg = new FmSearchDialog( pParent, strInitialText, _rContexts, nInitialContext, lnkContextSupplier );
1523 0 : if ( pDlg )
1524 0 : return new AbstractFmSearchDialog_Impl( pDlg );
1525 0 : return 0;
1526 : }
1527 :
1528 0 : AbstractGraphicFilterDialog * AbstractDialogFactory_Impl::CreateGraphicFilterEmboss (Window* pParent, //add for GraphicFilterEmboss
1529 : const Graphic& rGraphic,
1530 : RECT_POINT eLightSource,
1531 : sal_uInt32)
1532 : {
1533 0 : GraphicFilterDialog* pDlg = new GraphicFilterEmboss( pParent, rGraphic, eLightSource );
1534 0 : return new AbstractGraphicFilterDialog_Impl( pDlg );
1535 : }
1536 :
1537 0 : AbstractGraphicFilterDialog * AbstractDialogFactory_Impl::CreateGraphicFilterPosterSepia (Window* pParent,
1538 : const Graphic& rGraphic,
1539 : sal_uInt16 nCount,
1540 : sal_uInt32 nResId)
1541 : {
1542 0 : GraphicFilterDialog* pDlg=NULL;
1543 0 : switch ( nResId )
1544 : {
1545 : case RID_SVX_GRFFILTER_DLG_POSTER :
1546 0 : pDlg = new GraphicFilterPoster( pParent, rGraphic, nCount );
1547 0 : break;
1548 : case RID_SVX_GRFFILTER_DLG_SEPIA :
1549 0 : pDlg = new GraphicFilterSepia( pParent, rGraphic, nCount );
1550 0 : break;
1551 :
1552 : default:
1553 0 : break;
1554 : }
1555 :
1556 0 : if ( pDlg )
1557 0 : return new AbstractGraphicFilterDialog_Impl( pDlg );
1558 0 : return 0;
1559 : }
1560 :
1561 0 : AbstractGraphicFilterDialog * AbstractDialogFactory_Impl::CreateGraphicFilterSmooth ( Window* pParent,
1562 : const Graphic& rGraphic, double nRadius, sal_uInt32)
1563 : {
1564 0 : GraphicFilterDialog* pDlg = new GraphicFilterSmooth( pParent, rGraphic, nRadius );
1565 0 : return new AbstractGraphicFilterDialog_Impl( pDlg );
1566 : }
1567 :
1568 0 : AbstractGraphicFilterDialog * AbstractDialogFactory_Impl::CreateGraphicFilterSolarize (Window* pParent, //add for GraphicFilterSolarize
1569 : const Graphic& rGraphic, sal_uInt8 nGreyThreshold, sal_Bool bInvert, sal_uInt32 )
1570 : {
1571 0 : GraphicFilterDialog* pDlg = new GraphicFilterSolarize( pParent, rGraphic, nGreyThreshold, bInvert );
1572 0 : return new AbstractGraphicFilterDialog_Impl( pDlg );
1573 : }
1574 :
1575 0 : AbstractGraphicFilterDialog * AbstractDialogFactory_Impl::CreateGraphicFilterMosaic (Window* pParent, //add for GraphicFilterMosaic
1576 : const Graphic& rGraphic, sal_uInt16 nTileWidth, sal_uInt16 nTileHeight,
1577 : sal_Bool bEnhanceEdges, sal_uInt32 nResId)
1578 : {
1579 0 : GraphicFilterDialog* pDlg=NULL;
1580 0 : switch ( nResId )
1581 : {
1582 : case RID_SVX_GRFFILTER_DLG_MOSAIC :
1583 0 : pDlg = new GraphicFilterMosaic( pParent, rGraphic, nTileWidth, nTileHeight, bEnhanceEdges );
1584 0 : break;
1585 : default:
1586 0 : break;
1587 : }
1588 :
1589 0 : if ( pDlg )
1590 0 : return new AbstractGraphicFilterDialog_Impl( pDlg );
1591 0 : return 0;
1592 : }
1593 :
1594 0 : AbstractSvxAreaTabDialog* AbstractDialogFactory_Impl::CreateSvxAreaTabDialog( Window* pParent,
1595 : const SfxItemSet* pAttr,
1596 : SdrModel* pModel,
1597 : const SdrView* pSdrView )
1598 : {
1599 0 : SvxAreaTabDialog* pDlg = new SvxAreaTabDialog( pParent, pAttr, pModel,pSdrView );
1600 0 : return new AbstractSvxAreaTabDialog_Impl( pDlg );
1601 : }
1602 :
1603 0 : SfxAbstractTabDialog* AbstractDialogFactory_Impl::CreateSvxLineTabDialog( Window* pParent, const SfxItemSet* pAttr, //add forSvxLineTabDialog
1604 : SdrModel* pModel,
1605 : const SdrObject* pObj ,
1606 : sal_Bool bHasObj)
1607 : {
1608 0 : SfxTabDialog* pDlg = new SvxLineTabDialog( pParent, pAttr, pModel,pObj,bHasObj );
1609 0 : return new CuiAbstractTabDialog_Impl( pDlg );
1610 : }
1611 :
1612 0 : SfxAbstractDialog* AbstractDialogFactory_Impl::CreateSfxDialog( Window* pParent,
1613 : const SfxItemSet& rAttr,
1614 : const Reference< XFrame >& _rxDocumentFrame,
1615 : sal_uInt32 nResId
1616 : )
1617 : {
1618 0 : SfxModalDialog* pDlg=NULL;
1619 0 : switch ( nResId )
1620 : {
1621 : case SID_EVENTCONFIG :
1622 0 : pDlg = new SfxMacroAssignDlg( pParent, _rxDocumentFrame, rAttr );
1623 0 : break;
1624 : case RID_SVXPAGE_MACROASSIGN :
1625 0 : pDlg = new SvxShortcutAssignDlg( pParent, _rxDocumentFrame, rAttr );
1626 0 : break;
1627 : case RID_SVXDLG_CHARMAP :
1628 0 : pDlg = new SvxCharacterMap( pParent, sal_True, &rAttr );
1629 0 : break;
1630 : default:
1631 0 : break;
1632 : }
1633 :
1634 0 : if ( pDlg )
1635 0 : return new CuiAbstractSfxDialog_Impl( pDlg );
1636 0 : return 0;
1637 : }
1638 :
1639 0 : SfxAbstractDialog* AbstractDialogFactory_Impl::CreateSfxDialog( Window* pParent,
1640 : const SfxItemSet& rAttr,
1641 : const SdrView* pView,
1642 : sal_uInt32 nResId
1643 : )
1644 : {
1645 0 : SfxNoLayoutSingleTabDialog* pDlg=NULL;
1646 0 : switch ( nResId )
1647 : {
1648 : case RID_SVXPAGE_MEASURE :
1649 0 : pDlg = new SvxMeasureDialog( pParent, rAttr, pView );
1650 0 : break;
1651 : case RID_SVXPAGE_CONNECTION :
1652 0 : pDlg = new SvxConnectionDialog( pParent, rAttr, pView );
1653 0 : break;
1654 : case RID_SFXPAGE_DBREGISTER :
1655 0 : pDlg = new DatabaseRegistrationDialog( pParent, rAttr );
1656 0 : break;
1657 : default:
1658 0 : break;
1659 : }
1660 :
1661 0 : if ( pDlg )
1662 0 : return new CuiAbstractSfxDialog_Impl( pDlg );
1663 0 : return 0;
1664 : }
1665 :
1666 0 : AbstractSvxPostItDialog* AbstractDialogFactory_Impl::CreateSvxPostItDialog( Window* pParent,
1667 : const SfxItemSet& rCoreSet,
1668 : sal_Bool bPrevNext )
1669 : {
1670 0 : SvxPostItDialog* pDlg = new SvxPostItDialog( pParent, rCoreSet, bPrevNext );
1671 0 : return new AbstractSvxPostItDialog_Impl( pDlg );
1672 : }
1673 :
1674 : class SvxMacroAssignDialog : public VclAbstractDialog
1675 : {
1676 : public:
1677 0 : SvxMacroAssignDialog( Window* _pParent, const Reference< XFrame >& _rxDocumentFrame, const bool _bUnoDialogMode,
1678 : const Reference< XNameReplace >& _rxEvents, const sal_uInt16 _nInitiallySelectedEvent )
1679 0 : :m_aItems( SFX_APP()->GetPool(), SID_ATTR_MACROITEM, SID_ATTR_MACROITEM )
1680 : {
1681 0 : m_aItems.Put( SfxBoolItem( SID_ATTR_MACROITEM, _bUnoDialogMode ) );
1682 0 : m_pDialog.reset( new SvxMacroAssignDlg( _pParent, _rxDocumentFrame, m_aItems, _rxEvents, _nInitiallySelectedEvent ) );
1683 0 : }
1684 :
1685 : virtual short Execute();
1686 : virtual ~SvxMacroAssignDialog();
1687 :
1688 : private:
1689 : SfxItemSet m_aItems;
1690 : ::std::auto_ptr< SvxMacroAssignDlg > m_pDialog;
1691 : };
1692 :
1693 0 : short SvxMacroAssignDialog::Execute()
1694 : {
1695 0 : return m_pDialog->Execute();
1696 : }
1697 :
1698 0 : SvxMacroAssignDialog::~SvxMacroAssignDialog()
1699 : {
1700 0 : }
1701 :
1702 0 : VclAbstractDialog * AbstractDialogFactory_Impl::CreateSvxMacroAssignDlg(
1703 : Window* _pParent, const Reference< XFrame >& _rxDocumentFrame, const bool _bUnoDialogMode,
1704 : const Reference< XNameReplace >& _rxEvents, const sal_uInt16 _nInitiallySelectedEvent )
1705 : {
1706 0 : return new SvxMacroAssignDialog( _pParent, _rxDocumentFrame, _bUnoDialogMode, _rxEvents, _nInitiallySelectedEvent );
1707 : }
1708 :
1709 : // Factories for TabPages
1710 0 : CreateTabPage AbstractDialogFactory_Impl::GetTabPageCreatorFunc( sal_uInt16 nId )
1711 : {
1712 0 : switch ( nId )
1713 : {
1714 : case RID_OFA_TP_INTERNATIONAL:
1715 0 : return ::offapp::InternationalOptionsPage::CreateSc;
1716 : case RID_OFA_TP_INTERNATIONAL_SD:
1717 : case RID_OFA_TP_INTERNATIONAL_IMPR:
1718 0 : return offapp::InternationalOptionsPage::CreateSd;
1719 : case RID_SVXPAGE_TEXTANIMATION :
1720 0 : return SvxTextAnimationPage::Create;
1721 : case RID_SVXTABPAGE_GALLERY_GENERAL :
1722 0 : return TPGalleryThemeGeneral::Create;
1723 : case RID_SVXPAGE_TRANSPARENCE :
1724 0 : return SvxTransparenceTabPage::Create;
1725 : case RID_SVXPAGE_AREA :
1726 0 : return SvxAreaTabPage::Create;
1727 : case RID_SVXPAGE_SHADOW :
1728 0 : return SvxShadowTabPage::Create;
1729 : case RID_SVXPAGE_LINE :
1730 0 : return SvxLineTabPage::Create;
1731 : case RID_SVXPAGE_CONNECTION :
1732 0 : return SvxConnectionPage::Create;
1733 : case RID_SVXPAGE_MEASURE :
1734 0 : return SvxMeasurePage::Create;
1735 : case RID_SFXPAGE_GENERAL :
1736 0 : return SvxGeneralTabPage::Create;
1737 : case RID_SVXPAGE_PICK_SINGLE_NUM :
1738 0 : return SvxSingleNumPickTabPage::Create;
1739 : case RID_SVXPAGE_PICK_BMP :
1740 0 : return SvxBitmapPickTabPage::Create;
1741 : case RID_SVXPAGE_PICK_BULLET :
1742 0 : return SvxBulletPickTabPage::Create;
1743 : case RID_SVXPAGE_NUM_OPTIONS :
1744 0 : return SvxNumOptionsTabPage::Create;
1745 : case RID_SVXPAGE_PICK_NUM :
1746 0 : return SvxNumPickTabPage::Create;
1747 : case RID_SVXPAGE_NUM_POSITION :
1748 0 : return SvxNumPositionTabPage::Create;
1749 : case RID_SVXPAGE_PARA_ASIAN :
1750 0 : return SvxAsianTabPage::Create;
1751 : case RID_SVXPAGE_EXT_PARAGRAPH :
1752 0 : return SvxExtParagraphTabPage::Create;
1753 : case RID_SVXPAGE_ALIGN_PARAGRAPH :
1754 0 : return SvxParaAlignTabPage::Create;
1755 : case RID_SVXPAGE_STD_PARAGRAPH :
1756 0 : return SvxStdParagraphTabPage::Create;
1757 : case RID_SVXPAGE_TABULATOR :
1758 0 : return SvxTabulatorTabPage::Create;
1759 : case RID_SVXPAGE_TEXTATTR :
1760 0 : return SvxTextAttrPage::Create;
1761 : case RID_SVXPAGE_ALIGNMENT :
1762 0 : return svx::AlignmentTabPage::Create;
1763 : case RID_SW_TP_BACKGROUND :
1764 : case RID_SVXPAGE_BACKGROUND :
1765 0 : return SvxBackgroundTabPage::Create;
1766 : case RID_SVXPAGE_BORDER :
1767 0 : return SvxBorderTabPage::Create;
1768 : case RID_SVXPAGE_CHAR_NAME :
1769 0 : return SvxCharNamePage::Create;
1770 : case RID_SVXPAGE_CHAR_EFFECTS :
1771 0 : return SvxCharEffectsPage::Create;
1772 : case RID_SVXPAGE_CHAR_POSITION :
1773 0 : return SvxCharPositionPage::Create;
1774 : case RID_SVXPAGE_CHAR_TWOLINES :
1775 0 : return SvxCharTwoLinesPage::Create;
1776 : case RID_SVXPAGE_NUMBERFORMAT :
1777 0 : return SvxNumberFormatTabPage::Create;
1778 : case RID_SVXPAGE_PAGE :
1779 0 : return SvxPageDescPage::Create;
1780 : case RID_SVXPAGE_GRFCROP :
1781 0 : return SvxGrfCropPage::Create;
1782 : case RID_SVXPAGE_MACROASSIGN :
1783 0 : return SfxMacroTabPage::Create;
1784 : default:
1785 0 : break;
1786 : }
1787 :
1788 0 : return 0;
1789 : }
1790 :
1791 0 : CreateSvxDistributePage AbstractDialogFactory_Impl::GetSvxDistributePageCreatorFunc()
1792 : {
1793 0 : return SvxDistributePage::Create;
1794 : }
1795 :
1796 0 : DialogGetRanges AbstractDialogFactory_Impl::GetDialogGetRangesFunc()
1797 : {
1798 0 : return SvxPostItDialog::GetRanges; //add for SvxPostItDialog
1799 : }
1800 :
1801 0 : GetTabPageRanges AbstractDialogFactory_Impl::GetTabPageRangesFunc( sal_uInt16 nId )
1802 : {
1803 0 : switch ( nId )
1804 : {
1805 : case RID_SVXPAGE_TEXTANIMATION :
1806 0 : return SvxTextAnimationPage::GetRanges;
1807 : case RID_SVXPAGE_DISTRIBUTE:
1808 0 : return SvxDistributePage::GetRanges;
1809 : case RID_SVXPAGE_TRANSPARENCE :
1810 0 : return SvxTransparenceTabPage::GetRanges;
1811 : case RID_SVXPAGE_AREA :
1812 0 : return SvxAreaTabPage::GetRanges;
1813 : case RID_SVXPAGE_SHADOW :
1814 0 : return SvxShadowTabPage::GetRanges;
1815 : case RID_SVXPAGE_LINE :
1816 0 : return SvxLineTabPage::GetRanges;
1817 : case RID_SVXPAGE_CONNECTION :
1818 0 : return SvxConnectionPage::GetRanges;
1819 : case RID_SVXPAGE_MEASURE :
1820 0 : return SvxMeasurePage::GetRanges;
1821 : case RID_SVXPAGE_PARA_ASIAN :
1822 0 : return SvxAsianTabPage::GetRanges;
1823 : case RID_SVXPAGE_EXT_PARAGRAPH :
1824 0 : return SvxExtParagraphTabPage::GetRanges;
1825 : case RID_SVXPAGE_ALIGN_PARAGRAPH :
1826 0 : return SvxParaAlignTabPage::GetRanges;
1827 : case RID_SVXPAGE_STD_PARAGRAPH :
1828 0 : return SvxStdParagraphTabPage::GetRanges;
1829 : case RID_SVXPAGE_TABULATOR :
1830 0 : return SvxTabulatorTabPage::GetRanges;
1831 : case RID_SVXPAGE_TEXTATTR :
1832 0 : return SvxTextAttrPage::GetRanges;
1833 : case RID_SVXPAGE_ALIGNMENT :
1834 0 : return svx::AlignmentTabPage::GetRanges;
1835 : case RID_SW_TP_BACKGROUND :
1836 : case RID_SVXPAGE_BACKGROUND :
1837 0 : return SvxBackgroundTabPage::GetRanges;
1838 : case RID_SVXPAGE_BORDER :
1839 0 : return SvxBorderTabPage::GetRanges;
1840 : case RID_SVXPAGE_CHAR_NAME :
1841 0 : return SvxCharNamePage::GetRanges;
1842 : case RID_SVXPAGE_CHAR_EFFECTS :
1843 0 : return SvxCharEffectsPage::GetRanges;
1844 : case RID_SVXPAGE_CHAR_POSITION :
1845 0 : return SvxCharPositionPage::GetRanges;
1846 : case RID_SVXPAGE_CHAR_TWOLINES :
1847 0 : return SvxCharTwoLinesPage::GetRanges;
1848 : case RID_SVXPAGE_NUMBERFORMAT :
1849 0 : return SvxNumberFormatTabPage::GetRanges;
1850 : case RID_SVXPAGE_PAGE :
1851 0 : return SvxPageDescPage::GetRanges;
1852 : case RID_SVXPAGE_ASIAN_LAYOUT:
1853 0 : return SvxAsianLayoutPage::GetRanges;
1854 : default:
1855 0 : break;
1856 : }
1857 :
1858 0 : return 0;
1859 : }
1860 :
1861 0 : SfxAbstractInsertObjectDialog* AbstractDialogFactory_Impl::CreateInsertObjectDialog( Window* pParent, const OUString& rCommand,
1862 : const Reference < com::sun::star::embed::XStorage >& xStor,
1863 : const SvObjectServerList* pList )
1864 : {
1865 0 : InsertObjectDialog_Impl* pDlg=0;
1866 0 : if ( rCommand == ".uno:InsertObject" )
1867 0 : pDlg = new SvInsertOleDlg( pParent, xStor, pList );
1868 0 : else if ( rCommand == ".uno:InsertPlugin" )
1869 0 : pDlg = new SvInsertPlugInDialog( pParent, xStor );
1870 0 : else if ( rCommand == ".uno:InsertObjectFloatingFrame" )
1871 0 : pDlg = new SfxInsertFloatingFrameDialog( pParent, xStor );
1872 :
1873 0 : if ( pDlg )
1874 : {
1875 0 : pDlg->SetHelpId( OUStringToOString( rCommand, RTL_TEXTENCODING_UTF8 ) );
1876 0 : return new AbstractInsertObjectDialog_Impl( pDlg );
1877 : }
1878 0 : return 0;
1879 : }
1880 :
1881 0 : VclAbstractDialog* AbstractDialogFactory_Impl::CreateEditObjectDialog( Window* pParent, const OUString& rCommand,
1882 : const Reference < com::sun::star::embed::XEmbeddedObject >& xObj )
1883 : {
1884 0 : InsertObjectDialog_Impl* pDlg=0;
1885 0 : if ( rCommand == ".uno:InsertObjectFloatingFrame" )
1886 : {
1887 0 : pDlg = new SfxInsertFloatingFrameDialog( pParent, xObj );
1888 0 : pDlg->SetHelpId( OUStringToOString( rCommand, RTL_TEXTENCODING_UTF8 ) );
1889 0 : return new CuiVclAbstractDialog_Impl( pDlg );
1890 : }
1891 0 : return 0;
1892 : }
1893 :
1894 :
1895 :
1896 0 : SfxAbstractPasteDialog* AbstractDialogFactory_Impl::CreatePasteDialog( Window* pParent )
1897 : {
1898 0 : return new AbstractPasteDialog_Impl( new SvPasteObjectDialog( pParent ) );
1899 : }
1900 :
1901 0 : SfxAbstractLinksDialog* AbstractDialogFactory_Impl::CreateLinksDialog( Window* pParent, sfx2::LinkManager* pMgr, sal_Bool bHTML, sfx2::SvBaseLink* p)
1902 : {
1903 0 : SvBaseLinksDlg* pLinkDlg = new SvBaseLinksDlg( pParent, pMgr, bHTML );
1904 0 : if ( p )
1905 0 : pLinkDlg->SetActLink(p);
1906 0 : return new AbstractLinksDialog_Impl( pLinkDlg );
1907 : }
1908 :
1909 0 : SfxAbstractTabDialog* AbstractDialogFactory_Impl::CreateSvxFormatCellsDialog( Window* pParent, const SfxItemSet* pAttr, SdrModel* pModel, const SdrObject* /*pObj*/ )
1910 : {
1911 0 : return new CuiAbstractTabDialog_Impl( new SvxFormatCellsDialog( pParent, pAttr, pModel ) );
1912 : }
1913 :
1914 0 : SvxAbstractSplittTableDialog* AbstractDialogFactory_Impl::CreateSvxSplittTableDialog( Window* pParent, bool bIsTableVertical, long nMaxVertical, long nMaxHorizontal )
1915 : {
1916 0 : return new SvxSplitTableDlg( pParent, bIsTableVertical, nMaxVertical, nMaxHorizontal );
1917 : }
1918 :
1919 0 : SvxAbstractNewTableDialog* AbstractDialogFactory_Impl::CreateSvxNewTableDialog( Window* pParent )
1920 : {
1921 0 : return new SvxNewTableDialog( pParent );
1922 : }
1923 :
1924 0 : VclAbstractDialog* AbstractDialogFactory_Impl::CreateOptionsDialog(
1925 : Window* pParent, const OUString& rExtensionId, const OUString& /*rApplicationContext*/ )
1926 : {
1927 0 : return new CuiVclAbstractDialog_Impl( new OfaTreeOptionsDialog( pParent, rExtensionId ) );
1928 : }
1929 :
1930 0 : SvxAbstractInsRowColDlg* AbstractDialogFactory_Impl::CreateSvxInsRowColDlg( Window* pParent, bool bCol, const OString& sHelpId )
1931 : {
1932 0 : return new SvxInsRowColDlg( pParent, bCol, sHelpId );
1933 : }
1934 :
1935 0 : AbstractPasswordToOpenModifyDialog * AbstractDialogFactory_Impl::CreatePasswordToOpenModifyDialog(
1936 : Window * pParent,
1937 : sal_uInt16 nMinPasswdLen, sal_uInt16 nMaxPasswdLen, bool bIsPasswordToModify )
1938 : {
1939 0 : PasswordToOpenModifyDialog * pDlg = new PasswordToOpenModifyDialog( pParent, nMinPasswdLen, nMaxPasswdLen, bIsPasswordToModify );
1940 0 : return new AbstractPasswordToOpenModifyDialog_Impl( pDlg );
1941 0 : }
1942 :
1943 :
1944 : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|