[Libreoffice-commits] core.git: 2 commits - sw/inc sw/source sw/uiconfig sw/UIConfig_swriter.mk vcl/source

2017-04-18 Thread Caolán McNamara
 sw/UIConfig_swriter.mk |1 
 sw/inc/helpid.h|   11 -
 sw/source/uibase/docvw/docvw.hrc   |   26 ---
 sw/source/uibase/docvw/docvw.src   |  166 --
 sw/source/uibase/docvw/romenu.cxx  |  225 --
 sw/source/uibase/docvw/romenu.hxx  |   25 +++
 sw/uiconfig/swriter/ui/readonlymenu.ui |  247 +
 vcl/source/window/mouse.cxx|9 -
 8 files changed, 401 insertions(+), 309 deletions(-)

New commits:
commit 45d57a0dba8bb5a92150cc07bdff0b37b3041007
Author: Caolán McNamara 
Date:   Tue Apr 18 13:13:27 2017 +0100

convert readonly menu to .ui

Change-Id: Ia9400b3c4b410dbf70633e55286a4af77f0d651a

diff --git a/sw/UIConfig_swriter.mk b/sw/UIConfig_swriter.mk
index d6e4dd787eb2..86fe9b7e503d 100644
--- a/sw/UIConfig_swriter.mk
+++ b/sw/UIConfig_swriter.mk
@@ -229,6 +229,7 @@ $(eval $(call gb_UIConfig_add_uifiles,modules/swriter,\
sw/uiconfig/swriter/ui/printmonitordialog \
sw/uiconfig/swriter/ui/printoptionspage \
sw/uiconfig/swriter/ui/privateuserpage \
+   sw/uiconfig/swriter/ui/readonlymenu \
sw/uiconfig/swriter/ui/renameautotextdialog \
sw/uiconfig/swriter/ui/renameentrydialog \
sw/uiconfig/swriter/ui/renameobjectdialog \
diff --git a/sw/inc/helpid.h b/sw/inc/helpid.h
index 5bea9367c9df..0d18cd66e88d 100644
--- a/sw/inc/helpid.h
+++ b/sw/inc/helpid.h
@@ -88,17 +88,6 @@
 #define HID_MN_SUB_SPELLING 
"SW_HID_MN_SUB_SPELLING"
 #define HID_MN_SUB_MIRROR   
"SW_HID_MN_SUB_MIRROR"
 
-#define HID_MN_READONLY_SAVEGRAPHIC 
"SW_HID_MN_READONLY_SAVEGRAPHIC"
-#define HID_MN_READONLY_GRAPHICTOGALLERY
"SW_HID_MN_READONLY_GRAPHICTOGALLERY"
-#define HID_MN_READONLY_TOGALLERYLINK   
"SW_HID_MN_READONLY_TOGALLERYLINK"
-#define HID_MN_READONLY_TOGALLERYCOPY   
"SW_HID_MN_READONLY_TOGALLERYCOPY"
-#define HID_MN_READONLY_SAVEBACKGROUND  
"SW_HID_MN_READONLY_SAVEBACKGROUND"
-#define HID_MN_READONLY_BACKGROUNDTOGALLERY 
"SW_HID_MN_READONLY_BACKGROUNDTOGALLERY"
-#define HID_MN_READONLY_COPYLINK
"SW_HID_MN_READONLY_COPYLINK"
-#define HID_MN_READONLY_COPYGRAPHIC 
"SW_HID_MN_READONLY_COPYGRAPHIC"
-#define HID_MN_READONLY_LOADGRAPHIC 
"SW_HID_MN_READONLY_LOADGRAPHIC"
-#define HID_MN_READONLY_GRAPHICOFF  
"SW_HID_MN_READONLY_GRAPHICOFF"
-
 #define HID_LINGU_AUTOCORR  
"SW_HID_LINGU_AUTOCORR"
 #define HID_LINGU_REPLACE   
"SW_HID_LINGU_REPLACE"
 #define HID_SMARTTAG_MAIN   
"SW_HID_SMARTTAG_MAIN"// SMARTTAGS
diff --git a/sw/source/uibase/docvw/docvw.hrc b/sw/source/uibase/docvw/docvw.hrc
index ca60529fbe07..799efce72c69 100644
--- a/sw/source/uibase/docvw/docvw.hrc
+++ b/sw/source/uibase/docvw/docvw.hrc
@@ -22,32 +22,6 @@
 
 #include "rcid.hrc"
 
-#define MN_READONLY_POPUP   (RC_DOCVW_BEGIN + 1)
-#define MN_READONLY_OPENURL (RC_DOCVW_BEGIN + 2)
-#define MN_READONLY_OPENURLNEW  (RC_DOCVW_BEGIN + 3)
-#define MN_READONLY_EDITDOC (RC_DOCVW_BEGIN + 4)
-// free (5)
-#define MN_READONLY_BROWSE_BACKWARD (RC_DOCVW_BEGIN + 6)
-#define MN_READONLY_BROWSE_FORWARD  (RC_DOCVW_BEGIN + 7)
-#define MN_READONLY_SELECTION_MODE  (RC_DOCVW_BEGIN + 8)
-#define MN_READONLY_SAVEGRAPHIC (RC_DOCVW_BEGIN + 11)
-#define MN_READONLY_SAVEBACKGROUND  (RC_DOCVW_BEGIN + 12)
-#define MN_READONLY_COPYLINK(RC_DOCVW_BEGIN + 13)
-#define MN_READONLY_COPYGRAPHIC (RC_DOCVW_BEGIN + 14)
-#define MN_READONLY_LOADGRAPHIC (RC_DOCVW_BEGIN + 15)
-#define MN_READONLY_GRAPHICOFF  (RC_DOCVW_BEGIN + 16)
-// free (RC_DOCVW_BEGIN + 17)
-#define MN_READONLY_TOGALLERYLINK   (RC_DOCVW_BEGIN + 18)
-#define MN_READONLY_TOGALLERYCOPY   (RC_DOCVW_BEGIN + 19)
-#define MN_READONLY_SOURCEVIEW  (RC_DOCVW_BEGIN + 20)
-#define MN_READONLY_RELOAD_FRAME(RC_DOCVW_BEGIN + 21)
-#define MN_READONLY_RELOAD  (RC_DOCVW_BEGIN + 22)
-#define MN_READONLY_COPY(RC_DOCVW_BEGIN + 23)
-
-//For the following we need space for the gallery-themes
-#define MN_READONLY_GRAPHICTOGALLERY(RC_DOCVW_BEGIN + 24)
-#define MN_READONLY_BACKGROUNDTOGALLERY (RC_DOCVW_BEGIN + 60)
-
 #define STR_REDLINE_INSERT  (RC_DOCVW_BEGIN + 9)
 #define STR_REDLINE_DELETE  (RC_DOCVW_BEGIN + 10)
 #define STR_REDLINE_FORMAT  (RC_DOCVW_BEGIN + 11)
diff --git a/sw/source/uibase/docvw/docvw.src b/sw/source/uibase/docvw/docvw.src
index a589c11ae11f..22e47e6a8709 100644
--- 

[Libreoffice-commits] core.git: 2 commits - sw/inc sw/source sw/uiconfig sw/UIConfig_swriter.mk vcl/source

2013-10-14 Thread Caolán McNamara
 sw/UIConfig_swriter.mk |1 
 sw/inc/dbui.hrc|1 
 sw/inc/helpid.h|1 
 sw/source/ui/dbui/mailmergechildwindow.cxx |   37 ++
 sw/source/ui/dbui/mailmergechildwindow.hrc |6 ---
 sw/source/ui/dbui/mailmergechildwindow.src |   48 
 sw/source/ui/dbui/mmoutputpage.hrc |4 --
 sw/uiconfig/swriter/ui/warnemaildialog.ui  |   57 +
 vcl/source/window/layout.cxx   |1 
 9 files changed, 71 insertions(+), 85 deletions(-)

New commits:
commit a5598cf00a49469b14492b9c9c6a82d8f8e04c42
Author: Caolán McNamara caol...@redhat.com
Date:   Mon Oct 14 16:29:46 2013 +0100

convert warn email's can't be sent dialog to .ui

Change-Id: I611c5cb7ab140a04e7ee4a78b6d828ca199c5624

diff --git a/sw/UIConfig_swriter.mk b/sw/UIConfig_swriter.mk
index c588dd0..c346962 100644
--- a/sw/UIConfig_swriter.mk
+++ b/sw/UIConfig_swriter.mk
@@ -206,6 +206,7 @@ $(eval $(call gb_UIConfig_add_uifiles,modules/swriter,\
sw/uiconfig/swriter/ui/tokenwidget \
sw/uiconfig/swriter/ui/viewoptionspage \
sw/uiconfig/swriter/ui/warndatasourcedialog \
+   sw/uiconfig/swriter/ui/warnemaildialog \
sw/uiconfig/swriter/ui/wordcount \
sw/uiconfig/swriter/ui/wrapdialog \
sw/uiconfig/swriter/ui/wrappage \
diff --git a/sw/inc/dbui.hrc b/sw/inc/dbui.hrc
index 057375e..0e6a220 100644
--- a/sw/inc/dbui.hrc
+++ b/sw/inc/dbui.hrc
@@ -46,7 +46,6 @@
 #define DLG_MM_MAILBODY   (RC_DBUI_BEGIN + 24)
 #define DLG_MM_SENDMAILS  (RC_DBUI_BEGIN + 25)
 #define DLG_MAILMERGECHILD(RC_DBUI_BEGIN + 26)
-#define DLG_MM_SENDWARNING(RC_DBUI_BEGIN + 29)
 #define DLG_MM_CREATIONMONITOR(RC_DBUI_BEGIN + 30)
 // Strings --
 
diff --git a/sw/inc/helpid.h b/sw/inc/helpid.h
index 1651804..7284fdb 100644
--- a/sw/inc/helpid.h
+++ b/sw/inc/helpid.h
@@ -383,7 +383,6 @@
 #define HID_MAILMERGECHILD  
SW_HID_MAILMERGECHILD
 #define HID_MM_MAILSTATUS_TLB   
SW_HID_MM_MAILSTATUS_TLB
 #define HID_RETURN_TO_MAILMERGE 
SW_HID_RETURN_TO_MAILMERGE
-#define HID_MM_SENDWARNING  
SW_HID_MM_SENDWARNING
 
 #define HID_NID_TBL 
SW_HID_NID_TBL
 #define HID_NID_FRM 
SW_HID_NID_FRM
diff --git a/sw/source/ui/dbui/mailmergechildwindow.cxx 
b/sw/source/ui/dbui/mailmergechildwindow.cxx
index 2b9e2eb..0216245 100644
--- a/sw/source/ui/dbui/mailmergechildwindow.cxx
+++ b/sw/source/ui/dbui/mailmergechildwindow.cxx
@@ -24,6 +24,7 @@
 #include swmodule.hxx
 #include view.hxx
 #include edtwin.hxx
+#include vcl/layout.hxx
 #include vcl/svapp.hxx
 #include mailmergechildwindow.hxx
 #include mmoutputpage.hxx
@@ -241,36 +242,21 @@ void SwMailDispatcherListener_Impl::DeleteAttachments( 
uno::Reference mail::XMa
 }
 }
 
-class SwSendWarningBox_Impl : public ModalDialog
+class SwSendWarningBox_Impl : public MessageDialog
 {
-FixedImage  aWarningImageIM;
-FixedInfo   aWarningFI;
-FixedText   aDetailFT;
-MultiLineEdit   aDetailED;
-FixedLine   aSeparatorFL;
-OKButtonaOKPB;
-
+VclMultiLineEdit  *m_pDetailED;
 public:
 SwSendWarningBox_Impl(Window* pParent, const String rDetails);
-~SwSendWarningBox_Impl();
 };
 
-SwSendWarningBox_Impl::SwSendWarningBox_Impl(Window* pParent, const String 
rDetails) :
-ModalDialog(pParent, SW_RES( DLG_MM_SENDWARNING )),
-aWarningImageIM(this, SW_RES( IM_WARNING )),
-aWarningFI( this, SW_RES( FI_WARNING )),
-aDetailFT(  this, SW_RES( FT_DETAILS )),
-aDetailED(  this, SW_RES( ED_DETAILS )),
-aSeparatorFL(   this, SW_RES( FL_SEPARATOR   )),
-aOKPB(  this, SW_RES(PB_OK))
-{
-FreeResource();
-aWarningImageIM.SetImage(WarningBox::GetStandardImage());
-aDetailED.SetText(rDetails);
-}
-
-SwSendWarningBox_Impl::~SwSendWarningBox_Impl()
+SwSendWarningBox_Impl::SwSendWarningBox_Impl(Window* pParent, const String 
rDetails)
+: MessageDialog(pParent, WarnEmailDialog, 
modules/swriter/ui/warnemaildialog.ui)
 {
+get(m_pDetailED, errors);
+m_pDetailED-SetMaxTextWidth(80 * m_pDetailED-approximate_char_width());
+m_pDetailED-set_width_request(80 * m_pDetailED-approximate_char_width());
+m_pDetailED-set_height_request(8 * m_pDetailED-GetTextHeight());
+m_pDetailED-SetText(rDetails);
 }
 
 #define ITEMID_TASK 1
@@ -655,7 +641,8 @@ void SwSendMailDialog::DocumentSent( uno::Reference 
mail::XMailMessage xMessag
 ++m_nErrorCount;
 
 UpdateTransferStatus( );
-if(pError)
+
+if (pError)
 {
 SwSendWarningBox_Impl* pDlg = new