[Libreoffice-commits] core.git: 4 commits - sw/source xmlsecurity/source

Caolán McNamara caolanm at redhat.com
Fri Aug 22 02:15:29 PDT 2014


 sw/source/ui/dialog/uiregionsw.cxx                     |    5 ++---
 sw/source/ui/misc/glossary.cxx                         |    9 +++++----
 sw/source/ui/misc/glossary.src                         |    6 ++----
 sw/source/uibase/dialog/regionsw.hrc                   |    2 +-
 sw/source/uibase/dialog/regionsw.src                   |    6 ++----
 sw/source/uibase/inc/misc.hrc                          |    4 ++--
 sw/source/uibase/uiview/view.hrc                       |    4 +---
 sw/source/uibase/uiview/view.src                       |    6 ++----
 sw/source/uibase/uiview/viewling.cxx                   |    2 +-
 xmlsecurity/source/dialogs/digitalsignaturesdialog.cxx |    5 ++---
 xmlsecurity/source/dialogs/digitalsignaturesdialog.hrc |    2 +-
 xmlsecurity/source/dialogs/digitalsignaturesdialog.src |    6 ++----
 12 files changed, 23 insertions(+), 34 deletions(-)

New commits:
commit c70f22b9a56d19efa58329dcd5095804d1864513
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Fri Aug 22 09:33:44 2014 +0100

    QueryBox STR_QUERY_DELETE -> MessageDialog + string
    
    Change-Id: I570fe82f3207e8b40a0e4727c6641fdf59113978

diff --git a/sw/source/ui/misc/glossary.cxx b/sw/source/ui/misc/glossary.cxx
index 0e83851..33d8984 100644
--- a/sw/source/ui/misc/glossary.cxx
+++ b/sw/source/ui/misc/glossary.cxx
@@ -20,7 +20,7 @@
 #include <hintids.hxx>
 
 #include <vcl/menu.hxx>
-#include <vcl/msgbox.hxx>
+#include <vcl/layout.hxx>
 #include <vcl/help.hxx>
 #include <svl/stritem.hxx>
 #include <unotools/pathoptions.hxx>
