Branch data Line data Source code
1 : : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 : : /*************************************************************************
3 : : *
4 : : * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 : : *
6 : : * Copyright 2000, 2010 Oracle and/or its affiliates.
7 : : *
8 : : * OpenOffice.org - a multi-platform office productivity suite
9 : : *
10 : : * This file is part of OpenOffice.org.
11 : : *
12 : : * OpenOffice.org is free software: you can redistribute it and/or modify
13 : : * it under the terms of the GNU Lesser General Public License version 3
14 : : * only, as published by the Free Software Foundation.
15 : : *
16 : : * OpenOffice.org is distributed in the hope that it will be useful,
17 : : * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 : : * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 : : * GNU Lesser General Public License version 3 for more details
20 : : * (a copy is included in the LICENSE file that accompanied this code).
21 : : *
22 : : * You should have received a copy of the GNU Lesser General Public License
23 : : * version 3 along with OpenOffice.org. If not, see
24 : : * <http://www.openoffice.org/license.html>
25 : : * for a copy of the LGPLv3 License.
26 : : *
27 : : ************************************************************************/
28 : :
29 : : #ifndef _GLOSBIB_HXX
30 : : #define _GLOSBIB_HXX
31 : :
32 : : #include <vcl/edit.hxx>
33 : : #include <svx/stddlg.hxx>
34 : :
35 : : #include <vcl/lstbox.hxx>
36 : : #include <svtools/svtabbx.hxx>
37 : :
38 : : #include <vcl/button.hxx>
39 : : #include <vcl/fixed.hxx>
40 : :
41 : : #include <vector>
42 : :
43 : : class SwGlossaryHdl;
44 : :
45 : 0 : class FEdit : public Edit
46 : : {
47 : : public:
48 : 0 : FEdit(Window * pParent, const ResId& rResId) :
49 : 0 : Edit(pParent, rResId){}
50 : :
51 : : virtual void KeyInput( const KeyEvent& rKEvent );
52 : : };
53 : :
54 : 0 : struct GlosBibUserData
55 : : {
56 : : String sPath;
57 : : String sGroupName;
58 : : String sGroupTitle;
59 : : };
60 : :
61 : 0 : class SwGlossaryGroupTLB : public SvTabListBox
62 : : {
63 : : public:
64 : 0 : SwGlossaryGroupTLB(Window* pParent, const ResId& rResId) :
65 : 0 : SvTabListBox(pParent, rResId) {}
66 : :
67 : : virtual void RequestHelp( const HelpEvent& rHEvt );
68 : : };
69 : :
70 : : class SwGlossaryGroupDlg : public SvxStandardDialog
71 : : {
72 : : FixedText aBibFT;
73 : : FEdit aNameED;
74 : : FixedText aPathFT;
75 : : ListBox aPathLB;
76 : : FixedText aSelectFT;
77 : : SwGlossaryGroupTLB aGroupTLB;
78 : :
79 : : OKButton aOkPB;
80 : : CancelButton aCancelPB;
81 : : HelpButton aHelpPB;
82 : : PushButton aNewPB;
83 : : PushButton aDelPB;
84 : : PushButton aRenamePB;
85 : :
86 : : typedef std::vector< ::rtl::OUString> OUVector_t;
87 : : OUVector_t m_RemovedArr;
88 : : OUVector_t m_InsertedArr;
89 : : OUVector_t m_RenamedArr;
90 : :
91 : : SwGlossaryHdl *pGlosHdl;
92 : :
93 : : String sCreatedGroup;
94 : :
95 : : sal_Bool IsDeleteAllowed(const String &rGroup);
96 : :
97 : : protected:
98 : : virtual void Apply();
99 : : DECL_LINK( SelectHdl, SvTabListBox* );
100 : : DECL_LINK(NewHdl, void *);
101 : : DECL_LINK( DeleteHdl, Button* );
102 : : DECL_LINK(ModifyHdl, void *);
103 : : DECL_LINK(RenameHdl, void *);
104 : :
105 : : public:
106 : : SwGlossaryGroupDlg(Window * pParent,
107 : : std::vector<String> const& rPathArr,
108 : : SwGlossaryHdl *pGlosHdl);
109 : : ~SwGlossaryGroupDlg();
110 : :
111 : 0 : const String& GetCreatedGroupName() const {return sCreatedGroup;}
112 : : };
113 : :
114 : : #endif
115 : :
116 : : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|