From 4c26083959637ffa9ca8bc1eed99f3c218447123 Mon Sep 17 00:00:00 2001 From: Manal Alhassoun Date: Thu, 26 Dec 2013 15:11:57 +0300 Subject: convert save and modify imageMaps queryboxes to .ui MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: I222ce47187e46f7de9916bd559846d28c30d4562 Reviewed-on: https://gerrit.libreoffice.org/7201 Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara --- svx/UIConfig_svx.mk | 2 + svx/source/dialog/imapdlg.cxx | 11 +++-- svx/source/dialog/imapdlg.hrc | 7 --- svx/source/dialog/imapdlg.src | 9 ---- .../ui/querymodifyimagemapchangesdialog.ui | 52 ++++++++++++++++++++++ svx/uiconfig/ui/querysaveimagemapchangesdialog.ui | 52 ++++++++++++++++++++++ 6 files changed, 111 insertions(+), 22 deletions(-) create mode 100644 svx/uiconfig/ui/querymodifyimagemapchangesdialog.ui create mode 100644 svx/uiconfig/ui/querysaveimagemapchangesdialog.ui diff --git a/svx/UIConfig_svx.mk b/svx/UIConfig_svx.mk index f2a8087fb13e..e82509cbc76a 100644 --- a/svx/UIConfig_svx.mk +++ b/svx/UIConfig_svx.mk @@ -28,8 +28,10 @@ $(eval $(call gb_UIConfig_add_uifiles,svx,\ svx/uiconfig/ui/optgridpage \ svx/uiconfig/ui/passwd \ svx/uiconfig/ui/querydeletecontourdialog \ + svx/uiconfig/ui/querymodifyimagemapchangesdialog \ svx/uiconfig/ui/querynewcontourdialog \ svx/uiconfig/ui/querysavecontchangesdialog \ + svx/uiconfig/ui/querysaveimagemapchangesdialog \ svx/uiconfig/ui/queryunlinkgraphicsdialog \ svx/uiconfig/ui/redlinecontrol \ svx/uiconfig/ui/redlinefilterpage \ diff --git a/svx/source/dialog/imapdlg.cxx b/svx/source/dialog/imapdlg.cxx index 8c1b46ffd9ea..3cc0bb635d03 100644 --- a/svx/source/dialog/imapdlg.cxx +++ b/svx/source/dialog/imapdlg.cxx @@ -40,6 +40,7 @@ #include #include #include +#include #define _IMAPDLG_PRIVATE #include "svx/imapdlg.hxx" @@ -225,8 +226,7 @@ sal_Bool SvxIMapDlg::Close() if ( aTbxIMapDlg1.IsItemEnabled( TBI_APPLY ) ) { - QueryBox aQBox( this, WB_YES_NO_CANCEL | WB_DEF_YES, - SVX_RESSTR( STR_IMAPDLG_MODIFY ) ); + MessageDialog aQBox( this,"QueryModifyImageMapChangesDialog","svx/ui/querymodifyimagemapchangesdialog.ui"); const long nRet = aQBox.Execute(); if( nRet == RET_YES ) @@ -240,8 +240,7 @@ sal_Bool SvxIMapDlg::Close() } else if( pIMapWnd->IsChanged() ) { - QueryBox aQBox( this, WB_YES_NO_CANCEL | WB_DEF_YES, - SVX_RESSTR( STR_IMAPDLG_SAVE ) ); + MessageDialog aQBox( this,"QuerySaveImageMapChangesDialog","svx/ui/querysaveimagemapchangesdialog.ui"); const long nRet = aQBox.Execute(); if( nRet == RET_YES ) @@ -727,8 +726,8 @@ IMPL_LINK_NOARG(SvxIMapDlg, UpdateHdl) if ( pOwnData->pUpdateEditingObject != pCheckObj ) { if ( pIMapWnd->IsChanged() && - ( QueryBox( this, WB_YES_NO | WB_DEF_YES, - SVX_RESSTR( STR_IMAPDLG_SAVE ) ).Execute() == RET_YES ) ) + ( MessageDialog( this,"QuerySaveImageMapChangesDialog", + "svx/ui/querysaveimagemapchangesdialog.ui" ).Execute() == RET_YES ) ) { DoSave(); } diff --git a/svx/source/dialog/imapdlg.hrc b/svx/source/dialog/imapdlg.hrc index 40ba35b478a1..bcc2569e880a 100644 --- a/svx/source/dialog/imapdlg.hrc +++ b/svx/source/dialog/imapdlg.hrc @@ -84,13 +84,6 @@ #define RID_SVXCTL_CBB_TARGET (RID_SVX_IMAPDLG_START + 4) -/******************************************************************************/ - - -#define STR_IMAPDLG_SAVE (RID_SVX_IMAPDLG_START + 5) -#define STR_IMAPDLG_MODIFY (RID_SVX_IMAPDLG_START + 6) - - /******************************************************************************/ /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/svx/source/dialog/imapdlg.src b/svx/source/dialog/imapdlg.src index 730ef28e11ea..486217ae0a28 100644 --- a/svx/source/dialog/imapdlg.src +++ b/svx/source/dialog/imapdlg.src @@ -344,14 +344,5 @@ Menu RID_SVXMN_IMAP /******************************************************************************/ -String STR_IMAPDLG_SAVE -{ - Text [ en-US ] = "The ImageMap has been modified.\nDo you want to save the changes?"; -}; - -String STR_IMAPDLG_MODIFY -{ - Text [ en-US ] = "The ImageMap has been modified.\nDo you want to save the changes?" ; -}; /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/svx/uiconfig/ui/querymodifyimagemapchangesdialog.ui b/svx/uiconfig/ui/querymodifyimagemapchangesdialog.ui new file mode 100644 index 000000000000..33e388e4a550 --- /dev/null +++ b/svx/uiconfig/ui/querymodifyimagemapchangesdialog.ui @@ -0,0 +1,52 @@ + + + + + False + 12 + Save ImageMap changes? + False + dialog + True + question + yes-no + The ImageMap has been modified. + Do you want to save the changes? + + + False + vertical + 24 + + + False + end + + + gtk-cancel + True + True + True + True + + + False + True + 2 + + + + + False + True + end + 0 + + + + + + cancel + + + diff --git a/svx/uiconfig/ui/querysaveimagemapchangesdialog.ui b/svx/uiconfig/ui/querysaveimagemapchangesdialog.ui new file mode 100644 index 000000000000..bf49e7315634 --- /dev/null +++ b/svx/uiconfig/ui/querysaveimagemapchangesdialog.ui @@ -0,0 +1,52 @@ + + + + + False + 12 + Save ImageMap changes? + False + dialog + True + question + yes-no + The ImageMap has been modified. + Do you want to save the changes? + + + False + vertical + 24 + + + False + end + + + gtk-cancel + True + True + True + True + + + False + True + 2 + + + + + False + True + end + 0 + + + + + + cancel + + + -- cgit