1 /************************************************************************* 2 * 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * Copyright 2000, 2010 Oracle and/or its affiliates. 6 * 7 * OpenOffice.org - a multi-platform office productivity suite 8 * 9 * This file is part of OpenOffice.org. 10 * 11 * OpenOffice.org is free software: you can redistribute it and/or modify 12 * it under the terms of the GNU Lesser General Public License version 3 13 * only, as published by the Free Software Foundation. 14 * 15 * OpenOffice.org is distributed in the hope that it will be useful, 16 * but WITHOUT ANY WARRANTY; without even the implied warranty of 17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18 * GNU Lesser General Public License version 3 for more details 19 * (a copy is included in the LICENSE file that accompanied this code). 20 * 21 * You should have received a copy of the GNU Lesser General Public License 22 * version 3 along with OpenOffice.org. If not, see 23 * <http://www.openoffice.org/license.html> 24 * for a copy of the LGPLv3 License. 25 * 26 ************************************************************************/ 27 #ifndef _SWFLDREF_HXX 28 #define _SWFLDREF_HXX 29 30 #include <sfx2/tabdlg.hxx> 31 #include <vcl/fixed.hxx> 32 #include <vcl/lstbox.hxx> 33 #ifndef _SV_BUTTON_HXX //autogen 34 #include <vcl/button.hxx> 35 #endif 36 #include <vcl/group.hxx> 37 #include <vcl/edit.hxx> 38 39 #include "fldpage.hxx" 40 // --> OD 2007-11-15 #i83479# 41 #include <IDocumentOutlineNodes.hxx> 42 #include <IDocumentListItems.hxx> 43 #include <FldRefTreeListBox.hxx> 44 class SwTxtNode; 45 // <-- 46 47 /*-------------------------------------------------------------------- 48 Beschreibung: 49 --------------------------------------------------------------------*/ 50 51 class SwFldRefPage : public SwFldPage 52 { 53 FixedText aTypeFT; 54 ListBox aTypeLB; 55 FixedText aSelectionFT; 56 ListBox aSelectionLB; 57 // --> OD 2007-11-21 #i83479# 58 SwFldRefTreeListBox aSelectionToolTipLB; 59 // <-- 60 FixedText aFormatFT; 61 ListBox aFormatLB; 62 FixedText aNameFT; 63 Edit aNameED; 64 FixedText aValueFT; 65 Edit aValueED; 66 const String sBookmarkTxt; 67 const String sFootnoteTxt; 68 const String sEndnoteTxt; 69 // --> OD 2007-11-09 #i83479# 70 const String sHeadingTxt; 71 const String sNumItemTxt; 72 73 IDocumentOutlineNodes::tSortedOutlineNodeList maOutlineNodes; 74 IDocumentListItems::tSortedNodeNumList maNumItems; 75 76 // selected text node in the listbox for headings and numbered items 77 // in order to restore selection after update of selection listbox 78 const SwTxtNode* mpSavedSelectedTxtNode; 79 // fallback, if previously selected text node doesn't exist anymore 80 sal_uInt16 mnSavedSelectedPos; 81 // <-- 82 83 DECL_LINK( TypeHdl, ListBox* pLB = 0 ); 84 DECL_LINK( SubTypeHdl, ListBox* pLB = 0 ); 85 DECL_LINK( ModifyHdl, Edit *pEd = 0 ); 86 87 void UpdateSubType(); 88 sal_uInt16 FillFormatLB(sal_uInt16 nTypeId); 89 90 // --> OD 2007-12-05 #i83479# 91 void SaveSelectedTxtNode(); 92 const SwTxtNode* GetSavedSelectedTxtNode() const; 93 sal_uInt16 GetSavedSelectedPos() const; 94 // <-- 95 96 protected: 97 virtual sal_uInt16 GetGroup(); 98 99 public: 100 SwFldRefPage(Window* pParent, const SfxItemSet& rSet); 101 102 ~SwFldRefPage(); 103 104 static SfxTabPage* Create(Window* pParent, const SfxItemSet& rAttrSet); 105 106 virtual sal_Bool FillItemSet( SfxItemSet& rSet ); 107 virtual void Reset( const SfxItemSet& rSet ); 108 109 virtual void FillUserData(); 110 }; 111 112 113 #endif 114 115