fdo#74697 Add Bluez 5 support for impress remote.
[LibreOffice.git] / include / svx / imapdlg.hxx
blob9afd8b01a6fa02e147756742eb3b213829cf236c
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
21 #ifndef _IMAPDLG_HXX_
22 #define _IMAPDLG_HXX_
24 #include <svtools/inettbc.hxx>
25 #include <sfx2/childwin.hxx>
26 #include <sfx2/ctrlitem.hxx>
27 #include <sfx2/basedlgs.hxx>
29 #include <vcl/fixed.hxx>
31 #include <vcl/combobox.hxx>
33 #include <vcl/edit.hxx>
35 #include <vcl/toolbox.hxx>
37 #include <vcl/status.hxx>
38 #include "svx/svxdllapi.h"
39 #include <vector>
42 #ifndef _GOMISC_HXX
43 class ImageMap;
44 #endif
47 /*************************************************************************
49 |* Derivation from SfxChildWindow as "container" for float
51 \************************************************************************/
53 class Graphic;
54 typedef ::std::vector< String* > TargetList;
56 class SVX_DLLPUBLIC SvxIMapDlgChildWindow : public SfxChildWindow
58 public:
60 SvxIMapDlgChildWindow( Window*, sal_uInt16, SfxBindings*, SfxChildWinInfo* );
62 SFX_DECL_CHILDWINDOW_WITHID( SvxIMapDlgChildWindow );
64 static void UpdateIMapDlg( const Graphic& rGraphic, const ImageMap* pImageMap = NULL,
65 const TargetList* pTargetList = NULL, void* pEditingObj = NULL );
69 #ifndef _REDUCED_IMAPDLG_HXX_
70 #define _REDUCED_IMAPDLG_HXX_
72 class SvxIMapDlg;
74 class SvxIMapDlgItem : public SfxControllerItem
76 SvxIMapDlg& rIMap;
79 protected:
81 virtual void StateChanged( sal_uInt16 nSID, SfxItemState eState,
82 const SfxPoolItem* pState );
85 public:
87 SvxIMapDlgItem( sal_uInt16 nId, SvxIMapDlg& rIMapDlg, SfxBindings& rBindings );
90 class IMapOwnData;
91 class IMapWindow;
93 class SVX_DLLPUBLIC SvxIMapDlg : public SfxModelessDialog // SfxFloatingWindow
95 friend class IMapOwnData;
96 friend class IMapWindow;
97 using Window::Update;
99 ToolBox aTbxIMapDlg1;
100 FixedText aFtURL;
101 SvtURLBox maURLBox;
102 FixedText aFtText;
103 Edit aEdtText;
104 FixedText maFtTarget;
105 ComboBox maCbbTarget;
106 StatusBar aStbStatus;
107 ImageList maImageList;
109 Size aLastSize;
110 IMapWindow* pIMapWnd;
111 IMapOwnData* pOwnData;
112 void* pCheckObj;
113 SvxIMapDlgItem aIMapItem;
115 virtual void Resize();
116 virtual sal_Bool Close();
118 #ifdef _IMAPDLG_PRIVATE
120 DECL_LINK( TbxClickHdl, ToolBox* );
121 DECL_LINK( InfoHdl, IMapWindow* );
122 DECL_LINK( MousePosHdl, IMapWindow* );
123 DECL_LINK( GraphSizeHdl, IMapWindow* );
124 DECL_LINK( URLModifyHdl, void* );
125 DECL_LINK( URLLoseFocusHdl, void* );
126 DECL_LINK(UpdateHdl, void *);
127 DECL_LINK( TbxUpdateHdl, Timer* );
128 DECL_LINK( StateHdl, IMapWindow* );
129 DECL_LINK( MiscHdl, void* );
131 void DoOpen();
132 sal_Bool DoSave();
134 #endif
137 public:
139 SvxIMapDlg( SfxBindings *pBindings, SfxChildWindow *pCW,
140 Window* pParent, const ResId& rResId );
141 ~SvxIMapDlg();
143 void SetExecState( sal_Bool bEnable );
145 void SetGraphic( const Graphic& rGraphic );
147 void SetEditingObject( void* pObj ) { pCheckObj = pObj; }
148 const void* GetEditingObject() const { return pCheckObj; }
150 void SetImageMap( const ImageMap& rImageMap );
151 const ImageMap& GetImageMap() const;
153 void SetTargetList( const TargetList& rTargetList );
155 void Update( const Graphic& rGraphic, const ImageMap* pImageMap = NULL,
156 const TargetList* pTargetList = NULL, void* pEditingObj = NULL );
158 virtual void KeyInput( const KeyEvent& rKEvt );
160 virtual void DataChanged( const DataChangedEvent& rDCEvt );
161 void ApplyImageList();
165 /*************************************************************************
167 |* Defines
169 \************************************************************************/
171 #define SVXIMAPDLG() ( (SvxIMapDlg*) ( SfxViewFrame::Current()->GetChildWindow( \
172 SvxIMapDlgChildWindow::GetChildWindowId() )-> \
173 GetWindow() ) )
176 #endif // _REDUCED_IMAPDLG_HXX_
177 #endif // _IMAPDLG_HXX_
180 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */