1*cdf0e10cSrcweir /************************************************************************* 2*cdf0e10cSrcweir * 3*cdf0e10cSrcweir * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4*cdf0e10cSrcweir * 5*cdf0e10cSrcweir * Copyright 2000, 2010 Oracle and/or its affiliates. 6*cdf0e10cSrcweir * 7*cdf0e10cSrcweir * OpenOffice.org - a multi-platform office productivity suite 8*cdf0e10cSrcweir * 9*cdf0e10cSrcweir * This file is part of OpenOffice.org. 10*cdf0e10cSrcweir * 11*cdf0e10cSrcweir * OpenOffice.org is free software: you can redistribute it and/or modify 12*cdf0e10cSrcweir * it under the terms of the GNU Lesser General Public License version 3 13*cdf0e10cSrcweir * only, as published by the Free Software Foundation. 14*cdf0e10cSrcweir * 15*cdf0e10cSrcweir * OpenOffice.org is distributed in the hope that it will be useful, 16*cdf0e10cSrcweir * but WITHOUT ANY WARRANTY; without even the implied warranty of 17*cdf0e10cSrcweir * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18*cdf0e10cSrcweir * GNU Lesser General Public License version 3 for more details 19*cdf0e10cSrcweir * (a copy is included in the LICENSE file that accompanied this code). 20*cdf0e10cSrcweir * 21*cdf0e10cSrcweir * You should have received a copy of the GNU Lesser General Public License 22*cdf0e10cSrcweir * version 3 along with OpenOffice.org. If not, see 23*cdf0e10cSrcweir * <http://www.openoffice.org/license.html> 24*cdf0e10cSrcweir * for a copy of the LGPLv3 License. 25*cdf0e10cSrcweir * 26*cdf0e10cSrcweir ************************************************************************/ 27*cdf0e10cSrcweir 28*cdf0e10cSrcweir #ifndef _LINKDLG_HXX 29*cdf0e10cSrcweir #define _LINKDLG_HXX 30*cdf0e10cSrcweir 31*cdf0e10cSrcweir #ifndef _LSTBOX_HXX //autogen 32*cdf0e10cSrcweir #include <vcl/lstbox.hxx> 33*cdf0e10cSrcweir #endif 34*cdf0e10cSrcweir 35*cdf0e10cSrcweir #include <vcl/dialog.hxx> 36*cdf0e10cSrcweir #include <vcl/fixed.hxx> 37*cdf0e10cSrcweir #include <vcl/button.hxx> 38*cdf0e10cSrcweir #include <vcl/edit.hxx> 39*cdf0e10cSrcweir #include <vcl/lstbox.hxx> 40*cdf0e10cSrcweir 41*cdf0e10cSrcweir #include <svtools/svmedit.hxx> // MultiLineEdit 42*cdf0e10cSrcweir #include <svtools/svtabbx.hxx> // MultiLineEdit 43*cdf0e10cSrcweir 44*cdf0e10cSrcweir /********************** SvUpdateLinksDialog ****************************** 45*cdf0e10cSrcweir *************************************************************************/ 46*cdf0e10cSrcweir namespace sfx2 47*cdf0e10cSrcweir { 48*cdf0e10cSrcweir class LinkManager; 49*cdf0e10cSrcweir class SvBaseLink; 50*cdf0e10cSrcweir } 51*cdf0e10cSrcweir 52*cdf0e10cSrcweir class SvBaseLinksDlg : public ModalDialog 53*cdf0e10cSrcweir { 54*cdf0e10cSrcweir using Window::SetType; 55*cdf0e10cSrcweir 56*cdf0e10cSrcweir FixedText aFtFiles; 57*cdf0e10cSrcweir FixedText aFtLinks; 58*cdf0e10cSrcweir FixedText aFtType; 59*cdf0e10cSrcweir FixedText aFtStatus; 60*cdf0e10cSrcweir SvTabListBox aTbLinks; 61*cdf0e10cSrcweir FixedText aFtFiles2; 62*cdf0e10cSrcweir FixedText aFtFullFileName; 63*cdf0e10cSrcweir FixedText aFtSource2; 64*cdf0e10cSrcweir FixedText aFtFullSourceName; 65*cdf0e10cSrcweir FixedText aFtType2; 66*cdf0e10cSrcweir FixedText aFtFullTypeName; 67*cdf0e10cSrcweir FixedText aFtUpdate; 68*cdf0e10cSrcweir RadioButton aRbAutomatic; 69*cdf0e10cSrcweir RadioButton aRbManual; 70*cdf0e10cSrcweir CancelButton aCancelButton1; 71*cdf0e10cSrcweir HelpButton aHelpButton1; 72*cdf0e10cSrcweir PushButton aPbUpdateNow; 73*cdf0e10cSrcweir PushButton aPbOpenSource; 74*cdf0e10cSrcweir PushButton aPbChangeSource; 75*cdf0e10cSrcweir PushButton aPbBreakLink; 76*cdf0e10cSrcweir String aStrAutolink; 77*cdf0e10cSrcweir String aStrManuallink; 78*cdf0e10cSrcweir String aStrBrokenlink; 79*cdf0e10cSrcweir String aStrGraphiclink; 80*cdf0e10cSrcweir String aStrButtonclose; 81*cdf0e10cSrcweir String aStrCloselinkmsg; 82*cdf0e10cSrcweir String aStrCloselinkmsgMulti; 83*cdf0e10cSrcweir String aStrWaitinglink; 84*cdf0e10cSrcweir sfx2::LinkManager* pLinkMgr; 85*cdf0e10cSrcweir sal_Bool bHtmlMode; 86*cdf0e10cSrcweir Timer aUpdateTimer; 87*cdf0e10cSrcweir 88*cdf0e10cSrcweir #if _SOLAR__PRIVATE 89*cdf0e10cSrcweir DECL_LINK( LinksSelectHdl, SvTabListBox * ); 90*cdf0e10cSrcweir DECL_LINK( LinksDoubleClickHdl, SvTabListBox * ); 91*cdf0e10cSrcweir DECL_LINK( AutomaticClickHdl, RadioButton * ); 92*cdf0e10cSrcweir DECL_LINK( ManualClickHdl, RadioButton * ); 93*cdf0e10cSrcweir DECL_LINK( UpdateNowClickHdl, PushButton * ); 94*cdf0e10cSrcweir DECL_LINK( OpenSourceClickHdl, PushButton * ); 95*cdf0e10cSrcweir DECL_LINK( ChangeSourceClickHdl, PushButton * ); 96*cdf0e10cSrcweir DECL_LINK( BreakLinkClickHdl, PushButton * ); 97*cdf0e10cSrcweir DECL_LINK( UpdateWaitingHdl, Timer * ); 98*cdf0e10cSrcweir DECL_LINK( EndEditHdl, sfx2::SvBaseLink* ); 99*cdf0e10cSrcweir sfx2::SvBaseLink* GetSelEntry( sal_uInt16* pPos ); 100*cdf0e10cSrcweir String ImplGetStateStr( const sfx2::SvBaseLink& ); 101*cdf0e10cSrcweir void SetType( sfx2::SvBaseLink& rLink, sal_uInt16 nPos, sal_uInt16 nType ); 102*cdf0e10cSrcweir void InsertEntry( const sfx2::SvBaseLink& rLink, sal_uInt16 nPos = LISTBOX_APPEND, sal_Bool bSelect = sal_False); 103*cdf0e10cSrcweir #endif 104*cdf0e10cSrcweir 105*cdf0e10cSrcweir void StartUpdateTimer() { aUpdateTimer.Start(); } 106*cdf0e10cSrcweir 107*cdf0e10cSrcweir SvTabListBox& Links() { return aTbLinks; } 108*cdf0e10cSrcweir FixedText& FileName() { return aFtFullFileName; } 109*cdf0e10cSrcweir FixedText& SourceName() { return aFtFullSourceName; } 110*cdf0e10cSrcweir FixedText& TypeName() { return aFtFullTypeName; } 111*cdf0e10cSrcweir RadioButton& Automatic() { return aRbAutomatic; } 112*cdf0e10cSrcweir RadioButton& Manual() { return aRbManual; } 113*cdf0e10cSrcweir PushButton& UpdateNow() { return aPbUpdateNow; } 114*cdf0e10cSrcweir PushButton& OpenSource() { return aPbOpenSource; } 115*cdf0e10cSrcweir PushButton& ChangeSource() { return aPbChangeSource; } 116*cdf0e10cSrcweir PushButton& BreakLink() { return aPbBreakLink; } 117*cdf0e10cSrcweir 118*cdf0e10cSrcweir String& Autolink() { return aStrAutolink; } 119*cdf0e10cSrcweir String& Manuallink() { return aStrManuallink; } 120*cdf0e10cSrcweir String& Brokenlink() { return aStrBrokenlink; } 121*cdf0e10cSrcweir String& Graphiclink() { return aStrGraphiclink; } 122*cdf0e10cSrcweir String& Buttonclose() { return aStrButtonclose; } 123*cdf0e10cSrcweir String& Closelinkmsg() { return aStrCloselinkmsg; } 124*cdf0e10cSrcweir String& CloselinkmsgMulti() { return aStrCloselinkmsgMulti; } 125*cdf0e10cSrcweir String& Waitinglink() { return aStrWaitinglink; } 126*cdf0e10cSrcweir void SetManager( sfx2::LinkManager* ); 127*cdf0e10cSrcweir 128*cdf0e10cSrcweir public: 129*cdf0e10cSrcweir SvBaseLinksDlg( Window * pParent, sfx2::LinkManager*, sal_Bool bHtml = sal_False ); 130*cdf0e10cSrcweir ~SvBaseLinksDlg(); 131*cdf0e10cSrcweir void SetActLink( sfx2::SvBaseLink * pLink ); 132*cdf0e10cSrcweir }; 133*cdf0e10cSrcweir 134*cdf0e10cSrcweir #endif // _LINKDLG_HXX 135