summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorThomas Arnhold <thomas@arnhold.org>2014-08-18 03:44:59 +0200
committerThomas Arnhold <thomas@arnhold.org>2014-08-18 03:58:23 +0200
commit76f7bc12fa68585ab4a5b53e7891e4f9863123a4 (patch)
tree1434a00c2c0ad7ad402902337e830e26c57f2564 /sw
parent8807796e45084e560babb5f4da6f72262024398d (diff)
InfoBox to String final
Change-Id: I42f97a12052f4a173b05173fdd2c3079c517f78e
Diffstat (limited to 'sw')
-rw-r--r--sw/source/uibase/uiview/srcview.cxx3
-rw-r--r--sw/source/uibase/uiview/uivwimp.cxx3
-rw-r--r--sw/source/uibase/uiview/view.hrc11
-rw-r--r--sw/source/uibase/uiview/view.src16
-rw-r--r--sw/source/uibase/uiview/view2.cxx5
-rw-r--r--sw/source/uibase/uiview/viewprt.cxx7
6 files changed, 22 insertions, 23 deletions
diff --git a/sw/source/uibase/uiview/srcview.cxx b/sw/source/uibase/uiview/srcview.cxx
index 26d7a7791420..696916637a0b 100644
--- a/sw/source/uibase/uiview/srcview.cxx
+++ b/sw/source/uibase/uiview/srcview.cxx
@@ -25,6 +25,7 @@
#include <comphelper/string.hxx>
#include <unotools/tempfile.hxx>
#include <tools/urlobj.hxx>
+#include <vcl/layout.hxx>
#include <vcl/print.hxx>
#include <vcl/msgbox.hxx>
#include <vcl/wrkwin.hxx>
@@ -828,7 +829,7 @@ void SwSrcView::Load(SwDocShell* pDocShell)
else
{
Window *pTmpWindow = &GetViewFrame()->GetWindow();
- InfoBox(pTmpWindow, SW_RES(MSG_ERR_SRCSTREAM)).Execute();
+ MessageDialog(pTmpWindow, SW_RES(STR_ERR_SRCSTREAM), VCL_MESSAGE_INFO).Execute();
}
}
else
diff --git a/sw/source/uibase/uiview/uivwimp.cxx b/sw/source/uibase/uiview/uivwimp.cxx
index e2915e30c678..3c121f6dd52c 100644
--- a/sw/source/uibase/uiview/uivwimp.cxx
+++ b/sw/source/uibase/uiview/uivwimp.cxx
@@ -29,6 +29,7 @@
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
#include <comphelper/processfactory.hxx>
#include <osl/mutex.hxx>
+#include <vcl/layout.hxx>
#include <vcl/svapp.hxx>
#include <vcl/wrkwin.hxx>
#include <vcl/msgbox.hxx>
@@ -182,7 +183,7 @@ void SwView_Impl::ExecuteScan( SfxRequest& rReq )
if( !bDone )
{
- InfoBox( 0, SW_RES(MSG_SCAN_NOSOURCE) ).Execute();
+ MessageDialog( 0, SW_RES(STR_SCAN_NOSOURCE), VCL_MESSAGE_INFO ).Execute();
rReq.Ignore();
}
else
diff --git a/sw/source/uibase/uiview/view.hrc b/sw/source/uibase/uiview/view.hrc
index b90d5dae054b..8f7e78db2a05 100644
--- a/sw/source/uibase/uiview/view.hrc
+++ b/sw/source/uibase/uiview/view.hrc
@@ -31,13 +31,13 @@
#define STR_EDIT_FOOTNOTE (RC_VIEW_BEGIN + 14)
#define STR_NB_REPLACED (RC_VIEW_BEGIN + 20)
-#define MSG_SCAN_NOSOURCE (RC_VIEW_BEGIN + 21)
+#define STR_SCAN_NOSOURCE (RC_VIEW_BEGIN + 21)
#define STR_SRCVIEW_ROW (RC_VIEW_BEGIN + 22)
#define STR_SRCVIEW_COL (RC_VIEW_BEGIN + 23)
#define STR_SAVEAS_SRC (RC_VIEW_BEGIN + 24)
-#define MSG_NO_MERGE_ENTRY (RC_VIEW_BEGIN + 25)
+#define STR_NO_MERGE_ENTRY (RC_VIEW_BEGIN + 25)
#define STR_PRINT_TITLE (RC_VIEW_BEGIN + 26)
#define STR_PRINT_MSG (RC_VIEW_BEGIN + 27)
@@ -51,11 +51,8 @@
#define STR_SAVEACOPY_SRC (RC_VIEW_BEGIN + 34)
#define STR_ERR_INSERT_GLOS (RC_VIEW_BEGIN + 35)
-
-// MSG
-
-#define MSG_ERR_NO_FAX (RC_VIEW_BEGIN + 5)
-#define MSG_ERR_SRCSTREAM (RC_VIEW_BEGIN + 6)
+#define STR_ERR_NO_FAX (RC_VIEW_BEGIN + 36)
+#define STR_ERR_SRCSTREAM (RC_VIEW_BEGIN + 37)
// DLG
diff --git a/sw/source/uibase/uiview/view.src b/sw/source/uibase/uiview/view.src
index e85ad5dd7209..70dcff103b22 100644
--- a/sw/source/uibase/uiview/view.src
+++ b/sw/source/uibase/uiview/view.src
@@ -32,21 +32,21 @@ QueryBox DLG_SPECIAL_FORCED
DEFBUTTON = WB_DEF_NO ;
Message [ en-US ] = "Check special regions is deactivated. Check anyway?" ;
};
-InfoBox MSG_NO_MERGE_ENTRY
+String STR_NO_MERGE_ENTRY
{
- Message [ en-US ] = "Could not merge documents." ;
+ Text [ en-US ] = "Could not merge documents." ;
};
String STR_ERR_INSERT_GLOS
{
Text [ en-US ] = "AutoText could not be created." ;
};
-InfoBox MSG_ERR_SRCSTREAM
+String STR_ERR_SRCSTREAM
{
- Message [ en-US ] = "The source cannot be loaded." ;
+ Text [ en-US ] = "The source cannot be loaded." ;
};
-InfoBox MSG_ERR_NO_FAX
+String STR_ERR_NO_FAX
{
- Message [ en-US ] = "No fax printer has been set under Tools/Options/%1/Print." ;
+ Text [ en-US ] = "No fax printer has been set under Tools/Options/%1/Print." ;
};
String STR_WEBOPTIONS
{
@@ -56,9 +56,9 @@ String STR_TEXTOPTIONS
{
Text [ en-US ] = "Text document";
};
-InfoBox MSG_SCAN_NOSOURCE
+String STR_SCAN_NOSOURCE
{
- Message [ en-US ] = "Source not specified." ;
+ Text [ en-US ] = "Source not specified." ;
};
String STR_NUM_LEVEL
{
diff --git a/sw/source/uibase/uiview/view2.cxx b/sw/source/uibase/uiview/view2.cxx
index 4fbf93c8a0e4..5b5c97f464cf 100644
--- a/sw/source/uibase/uiview/view2.cxx
+++ b/sw/source/uibase/uiview/view2.cxx
@@ -57,6 +57,7 @@
#include <editeng/lrspitem.hxx>
#include <unotools/textsearch.hxx>
#include <editeng/unolingu.hxx>
+#include <vcl/layout.hxx>
#include <vcl/msgbox.hxx>
#include <editeng/tstpitem.hxx>
#include <sfx2/event.hxx>
@@ -500,7 +501,7 @@ bool SwView::InsertGraphicDlg( SfxRequest& rReq )
{
if( bShowError )
{
- InfoBox aInfoBox( GetWindow(), SW_RESSTR( nResId ));
+ MessageDialog aInfoBox( GetWindow(), SW_RESSTR( nResId ), VCL_MESSAGE_INFO);
aInfoBox.Execute();
}
rReq.Ignore();
@@ -2265,7 +2266,7 @@ long SwView::InsertMedium( sal_uInt16 nSlotId, SfxMedium* pMedium, sal_Int16 nVe
if (!bCompare && !nFound)
{
Window* pWin = &GetEditWin();
- InfoBox(pWin, SW_RES(MSG_NO_MERGE_ENTRY)).Execute();
+ MessageDialog(pWin, SW_RES(STR_NO_MERGE_ENTRY), VCL_MESSAGE_INFO).Execute();
}
if( nRet==2 && xDocSh.Is() )
xDocSh->DoClose();
diff --git a/sw/source/uibase/uiview/viewprt.cxx b/sw/source/uibase/uiview/viewprt.cxx
index ac0b151d98b3..39af799fa453 100644
--- a/sw/source/uibase/uiview/viewprt.cxx
+++ b/sw/source/uibase/uiview/viewprt.cxx
@@ -23,6 +23,7 @@
#include <sfx2/request.hxx>
#include <sfx2/progress.hxx>
#include <sfx2/app.hxx>
+#include <vcl/layout.hxx>
#include <vcl/msgbox.hxx>
#include <vcl/oldprintadaptor.hxx>
#include <sfx2/printer.hxx>
@@ -175,11 +176,9 @@ void SwView::ExecutePrint(SfxRequest& rReq)
}
else
{
- InfoBox aInfoBox(&GetEditWin(), SW_RES(MSG_ERR_NO_FAX));
- OUString sMsg = aInfoBox.GetMessText();
+ MessageDialog aInfoBox(&GetEditWin(), SW_RES(STR_ERR_NO_FAX), VCL_MESSAGE_INFO);
sal_uInt16 nResNo = bWeb ? STR_WEBOPTIONS : STR_TEXTOPTIONS;
- sMsg = sMsg.replaceFirst("%1", OUString(SW_RES(nResNo)));
- aInfoBox.SetMessText(sMsg);
+ aInfoBox.set_primary_text(aInfoBox.get_primary_text().replaceFirst("%1", OUString(SW_RES(nResNo))));
aInfoBox.Execute();
SfxUInt16Item aDefPage(SID_SW_EDITOPTIONS, TP_OPTPRINT_PAGE);
GetViewFrame()->GetDispatcher()->Execute(SID_SW_EDITOPTIONS,