@@ -488,8 +488,8 @@ IMPL_LINK( SwGlossaryDlg, MenuHdl, Menu *, pMn )
     }
     else if (sItemIdent == "delete")
     {
-        QueryBox aQuery(this, SW_RES(MSG_QUERY_DELETE));
-        if(RET_YES == aQuery.Execute())
+        MessageDialog aQuery(this, SW_RES(STR_QUERY_DELETE), VCL_MESSAGE_QUESTION, VCL_BUTTONS_YES_NO);
+        if (RET_YES == aQuery.Execute())
         {
             const OUString aShortName(m_pShortNameEdit->GetText());
             const OUString aTitle(m_pNameED->GetText());
@@ -646,7 +646,8 @@ IMPL_LINK_NOARG(SwGlossaryDlg, BibHdl)
         }
         else
         {
-            QueryBox aBox(this, WB_YES_NO, sReadonlyPath);
+            MessageDialog aBox(this, sReadonlyPath, VCL_MESSAGE_QUESTION, VCL_BUTTONS_YES_NO);
+
             if(RET_YES == aBox.Execute())
                 PathHdl(m_pPathBtn);
         }
diff --git a/sw/source/ui/misc/glossary.src b/sw/source/ui/misc/glossary.src
index 28d8f5b..7d44cdf 100644
--- a/sw/source/ui/misc/glossary.src
+++ b/sw/source/ui/misc/glossary.src
@@ -26,11 +26,9 @@ String STR_DOUBLE_SHORTNAME
 {
     Text [ en-US ] = "Shortcut name already exists. Please choose another name." ;
 };
-QueryBox MSG_QUERY_DELETE
+String STR_QUERY_DELETE
 {
-    BUTTONS = WB_YES_NO ;
-    DEFBUTTON = WB_DEF_NO ;
-    Message [ en-US ] = "Delete AutoText?" ;
+    Text[ en-US ] = "Delete AutoText?" ;
 };
 String STR_QUERY_DELETE_GROUP1
 {
diff --git a/sw/source/uibase/inc/misc.hrc b/sw/source/uibase/inc/misc.hrc
index 01e1e3d..03f944f 100644
--- a/sw/source/uibase/inc/misc.hrc
+++ b/sw/source/uibase/inc/misc.hrc
@@ -26,10 +26,10 @@
 
 #define DLG_SORTING                 (RC_MISC_BEGIN + 19)
 
-#define DLG_TAB_OUTLINE             (RC_MISC_BEGIN + 31)
+#define DLG_TAB_OUTLINE             (RC_MISC_BEGIN + 29)
 
 #define STR_DOUBLE_SHORTNAME        (RC_MISC_BEGIN + 30)
-#define MSG_QUERY_DELETE            (RC_MISC_BEGIN + 31)
+#define STR_QUERY_DELETE            (RC_MISC_BEGIN + 31)
 #define STR_QUERY_DELETE_GROUP1     (RC_MISC_BEGIN + 32)
 #define STR_QUERY_DELETE_GROUP2     (RC_MISC_BEGIN + 33)
 #define STR_NO_GLOSSARIES           (RC_MISC_BEGIN + 34)
commit f10e4157ce6c134bb9561b7b48254c2c566726eb
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Fri Aug 22 09:20:01 2014 +0100

    QueryBox QB_CONNECT -> MessageDialog + string
    
    Change-Id: I593527c365ad6925229a3dd7d9e1c589fc4e34a5

diff --git a/sw/source/ui/dialog/uiregionsw.cxx b/sw/source/ui/dialog/uiregionsw.cxx
index 31b53da..14e078f 100644
--- a/sw/source/ui/dialog/uiregionsw.cxx
+++ b/sw/source/ui/dialog/uiregionsw.cxx
@@ -23,7 +23,6 @@
 #include <svl/PasswordHelper.hxx>
 #include <vcl/svapp.hxx>
 #include <vcl/layout.hxx>
-#include <vcl/msgbox.hxx>
 #include <svl/stritem.hxx>
 #include <svl/eitem.hxx>
 #include <sfx2/passwd.hxx>
@@ -961,7 +960,7 @@ IMPL_LINK( SwEditRegionDlg, UseFileHdl, CheckBox *, pBox )
             bool bContent = pSectRepr->IsContent();
             if( pBox->IsChecked() && bContent && rSh.HasSelection() )
             {
-                if( RET_NO == QueryBox( this, SW_RES(QB_CONNECT) ).Execute() )
+                if (RET_NO == MessageDialog(this, SW_RES(STR_QUERY_CONNECT), VCL_MESSAGE_QUESTION, VCL_BUTTONS_YES_NO).Execute())
                     pBox->Check( false );
             }
             if( bFile )
@@ -1709,7 +1708,7 @@ IMPL_LINK( SwInsertSectionTabPage, UseFileHdl, CheckBox *, pBox )
     if( pBox->IsChecked() )
     {
         if( m_pWrtSh->HasSelection() &&
-            RET_NO == QueryBox( this, SW_RES(QB_CONNECT) ).Execute() )
+            RET_NO == MessageDialog(this, SW_RES(STR_QUERY_CONNECT), VCL_MESSAGE_QUESTION, VCL_BUTTONS_YES_NO).Execute())
             pBox->Check( false );
     }
 
diff --git a/sw/source/uibase/dialog/regionsw.hrc b/sw/source/uibase/dialog/regionsw.hrc
index bc7f188..44f327c 100644
--- a/sw/source/uibase/dialog/regionsw.hrc
+++ b/sw/source/uibase/dialog/regionsw.hrc
@@ -27,7 +27,7 @@
 #define STR_REG_DUPLICATE       (RC_REGIONSW_BEGIN+6)
 #define STR_INFO_DUPLICATE      (RC_REGIONSW_BEGIN+7)
 
-#define QB_CONNECT              (RC_REGIONSW_BEGIN+10)
+#define STR_QUERY_CONNECT       (RC_REGIONSW_BEGIN+10)
 #define STR_WRONG_PASSWORD      (RC_REGIONSW_BEGIN+11)
 #define STR_WRONG_PASSWD_REPEAT (RC_REGIONSW_BEGIN+12)
 
diff --git a/sw/source/uibase/dialog/regionsw.src b/sw/source/uibase/dialog/regionsw.src
index 65b45b1..1e99ba9 100644
--- a/sw/source/uibase/dialog/regionsw.src
+++ b/sw/source/uibase/dialog/regionsw.src
@@ -47,11 +47,9 @@ String STR_INFO_DUPLICATE
 {
     Text [ en-US ] = "Duplicate section name" ;
 };
-QueryBox QB_CONNECT
+String STR_QUERY_CONNECT
 {
-    Buttons = WB_YES_NO ;
-    DefButton = WB_DEF_NO ;
-    Message [ en-US ] = "A file connection will delete the contents of the current section. Connect anyway?" ;
+    Text[ en-US ] = "A file connection will delete the contents of the current section. Connect anyway?" ;
 };
 String STR_WRONG_PASSWORD
 {
commit d2fa1d55dbf95b61e035e8b1f3aafec0cb2861c9
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Fri Aug 22 08:57:10 2014 +0100

    QueryBox DLG_SPECIAL_FORCED -> MessageDialog + string
    
    Change-Id: I461bdb31e7a088a2aa5200614479c8578e717b23

diff --git a/sw/source/uibase/uiview/view.hrc b/sw/source/uibase/uiview/view.hrc
index 0bb2d3e..b6c58e7 100644
--- a/sw/source/uibase/uiview/view.hrc
+++ b/sw/source/uibase/uiview/view.hrc
@@ -53,9 +53,7 @@
 #define STR_ERR_NO_FAX              (RC_VIEW_BEGIN + 36)
 #define STR_ERR_SRCSTREAM           (RC_VIEW_BEGIN + 37)
 
-// DLG
-
-#define DLG_SPECIAL_FORCED              (RC_VIEW_BEGIN)
+#define STR_QUERY_SPECIAL_FORCED    (RC_VIEW_BEGIN + 38)
 
 // Overflow checking
 
diff --git a/sw/source/uibase/uiview/view.src b/sw/source/uibase/uiview/view.src
index 20c851d..a986d6b 100644
--- a/sw/source/uibase/uiview/view.src
+++ b/sw/source/uibase/uiview/view.src
@@ -26,11 +26,9 @@
 #include "helpid.h"
 #include "cmdid.h"
 
-QueryBox DLG_SPECIAL_FORCED
+String STR_QUERY_SPECIAL_FORCED
 {
-    BUTTONS = WB_YES_NO ;
-    DEFBUTTON = WB_DEF_NO ;
-    Message [ en-US ] = "Check special regions is deactivated. Check anyway?" ;
+    Text [ en-US ] = "Check special regions is deactivated. Check anyway?" ;
 };
 String STR_NO_MERGE_ENTRY
 {
diff --git a/sw/source/uibase/uiview/viewling.cxx b/sw/source/uibase/uiview/viewling.cxx
index caef90a..42653d0 100644
--- a/sw/source/uibase/uiview/viewling.cxx
+++ b/sw/source/uibase/uiview/viewling.cxx
@@ -459,7 +459,7 @@ void SwView::HyphenateDocument()
         // turned on no special area
         {
             // I want also in special areas hyphenation
-            QueryBox aBox( &GetEditWin(), SW_RES( DLG_SPECIAL_FORCED ) );
+            MessageDialog aBox(&GetEditWin(), SW_RES(STR_QUERY_SPECIAL_FORCED), VCL_MESSAGE_QUESTION, VCL_BUTTONS_YES_NO);
             if( aBox.Execute() == RET_YES )
             {
                 bOther = true;
commit b13936abe9b8b3571da7058b573e4e6456559dec
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Fri Aug 22 08:54:32 2014 +0100

    QueryBox MSG_XMLSECDLG_QUERY_REMOVEDOCSIGNBEFORESIGN -> MessageDialog + string
    
    Change-Id: I9dcbc271dac9a2395bf2a7adb160c965627a0277

diff --git a/xmlsecurity/source/dialogs/digitalsignaturesdialog.cxx b/xmlsecurity/source/dialogs/digitalsignaturesdialog.cxx
index 53ea3c9..c0c08d7 100644
--- a/xmlsecurity/source/dialogs/digitalsignaturesdialog.cxx
+++ b/xmlsecurity/source/dialogs/digitalsignaturesdialog.cxx
@@ -54,7 +54,6 @@
 #include "helpids.hrc"
 #include "resourcemanager.hxx"
 
-#include <vcl/msgbox.hxx>
 #include <vcl/layout.hxx>
 #include <unotools/configitem.hxx>
 
@@ -308,8 +307,8 @@ bool DigitalSignaturesDialog::canAddRemove()
             //It the user presses 'Add' or 'Remove' several times then, then the warning
             //is shown every time until the user presses 'OK'. From then on, the warning
             //is not displayed anymore as long as the signatures dialog is alive.
-            if (QueryBox(
-                NULL, XMLSEC_RES(MSG_XMLSECDLG_QUERY_REMOVEDOCSIGNBEFORESIGN)).Execute() == RET_NO)
+            if (MessageDialog(
+                NULL, XMLSEC_RES(STR_XMLSECDLG_QUERY_REMOVEDOCSIGNBEFORESIGN), VCL_MESSAGE_QUESTION, VCL_BUTTONS_YES_NO).Execute() == RET_NO)
                 ret = false;
             else
                 m_bWarningShowSignMacro = true;
diff --git a/xmlsecurity/source/dialogs/digitalsignaturesdialog.hrc b/xmlsecurity/source/dialogs/digitalsignaturesdialog.hrc
index 7298555..51dee1c 100644
--- a/xmlsecurity/source/dialogs/digitalsignaturesdialog.hrc
+++ b/xmlsecurity/source/dialogs/digitalsignaturesdialog.hrc
@@ -24,7 +24,7 @@
 #define RID_DIGITALSIGNATUREDLG_START                 2000
 
 #define STR_XMLSECDLG_OLD_ODF_FORMAT     RID_DIGITALSIGNATUREDLG_START
-#define MSG_XMLSECDLG_QUERY_REMOVEDOCSIGNBEFORESIGN (RID_DIGITALSIGNATUREDLG_START + 1)
+#define STR_XMLSECDLG_QUERY_REMOVEDOCSIGNBEFORESIGN (RID_DIGITALSIGNATUREDLG_START + 1)
 #endif
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/xmlsecurity/source/dialogs/digitalsignaturesdialog.src b/xmlsecurity/source/dialogs/digitalsignaturesdialog.src
index 37b37db..69db6f0 100644
--- a/xmlsecurity/source/dialogs/digitalsignaturesdialog.src
+++ b/xmlsecurity/source/dialogs/digitalsignaturesdialog.src
@@ -30,11 +30,9 @@ String STR_XMLSECDLG_OLD_ODF_FORMAT
         "Save document in ODF 1.2 format and add all desired signatures again.";
 };
 
-QueryBox MSG_XMLSECDLG_QUERY_REMOVEDOCSIGNBEFORESIGN
+String STR_XMLSECDLG_QUERY_REMOVEDOCSIGNBEFORESIGN
 {
-    Buttons = WB_YES_NO ;
-    DefButton = WB_DEF_NO ;
-    Message [ en-US ] = "Adding or removing a macro signature will remove all document signatures.\n"
+    Text [ en-US ] = "Adding or removing a macro signature will remove all document signatures.\n"
         "Do you really want to continue?";
 };
 


More information about the Libreoffice-commits mailing list