merge the formfield patch from ooo-build
[ooovba.git] / sc / source / ui / inc / dbnamdlg.hxx
blob69abc2bf1888979e128153965162f1e5df7325cf
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: dbnamdlg.hxx,v $
10 * $Revision: 1.5 $
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 #ifndef SC_DBNAMDLG_HXX
32 #define SC_DBNAMDLG_HXX
34 #ifndef _COMBOBOX_HXX //autogen
35 #include <vcl/combobox.hxx>
36 #endif
38 #ifndef _FIXED_HXX //autogen
39 #include <vcl/fixed.hxx>
40 #endif
42 #ifndef _MOREBTN_HXX //autogen
43 #include <vcl/morebtn.hxx>
44 #endif
45 #include "anyrefdg.hxx"
46 #include "dbcolect.hxx"
47 #include "expftext.hxx"
49 class ScViewData;
50 class ScDocument;
53 //============================================================================
55 class ScDbNameDlg : public ScAnyRefDlg
57 public:
58 ScDbNameDlg( SfxBindings* pB, SfxChildWindow* pCW, Window* pParent,
59 ScViewData* ptrViewData );
60 ~ScDbNameDlg();
62 virtual void SetReference( const ScRange& rRef, ScDocument* pDoc );
64 virtual BOOL IsRefInputMode() const;
65 virtual void SetActive();
66 virtual BOOL Close();
68 private:
69 FixedLine aFlName;
70 ComboBox aEdName;
72 FixedLine aFlAssign;
73 formula::RefEdit aEdAssign;
74 formula::RefButton aRbAssign;
76 FixedLine aFlOptions;
77 CheckBox aBtnHeader;
78 CheckBox aBtnDoSize;
79 CheckBox aBtnKeepFmt;
80 CheckBox aBtnStripData;
81 ScExpandedFixedText aFTSource; //@18.09.97 erweiterter FixedText
82 FixedText aFTOperations;
84 OKButton aBtnOk;
85 CancelButton aBtnCancel;
86 HelpButton aBtnHelp;
87 PushButton aBtnAdd;
88 PushButton aBtnRemove;
89 MoreButton aBtnMore;
91 BOOL bSaved;
94 const String aStrAdd; // "Hinzufuegen"
95 const String aStrModify; // "Aendern"
96 const String aStrNoName; // "unbenannt"
97 const String aStrInvalid;
99 String aStrSource;
100 String aStrOperations;
102 ScViewData* pViewData;
103 ScDocument* pDoc;
104 BOOL bRefInputMode;
105 ScAddress::Details aAddrDetails;
107 ScDBCollection aLocalDbCol;
108 ScRange theCurArea;
109 List aRemoveList;
111 #ifdef _DBNAMDLG_CXX
112 private:
113 void Init();
114 void UpdateNames();
115 void UpdateDBData( const String& rStrName );
116 void SetInfoStrings( const ScDBData* pDBData );
118 DECL_LINK( CancelBtnHdl, void * );
119 DECL_LINK( OkBtnHdl, void * );
120 DECL_LINK( AddBtnHdl, void * );
121 DECL_LINK( RemoveBtnHdl, void * );
122 DECL_LINK( NameModifyHdl, void * );
123 DECL_LINK( AssModifyHdl, void * );
124 #endif
129 #endif // SC_DBNAMDLG_HXX