Files
libreoffice/svx/source/dialog/imapdlg.cxx

785 lines
25 KiB
C++
Raw Normal View History

/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
re-base on ALv2 code. Includes: Patch contributed by Christian Lippka impress212: #i113063# patch: dubios self assign in svx/source/dialog/framelink.cxx http://svn.apache.org/viewvc?view=revision&revision=1167619 Patches contributed by Mathias Bauer gnumake4 work variously http://svn.apache.org/viewvc?view=revision&revision=1394707 http://svn.apache.org/viewvc?view=revision&revision=1394326 cws mba34issues01: #i117712#: fix several resource errors introduced by IAccessible2 implementation http://svn.apache.org/viewvc?view=revision&revision=1172343 cws mba34issues01: #i117719#: use correct resource ID http://svn.apache.org/viewvc?view=revision&revision=1172351 Patch contributed by Andre Fischer Do not add targets for junit tests when junit is disabled. http://svn.apache.org/viewvc?view=revision&revision=1241508 Patches contributed by Armin Le-Grand #118804# corrected GraphicExporter behaviour on shortcut when pixel graphic is requested http://svn.apache.org/viewvc?view=revision&revision=1240195 fix for #118525#: Using primitives for chart sub-geometry visualisation http://svn.apache.org/viewvc?view=revision&revision=1226879 #118485# - Styles for OLEs are not saved. http://svn.apache.org/viewvc?view=revision&revision=1182166 #118524: apply patch, followup fixes to 118485 http://svn.apache.org/viewvc?view=revision&revision=1186077 13f79535-47bb-0310-9956-ffa450edef68 Patch contributed by Regina Henschel linecap: Reintegrating finished LineCap feature http://svn.apache.org/viewvc?view=revision&revision=1232507 Patch contributed by Wang Lei (leiw) #i118760# split the first table cell vertically, then undo&redo, the Presentation app will crash http://svn.apache.org/viewvc?view=revision&revision=1301361 cleanup globlmn hacks, undo dependent fixmes.
2012-11-21 22:06:52 +00:00
/*
* This file is part of the LibreOffice project.
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*
* This file incorporates work covered by the following license notice:
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed
* with this work for additional information regarding copyright
* ownership. The ASF licenses this file to you under the Apache
* License, Version 2.0 (the "License"); you may not use this file
* except in compliance with the License. You may obtain a copy of
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
2000-09-18 16:07:07 +00:00
#include <stdlib.h>
#include <tools/errinf.hxx>
#include <tools/urlobj.hxx>
2000-11-10 14:04:21 +00:00
#include <unotools/ucbstreamhelper.hxx>
2000-09-18 16:07:07 +00:00
#include <vcl/msgbox.hxx>
#include <vcl/group.hxx>
#include <vcl/lstbox.hxx>
#include <svl/eitem.hxx>
#include <unotools/pathoptions.hxx>
2000-09-18 16:07:07 +00:00
#include <sfx2/dispatch.hxx>
#include <sfx2/module.hxx>
#include <sfx2/filedlghelper.hxx>
#include "com/sun/star/ui/dialogs/TemplateDescription.hpp"
#include <svl/urihelper.hxx>
2002-07-05 13:55:35 +00:00
#include <svtools/miscopt.hxx>
CWS-TOOLING: integrate CWS impress171 2009-06-02 16:32:02 +0200 cl r272511 : fixed build error 2009-05-29 16:40:09 +0200 cl r272471 : CWS-TOOLING: rebase CWS impress171 to trunk@272291 (milestone: DEV300:m49) 2009-05-19 15:14:08 +0200 sj r272082 : #i101459# applied patch (writing out StyleTextProperties even if no chars given) 2009-05-19 15:09:31 +0200 sj r272081 : #i101459# applied patch (writing out StyleTextProperties even if no chars given) 2009-05-19 15:09:14 +0200 sj r272080 : #i101459# applied patch (writing out StyleTextProperties even if no chars given) 2009-05-18 13:34:05 +0200 sj r272015 : #i47689# fixed rectangles toolbar 2009-05-13 14:59:08 +0200 sj r271862 : #i101563# fixed crash when loading pptx document 2009-05-12 19:31:58 +0200 sj r271835 : #101684# fixed rotation of customshapes 2009-05-08 16:37:01 +0200 sj r271724 : #i101683,i101584,i48160# added shearing of customshapes, fixed rotation problem 2009-04-28 17:32:14 +0200 sj r271335 : #i48160# fixed gluepoint rotation of customshapes 2009-04-27 16:31:54 +0200 cl r271291 : #i100138# applied patch for japanese reconversion feature 2009-04-27 16:30:52 +0200 cl r271290 : #i100138# applied patch for japanese reconversion feature 2009-04-27 16:28:55 +0200 cl r271289 : #i100138# applied patch for japanese reconversion feature 2009-04-23 14:22:59 +0200 cl r271170 : #i95342# #i96820# #i97298# multiple table handling fixes 2009-04-23 14:18:54 +0200 sj r271169 : #i60368# ignoring gamma values for toolbar/menu icons 2009-04-23 11:54:28 +0200 cl r271146 : #i97298# set style to text even during text edit 2009-04-23 11:46:38 +0200 cl r271145 : fixed compiler error with debug 2009-04-22 19:09:37 +0200 sj r271135 : #i101051# applied patch (proper import of notes page object) 2009-04-22 11:07:54 +0200 cl r271082 : #i96820# modify doc after merging cells 2009-04-22 10:57:35 +0200 cl r271081 : #i100307# applied patch from jlcheng to correctly set modfiy state 2009-04-22 10:31:11 +0200 cl r271079 : #i96736# copy merge information on clone 2009-04-21 08:27:22 +0200 cl r271016 : #i89541# use SfxErrorContext to make the ErrorHandler dialog modal 2009-04-20 17:52:56 +0200 cl r271003 : #i98480# removed 'EndPosition' and 'StartPosition' from styles 2009-04-20 16:41:55 +0200 cl r270994 : #i98403# fixed state handling for selected motion path 2009-04-17 11:35:25 +0200 cl r270931 : #i61274# export to pdf should behave like printing considering layer visibility 2009-04-17 10:00:17 +0200 cl r270924 : #i98967# set default style on any new shape except a page obj 2009-04-16 16:28:20 +0200 cl r270893 : #i98859# use percentage type for relative font height
2009-06-17 10:58:14 +00:00
#include <svtools/ehdl.hxx>
#include <svtools/sfxecode.hxx>
2000-09-18 16:07:07 +00:00
#include <sfx2/viewfrm.hxx>
#include <sfx2/objsh.hxx>
#include <sfx2/docfile.hxx>
#include <unotools/localedatawrapper.hxx>
#include <comphelper/processfactory.hxx>
#include <vcl/layout.hxx>
#include <svx/imapdlg.hxx>
#include <svx/dialmgr.hxx>
#include <svx/dialogs.hrc>
#include <svx/svxids.hrc>
2000-09-18 16:07:07 +00:00
#include "imapdlg.hrc"
#include "imapwnd.hxx"
#include "imapimp.hxx"
#include "svx/dlgutil.hxx"
#include <svx/svdtrans.hxx>
#include <svx/svdopath.hxx>
#include <vcl/svapp.hxx>
#include <vcl/settings.hxx>
#include "dlgunit.hxx"
#include <boost/scoped_ptr.hpp>
2000-09-18 16:07:07 +00:00
#define SELF_TARGET "_self"
#define IMAP_ALL_FILTER OUString("<Alle>")
#define IMAP_CERN_FILTER OUString("MAP - CERN")
#define IMAP_NCSA_FILTER OUString("MAP - NCSA")
#define IMAP_BINARY_FILTER OUString("SIP - StarView ImageMap")
#define IMAP_ALL_TYPE OUString("*.*")
#define IMAP_BINARY_TYPE OUString("*.sip")
#define IMAP_CERN_TYPE OUString("*.map")
#define IMAP_NCSA_TYPE OUString("*.map")
2000-09-18 16:07:07 +00:00
SFX_IMPL_MODELESSDIALOG_WITHID( SvxIMapDlgChildWindow, SID_IMAP );
2000-09-18 16:07:07 +00:00
// ControllerItem
2000-09-18 16:07:07 +00:00
SvxIMapDlgItem::SvxIMapDlgItem( sal_uInt16 _nId, SvxIMapDlg& rIMapDlg, SfxBindings& rBindings ) :
SfxControllerItem ( _nId, rBindings ),
2000-09-18 16:07:07 +00:00
rIMap ( rIMapDlg )
{
}
void SvxIMapDlgItem::StateChanged( sal_uInt16 nSID, SfxItemState /*eState*/,
2000-09-18 16:07:07 +00:00
const SfxPoolItem* pItem )
{
if ( ( nSID == SID_IMAP_EXEC ) && pItem )
{
const SfxBoolItem* pStateItem = PTR_CAST( SfxBoolItem, pItem );
assert(pStateItem); //SfxBoolItem expected
if (pStateItem)
{
// Disable Float if possible
rIMap.SetExecState( !pStateItem->GetValue() );
}
2000-09-18 16:07:07 +00:00
}
}
SvxIMapDlgChildWindow::SvxIMapDlgChildWindow( vcl::Window* _pParent, sal_uInt16 nId,
2000-09-18 16:07:07 +00:00
SfxBindings* pBindings,
SfxChildWinInfo* pInfo ) :
SfxChildWindow( _pParent, nId )
2000-09-18 16:07:07 +00:00
{
pWindow = new SvxIMapDlg( pBindings, this, _pParent );
SvxIMapDlg* pDlg = static_cast<SvxIMapDlg*>(pWindow);
2000-09-18 16:07:07 +00:00
if ( pInfo->nFlags & SfxChildWindowFlags::ZOOMIN )
2000-09-18 16:07:07 +00:00
pDlg->RollUp();
eChildAlignment = SfxChildAlignment::NOALIGNMENT;
pDlg->Initialize( pInfo );
2000-09-18 16:07:07 +00:00
}
void SvxIMapDlgChildWindow::UpdateIMapDlg( const Graphic& rGraphic, const ImageMap* pImageMap,
const TargetList* pTargetList, void* pEditingObj )
{
SvxIMapDlg* pDlg = GetIMapDlg();
if (pDlg)
pDlg->UpdateLink(rGraphic, pImageMap, pTargetList, pEditingObj);
2000-09-18 16:07:07 +00:00
}
extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeStatusBar(vcl::Window *pParent, VclBuilder::stringmap &)
{
return new StatusBar(pParent);
}
SvxIMapDlg::SvxIMapDlg(SfxBindings *_pBindings, SfxChildWindow *pCW, vcl::Window* _pParent)
: SfxModelessDialog(_pBindings, pCW, _pParent, "ImapDialog", "svx/ui/imapdialog.ui")
, pCheckObj(NULL)
, aIMapItem(SID_IMAP_EXEC, *this, *_pBindings)
2000-09-18 16:07:07 +00:00
{
get(m_pTbxIMapDlg1, "toolbar");
m_pTbxIMapDlg1->InsertSeparator(3, 5);
m_pTbxIMapDlg1->InsertSeparator(9, 5);
m_pTbxIMapDlg1->InsertSeparator(14, 5);
m_pTbxIMapDlg1->InsertSeparator(17, 5);
mnApplyId = m_pTbxIMapDlg1->GetItemId("TBI_APPLY");
mnOpenId = m_pTbxIMapDlg1->GetItemId("TBI_OPEN");
mnSaveAsId = m_pTbxIMapDlg1->GetItemId("TBI_SAVEAS");
mnSelectId = m_pTbxIMapDlg1->GetItemId("TBI_SELECT");
mnRectId = m_pTbxIMapDlg1->GetItemId("TBI_RECT");
mnCircleId = m_pTbxIMapDlg1->GetItemId("TBI_CIRCLE");
mnPolyId = m_pTbxIMapDlg1->GetItemId("TBI_POLY");
mnFreePolyId = m_pTbxIMapDlg1->GetItemId("TBI_FREEPOLY");
mnPolyEditId = m_pTbxIMapDlg1->GetItemId("TBI_POLYEDIT");
mnPolyMoveId = m_pTbxIMapDlg1->GetItemId("TBI_POLYMOVE");
mnPolyInsertId = m_pTbxIMapDlg1->GetItemId("TBI_POLYINSERT");
mnPolyDeleteId = m_pTbxIMapDlg1->GetItemId("TBI_POLYDELETE");
mnUndoId = m_pTbxIMapDlg1->GetItemId("TBI_UNDO");
mnRedoId = m_pTbxIMapDlg1->GetItemId("TBI_REDO");
mnActiveId = m_pTbxIMapDlg1->GetItemId("TBI_ACTIVE");
mnMacroId = m_pTbxIMapDlg1->GetItemId("TBI_MACRO");
mnPropertyId = m_pTbxIMapDlg1->GetItemId("TBI_PROPERTY");
get(m_pFtURL, "urlft");
get(m_pURLBox, "url");
get(m_pFtText, "textft");
get(m_pEdtText, "text");
get(m_pFtTarget, "targetft");
get(m_pCbbTarget, "target");
//lock this down so it doesn't jump around in size
//as entries are added later on
TargetList aTmpList;
SfxFrame::GetDefaultTargetList(aTmpList);
for (size_t i = 0, n = aTmpList.size(); i < n; ++i)
m_pCbbTarget->InsertEntry(aTmpList[i]);
Size aPrefSize(m_pCbbTarget->get_preferred_size());
m_pCbbTarget->set_width_request(aPrefSize.Width());
m_pCbbTarget->Clear();
get(m_pStbStatus, "statusbar");
VclVBox* _pContainer = get<VclVBox>("container");
pIMapWnd = new IMapWindow( _pContainer, WB_BORDER, _pBindings->GetActiveFrame() );
pIMapWnd->set_hexpand(true);
pIMapWnd->set_vexpand(true);
pIMapWnd->Show();
2002-04-12 10:54:45 +00:00
pOwnData = new IMapOwnData;
2000-09-18 16:07:07 +00:00
pIMapWnd->SetInfoLink( LINK( this, SvxIMapDlg, InfoHdl ) );
pIMapWnd->SetMousePosLink( LINK( this, SvxIMapDlg, MousePosHdl ) );
pIMapWnd->SetGraphSizeLink( LINK( this, SvxIMapDlg, GraphSizeHdl ) );
pIMapWnd->SetUpdateLink( LINK( this, SvxIMapDlg, StateHdl ) );
m_pURLBox->SetModifyHdl( LINK( this, SvxIMapDlg, URLModifyHdl ) );
m_pURLBox->SetSelectHdl( LINK( this, SvxIMapDlg, URLModifyHdl ) );
m_pURLBox->SetLoseFocusHdl( LINK( this, SvxIMapDlg, URLLoseFocusHdl ) );
m_pEdtText->SetModifyHdl( LINK( this, SvxIMapDlg, URLModifyHdl ) );
m_pCbbTarget->SetLoseFocusHdl( LINK( this, SvxIMapDlg, URLLoseFocusHdl ) );
2000-09-18 16:07:07 +00:00
2002-07-05 13:55:35 +00:00
SvtMiscOptions aMiscOptions;
aMiscOptions.AddListenerLink( LINK( this, SvxIMapDlg, MiscHdl ) );
2002-07-05 13:55:35 +00:00
m_pTbxIMapDlg1->SetSelectHdl( LINK( this, SvxIMapDlg, TbxClickHdl ) );
m_pTbxIMapDlg1->CheckItem( mnSelectId, true );
TbxClickHdl( m_pTbxIMapDlg1 );
2000-09-18 16:07:07 +00:00
SetMinOutputSizePixel( aLastSize = GetOutputSizePixel() );
m_pStbStatus->InsertItem( 1, 130, SIB_LEFT | SIB_IN | SIB_AUTOSIZE );
m_pStbStatus->InsertItem( 2, 10 + GetTextWidth( OUString(" 9999,99 cm / 9999,99 cm ") ), SIB_CENTER | SIB_IN );
m_pStbStatus->InsertItem( 3, 10 + GetTextWidth( OUString(" 9999,99 cm x 9999,99 cm ") ), SIB_CENTER | SIB_IN );
2000-09-18 16:07:07 +00:00
m_pFtURL->Disable();
m_pURLBox->Disable();
m_pFtText->Disable();
m_pEdtText->Disable();
m_pFtTarget->Disable();
m_pCbbTarget->Disable();
pOwnData->bExecState = false;
2000-09-18 16:07:07 +00:00
pOwnData->aIdle.SetPriority( SchedulerPriority::LOW );
pOwnData->aIdle.SetIdleHdl( LINK( this, SvxIMapDlg, UpdateHdl ) );
2000-09-18 16:07:07 +00:00
m_pTbxIMapDlg1->EnableItem( mnActiveId, false );
m_pTbxIMapDlg1->EnableItem( mnMacroId, false );
m_pTbxIMapDlg1->EnableItem( mnPropertyId, false );
2000-09-18 16:07:07 +00:00
}
SvxIMapDlg::~SvxIMapDlg()
{
// Delete URL-List
2000-09-18 16:07:07 +00:00
delete pIMapWnd;
delete pOwnData;
}
bool SvxIMapDlg::Close()
2000-09-18 16:07:07 +00:00
{
bool bRet = true;
2000-09-18 16:07:07 +00:00
if ( m_pTbxIMapDlg1->IsItemEnabled( mnApplyId ) )
2000-09-18 16:07:07 +00:00
{
MessageDialog aQBox( this,"QueryModifyImageMapChangesDialog","svx/ui/querymodifyimagemapchangesdialog.ui");
2000-09-18 16:07:07 +00:00
const long nRet = aQBox.Execute();
if( nRet == RET_YES )
{
SfxBoolItem aBoolItem( SID_IMAP_EXEC, true );
2000-09-18 16:07:07 +00:00
GetBindings().GetDispatcher()->Execute(
SID_IMAP_EXEC, SfxCallMode::SYNCHRON | SfxCallMode::RECORD, &aBoolItem, 0L );
2000-09-18 16:07:07 +00:00
}
else if( nRet == RET_CANCEL )
bRet = false;
2000-09-18 16:07:07 +00:00
}
else if( pIMapWnd->IsChanged() )
{
MessageDialog aQBox( this,"QuerySaveImageMapChangesDialog","svx/ui/querysaveimagemapchangesdialog.ui");
2000-09-18 16:07:07 +00:00
const long nRet = aQBox.Execute();
if( nRet == RET_YES )
bRet = DoSave();
else if( nRet == RET_CANCEL )
bRet = false;
2000-09-18 16:07:07 +00:00
}
return( bRet ? SfxModelessDialog::Close() : sal_False );
2000-09-18 16:07:07 +00:00
}
// Enabled or disable all Controls
2000-09-18 16:07:07 +00:00
void SvxIMapDlg::SetExecState( bool bEnable )
2000-09-18 16:07:07 +00:00
{
pOwnData->bExecState = bEnable;
}
void SvxIMapDlg::SetGraphic( const Graphic& rGraphic )
{
pIMapWnd->SetGraphic( rGraphic );
}
void SvxIMapDlg::SetImageMap( const ImageMap& rImageMap )
{
pIMapWnd->SetImageMap( rImageMap );
}
const ImageMap& SvxIMapDlg::GetImageMap() const
{
return pIMapWnd->GetImageMap();
}
void SvxIMapDlg::SetTargetList( const TargetList& rTargetList )
{
TargetList aNewList( rTargetList );
2000-09-18 16:07:07 +00:00
pIMapWnd->SetTargetList( aNewList );
m_pCbbTarget->Clear();
2000-09-18 16:07:07 +00:00
for ( size_t i = 0, n = aNewList.size(); i < n; ++i )
m_pCbbTarget->InsertEntry( aNewList[ i ] );
2000-09-18 16:07:07 +00:00
}
void SvxIMapDlg::UpdateLink( const Graphic& rGraphic, const ImageMap* pImageMap,
2000-09-18 16:07:07 +00:00
const TargetList* pTargetList, void* pEditingObj )
{
pOwnData->aUpdateGraphic = rGraphic;
if ( pImageMap )
pOwnData->aUpdateImageMap = *pImageMap;
else
pOwnData->aUpdateImageMap.ClearImageMap();
pOwnData->pUpdateEditingObject = pEditingObj;
// Delete UpdateTargetList, because this method can still be called several
// times before the update timer is turned on
pOwnData->aUpdateTargetList.clear();
2000-09-18 16:07:07 +00:00
// TargetList must be copied, since it is owned by the caller and can be
// deleted immediately after this call the copied list will be deleted
// again in the handler
2000-09-18 16:07:07 +00:00
if( pTargetList )
{
TargetList aTargetList( *pTargetList );
for ( size_t i = 0, n = aTargetList.size(); i < n; ++i )
pOwnData->aUpdateTargetList.push_back( aTargetList[ i ] );
2000-09-18 16:07:07 +00:00
}
pOwnData->aIdle.Start();
2000-09-18 16:07:07 +00:00
}
void SvxIMapDlg::KeyInput( const KeyEvent& rKEvt )
{
2002-05-14 08:12:45 +00:00
SfxModelessDialog::KeyInput( rKEvt );
}
// Click-handler for ToolBox
2000-09-18 16:07:07 +00:00
IMPL_LINK( SvxIMapDlg, TbxClickHdl, ToolBox*, pTbx )
{
sal_uInt16 nNewItemId = pTbx->GetCurItemId();
2000-09-18 16:07:07 +00:00
if(nNewItemId == mnApplyId)
2000-09-18 16:07:07 +00:00
{
URLLoseFocusHdl( NULL );
SfxBoolItem aBoolItem( SID_IMAP_EXEC, true );
GetBindings().GetDispatcher()->Execute(
SID_IMAP_EXEC, SfxCallMode::ASYNCHRON | SfxCallMode::RECORD, &aBoolItem, 0L );
}
else if(nNewItemId == mnOpenId)
DoOpen();
else if(nNewItemId == mnSaveAsId)
2000-09-18 16:07:07 +00:00
DoSave();
else if(nNewItemId == mnSelectId)
{
pTbx->CheckItem( nNewItemId, true );
pIMapWnd->SetEditMode( true );
if( pTbx->IsKeyEvent() )
2000-09-18 16:07:07 +00:00
{
if((pTbx->GetKeyModifier() & KEY_MOD1) != 0)
pIMapWnd->SelectFirstObject();
else
2002-04-12 10:54:45 +00:00
pIMapWnd->GrabFocus();
2000-09-18 16:07:07 +00:00
}
}
else if(nNewItemId == mnRectId)
{
pTbx->CheckItem( nNewItemId, true );
pIMapWnd->SetObjKind( OBJ_RECT );
if( pTbx->IsKeyEvent() && ((pTbx->GetKeyModifier() & KEY_MOD1) != 0) )
2000-09-18 16:07:07 +00:00
{
pIMapWnd->CreateDefaultObject();
pIMapWnd->GrabFocus();
2000-09-18 16:07:07 +00:00
}
}
else if(nNewItemId == mnCircleId)
{
pTbx->CheckItem( nNewItemId, true );
pIMapWnd->SetObjKind( OBJ_CIRC );
if( pTbx->IsKeyEvent() && ((pTbx->GetKeyModifier() & KEY_MOD1) != 0) )
2000-09-18 16:07:07 +00:00
{
pIMapWnd->CreateDefaultObject();
pIMapWnd->GrabFocus();
2000-09-18 16:07:07 +00:00
}
}
else if(nNewItemId == mnPolyId)
{
pTbx->CheckItem( nNewItemId, true );
pIMapWnd->SetObjKind( OBJ_POLY );
if( pTbx->IsKeyEvent() && ((pTbx->GetKeyModifier() & KEY_MOD1) != 0) )
{
pIMapWnd->CreateDefaultObject();
pIMapWnd->GrabFocus();
}
}
else if(nNewItemId == mnFreePolyId)
{
pTbx->CheckItem( nNewItemId, true );
pIMapWnd->SetObjKind( OBJ_FREEFILL );
if( pTbx->IsKeyEvent() && ((pTbx->GetKeyModifier() & KEY_MOD1) != 0) )
{
pIMapWnd->CreateDefaultObject();
pIMapWnd->GrabFocus();
}
}
else if(nNewItemId == mnActiveId)
{
URLLoseFocusHdl( NULL );
bool bNewState = !pTbx->IsItemChecked( TBI_ACTIVE );
pTbx->CheckItem( TBI_ACTIVE, bNewState );
pIMapWnd->SetCurrentObjState( !bNewState );
}
else if(nNewItemId == mnMacroId)
pIMapWnd->DoMacroAssign();
else if(nNewItemId == mnPropertyId)
pIMapWnd->DoPropertyDialog();
else if(nNewItemId == mnPolyEditId)
{
pIMapWnd->SetPolyEditMode( pTbx->IsItemChecked( TBI_POLYEDIT ) ? SID_BEZIER_MOVE : 0 );
if( pTbx->IsKeyEvent() && pTbx->IsItemChecked( TBI_POLYEDIT ) )
pIMapWnd->StartPolyEdit();
}
else if(nNewItemId == mnPolyMoveId)
pIMapWnd->SetPolyEditMode( SID_BEZIER_MOVE );
else if(nNewItemId == mnPolyInsertId)
pIMapWnd->SetPolyEditMode( SID_BEZIER_INSERT );
else if(nNewItemId == mnPolyDeleteId)
pIMapWnd->GetSdrView()->DeleteMarkedPoints();
else if(nNewItemId == mnUndoId)
{
URLLoseFocusHdl( NULL );
pIMapWnd->GetSdrModel()->Undo();
}
else if(nNewItemId == mnRedoId)
{
URLLoseFocusHdl( NULL );
pIMapWnd->GetSdrModel()->Redo();
2000-09-18 16:07:07 +00:00
}
return 0;
}
void SvxIMapDlg::DoOpen()
{
::sfx2::FileDialogHelper aDlg(
com::sun::star::ui::dialogs::TemplateDescription::FILEOPEN_SIMPLE, 0 );
2000-09-18 16:07:07 +00:00
ImageMap aLoadIMap;
const OUString aFilter( IMAP_ALL_FILTER );
2000-09-18 16:07:07 +00:00
aDlg.AddFilter( aFilter, IMAP_ALL_TYPE );
aDlg.AddFilter( IMAP_CERN_FILTER, IMAP_CERN_TYPE );
aDlg.AddFilter( IMAP_NCSA_FILTER, IMAP_NCSA_TYPE );
aDlg.AddFilter( IMAP_BINARY_FILTER, IMAP_BINARY_TYPE );
2000-09-18 16:07:07 +00:00
aDlg.SetCurrentFilter( aFilter );
aDlg.SetDisplayDirectory( SvtPathOptions().GetWorkPath() );
2000-09-18 16:07:07 +00:00
if( aDlg.Execute() == ERRCODE_NONE )
2000-09-18 16:07:07 +00:00
{
2000-11-10 14:04:21 +00:00
INetURLObject aURL( aDlg.GetPath() );
DBG_ASSERT( aURL.GetProtocol() != INetProtocol::NotValid, "invalid URL" );
boost::scoped_ptr<SvStream> pIStm(::utl::UcbStreamHelper::CreateStream( aURL.GetMainURL( INetURLObject::NO_DECODE ), StreamMode::READ ));
2000-09-18 16:07:07 +00:00
2000-11-10 14:04:21 +00:00
if( pIStm )
2000-09-18 16:07:07 +00:00
{
aLoadIMap.Read( *pIStm, IMAP_FORMAT_DETECT, "" );
2000-09-18 16:07:07 +00:00
2000-11-10 14:04:21 +00:00
if( pIStm->GetError() )
CWS-TOOLING: integrate CWS impress171 2009-06-02 16:32:02 +0200 cl r272511 : fixed build error 2009-05-29 16:40:09 +0200 cl r272471 : CWS-TOOLING: rebase CWS impress171 to trunk@272291 (milestone: DEV300:m49) 2009-05-19 15:14:08 +0200 sj r272082 : #i101459# applied patch (writing out StyleTextProperties even if no chars given) 2009-05-19 15:09:31 +0200 sj r272081 : #i101459# applied patch (writing out StyleTextProperties even if no chars given) 2009-05-19 15:09:14 +0200 sj r272080 : #i101459# applied patch (writing out StyleTextProperties even if no chars given) 2009-05-18 13:34:05 +0200 sj r272015 : #i47689# fixed rectangles toolbar 2009-05-13 14:59:08 +0200 sj r271862 : #i101563# fixed crash when loading pptx document 2009-05-12 19:31:58 +0200 sj r271835 : #101684# fixed rotation of customshapes 2009-05-08 16:37:01 +0200 sj r271724 : #i101683,i101584,i48160# added shearing of customshapes, fixed rotation problem 2009-04-28 17:32:14 +0200 sj r271335 : #i48160# fixed gluepoint rotation of customshapes 2009-04-27 16:31:54 +0200 cl r271291 : #i100138# applied patch for japanese reconversion feature 2009-04-27 16:30:52 +0200 cl r271290 : #i100138# applied patch for japanese reconversion feature 2009-04-27 16:28:55 +0200 cl r271289 : #i100138# applied patch for japanese reconversion feature 2009-04-23 14:22:59 +0200 cl r271170 : #i95342# #i96820# #i97298# multiple table handling fixes 2009-04-23 14:18:54 +0200 sj r271169 : #i60368# ignoring gamma values for toolbar/menu icons 2009-04-23 11:54:28 +0200 cl r271146 : #i97298# set style to text even during text edit 2009-04-23 11:46:38 +0200 cl r271145 : fixed compiler error with debug 2009-04-22 19:09:37 +0200 sj r271135 : #i101051# applied patch (proper import of notes page object) 2009-04-22 11:07:54 +0200 cl r271082 : #i96820# modify doc after merging cells 2009-04-22 10:57:35 +0200 cl r271081 : #i100307# applied patch from jlcheng to correctly set modfiy state 2009-04-22 10:31:11 +0200 cl r271079 : #i96736# copy merge information on clone 2009-04-21 08:27:22 +0200 cl r271016 : #i89541# use SfxErrorContext to make the ErrorHandler dialog modal 2009-04-20 17:52:56 +0200 cl r271003 : #i98480# removed 'EndPosition' and 'StartPosition' from styles 2009-04-20 16:41:55 +0200 cl r270994 : #i98403# fixed state handling for selected motion path 2009-04-17 11:35:25 +0200 cl r270931 : #i61274# export to pdf should behave like printing considering layer visibility 2009-04-17 10:00:17 +0200 cl r270924 : #i98967# set default style on any new shape except a page obj 2009-04-16 16:28:20 +0200 cl r270893 : #i98859# use percentage type for relative font height
2009-06-17 10:58:14 +00:00
{
SfxErrorContext eEC(ERRCODE_SFX_GENERAL,this);
2000-09-18 16:07:07 +00:00
ErrorHandler::HandleError( ERRCODE_IO_GENERAL );
CWS-TOOLING: integrate CWS impress171 2009-06-02 16:32:02 +0200 cl r272511 : fixed build error 2009-05-29 16:40:09 +0200 cl r272471 : CWS-TOOLING: rebase CWS impress171 to trunk@272291 (milestone: DEV300:m49) 2009-05-19 15:14:08 +0200 sj r272082 : #i101459# applied patch (writing out StyleTextProperties even if no chars given) 2009-05-19 15:09:31 +0200 sj r272081 : #i101459# applied patch (writing out StyleTextProperties even if no chars given) 2009-05-19 15:09:14 +0200 sj r272080 : #i101459# applied patch (writing out StyleTextProperties even if no chars given) 2009-05-18 13:34:05 +0200 sj r272015 : #i47689# fixed rectangles toolbar 2009-05-13 14:59:08 +0200 sj r271862 : #i101563# fixed crash when loading pptx document 2009-05-12 19:31:58 +0200 sj r271835 : #101684# fixed rotation of customshapes 2009-05-08 16:37:01 +0200 sj r271724 : #i101683,i101584,i48160# added shearing of customshapes, fixed rotation problem 2009-04-28 17:32:14 +0200 sj r271335 : #i48160# fixed gluepoint rotation of customshapes 2009-04-27 16:31:54 +0200 cl r271291 : #i100138# applied patch for japanese reconversion feature 2009-04-27 16:30:52 +0200 cl r271290 : #i100138# applied patch for japanese reconversion feature 2009-04-27 16:28:55 +0200 cl r271289 : #i100138# applied patch for japanese reconversion feature 2009-04-23 14:22:59 +0200 cl r271170 : #i95342# #i96820# #i97298# multiple table handling fixes 2009-04-23 14:18:54 +0200 sj r271169 : #i60368# ignoring gamma values for toolbar/menu icons 2009-04-23 11:54:28 +0200 cl r271146 : #i97298# set style to text even during text edit 2009-04-23 11:46:38 +0200 cl r271145 : fixed compiler error with debug 2009-04-22 19:09:37 +0200 sj r271135 : #i101051# applied patch (proper import of notes page object) 2009-04-22 11:07:54 +0200 cl r271082 : #i96820# modify doc after merging cells 2009-04-22 10:57:35 +0200 cl r271081 : #i100307# applied patch from jlcheng to correctly set modfiy state 2009-04-22 10:31:11 +0200 cl r271079 : #i96736# copy merge information on clone 2009-04-21 08:27:22 +0200 cl r271016 : #i89541# use SfxErrorContext to make the ErrorHandler dialog modal 2009-04-20 17:52:56 +0200 cl r271003 : #i98480# removed 'EndPosition' and 'StartPosition' from styles 2009-04-20 16:41:55 +0200 cl r270994 : #i98403# fixed state handling for selected motion path 2009-04-17 11:35:25 +0200 cl r270931 : #i61274# export to pdf should behave like printing considering layer visibility 2009-04-17 10:00:17 +0200 cl r270924 : #i98967# set default style on any new shape except a page obj 2009-04-16 16:28:20 +0200 cl r270893 : #i98859# use percentage type for relative font height
2009-06-17 10:58:14 +00:00
}
2000-11-10 14:04:21 +00:00
else
pIMapWnd->SetImageMap( aLoadIMap );
2000-09-18 16:07:07 +00:00
}
pIMapWnd->Invalidate();
2000-09-18 16:07:07 +00:00
}
}
bool SvxIMapDlg::DoSave()
2000-09-18 16:07:07 +00:00
{
::sfx2::FileDialogHelper aDlg(
com::sun::star::ui::dialogs::TemplateDescription::FILESAVE_SIMPLE, 0 );
const OUString aBinFilter( IMAP_BINARY_FILTER );
const OUString aCERNFilter( IMAP_CERN_FILTER );
const OUString aNCSAFilter( IMAP_NCSA_FILTER );
2000-09-18 16:07:07 +00:00
SdrModel* pModel = pIMapWnd->GetSdrModel();
const bool bChanged = pModel->IsChanged();
bool bRet = false;
2000-09-18 16:07:07 +00:00
aDlg.AddFilter( aCERNFilter, IMAP_CERN_TYPE );
aDlg.AddFilter( aNCSAFilter, IMAP_NCSA_TYPE );
aDlg.AddFilter( aBinFilter, IMAP_BINARY_TYPE );
2000-09-18 16:07:07 +00:00
aDlg.SetCurrentFilter( aCERNFilter );
aDlg.SetDisplayDirectory( SvtPathOptions().GetWorkPath() );
2000-09-18 16:07:07 +00:00
if( aDlg.Execute() == ERRCODE_NONE )
2000-09-18 16:07:07 +00:00
{
const OUString aFilter( aDlg.GetCurrentFilter() );
OUString aExt;
sal_uIntPtr nFormat;
2000-09-18 16:07:07 +00:00
if ( aFilter == aBinFilter )
{
nFormat = IMAP_FORMAT_BIN;
aExt = "sip";
2000-09-18 16:07:07 +00:00
}
else if ( aFilter == aCERNFilter )
{
nFormat = IMAP_FORMAT_CERN;
aExt = "map";
2000-09-18 16:07:07 +00:00
}
else if ( aFilter == aNCSAFilter )
{
nFormat = IMAP_FORMAT_NCSA;
aExt = "map";
2000-09-18 16:07:07 +00:00
}
else
{
return false;
}
2000-09-18 16:07:07 +00:00
2000-11-10 14:04:21 +00:00
INetURLObject aURL( aDlg.GetPath() );
2000-09-18 16:07:07 +00:00
if( aURL.GetProtocol() == INetProtocol::NotValid )
2000-09-18 16:07:07 +00:00
{
2011-03-01 19:07:44 +01:00
OSL_FAIL( "invalid URL" );
2000-09-18 16:07:07 +00:00
}
2000-11-10 14:04:21 +00:00
else
{
if( aURL.getExtension().isEmpty() )
2000-11-10 14:04:21 +00:00
aURL.setExtension( aExt );
2000-09-18 16:07:07 +00:00
boost::scoped_ptr<SvStream> pOStm(::utl::UcbStreamHelper::CreateStream( aURL.GetMainURL( INetURLObject::NO_DECODE ), StreamMode::WRITE | StreamMode::TRUNC ));
2000-11-10 14:04:21 +00:00
if( pOStm )
{
pIMapWnd->GetImageMap().Write( *pOStm, nFormat, "" );
2000-09-18 16:07:07 +00:00
2000-11-10 14:04:21 +00:00
if( pOStm->GetError() )
ErrorHandler::HandleError( ERRCODE_IO_GENERAL );
2000-09-18 16:07:07 +00:00
pOStm.reset();
2000-11-10 14:04:21 +00:00
pModel->SetChanged( bChanged );
bRet = true;
2000-11-10 14:04:21 +00:00
}
}
2000-09-18 16:07:07 +00:00
}
return bRet;
}
IMPL_LINK( SvxIMapDlg, InfoHdl, IMapWindow*, pWnd )
{
OUString aStr;
2000-09-18 16:07:07 +00:00
const NotifyInfo& rInfo = pWnd->GetInfo();
if ( rInfo.bNewObj )
{
if( !rInfo.aMarkURL.isEmpty() && ( m_pURLBox->GetEntryPos( rInfo.aMarkURL ) == LISTBOX_ENTRY_NOTFOUND ) )
m_pURLBox->InsertEntry( rInfo.aMarkURL );
2000-09-18 16:07:07 +00:00
m_pURLBox->SetText( rInfo.aMarkURL );
m_pEdtText->SetText( rInfo.aMarkAltText );
2000-09-18 16:07:07 +00:00
if ( rInfo.aMarkTarget.isEmpty() )
m_pCbbTarget->SetText( SELF_TARGET );
2000-09-18 16:07:07 +00:00
else
m_pCbbTarget->SetText( rInfo.aMarkTarget );
2000-09-18 16:07:07 +00:00
}
if ( !rInfo.bOneMarked )
{
m_pTbxIMapDlg1->CheckItem( mnActiveId, false );
m_pTbxIMapDlg1->EnableItem( mnActiveId, false );
m_pTbxIMapDlg1->EnableItem( mnMacroId, false );
m_pTbxIMapDlg1->EnableItem( mnPropertyId, false );
m_pStbStatus->SetItemText( 1, aStr );
m_pFtURL->Disable();
m_pURLBox->Disable();
m_pFtText->Disable();
m_pEdtText->Disable();
m_pFtTarget->Disable();
m_pCbbTarget->Disable();
m_pURLBox->SetText( "" );
m_pEdtText->SetText( "" );
2000-09-18 16:07:07 +00:00
}
else
{
m_pTbxIMapDlg1->EnableItem( mnActiveId, true );
m_pTbxIMapDlg1->CheckItem( mnActiveId, !rInfo.bActivated );
m_pTbxIMapDlg1->EnableItem( mnMacroId, true );
m_pTbxIMapDlg1->EnableItem( mnPropertyId, true );
2000-09-18 16:07:07 +00:00
m_pFtURL->Enable();
m_pURLBox->Enable();
m_pFtText->Enable();
m_pEdtText->Enable();
m_pFtTarget->Enable();
m_pCbbTarget->Enable();
2000-09-18 16:07:07 +00:00
m_pStbStatus->SetItemText( 1, rInfo.aMarkURL );
2000-09-18 16:07:07 +00:00
if ( m_pURLBox->GetText() != OUString(rInfo.aMarkURL) )
m_pURLBox->SetText( rInfo.aMarkURL );
2000-09-18 16:07:07 +00:00
if ( m_pEdtText->GetText() != OUString(rInfo.aMarkAltText) )
m_pEdtText->SetText( rInfo.aMarkAltText );
2000-09-18 16:07:07 +00:00
if ( rInfo.aMarkTarget.isEmpty() )
m_pCbbTarget->SetText( SELF_TARGET );
2000-09-18 16:07:07 +00:00
else
m_pCbbTarget->SetText( rInfo.aMarkTarget );
2000-09-18 16:07:07 +00:00
}
return 0;
}
IMPL_LINK( SvxIMapDlg, MousePosHdl, IMapWindow*, pWnd )
{
const FieldUnit eFieldUnit = GetBindings().GetDispatcher()->GetModule()->GetFieldUnit();
const Point& rMousePos = pWnd->GetMousePos();
const LocaleDataWrapper& rLocaleWrapper( Application::GetSettings().GetLocaleDataWrapper() );
const sal_Unicode cSep = rLocaleWrapper.getNumDecimalSep()[0];
2000-09-18 16:07:07 +00:00
OUString aStr = GetUnitString( rMousePos.X(), eFieldUnit, cSep ) +
" / " + GetUnitString( rMousePos.Y(), eFieldUnit, cSep );
2000-09-18 16:07:07 +00:00
m_pStbStatus->SetItemText( 2, aStr );
2000-09-18 16:07:07 +00:00
return 0L;
}
IMPL_LINK( SvxIMapDlg, GraphSizeHdl, IMapWindow*, pWnd )
{
const FieldUnit eFieldUnit = GetBindings().GetDispatcher()->GetModule()->GetFieldUnit();
2000-09-18 16:07:07 +00:00
const Size& rSize = pWnd->GetGraphicSize();
const LocaleDataWrapper& rLocaleWrapper( Application::GetSettings().GetLocaleDataWrapper() );
const sal_Unicode cSep = rLocaleWrapper.getNumDecimalSep()[0];
2000-09-18 16:07:07 +00:00
OUString aStr = GetUnitString( rSize.Width(), eFieldUnit, cSep ) +
" x " + GetUnitString( rSize.Height(), eFieldUnit, cSep );
2000-09-18 16:07:07 +00:00
m_pStbStatus->SetItemText( 3, aStr );
2000-09-18 16:07:07 +00:00
return 0L;
}
IMPL_LINK_NOARG(SvxIMapDlg, URLModifyHdl)
2000-09-18 16:07:07 +00:00
{
NotifyInfo aNewInfo;
aNewInfo.aMarkURL = m_pURLBox->GetText();
aNewInfo.aMarkAltText = m_pEdtText->GetText();
aNewInfo.aMarkTarget = m_pCbbTarget->GetText();
2000-09-18 16:07:07 +00:00
pIMapWnd->ReplaceActualIMapInfo( aNewInfo );
return 0;
}
IMPL_LINK_NOARG(SvxIMapDlg, URLLoseFocusHdl)
2000-09-18 16:07:07 +00:00
{
NotifyInfo aNewInfo;
const OUString aURLText( m_pURLBox->GetText() );
const OUString aTargetText( m_pCbbTarget->GetText() );
2000-09-18 16:07:07 +00:00
if ( !aURLText.isEmpty() )
2000-09-18 16:07:07 +00:00
{
OUString aBase = GetBindings().GetDispatcher()->GetFrame()->GetObjectShell()->GetMedium()->GetBaseURL();
aNewInfo.aMarkURL = ::URIHelper::SmartRel2Abs( INetURLObject(aBase), aURLText, URIHelper::GetMaybeFileHdl(), true, false,
2000-09-18 16:07:07 +00:00
INetURLObject::WAS_ENCODED,
INetURLObject::DECODE_UNAMBIGUOUS );
}
else
aNewInfo.aMarkURL = aURLText;
aNewInfo.aMarkAltText = m_pEdtText->GetText();
2000-09-18 16:07:07 +00:00
if ( aTargetText.isEmpty() )
aNewInfo.aMarkTarget = SELF_TARGET;
2000-09-18 16:07:07 +00:00
else
aNewInfo.aMarkTarget = aTargetText;
pIMapWnd->ReplaceActualIMapInfo( aNewInfo );
return 0;
}
IMPL_LINK_NOARG(SvxIMapDlg, UpdateHdl)
2000-09-18 16:07:07 +00:00
{
pOwnData->aIdle.Stop();
2000-09-18 16:07:07 +00:00
if ( pOwnData->pUpdateEditingObject != pCheckObj )
{
if ( pIMapWnd->IsChanged() &&
( MessageDialog( this,"QuerySaveImageMapChangesDialog",
"svx/ui/querysaveimagemapchangesdialog.ui" ).Execute() == RET_YES ) )
2000-09-18 16:07:07 +00:00
{
DoSave();
}
SetGraphic( pOwnData->aUpdateGraphic );
SetImageMap( pOwnData->aUpdateImageMap );
SetTargetList( pOwnData->aUpdateTargetList );
SetEditingObject( pOwnData->pUpdateEditingObject );
// After changes => default selection
m_pTbxIMapDlg1->CheckItem( mnSelectId, true );
pIMapWnd->SetEditMode( true );
2000-09-18 16:07:07 +00:00
}
// Delete the copied list again in the Update method
pOwnData->aUpdateTargetList.clear();
2000-09-18 16:07:07 +00:00
GetBindings().Invalidate( SID_IMAP_EXEC );
return 0L;
}
IMPL_LINK( SvxIMapDlg, StateHdl, IMapWindow*, pWnd )
{
const SdrObject* pObj = pWnd->GetSelectedSdrObject();
const SdrModel* pModel = pWnd->GetSdrModel();
const SdrView* pView = pWnd->GetSdrView();
const bool bPolyEdit = ( pObj != NULL ) && pObj->ISA( SdrPathObj );
const bool bDrawEnabled = !( bPolyEdit && m_pTbxIMapDlg1->IsItemChecked( mnPolyEditId ) );
2000-09-18 16:07:07 +00:00
m_pTbxIMapDlg1->EnableItem( mnApplyId, pOwnData->bExecState && pWnd->IsChanged() );
2000-09-18 16:07:07 +00:00
m_pTbxIMapDlg1->EnableItem( mnSelectId, bDrawEnabled );
m_pTbxIMapDlg1->EnableItem( mnRectId, bDrawEnabled );
m_pTbxIMapDlg1->EnableItem( mnCircleId, bDrawEnabled );
m_pTbxIMapDlg1->EnableItem( mnPolyId, bDrawEnabled );
m_pTbxIMapDlg1->EnableItem( mnFreePolyId, bDrawEnabled );
2000-09-18 16:07:07 +00:00
// BezierEditor State
m_pTbxIMapDlg1->EnableItem( mnPolyEditId, bPolyEdit );
m_pTbxIMapDlg1->EnableItem( mnPolyMoveId, !bDrawEnabled );
m_pTbxIMapDlg1->EnableItem( mnPolyInsertId, !bDrawEnabled );
m_pTbxIMapDlg1->EnableItem( mnPolyDeleteId, !bDrawEnabled && pView->IsDeleteMarkedPointsPossible() );
2000-09-18 16:07:07 +00:00
// Undo/Redo
m_pTbxIMapDlg1->EnableItem( mnUndoId, pModel->HasUndoActions() );
m_pTbxIMapDlg1->EnableItem( mnRedoId, pModel->HasRedoActions() );
2000-09-18 16:07:07 +00:00
if ( bPolyEdit )
{
sal_uInt16 nId = 0;
2000-09-18 16:07:07 +00:00
switch( pWnd->GetPolyEditMode() )
{
case( SID_BEZIER_MOVE ): nId = mnPolyMoveId; break;
case( SID_BEZIER_INSERT ): nId = mnPolyInsertId; break;
2000-09-18 16:07:07 +00:00
default:
break;
}
m_pTbxIMapDlg1->CheckItem( nId, true );
2000-09-18 16:07:07 +00:00
}
else
{
m_pTbxIMapDlg1->CheckItem( mnPolyEditId, false );
m_pTbxIMapDlg1->CheckItem( mnPolyMoveId, true );
m_pTbxIMapDlg1->CheckItem( mnPolyInsertId, false );
2000-09-18 16:07:07 +00:00
pWnd->SetPolyEditMode( 0 );
}
return 0L;
}
IMPL_LINK_NOARG(SvxIMapDlg, MiscHdl)
2002-07-05 13:55:35 +00:00
{
SvtMiscOptions aMiscOptions;
m_pTbxIMapDlg1->SetOutStyle( aMiscOptions.GetToolboxStyle() );
2000-09-18 16:07:07 +00:00
2002-07-05 13:55:35 +00:00
return 0L;
}
2002-07-11 09:48:07 +00:00
SvxIMapDlg* GetIMapDlg()
{
SfxChildWindow* pWnd = NULL;
if (SfxViewFrame::Current() && SfxViewFrame::Current()->HasChildWindow(SvxIMapDlgChildWindow::GetChildWindowId()))
pWnd = SfxViewFrame::Current()->GetChildWindow(SvxIMapDlgChildWindow::GetChildWindowId());
return pWnd ? static_cast<SvxIMapDlg*>(pWnd->GetWindow()) : NULL;
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */