update dev300-m58
[ooovba.git] / svx / source / dialog / SpellDialogChildWindow.cxx
blobd5e99df85761c9a4217e73ef782e651b2926ffd2
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: SpellDialogChildWindow.cxx,v $
10 * $Revision: 1.8 $
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"
33 #include <svx/SpellDialogChildWindow.hxx>
35 #include <svx/svxdlg.hxx>
37 namespace svx {
39 /*-------------------------------------------------------------------------
41 -----------------------------------------------------------------------*/
42 SpellDialogChildWindow::SpellDialogChildWindow (
43 Window* _pParent,
44 USHORT nId,
45 SfxBindings* pBindings,
46 SfxChildWinInfo* /*pInfo*/)
47 : SfxChildWindow (_pParent, nId)
51 SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
52 DBG_ASSERT(pFact, "SvxAbstractDialogFactory::Create() failed");
53 m_pAbstractSpellDialog = pFact->CreateSvxSpellDialog(_pParent,
54 pBindings,
55 this );
56 pWindow = m_pAbstractSpellDialog->GetWindow();
57 eChildAlignment = SFX_ALIGN_NOALIGNMENT;
58 SetHideNotDelete (TRUE);
60 /*-------------------------------------------------------------------------
62 -----------------------------------------------------------------------*/
63 SpellDialogChildWindow::~SpellDialogChildWindow (void)
66 /*-------------------------------------------------------------------------
68 -----------------------------------------------------------------------*/
69 SfxBindings& SpellDialogChildWindow::GetBindings (void) const
71 OSL_ASSERT (m_pAbstractSpellDialog != NULL);
72 return m_pAbstractSpellDialog->GetBindings();
74 /*-------------------------------------------------------------------------
76 -----------------------------------------------------------------------*/
77 void SpellDialogChildWindow::InvalidateSpellDialog()
79 OSL_ASSERT (m_pAbstractSpellDialog != NULL);
80 if(m_pAbstractSpellDialog)
81 m_pAbstractSpellDialog->Invalidate();
83 /*-------------------------------------------------------------------------
85 -----------------------------------------------------------------------*/
86 bool SpellDialogChildWindow::HasAutoCorrection()
88 return false;
90 /*-------------------------------------------------------------------------
92 -----------------------------------------------------------------------*/
93 void SpellDialogChildWindow::AddAutoCorrection(
94 const String& /*rOld*/,
95 const String& /*rNew*/,
96 LanguageType /*eLanguage*/)
98 DBG_ERROR("AutoCorrection should have been overloaded - if available");
100 /*-- 16.06.2008 10:11:57---------------------------------------------------
102 -----------------------------------------------------------------------*/
103 bool SpellDialogChildWindow::HasGrammarChecking()
105 return false;
107 /*-- 18.06.2008 12:26:35---------------------------------------------------
109 -----------------------------------------------------------------------*/
110 bool SpellDialogChildWindow::IsGrammarChecking()
112 DBG_ERROR("Grammar checking should have been overloaded - if available");
113 return false;
115 /*-- 18.06.2008 12:26:35---------------------------------------------------
117 -----------------------------------------------------------------------*/
118 void SpellDialogChildWindow::SetGrammarChecking(bool )
120 DBG_ERROR("Grammar checking should have been overloaded - if available");
122 } // end of namespace ::svx