svx/UIConfig_svx.mk | 2 svx/source/dialog/imapdlg.cxx | 11 +--- svx/source/dialog/imapdlg.hrc | 7 -- svx/source/dialog/imapdlg.src | 9 --- svx/uiconfig/ui/querymodifyimagemapchangesdialog.ui | 52 ++++++++++++++++++++ svx/uiconfig/ui/querysaveimagemapchangesdialog.ui | 52 ++++++++++++++++++++ 6 files changed, 111 insertions(+), 22 deletions(-)
New commits: commit 4c26083959637ffa9ca8bc1eed99f3c218447123 Author: Manal Alhassoun <malhass...@kacst.edu.sa> Date: Thu Dec 26 15:11:57 2013 +0300 convert save and modify imageMaps queryboxes to .ui Change-Id: I222ce47187e46f7de9916bd559846d28c30d4562 Reviewed-on: https://gerrit.libreoffice.org/7201 Reviewed-by: Caolán McNamara <caol...@redhat.com> Tested-by: Caolán McNamara <caol...@redhat.com> diff --git a/svx/UIConfig_svx.mk b/svx/UIConfig_svx.mk index f2a8087..e82509c 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 8c1b46f..3cc0bb63 100644 --- a/svx/source/dialog/imapdlg.cxx +++ b/svx/source/dialog/imapdlg.cxx @@ -40,6 +40,7 @@ #include <sfx2/docfile.hxx> #include <unotools/localedatawrapper.hxx> #include <comphelper/processfactory.hxx> +#include <vcl/layout.hxx> #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 40ba35b..bcc2569 100644 --- a/svx/source/dialog/imapdlg.hrc +++ b/svx/source/dialog/imapdlg.hrc @@ -86,11 +86,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 730ef28..486217a 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 0000000..33e388e --- /dev/null +++ b/svx/uiconfig/ui/querymodifyimagemapchangesdialog.ui @@ -0,0 +1,52 @@ +<?xml version="1.0" encoding="UTF-8"?> +<interface> + <!-- interface-requires gtk+ 3.0 --> + <object class="GtkMessageDialog" id="QueryModifyImageMapChangesDialog"> + <property name="can_focus">False</property> + <property name="border_width">12</property> + <property name="title" translatable="yes">Save ImageMap changes?</property> + <property name="resizable">False</property> + <property name="type_hint">dialog</property> + <property name="skip_taskbar_hint">True</property> + <property name="message_type">question</property> + <property name="buttons">yes-no</property> + <property name="text" translatable="yes">The ImageMap has been modified.</property> + <property name="secondary_text" translatable="yes">Do you want to save the changes?</property> + <child internal-child="vbox"> + <object class="GtkBox" id="messagedialog-vbox5"> + <property name="can_focus">False</property> + <property name="orientation">vertical</property> + <property name="spacing">24</property> + <child internal-child="action_area"> + <object class="GtkButtonBox" id="messagedialog-action_area5"> + <property name="can_focus">False</property> + <property name="layout_style">end</property> + <child> + <object class="GtkButton" id="cancel"> + <property name="label">gtk-cancel</property> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="receives_default">True</property> + <property name="use_stock">True</property> + </object> + <packing> + <property name="expand">False</property> + <property name="fill">True</property> + <property name="position">2</property> + </packing> + </child> + </object> + <packing> + <property name="expand">False</property> + <property name="fill">True</property> + <property name="pack_type">end</property> + <property name="position">0</property> + </packing> + </child> + </object> + </child> + <action-widgets> + <action-widget response="0">cancel</action-widget> + </action-widgets> + </object> +</interface> diff --git a/svx/uiconfig/ui/querysaveimagemapchangesdialog.ui b/svx/uiconfig/ui/querysaveimagemapchangesdialog.ui new file mode 100644 index 0000000..bf49e73 --- /dev/null +++ b/svx/uiconfig/ui/querysaveimagemapchangesdialog.ui @@ -0,0 +1,52 @@ +<?xml version="1.0" encoding="UTF-8"?> +<interface> + <!-- interface-requires gtk+ 3.0 --> + <object class="GtkMessageDialog" id="QuerySaveImageMapChangesDialog"> + <property name="can_focus">False</property> + <property name="border_width">12</property> + <property name="title" translatable="yes">Save ImageMap changes?</property> + <property name="resizable">False</property> + <property name="type_hint">dialog</property> + <property name="skip_taskbar_hint">True</property> + <property name="message_type">question</property> + <property name="buttons">yes-no</property> + <property name="text" translatable="yes">The ImageMap has been modified.</property> + <property name="secondary_text" translatable="yes">Do you want to save the changes?</property> + <child internal-child="vbox"> + <object class="GtkBox" id="messagedialog-vbox4"> + <property name="can_focus">False</property> + <property name="orientation">vertical</property> + <property name="spacing">24</property> + <child internal-child="action_area"> + <object class="GtkButtonBox" id="messagedialog-action_area4"> + <property name="can_focus">False</property> + <property name="layout_style">end</property> + <child> + <object class="GtkButton" id="cancel"> + <property name="label">gtk-cancel</property> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="receives_default">True</property> + <property name="use_stock">True</property> + </object> + <packing> + <property name="expand">False</property> + <property name="fill">True</property> + <property name="position">2</property> + </packing> + </child> + </object> + <packing> + <property name="expand">False</property> + <property name="fill">True</property> + <property name="pack_type">end</property> + <property name="position">0</property> + </packing> + </child> + </object> + </child> + <action-widgets> + <action-widget response="0">cancel</action-widget> + </action-widgets> + </object> +</interface>
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits