merge the formfield patch from ooo-build
[ooovba.git] / svx / source / cui / cuisrchdlg.cxx
blob6cbe6268d0fcb96b6ff3c823cdfad15b18eb5641
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: cuisrchdlg.cxx,v $
10 * $Revision: 1.11 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
31 // MARKER(update_precomp.py): autogen include statement, do not remove
32 #include "precompiled_svx.hxx"
34 #ifdef SVX_DLLIMPLEMENTATION
35 #undef SVX_DLLIMPLEMENTATION
36 #endif
38 // include ---------------------------------------------------------------
39 #include <vcl/wrkwin.hxx>
40 #include <vcl/morebtn.hxx>
41 #include <vcl/msgbox.hxx>
42 #include <svtools/slstitm.hxx>
43 #include <svtools/itemiter.hxx>
44 #include <svtools/style.hxx>
45 #include <svtools/searchopt.hxx>
46 #include <sfx2/dispatch.hxx>
47 #include <sfx2/objsh.hxx>
48 #include <sfx2/module.hxx>
49 #include <sfx2/viewsh.hxx>
50 #include <sfx2/basedlgs.hxx>
51 #include <svtools/cjkoptions.hxx>
52 #include <com/sun/star/i18n/TransliterationModules.hpp>
54 #define _CUI_SRCHDLG_CXX
55 #include "cuisrchdlg.hxx"
57 #include <svx/dialogs.hrc>
58 #include <svx/svxitems.hrc>
59 //#include "srchdlg.hrc"
62 #define ITEMID_SETITEM 0
64 #include <sfx2/srchitem.hxx>
65 #include <svx/pageitem.hxx>
66 //#include "srchctrl.hxx"
67 //CHINA001 #include "srchxtra.hxx"
68 #include <svx/dialmgr.hxx>
69 #include "dlgutil.hxx"
70 #include <optjsearch.hxx>
71 #include <svx/brshitem.hxx>
72 #include "backgrnd.hxx"
75 // class SvxJSearchOptionsDialog -----------------------------------------
77 SvxJSearchOptionsDialog::SvxJSearchOptionsDialog(
78 Window *pParent,
79 const SfxItemSet& rOptionsSet, USHORT /*nUniqueId*/, INT32 nInitialFlags ) :
80 SfxSingleTabDialog ( pParent, rOptionsSet, RID_SVXPAGE_JSEARCH_OPTIONS ),
81 nInitialTlFlags( nInitialFlags )
83 pPage = (SvxJSearchOptionsPage *)
84 SvxJSearchOptionsPage::Create( this, rOptionsSet );
85 SetTabPage( pPage ); //! implicitly calls pPage->Reset(...)!
86 pPage->EnableSaveOptions( FALSE );
90 SvxJSearchOptionsDialog::~SvxJSearchOptionsDialog()
92 // pPage will be implicitly destroyed by the
93 // SfxSingleTabDialog destructor
97 void SvxJSearchOptionsDialog::Activate()
99 pPage->SetTransliterationFlags( nInitialTlFlags );
103 INT32 SvxJSearchOptionsDialog::GetTransliterationFlags() const
105 return pPage->GetTransliterationFlags();
109 void SvxJSearchOptionsDialog::SetTransliterationFlags( INT32 nSettings )
111 pPage->SetTransliterationFlags( nSettings );