[Libreoffice-commits] core.git: cui/source cui/uiconfig cui/UIConfig_cui.mk

Manal Alhassoun malhassoun at kacst.edu.sa
Wed Nov 20 01:57:07 PST 2013


 cui/UIConfig_cui.mk                        |    1 
 cui/source/inc/cuires.hrc                  |    1 
 cui/source/tabpages/strings.src            |    4 ---
 cui/source/tabpages/tpbitmap.cxx           |    3 --
 cui/uiconfig/ui/querydeletebitmapdialog.ui |   34 +++++++++++++++++++++++++++++
 5 files changed, 36 insertions(+), 7 deletions(-)

New commits:
commit f138a539ddd77265343fbdd1eadb4c4d990b0e38
Author: Manal Alhassoun <malhassoun at kacst.edu.sa>
Date:   Tue Nov 19 10:41:09 2013 +0300

    convert delete bitmap querybox to .ui
    
    Change-Id: Ie789954555012f766e48f9605f84e0ca5b2bca6d
    Reviewed-on: https://gerrit.libreoffice.org/6717
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/cui/UIConfig_cui.mk b/cui/UIConfig_cui.mk
index 474189a..5973275 100644
--- a/cui/UIConfig_cui.mk
+++ b/cui/UIConfig_cui.mk
@@ -104,6 +104,7 @@ $(eval $(call gb_UIConfig_add_uifiles,cui,\
 	cui/uiconfig/ui/positionsizedialog \
 	cui/uiconfig/ui/possizetabpage \
 	cui/uiconfig/ui/querychangelineenddialog \
+	cui/uiconfig/ui/querydeletebitmapdialog \
 	cui/uiconfig/ui/querydeletechartcolordialog \
 	cui/uiconfig/ui/querydeletedictionarydialog \
 	cui/uiconfig/ui/querydeletehatchdialog \
diff --git a/cui/source/inc/cuires.hrc b/cui/source/inc/cuires.hrc
index 99fdaa2..c8507a6 100644
--- a/cui/source/inc/cuires.hrc
+++ b/cui/source/inc/cuires.hrc
@@ -78,7 +78,6 @@
 #define RID_SVXSTR_DESC_GRADIENT            (RID_SVX_START + 163)
 #define RID_SVXSTR_ASK_DEL_GRADIENT         (RID_SVX_START + 165)
 #define RID_SVXSTR_ASK_CHANGE_GRADIENT      (RID_SVX_START + 166)
-#define RID_SVXSTR_ASK_DEL_BITMAP           (RID_SVX_START + 171)
 #define RID_SVXSTR_ASK_CHANGE_BITMAP        (RID_SVX_START + 172)
 #define RID_SVXSTR_DESC_NEW_BITMAP          (RID_SVX_START + 168)
 #define RID_SVXSTR_DESC_EXT_BITMAP          (RID_SVX_START + 169)
diff --git a/cui/source/tabpages/strings.src b/cui/source/tabpages/strings.src
index db8c177..dee7e7e 100644
--- a/cui/source/tabpages/strings.src
+++ b/cui/source/tabpages/strings.src
@@ -39,10 +39,6 @@ String RID_SVXSTR_DESC_EXT_BITMAP
 {
     Text [ en-US ] = "Please enter a name for the external bitmap:" ;
 };
-String RID_SVXSTR_ASK_DEL_BITMAP
-{
-    Text [ en-US ] = "Are you sure you want to delete the bitmap?" ;
-};
 String RID_SVXSTR_ASK_CHANGE_BITMAP
 {
     Text [ en-US ] = "The bitmap was modified without saving. \nModify the selected bitmap or add a new bitmap." ;
diff --git a/cui/source/tabpages/tpbitmap.cxx b/cui/source/tabpages/tpbitmap.cxx
index d3647e3..81373db 100644
--- a/cui/source/tabpages/tpbitmap.cxx
+++ b/cui/source/tabpages/tpbitmap.cxx
@@ -729,8 +729,7 @@ IMPL_LINK_NOARG(SvxBitmapTabPage, ClickDeleteHdl_Impl)
 
     if( nPos != LISTBOX_ENTRY_NOTFOUND )
     {
-        QueryBox aQueryBox( GetParentDialog(), WinBits( WB_YES_NO | WB_DEF_NO ),
-            OUString( CUI_RES( RID_SVXSTR_ASK_DEL_BITMAP ) ) );
+        MessageDialog aQueryBox( GetParentDialog(),"AskDelBitmapDialog","cui/ui/querydeletebitmapdialog.ui");
 
         if( aQueryBox.Execute() == RET_YES )
         {
diff --git a/cui/uiconfig/ui/querydeletebitmapdialog.ui b/cui/uiconfig/ui/querydeletebitmapdialog.ui
new file mode 100644
index 0000000..01f6e9b
--- /dev/null
+++ b/cui/uiconfig/ui/querydeletebitmapdialog.ui
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+  <!-- interface-requires gtk+ 3.0 -->
+  <object class="GtkMessageDialog" id="AskDelBitmapDialog">
+    <property name="can_focus">False</property>
+    <property name="border_width">12</property>
+    <property name="title" translatable="yes">Delete bitmap?</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">Are you sure you want to delete the bitmap?</property>
+    <child internal-child="vbox">
+      <object class="GtkBox" id="messagedialog-vbox">
+        <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_area">
+            <property name="can_focus">False</property>
+            <property name="layout_style">center</property>
+          </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>
+  </object>
+</interface>


More information about the Libreoffice-commits mailing list