Kaydet (Commit) 9a114917 authored tarafından Caolán McNamara's avatar Caolán McNamara

convert RID_QRY_SAVEMODIFIED with custom buttons to .ui

Change-Id: I782ca0f7e60f92e65e1a93bb8d1d38eded941cbb
üst 65597c99
...@@ -85,7 +85,6 @@ ...@@ -85,7 +85,6 @@
#define RID_MENU_DATANAVIGATOR (RID_FORMS_START + 10) #define RID_MENU_DATANAVIGATOR (RID_FORMS_START + 10)
// QueryBox-Id's ----------------------------------------------------------- // QueryBox-Id's -----------------------------------------------------------
#define RID_QRY_SAVEMODIFIED (RID_FORMS_START + 1)
#define RID_QRY_LINK_WARNING (RID_FORMS_START + 6) #define RID_QRY_LINK_WARNING (RID_FORMS_START + 6)
// String-Id's ----------------------------------------------------------- // String-Id's -----------------------------------------------------------
......
...@@ -49,6 +49,7 @@ $(eval $(call gb_UIConfig_add_uifiles,svx,\ ...@@ -49,6 +49,7 @@ $(eval $(call gb_UIConfig_add_uifiles,svx,\
svx/uiconfig/ui/redlinecontrol \ svx/uiconfig/ui/redlinecontrol \
svx/uiconfig/ui/redlinefilterpage \ svx/uiconfig/ui/redlinefilterpage \
svx/uiconfig/ui/redlineviewpage \ svx/uiconfig/ui/redlineviewpage \
svx/uiconfig/ui/savemodifieddialog \
svx/uiconfig/ui/sidebararea \ svx/uiconfig/ui/sidebararea \
svx/uiconfig/ui/sidebargraphic \ svx/uiconfig/ui/sidebargraphic \
svx/uiconfig/ui/sidebarinsert \ svx/uiconfig/ui/sidebarinsert \
......
...@@ -37,8 +37,8 @@ ...@@ -37,8 +37,8 @@
#include <com/sun/star/container/XNameContainer.hpp> #include <com/sun/star/container/XNameContainer.hpp>
#include <com/sun/star/awt/XTabControllerModel.hpp> #include <com/sun/star/awt/XTabControllerModel.hpp>
#include <sfx2/viewfrm.hxx> #include <sfx2/viewfrm.hxx>
#include <vcl/layout.hxx>
#include <vcl/wrkwin.hxx> #include <vcl/wrkwin.hxx>
#include <vcl/msgbox.hxx>
#include <svl/whiter.hxx> #include <svl/whiter.hxx>
#include <sfx2/app.hxx> #include <sfx2/app.hxx>
#include <svl/intitem.hxx> #include <svl/intitem.hxx>
...@@ -272,7 +272,8 @@ bool FmFormShell::PrepareClose(bool bUI) ...@@ -272,7 +272,8 @@ bool FmFormShell::PrepareClose(bool bUI)
if ( bModified && bUI ) if ( bModified && bUI )
{ {
QueryBox aQry(NULL, SVX_RES(RID_QRY_SAVEMODIFIED)); MessageDialog aQry(NULL, "SaveModifiedDialog",
"svx/ui/savemodifieddialog.ui");
switch (aQry.Execute()) switch (aQry.Execute())
{ {
case RET_NO: case RET_NO:
......
...@@ -301,12 +301,6 @@ String RID_STR_AUTOFIELD ...@@ -301,12 +301,6 @@ String RID_STR_AUTOFIELD
Text [ en-US ] = "<AutoField>"; Text [ en-US ] = "<AutoField>";
}; };
QueryBox RID_QRY_SAVEMODIFIED
{
Buttons = WB_YES_NO_CANCEL ;
DefButton = WB_DEF_YES ;
Message [ en-US ] = "The content of the current form has been modified.\nDo you want to save your changes?";
};
Resource RID_RSC_SQL_INTERNATIONAL Resource RID_RSC_SQL_INTERNATIONAL
{ {
String 1 String 1
......
<?xml version="1.0" encoding="UTF-8"?>
<!-- Generated with glade 3.16.1 -->
<interface>
<requires lib="gtk+" version="3.0"/>
<object class="GtkMessageDialog" id="SaveModifiedDialog">
<property name="can_focus">False</property>
<property name="border_width">12</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="text" translatable="yes">Do you want to save your changes?</property>
<property name="secondary_text" translatable="yes">The content of the current form has been modified.</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">end</property>
<child>
<object class="GtkButton" id="no">
<property name="label">gtk-no</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="use_underline">True</property>
<property name="use_stock">True</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkButton" id="yes">
<property name="label">gtk-yes</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="can_default">True</property>
<property name="has_default">True</property>
<property name="receives_default">True</property>
<property name="use_underline">True</property>
<property name="use_stock">True</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
<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="3">no</action-widget>
<action-widget response="2">yes</action-widget>
<action-widget response="0">cancel</action-widget>
</action-widgets>
</object>
</interface>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment