From 97729079cd2ac8aab0cea36b534837bd38514a34 Mon Sep 17 00:00:00 2001 From: jp Date: Mon, 20 Nov 2000 08:07:00 +0000 Subject: should change: use LocaleDataWrapper --- sw/source/ui/config/viewopt.cxx | 32 ++++++++--- sw/source/ui/fldui/fldmgr.cxx | 120 +++++++++++++++++++++++++-------------- sw/source/ui/misc/pgfnote.cxx | 55 +++++++++++++----- sw/source/ui/uiview/viewling.cxx | 17 ++++-- sw/source/ui/utlui/initui.cxx | 17 +++--- sw/source/ui/utlui/numfmtlb.cxx | 55 ++++++++++++------ 6 files changed, 201 insertions(+), 95 deletions(-) diff --git a/sw/source/ui/config/viewopt.cxx b/sw/source/ui/config/viewopt.cxx index 3d8123a8423e..d39418798e0a 100644 --- a/sw/source/ui/config/viewopt.cxx +++ b/sw/source/ui/config/viewopt.cxx @@ -2,9 +2,9 @@ * * $RCSfile: viewopt.cxx,v $ * - * $Revision: 1.1.1.1 $ + * $Revision: 1.2 $ * - * last change: $Author: hr $ $Date: 2000-09-18 17:14:33 $ + * last change: $Author: jp $ $Date: 2000-11-20 09:07:00 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -83,12 +83,25 @@ #ifndef _MySVXACORR_HXX //autogen #include #endif +#ifndef _UNOTOOLS_LOCALEDATAWRAPPER_HXX +#include +#endif -#include "swtypes.hxx" -#include "viewopt.hxx" -#include "wdocsh.hxx" -#include "swrect.hxx" -#include "crstate.hxx" +#ifndef _SWTYPES_HXX +#include +#endif +#ifndef _VIEWOPT_HXX +#include +#endif +#ifndef _WDOCSH_HXX +#include +#endif +#ifndef _SWRECT_HXX +#include +#endif +#ifndef _CRSTATE_HXX +#include +#endif #ifndef PRODUCT @@ -444,7 +457,7 @@ SwViewOption::SwViewOption() : nUIOptions = VIEWOPT_2_MODIFIED | VIEWOPT_2_EXECHYPERLINKS; MeasurementSystem eSys = Application::GetAppInternational().GetMeasurementSystem(); - if(MEASURE_METRIC != eSys) + if(MEASURE_METRIC != GetAppLocaleData().getMeasurementSystemEnum()) aSnapSize.Width() = aSnapSize.Height() = 720; // 1/2" else aSnapSize.Width() = aSnapSize.Height() = 567; // 1 cm @@ -611,6 +624,9 @@ USHORT GetHtmlMode(const SwDocShell* pShell) /************************************************************************ $Log: not supported by cvs2svn $ + Revision 1.1.1.1 2000/09/18 17:14:33 hr + initial import + Revision 1.57 2000/09/18 16:05:18 willem.vandorp OpenOffice header added. diff --git a/sw/source/ui/fldui/fldmgr.cxx b/sw/source/ui/fldui/fldmgr.cxx index 171d22adc261..3b8ff94a406c 100644 --- a/sw/source/ui/fldui/fldmgr.cxx +++ b/sw/source/ui/fldui/fldmgr.cxx @@ -2,9 +2,9 @@ * * $RCSfile: fldmgr.cxx,v $ * - * $Revision: 1.3 $ + * $Revision: 1.4 $ * - * last change: $Author: os $ $Date: 2000-10-27 11:24:22 $ + * last change: $Author: jp $ $Date: 2000-11-20 09:06:40 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -65,14 +65,12 @@ #pragma hdrstop -#include "cmdid.h" -#include "view.hxx" -#include "wrtsh.hxx" // Actives Fenster -#include "doc.hxx" // Actives Fenster -#include "docsh.hxx" // Actives Fenster -#include "swmodule.hxx" -#include "hintids.hxx" -#include "charatr.hxx" +#ifndef _CMDID_H +#include +#endif +#ifndef _HINTIDS_HXX +#include +#endif #ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_ #include @@ -101,94 +99,132 @@ #ifndef _COMPHELPER_PROCESSFACTORY_HXX_ #include #endif +#ifndef _UNO_LINGU_HXX +#include +#endif +#ifndef _UNOTOOLS_LOCALEDATAWRAPPER_HXX +#include +#endif #ifndef _SFXDISPATCH_HXX //autogen #include #endif - #ifndef _SFXDOCINF_HXX //autogen #include #endif - #ifndef _SFX_OBJSH_HXX //autogen #include #endif - #ifndef _LINKMGR_HXX //autogen #include #endif - #ifndef _BASMGR_HXX //autogen #include #endif - #ifndef _SVX_LANGITEM_HXX //autogen #include #endif - #ifndef _SFXMACITEM_HXX //autogen #include #endif - #ifndef _SB_SBMOD_HXX //autogen #include #endif - #ifndef _FMTRFMRK_HXX //autogen #include #endif - #ifndef _SFXAPP_HXX //autogen #include #endif - #ifndef _SB_SBSTAR_HXX //autogen #include #endif - #ifndef _SB_SBMETH_HXX //autogen #include #endif - #ifndef _SBXCLASS_HXX //autogen #include #endif #ifndef _BASOBJ_HXX //autogen #include #endif - #ifndef _ZFORLIST_HXX //autogen #include #endif - #ifndef _ZFORMAT_HXX //autogen #include #endif - #ifndef _SB_SBMOD_HXX //autogen #include #endif + +#ifndef _VIEW_HXX +#include +#endif +#ifndef _WRTSH_HXX +#include // Actives Fenster +#endif +#ifndef _DOC_HXX +#include // Actives Fenster +#endif +#ifndef _DOCSH_HXX +#include // Actives Fenster +#endif +#ifndef _SWMODULE_HXX +#include +#endif +#ifndef _CHARATR_HXX +#include +#endif #ifndef _FMTINFMT_HXX //autogen #include #endif #ifndef _CELLATR_HXX #include #endif -#include "dbmgr.hxx" -#include "shellres.hxx" -#include "fldbas.hxx" -#include "docufld.hxx" -#include "chpfld.hxx" -#include "ddefld.hxx" -#include "expfld.hxx" -#include "reffld.hxx" -#include "usrfld.hxx" -#include "dbfld.hxx" -#include "authfld.hxx" -#include "flddat.hxx" -#include "fldmgr.hxx" - -#include "fldui.hrc" +#ifndef _DBMGR_HXX +#include +#endif +#ifndef _SHELLRES_HXX +#include +#endif +#ifndef _FLDBAS_HXX +#include +#endif +#ifndef _DOCUFLD_HXX +#include +#endif +#ifndef _CHPFLD_HXX +#include +#endif +#ifndef _DDEFLD_HXX +#include +#endif +#ifndef _EXPFLD_HXX +#include +#endif +#ifndef _REFFLD_HXX +#include +#endif +#ifndef _USRFLD_HXX +#include +#endif +#ifndef _DBFLD_HXX +#include +#endif +#ifndef _AUTHFLD_HXX +#include +#endif +#ifndef _FLDDAT_HXX +#include +#endif +#ifndef _FLDMGR_HXX +#include +#endif + +#ifndef _FLDUI_HRC +#include +#endif using namespace rtl; using namespace com::sun::star::uno; @@ -1760,9 +1796,7 @@ USHORT SwFldMgr::GetCurrLanguage() const return ((const SvxLanguageItem&)aSet.Get( RES_CHRATR_LANGUAGE ) ).GetLanguage(); } - LanguageType eCurLanguage = GetpApp()->GetAppInternational().GetLanguage(); - - return (USHORT)eCurLanguage; + return SvxLocaleToLanguage( GetAppLocaleData().getLocale() ); } void SwFieldType::_GetFldName() diff --git a/sw/source/ui/misc/pgfnote.cxx b/sw/source/ui/misc/pgfnote.cxx index c60da0aee7d9..071c91ffb8f9 100644 --- a/sw/source/ui/misc/pgfnote.cxx +++ b/sw/source/ui/misc/pgfnote.cxx @@ -2,9 +2,9 @@ * * $RCSfile: pgfnote.cxx,v $ * - * $Revision: 1.1.1.1 $ + * $Revision: 1.2 $ * - * last change: $Author: hr $ $Date: 2000-09-18 17:14:45 $ + * last change: $Author: jp $ $Date: 2000-11-20 09:04:01 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -65,14 +65,19 @@ #pragma hdrstop +#ifndef _CMDID_H +#include +#endif +#ifndef _HINTIDS_HXX +#include +#endif +#ifndef _UIPARAM_HXX +#include +#endif + #ifndef _REF_HXX //to avoid internal compiler errors #include #endif - -#include "cmdid.h" -#include "hintids.hxx" -#include "uiparam.hxx" - #ifndef _SVX_DIALOGS_HRC #include #endif @@ -82,16 +87,33 @@ #ifndef _SV_SVAPP_HXX #include #endif +#ifndef _UNOTOOLS_LOCALEDATAWRAPPER_HXX +#include +#endif -#include "uitool.hxx" -#include "globals.hrc" -#include "pagedesc.hxx" -#include "pgfnote.hxx" -#include "uiitems.hxx" +#ifndef _UITOOL_HXX +#include +#endif +#ifndef _PAGEDESC_HXX +#include +#endif +#ifndef _PGFNOTE_HXX +#include +#endif +#ifndef _UIITEMS_HXX +#include +#endif -#include "misc.hrc" -#include "pgfnote.hrc" +#ifndef _GLOBALS_HRC +#include +#endif +#ifndef _MISC_HRC +#include +#endif +#ifndef _PGFNOTE_HRC +#include +#endif #define TWIP_TO_LBOX 5 /*-----------------------------------------------------#--------------- @@ -211,7 +233,7 @@ SwFootNotePage::SwFootNotePage(Window *pParent, const SfxItemSet &rSet) : SetMetric( aMaxHeightEdit, aMetric ); SetMetric( aDistEdit, aMetric ); SetMetric( aLineDistEdit, aMetric ); - MeasurementSystem eSys = Application::GetAppInternational().GetMeasurementSystem(); + MeasurementSystem eSys = GetAppLocaleData().getMeasurementSystemEnum(); long nHeightValue = MEASURE_METRIC != eSys ? 1440 : 1134; aMaxHeightEdit.SetValue(aMaxHeightEdit.Normalize(nHeightValue),FUNIT_TWIP);; } @@ -385,6 +407,9 @@ USHORT* SwFootNotePage::GetRanges() /*------------------------------------------------------------------------ $Log: not supported by cvs2svn $ + Revision 1.1.1.1 2000/09/18 17:14:45 hr + initial import + Revision 1.79 2000/09/18 16:05:59 willem.vandorp OpenOffice header added. diff --git a/sw/source/ui/uiview/viewling.cxx b/sw/source/ui/uiview/viewling.cxx index 9a60e425a637..093b1fbae778 100644 --- a/sw/source/ui/uiview/viewling.cxx +++ b/sw/source/ui/uiview/viewling.cxx @@ -2,9 +2,9 @@ * * $RCSfile: viewling.cxx,v $ * - * $Revision: 1.4 $ + * $Revision: 1.5 $ * - * last change: $Author: tl $ $Date: 2000-11-19 11:41:10 $ + * last change: $Author: jp $ $Date: 2000-11-20 09:05:50 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -65,8 +65,12 @@ #pragma hdrstop -#include "hintids.hxx" -#include "uiparam.hxx" // fuer ITEMID_SPELLCHECK (muss _vor_ sfxdlg.hxx!) +#ifndef _HINTIDS_HXX +#include +#endif +#ifndef _UIPARAM_HXX +#include // fuer ITEMID_SPELLCHECK (muss _vor_ sfxdlg.hxx!) +#endif #ifndef _SVSTDARR_HXX @@ -86,6 +90,9 @@ #ifndef _UNO_LINGU_HXX #include #endif +#ifndef _UNOTOOLS_LOCALEDATAWRAPPER_HXX +#include +#endif #ifndef _SVX_THESDLG_HXX //autogen @@ -580,7 +587,7 @@ void SwView::StartThesaurus() RES_CHRATR_LANGUAGE ); LanguageType eLang = rLang.GetLanguage(); if ( ( eLang == LANGUAGE_SYSTEM ) && - ( ((eLang=GetpApp()->GetAppInternational().GetLanguage())==LANGUAGE_SYSTEM ) + ( ((eLang=SvxLocaleToLanguage( GetAppLocaleData().getLocale() ))==LANGUAGE_SYSTEM ) && ( ( eLang=::GetSystemLanguage() ) == LANGUAGE_SYSTEM ) ) ) eLang = LANGUAGE_DONTKNOW; diff --git a/sw/source/ui/utlui/initui.cxx b/sw/source/ui/utlui/initui.cxx index 28f0171998d7..e712f7638bcb 100644 --- a/sw/source/ui/utlui/initui.cxx +++ b/sw/source/ui/utlui/initui.cxx @@ -2,9 +2,9 @@ * * $RCSfile: initui.cxx,v $ * - * $Revision: 1.2 $ + * $Revision: 1.3 $ * - * last change: $Author: jp $ $Date: 2000-10-06 13:39:19 $ + * last change: $Author: jp $ $Date: 2000-11-20 09:02:23 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -65,8 +65,8 @@ #pragma hdrstop -#ifndef _SV_SVAPP_HXX //autogen -#include +#ifndef _UNOTOOLS_LOCALEDATAWRAPPER_HXX +#include #endif #ifndef _VIEWSH_HXX #include @@ -250,15 +250,15 @@ ImpAutoFmtNameListLoader::ImpAutoFmtNameListLoader( SvStringsDtor& rLst ) String* p = new String( ResId( n + 1, pSwResMgr) ); if(STR_AUTOFMTREDL_TYPO == n) { - const International& rInt = Application::GetAppInternational(); + LocaleDataWrapper& rLclD = GetAppLocaleData(); #ifdef WNT //fuer Windows Sonderbehandlung, da MS hier ein paar Zeichen im Dialogfont vergessen hat p->SearchAndReplace(C2S("%1"), C2S(",,")); p->SearchAndReplace(C2S("%2"), C2S("''")); #else //unter richtigen Betriebssystemen funktioniert es auch so - p->SearchAndReplace(C2S("%1"), rInt.GetDoubleQuotationMarkStartChar()); - p->SearchAndReplace(C2S("%2"), rInt.GetDoubleQuotationMarkEndChar()); + p->SearchAndReplace(C2S("%1"), rLclD.getDoubleQuotationMarkStartChar()); + p->SearchAndReplace(C2S("%2"), rLclD.getDoubleQuotationMarkEndChar()); #endif } rLst.Insert( p, n ); @@ -302,6 +302,9 @@ const String& SwAuthorityFieldType::GetAuthTypeName(ToxAuthorityType eType) /************************************************************************* $Log: not supported by cvs2svn $ + Revision 1.2 2000/10/06 13:39:19 jp + should changes: don't use IniManager + Revision 1.1.1.1 2000/09/18 17:14:50 hr initial import diff --git a/sw/source/ui/utlui/numfmtlb.cxx b/sw/source/ui/utlui/numfmtlb.cxx index 28e604a8811b..97de03864b7a 100644 --- a/sw/source/ui/utlui/numfmtlb.cxx +++ b/sw/source/ui/utlui/numfmtlb.cxx @@ -2,9 +2,9 @@ * * $RCSfile: numfmtlb.cxx,v $ * - * $Revision: 1.3 $ + * $Revision: 1.4 $ * - * last change: $Author: os $ $Date: 2000-10-20 14:18:07 $ + * last change: $Author: jp $ $Date: 2000-11-20 09:02:23 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -64,7 +64,9 @@ #pragma hdrstop -#include "hintids.hxx" +#ifndef _HINTIDS_HXX +#include +#endif #ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_ #include @@ -73,8 +75,11 @@ #include #endif -#ifndef _SV_SVAPP_HXX //autogen -#include +#ifndef _UNO_LINGU_HXX +#include +#endif +#ifndef _UNOTOOLS_LOCALEDATAWRAPPER_HXX +#include #endif #ifndef _LANG_HXX //autogen #include @@ -105,19 +110,32 @@ #ifndef _SVX_NUMFMT_HXX //autogen #include #endif -#ifndef _SV_SYSTEM_HXX //autogen -#include -#endif -#include "tblnumfm.hxx" -#include "docsh.hxx" -#include "swtypes.hxx" -#include "swmodule.hxx" -#include "view.hxx" -#include "wrtsh.hxx" +#ifndef _TBLNUMFM_HXX +#include +#endif +#ifndef _DOCSH_HXX +#include +#endif +#ifndef _SWTYPES_HXX +#include +#endif +#ifndef _SWMODULE_HXX +#include +#endif +#ifndef _VIEW_HXX +#include +#endif +#ifndef _WRTSH_HXX +#include +#endif +#ifndef _NUMFMTLB_HXX +#include +#endif -#include "utlui.hrc" -#include "numfmtlb.hxx" +#ifndef _UTLUI_HRC +#include +#endif using namespace ::com::sun::star::uno; @@ -181,7 +199,7 @@ void NumFormatListBox::Init(short nFormatType, BOOL bUsrFmts) eCurLanguage = ((const SvxLanguageItem&)aSet.Get( RES_CHRATR_LANGUAGE ) ).GetLanguage(); } else - eCurLanguage = Application::GetAppInternational().GetLanguage(); + eCurLanguage = SvxLocaleToLanguage( GetAppLocaleData().getLocale() ); if (bUsrFmts == FALSE) { @@ -601,6 +619,9 @@ void NumFormatListBox::Clear() Source Code Control System - History $Log: not supported by cvs2svn $ + Revision 1.3 2000/10/20 14:18:07 os + use comphelper methods + Revision 1.2 2000/10/20 09:51:30 os change: use SvNumberFormatter ctor using XMultiServiceFactory -- cgit v1.2.3