summaryrefslogtreecommitdiff
path: root/sfx2
diff options
context:
space:
mode:
authorJens-Heiner Rechtien <hr@openoffice.org>2009-01-06 17:37:13 +0000
committerJens-Heiner Rechtien <hr@openoffice.org>2009-01-06 17:37:13 +0000
commit980442418868a7a187988bba0660b9d0e4d8af96 (patch)
treedc2c64c8e03e44c167d878749324625227da0ca4 /sfx2
parent1a5e9b8ae738288c44e66c2deafa147db84a1db3 (diff)
CWS-TOOLING: integrate CWS fwk98
2008-12-12 22:28:04 +0100 pb r265444 : fix: #i44211# precompiled directive was missed 2008-12-11 10:43:34 +0100 pb r265262 : fix: #i87952# #i84982# SID_INSERT_APPLET and SID_CHAR_DLG_FOR_PARAGRAPH not configurable any longer 2008-12-11 10:40:05 +0100 pb r265261 : fix: #i64346# SID_MAIL_SENDDOCASFORMAT not configurable any longer 2008-12-11 10:36:53 +0100 pb r265260 : fix: #i41265# #i64346# ui name for MacroOrganizer and SendMailDocAs... 2008-12-11 10:29:07 +0100 pb r265258 : fix: #i60617# #i92080# ui name for ContinueNumbering and SaveGraphic 2008-12-11 10:25:52 +0100 pb r265256 : fix: #i80850# ui name for ToggleFormula and AssignMacro 2008-12-08 14:16:20 +0100 pb r264996 : fix: #i44211# querytemplate.obj added 2008-12-08 12:54:02 +0100 pb r264992 : fix: #i44211# use the new query template box 2008-12-08 12:50:45 +0100 pb r264991 : fix: #i44211# STR_QRYTEMPL_... added 2008-12-08 12:48:21 +0100 pb r264990 : fix: #i44211# new query box 2008-12-02 11:06:54 +0100 pb r264681 : fix: #i88478# ScStyleFamilyObj: XPropertySet support added 2008-12-02 11:05:29 +0100 pb r264680 : fix: #i88478# STR_STYLE_FAMILY_... added 2008-12-02 11:03:22 +0100 pb r264679 : fix: #i88478# ScStyleFamilyObj: XPropertySet support added 2008-12-02 10:54:27 +0100 pb r264678 : fix: #i88478# STR_STYLE_FAMILY_... added 2008-12-02 10:50:16 +0100 pb r264677 : fix: #i88478# SwXStyleFamily: XpropertySet support added 2008-12-02 10:48:12 +0100 pb r264676 : fix: #i88478# STR_STYLE_FAMILY_... added 2008-12-02 10:45:46 +0100 pb r264674 : fix: #i88478# SwXStyleFamily: XpropertySet support added 2008-12-02 10:43:44 +0100 pb r264673 : fix: #i88478# STR_STYLE_FAMILY_... added 2008-12-02 10:40:45 +0100 pb r264671 : fix: #i88478# table.srs added 2008-12-02 10:37:45 +0100 pb r264669 : fix: #i88478# dummy text of DisplayName replaced 2008-12-02 10:35:26 +0100 pb r264668 : fix: #i88478# RID_SVXSTR_STYLEFAMILY_TABLEDESIGN added 2008-12-02 10:30:24 +0100 pb r264666 : fix: #i88478# RID_SVXSTR_STYLEFAMILY_TABLEDESIGN added 2008-11-24 10:42:03 +0100 pb r264214 : fix: #i92765# set search algorithm with sense 2008-11-24 07:02:31 +0100 pb r264194 : fix: #i61775# dont display more than 100 fonts 2008-11-24 06:15:20 +0100 pb r264193 : fix: #i96418# map module swxform to swriter for help 2008-11-20 11:34:21 +0100 pb r264035 : fix: #i93453# map 'swform' and 'swreport' to 'sdatabase' 2008-11-20 09:55:30 +0100 pb r264030 : fix: #i94023# after copy a ResId dont forget to set RT correctly
Diffstat (limited to 'sfx2')
-rw-r--r--sfx2/sdi/sfx.sdi6
-rw-r--r--sfx2/source/appl/sfxhelp.cxx31
-rw-r--r--sfx2/source/control/srchitem.cxx8
-rw-r--r--sfx2/source/dialog/templdlg.cxx1
-rw-r--r--sfx2/source/doc/doc.hrc6
-rw-r--r--sfx2/source/doc/doc.src15
-rw-r--r--sfx2/source/doc/makefile.mk5
-rw-r--r--sfx2/source/doc/objcont.cxx5
-rw-r--r--sfx2/source/doc/querytemplate.cxx55
-rw-r--r--sfx2/source/doc/querytemplate.hxx47
10 files changed, 151 insertions, 28 deletions
diff --git a/sfx2/sdi/sfx.sdi b/sfx2/sdi/sfx.sdi
index d397f2906a22..bc74b1be3946 100644
--- a/sfx2/sdi/sfx.sdi
+++ b/sfx2/sdi/sfx.sdi
@@ -6226,10 +6226,10 @@ SfxBoolItem SendMailDocAsFormat SID_MAIL_SENDDOCASFORMAT
SlotType = SfxStringItem
/* config: */
- AccelConfig = TRUE,
- MenuConfig = TRUE,
+ AccelConfig = FALSE,
+ MenuConfig = FALSE,
StatusBarConfig = FALSE,
- ToolBoxConfig = TRUE,
+ ToolBoxConfig = FALSE,
GroupId = GID_DOCUMENT;
]
diff --git a/sfx2/source/appl/sfxhelp.cxx b/sfx2/source/appl/sfxhelp.cxx
index fe65cc931791..f419bc3e3d55 100644
--- a/sfx2/source/appl/sfxhelp.cxx
+++ b/sfx2/source/appl/sfxhelp.cxx
@@ -549,25 +549,22 @@ String SfxHelp::GetHelpModuleName_Impl()
aFactoryShortName = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "schart" ) );
else if ( aFactoryShortName.equalsAscii( "BasicIDE" ) )
aFactoryShortName = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "sbasic" ) );
- else if ( aFactoryShortName.equalsAscii( "sweb" ) )
+ else if ( aFactoryShortName.equalsAscii( "sweb" )
+ || aFactoryShortName.equalsAscii( "sglobal" )
+ || aFactoryShortName.equalsAscii( "swxform" ) )
aFactoryShortName = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "swriter" ) );
- else if ( aFactoryShortName.equalsAscii( "sglobal" ) )
- aFactoryShortName = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "swriter" ) );
- else if ( aFactoryShortName.equalsAscii( "dbquery" ) )
- aFactoryShortName = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "sdatabase" ) );
- else if ( aFactoryShortName.equalsAscii( "dbbrowser" ) )
- aFactoryShortName = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "sdatabase" ) );
- else if ( aFactoryShortName.equalsAscii( "dbrelation" ) )
- aFactoryShortName = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "sdatabase" ) );
- else if ( aFactoryShortName.equalsAscii( "dbtable" ) )
+ else if ( aFactoryShortName.equalsAscii( "dbquery" )
+ || aFactoryShortName.equalsAscii( "dbbrowser" )
+ || aFactoryShortName.equalsAscii( "dbrelation" )
+ || aFactoryShortName.equalsAscii( "dbtable" )
+ || aFactoryShortName.equalsAscii( "dbapp" )
+ || aFactoryShortName.equalsAscii( "dbreport" )
+ || aFactoryShortName.equalsAscii( "swreport" )
+ || aFactoryShortName.equalsAscii( "dbbrowser" )
+ || aFactoryShortName.equalsAscii( "swform" ) )
aFactoryShortName = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "sdatabase" ) );
- else if ( aFactoryShortName.equalsAscii( "dbapp" ) )
- aFactoryShortName = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "sdatabase" ) );
- else if ( aFactoryShortName.equalsAscii( "dbreport" ) )
- aFactoryShortName = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "sdatabase" ) );
- else if ( aFactoryShortName.equalsAscii( "sbibliography" ) )
- aFactoryShortName = sDefaultModule;
- else if ( aFactoryShortName.equalsAscii( "StartModule" ) )
+ else if ( aFactoryShortName.equalsAscii( "sbibliography" )
+ || aFactoryShortName.equalsAscii( "StartModule" ) )
aFactoryShortName = sDefaultModule;
}
else
diff --git a/sfx2/source/control/srchitem.cxx b/sfx2/source/control/srchitem.cxx
index 3d499e5e263f..8f1507a45610 100644
--- a/sfx2/source/control/srchitem.cxx
+++ b/sfx2/source/control/srchitem.cxx
@@ -404,9 +404,9 @@ void SvxSearchItem::SetSelection( sal_Bool bVal )
void SvxSearchItem::SetRegExp( sal_Bool bVal )
{
- if (bVal)
+ if ( bVal )
aSearchOpt.algorithmType = SearchAlgorithms_REGEXP;
- else
+ else if ( SearchAlgorithms_REGEXP == aSearchOpt.algorithmType )
aSearchOpt.algorithmType = SearchAlgorithms_ABSOLUTE;
}
@@ -422,9 +422,9 @@ void SvxSearchItem::SetLEVRelaxed( sal_Bool bVal )
void SvxSearchItem::SetLevenshtein( sal_Bool bVal )
{
- if (bVal)
+ if ( bVal )
aSearchOpt.algorithmType = SearchAlgorithms_APPROXIMATE;
- else
+ else if ( SearchAlgorithms_APPROXIMATE == aSearchOpt.algorithmType )
aSearchOpt.algorithmType = SearchAlgorithms_ABSOLUTE;
}
diff --git a/sfx2/source/dialog/templdlg.cxx b/sfx2/source/dialog/templdlg.cxx
index 01d0de93cd9c..ad87e2867eae 100644
--- a/sfx2/source/dialog/templdlg.cxx
+++ b/sfx2/source/dialog/templdlg.cxx
@@ -873,6 +873,7 @@ void SfxCommonTemplateDialog_Impl::ReadResource()
ResId aFamId( DLG_STYLE_DESIGNER, *pMgr );
aFamId.SetRT(RSC_SFX_STYLE_FAMILIES);
m_pStyleFamiliesId = new ResId( aFamId.GetId(), *pMgr );
+ m_pStyleFamiliesId->SetRT(RSC_SFX_STYLE_FAMILIES);
if( !pMgr || !pMgr->IsAvailable( aFamId ) )
pStyleFamilies = new SfxStyleFamilies;
else
diff --git a/sfx2/source/doc/doc.hrc b/sfx2/source/doc/doc.hrc
index b17a11b40f24..ae4ff419565c 100644
--- a/sfx2/source/doc/doc.hrc
+++ b/sfx2/source/doc/doc.hrc
@@ -211,8 +211,12 @@
#define MSG_XMLSEC_QUERY_SAVESIGNEDBEFORESIGN (RID_SFX_DOC_START+125)
#define STR_XMLSEC_ODF12_EXPECTED (RID_SFX_DOC_START+126)
+#define STR_QRYTEMPL_MESSAGE (RID_SFX_DOC_START+127)
+#define STR_QRYTEMPL_UPDATE_BTN (RID_SFX_DOC_START+128)
+#define STR_QRYTEMPL_KEEP_BTN (RID_SFX_DOC_START+129)
+
// please update to the last id
-#define ACT_SFX_DOC_END STR_XMLSEC_ODF12_EXPECTED
+#define ACT_SFX_DOC_END STR_QRYTEMPL_KEEP_BTN
#if ACT_SFX_DOC_END > RID_SFX_DOC_END
#error resource overflow in #line, #file
#endif
diff --git a/sfx2/source/doc/doc.src b/sfx2/source/doc/doc.src
index 1d10290cb167..3f8ab1ae7177 100644
--- a/sfx2/source/doc/doc.src
+++ b/sfx2/source/doc/doc.src
@@ -520,5 +520,20 @@ QueryBox MSG_XMLSEC_QUERY_SAVESIGNEDBEFORESIGN
Message [ en-US ] = "The document has to be saved before it can be signed. Saving the document removes all present signatures.\nDo you want to save the document?";
};
+String STR_QRYTEMPL_MESSAGE
+{
+ Text [ en-US ] = "The template '$(ARG1)' on which this document is based, has been modified. Do you want to update style based formattings according to the modified template?";
+};
+
+String STR_QRYTEMPL_UPDATE_BTN
+{
+ Text [ en-US ] = "~Update Styles";
+};
+
+String STR_QRYTEMPL_KEEP_BTN
+{
+ Text [ en-US ] = "~Keep Old Styles";
+};
+
// ******************************************************************* EOF
diff --git a/sfx2/source/doc/makefile.mk b/sfx2/source/doc/makefile.mk
index c2398fdd74bf..b46ee5aa30e8 100644
--- a/sfx2/source/doc/makefile.mk
+++ b/sfx2/source/doc/makefile.mk
@@ -1,7 +1,7 @@
#*************************************************************************
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# Copyright 2008 by Sun Microsystems, Inc.
#
# OpenOffice.org - a multi-platform office productivity suite
@@ -81,7 +81,8 @@ SLOFILES = \
$(SLO)$/docmacromode.obj \
$(SLO)$/SfxDocumentMetaData.obj \
$(SLO)$/sfxmodelfactory.obj \
- $(SLO)$/docstoragemodifylistener.obj
+ $(SLO)$/docstoragemodifylistener.obj \
+ $(SLO)$/querytemplate.obj
# --- Tagets -------------------------------------------------------
diff --git a/sfx2/source/doc/objcont.cxx b/sfx2/source/doc/objcont.cxx
index df77e397bf81..b7c2791cde32 100644
--- a/sfx2/source/doc/objcont.cxx
+++ b/sfx2/source/doc/objcont.cxx
@@ -84,6 +84,7 @@
#include <sfx2/docfile.hxx>
#include <sfx2/request.hxx>
#include "openflag.hxx"
+#include "querytemplate.hxx"
using namespace ::com::sun::star;
using namespace ::com::sun::star::uno;
@@ -1320,7 +1321,9 @@ void SfxObjectShell::UpdateFromTemplate_Impl( )
bLoad = TRUE;
else if ( bCanUpdateFromTemplate == document::UpdateDocMode::ACCORDING_TO_CONFIG )
{
- QueryBox aBox( GetDialogParent(), SfxResId(MSG_QUERY_LOAD_TEMPLATE) );
+ String sMessage( SfxResId( STR_QRYTEMPL_MESSAGE ) );
+ sMessage.SearchAndReplace( String::CreateFromAscii("$(ARG1)"), aTemplName );
+ sfx2::QueryTemplateBox aBox( GetDialogParent(), sMessage );
if ( RET_YES == aBox.Execute() )
bLoad = TRUE;
}
diff --git a/sfx2/source/doc/querytemplate.cxx b/sfx2/source/doc/querytemplate.cxx
new file mode 100644
index 000000000000..d430205a831e
--- /dev/null
+++ b/sfx2/source/doc/querytemplate.cxx
@@ -0,0 +1,55 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * $RCSfile: openlocked.cxx,v $
+ * $Revision: 1.3 $
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+// MARKER(update_precomp.py): autogen include statement, do not remove
+#include "precompiled_sfx2.hxx"
+
+#include "querytemplate.hxx"
+#include "sfxresid.hxx"
+#include "doc.hrc"
+
+#include <vcl/svapp.hxx>
+
+namespace sfx2
+{
+
+QueryTemplateBox::QueryTemplateBox( Window* pParent, const String& rMessage ) :
+ MessBox ( pParent, 0, Application::GetDisplayName(), rMessage )
+{
+ SetImage( QueryBox::GetStandardImage() );
+ SetHelpId( MSG_QUERY_LOAD_TEMPLATE );
+
+ AddButton( String( SfxResId( STR_QRYTEMPL_UPDATE_BTN ) ), RET_YES,
+ BUTTONDIALOG_DEFBUTTON | BUTTONDIALOG_OKBUTTON | BUTTONDIALOG_FOCUSBUTTON );
+ AddButton( String( SfxResId( STR_QRYTEMPL_KEEP_BTN ) ), RET_NO, BUTTONDIALOG_CANCELBUTTON );
+}
+
+} // end of namespace sfx2
+
diff --git a/sfx2/source/doc/querytemplate.hxx b/sfx2/source/doc/querytemplate.hxx
new file mode 100644
index 000000000000..71f709db06dd
--- /dev/null
+++ b/sfx2/source/doc/querytemplate.hxx
@@ -0,0 +1,47 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * $RCSfile: openlocked.hxx,v $
+ * $Revision: 1.3 $
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+#ifndef _SFX2_QUERYTEMPLATE_HXX
+#define _SFX2_QUERYTEMPLATE_HXX
+
+#include <vcl/msgbox.hxx>
+
+namespace sfx2
+{
+
+ class QueryTemplateBox : public MessBox
+ {
+ public:
+ QueryTemplateBox( Window* pParent, const String& rMessage );
+ };
+
+} // end of namespace sfx2
+
+#endif
+