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