Kaydet (Commit) d9ef81c0 authored tarafından Oliver Specht's avatar Oliver Specht

use of configuration service in view options

üst dbe6385a
...@@ -2,9 +2,9 @@ ...@@ -2,9 +2,9 @@
* *
* $RCSfile: swmodule.hxx,v $ * $RCSfile: swmodule.hxx,v $
* *
* $Revision: 1.1.1.1 $ * $Revision: 1.2 $
* *
* last change: $Author: hr $ $Date: 2000-09-18 17:14:28 $ * last change: $Author: os $ $Date: 2000-09-28 15:21:23 $
* *
* The Contents of this file are made available subject to the terms of * The Contents of this file are made available subject to the terms of
* either of the following licenses * either of the following licenses
...@@ -82,6 +82,9 @@ ...@@ -82,6 +82,9 @@
#ifndef _COM_SUN_STAR_LINGUISTIC_XDICTIONARYLISTEVENTLISTENER_HPP_ #ifndef _COM_SUN_STAR_LINGUISTIC_XDICTIONARYLISTEVENTLISTENER_HPP_
#include <com/sun/star/linguistic/XDictionaryListEventListener.hpp> #include <com/sun/star/linguistic/XDictionaryListEventListener.hpp>
#endif #endif
#ifndef _VCL_FLDUNIT_HXX
#include <vcl/fldunit.hxx>
#endif
class SvStringsDtor; class SvStringsDtor;
class Color; class Color;
...@@ -191,11 +194,14 @@ public: ...@@ -191,11 +194,14 @@ public:
void ExecDB(SfxRequest &); // DBManager void ExecDB(SfxRequest &); // DBManager
// Benutzereinstellungen modifizieren // Benutzereinstellungen modifizieren
const SwMasterUsrPref *GetUsrPref(sal_Bool bWeb); const SwMasterUsrPref *GetUsrPref(sal_Bool bWeb) const;
const SwViewOption* GetViewOption(sal_Bool bWeb); const SwViewOption* GetViewOption(sal_Bool bWeb);
void MakeUsrPref( SwViewOption &rToFill, sal_Bool bWeb ) const; void MakeUsrPref( SwViewOption &rToFill, sal_Bool bWeb ) const;
void ApplyUsrPref(const SwViewOption &, SwView*, void ApplyUsrPref(const SwViewOption &, SwView*,
sal_uInt16 nDest = VIEWOPT_DEST_VIEW ); sal_uInt16 nDest = VIEWOPT_DEST_VIEW );
void ApplyUserMetric( FieldUnit eMetric, BOOL bWeb );
void ApplyFldUpdateFlags(sal_Int32 nFldFlags);
void ApplyLinkMode(sal_Int32 nNewLinkMode);
// ConfigItems erzeugen // ConfigItems erzeugen
SwSrcViewConfig* GetSourceViewConfig(); SwSrcViewConfig* GetSourceViewConfig();
......
...@@ -2,9 +2,9 @@ ...@@ -2,9 +2,9 @@
* *
* $RCSfile: viewopt.hxx,v $ * $RCSfile: viewopt.hxx,v $
* *
* $Revision: 1.1.1.1 $ * $Revision: 1.2 $
* *
* last change: $Author: hr $ $Date: 2000-09-18 17:14:29 $ * last change: $Author: os $ $Date: 2000-09-28 15:21:23 $
* *
* The Contents of this file are made available subject to the terms of * The Contents of this file are made available subject to the terms of
* either of the following licenses * either of the following licenses
...@@ -119,16 +119,16 @@ class SwDocShell; ...@@ -119,16 +119,16 @@ class SwDocShell;
#define VIEWOPT_CORE2_INDEX_BACKGROUND 0x00000020L #define VIEWOPT_CORE2_INDEX_BACKGROUND 0x00000020L
#define VIEWOPT_CORE2_BIGMARKHDL 0x00000040L #define VIEWOPT_CORE2_BIGMARKHDL 0x00000040L
#define VIEWOPT_2_TOOLBOX 0x00000001L //#define VIEWOPT_2_TOOLBOX 0x00000001L
#define VIEWOPT_2_TOOLBOXTEXT 0x00000002L //#define VIEWOPT_2_TOOLBOXTEXT 0x00000002L
#define VIEWOPT_2_TOOLBOXBITMAP 0x00000004L //#define VIEWOPT_2_TOOLBOXBITMAP 0x00000004L
#define VIEWOPT_2_TOOLBOXBOTH 0x00000008L //#define VIEWOPT_2_TOOLBOXBOTH 0x00000008L
#define VIEWOPT_2_TOOLBOXLEFT 0x00000010L //#define VIEWOPT_2_TOOLBOXLEFT 0x00000010L
#define VIEWOPT_2_TOOLBOXRIGHT 0x00000020L //#define VIEWOPT_2_TOOLBOXRIGHT 0x00000020L
#define VIEWOPT_2_TOOLBOXTOP 0x00000040L //#define VIEWOPT_2_TOOLBOXTOP 0x00000040L
#define VIEWOPT_2_TOOLBOXBOTTOM 0x00000080L //#define VIEWOPT_2_TOOLBOXBOTTOM 0x00000080L
#define VIEWOPT_2_UNUSED1 0x00000100L #define VIEWOPT_2_UNUSED1 0x00000100L
#define VIEWOPT_2_RIBBONBAR 0x00000200L //#define VIEWOPT_2_RIBBONBAR 0x00000200L
#define VIEWOPT_2_TABWIN 0x00000400L #define VIEWOPT_2_TABWIN 0x00000400L
#define VIEWOPT_2_VSCROLLBAR 0x00000800L #define VIEWOPT_2_VSCROLLBAR 0x00000800L
#define VIEWOPT_2_HSCROLLBAR 0x00001000L #define VIEWOPT_2_HSCROLLBAR 0x00001000L
...@@ -485,10 +485,8 @@ public: ...@@ -485,10 +485,8 @@ public:
Optionen aus nUIOptions Optionen aus nUIOptions
----------------------------------------------------------------------------*/ ----------------------------------------------------------------------------*/
BOOL IsViewToolbox() const // BOOL IsViewRibbonBar() const
{ return nUIOptions & VIEWOPT_2_TOOLBOX ? TRUE : FALSE; } // { return nUIOptions & VIEWOPT_2_RIBBONBAR ? TRUE : FALSE; }
BOOL IsViewRibbonBar() const
{ return nUIOptions & VIEWOPT_2_RIBBONBAR ? TRUE : FALSE; }
BOOL IsViewVScrollBar() const BOOL IsViewVScrollBar() const
{ return nUIOptions & VIEWOPT_2_VSCROLLBAR ? TRUE : FALSE; } { return nUIOptions & VIEWOPT_2_VSCROLLBAR ? TRUE : FALSE; }
BOOL IsViewHScrollBar() const BOOL IsViewHScrollBar() const
...@@ -508,16 +506,14 @@ public: ...@@ -508,16 +506,14 @@ public:
BYTE GetTblDest() const { return nTblDest; } BYTE GetTblDest() const { return nTblDest; }
void SetViewToolbox (BOOL b) // void SetViewRibbonBar (BOOL b)
{ b ? (nUIOptions |= VIEWOPT_2_TOOLBOX ) : ( nUIOptions &= ~VIEWOPT_2_TOOLBOX); } // { b ? (nUIOptions |= VIEWOPT_2_RIBBONBAR ) : ( nUIOptions &= ~VIEWOPT_2_RIBBONBAR); }
void SetViewRibbonBar (BOOL b)
{ b ? (nUIOptions |= VIEWOPT_2_RIBBONBAR ) : ( nUIOptions &= ~VIEWOPT_2_RIBBONBAR); }
void SetViewVScrollBar(BOOL b) void SetViewVScrollBar(BOOL b)
{ b ? (nUIOptions |= VIEWOPT_2_VSCROLLBAR ) : ( nUIOptions &= ~VIEWOPT_2_VSCROLLBAR); } { b ? (nUIOptions |= VIEWOPT_2_VSCROLLBAR ) : ( nUIOptions &= ~VIEWOPT_2_VSCROLLBAR); }
void SetViewHScrollBar(BOOL b) void SetViewHScrollBar(BOOL b)
{ b ? (nUIOptions |= VIEWOPT_2_HSCROLLBAR ) : ( nUIOptions &= ~VIEWOPT_2_HSCROLLBAR); } { b ? (nUIOptions |= VIEWOPT_2_HSCROLLBAR ) : ( nUIOptions &= ~VIEWOPT_2_HSCROLLBAR); }
void SetViewSVLook (BOOL b) // void SetViewSVLook (BOOL b)
{ b ? (nUIOptions |= VIEWOPT_2_SVLOOK ) : ( nUIOptions &= ~VIEWOPT_2_SVLOOK); } // { b ? (nUIOptions |= VIEWOPT_2_SVLOOK ) : ( nUIOptions &= ~VIEWOPT_2_SVLOOK); }
void SetKeepRatio (BOOL b) void SetKeepRatio (BOOL b)
{ b ? (nUIOptions |= VIEWOPT_2_KEEPASPECTRATIO ) : ( nUIOptions &= ~VIEWOPT_2_KEEPASPECTRATIO); } { b ? (nUIOptions |= VIEWOPT_2_KEEPASPECTRATIO ) : ( nUIOptions &= ~VIEWOPT_2_KEEPASPECTRATIO); }
void SetGrfKeepZoom (BOOL b) void SetGrfKeepZoom (BOOL b)
......
...@@ -2,9 +2,9 @@ ...@@ -2,9 +2,9 @@
* *
* $RCSfile: apphdl.cxx,v $ * $RCSfile: apphdl.cxx,v $
* *
* $Revision: 1.1.1.1 $ * $Revision: 1.2 $
* *
* last change: $Author: hr $ $Date: 2000-09-18 17:14:31 $ * last change: $Author: os $ $Date: 2000-09-28 15:22:17 $
* *
* The Contents of this file are made available subject to the terms of * The Contents of this file are made available subject to the terms of
* either of the following licenses * either of the following licenses
...@@ -721,13 +721,11 @@ void SwModule::ExecViewOptions(SfxRequest &rReq) ...@@ -721,13 +721,11 @@ void SwModule::ExecViewOptions(SfxRequest &rReq)
// fuer die Initialisierung // fuer die Initialisierung
if(!pWebUsrPref) if(!pWebUsrPref)
GetUsrPref(sal_True); GetUsrPref(sal_True);
pWebUsrPref->SetDefault( sal_False );
} }
else else
{ {
if(!pUsrPref) if(!pUsrPref)
GetUsrPref(sal_False); GetUsrPref(sal_False);
pUsrPref->SetDefault( sal_False );
} }
SW_MOD()->CheckSpellChanges( pOpt->IsOnlineSpell(), sal_False, sal_False ); SW_MOD()->CheckSpellChanges( pOpt->IsOnlineSpell(), sal_False, sal_False );
...@@ -1075,25 +1073,27 @@ SwSrcViewConfig* SwModule::GetSourceViewConfig() ...@@ -1075,25 +1073,27 @@ SwSrcViewConfig* SwModule::GetSourceViewConfig()
/*-----------------30.01.97 08.30------------------- /*-----------------30.01.97 08.30-------------------
--------------------------------------------------*/ --------------------------------------------------*/
const SwMasterUsrPref *SwModule::GetUsrPref(sal_Bool bWeb) const SwMasterUsrPref *SwModule::GetUsrPref(sal_Bool bWeb) const
{ {
SwModule* pNonConstModule = (SwModule*)this;
if(bWeb && !pWebUsrPref) if(bWeb && !pWebUsrPref)
{ {
// im Load der SwMasterUsrPref wird der SpellChecker gebraucht, dort darf // im Load der SwMasterUsrPref wird der SpellChecker gebraucht, dort darf
// er aber nicht angelegt werden #58256# // er aber nicht angelegt werden #58256#
pWebUsrPref = new SwMasterUsrPref(CFG_SWWEB_USRPREF); pNonConstModule->pWebUsrPref = new SwMasterUsrPref(TRUE);
pWebUsrPref->Initialize();
} }
else if(!bWeb && !pUsrPref) else if(!bWeb && !pUsrPref)
{ {
pUsrPref = new SwMasterUsrPref(CFG_USERPREF_ITEM); pNonConstModule->pUsrPref = new SwMasterUsrPref(FALSE);
pUsrPref->Initialize();
} }
return bWeb ? pWebUsrPref : pUsrPref; return bWeb ? pWebUsrPref : pUsrPref;
} }
/*------------------------------------------------------------------------- /*-------------------------------------------------------------------------
$Log: not supported by cvs2svn $ $Log: not supported by cvs2svn $
Revision 1.1.1.1 2000/09/18 17:14:31 hr
initial import
Revision 1.289 2000/09/18 16:05:09 willem.vandorp Revision 1.289 2000/09/18 16:05:09 willem.vandorp
OpenOffice header added. OpenOffice header added.
......
...@@ -2,9 +2,9 @@ ...@@ -2,9 +2,9 @@
* *
* $RCSfile: appopt.cxx,v $ * $RCSfile: appopt.cxx,v $
* *
* $Revision: 1.1.1.1 $ * $Revision: 1.2 $
* *
* last change: $Author: hr $ $Date: 2000-09-18 17:14:31 $ * last change: $Author: os $ $Date: 2000-09-28 15:22:17 $
* *
* The Contents of this file are made available subject to the terms of * The Contents of this file are made available subject to the terms of
* either of the following licenses * either of the following licenses
...@@ -151,6 +151,7 @@ SfxItemSet* SwModule::CreateItemSet( USHORT nId ) ...@@ -151,6 +151,7 @@ SfxItemSet* SwModule::CreateItemSet( USHORT nId )
// hier werden die Optionen fuer die Web- und den Textdialog zusmmengesetzt // hier werden die Optionen fuer die Web- und den Textdialog zusmmengesetzt
SwViewOption aViewOpt = *GetUsrPref(!bTextDialog); SwViewOption aViewOpt = *GetUsrPref(!bTextDialog);
SwMasterUsrPref* pPref = bTextDialog ? pUsrPref : pWebUsrPref;
BOOL bFrameDoc = FALSE; BOOL bFrameDoc = FALSE;
//kein MakeUsrPref, da hier nur die Optionen von Textdoks genommen werden duerfen //kein MakeUsrPref, da hier nur die Optionen von Textdoks genommen werden duerfen
SwView* pAppView = GetView(); SwView* pAppView = GetView();
...@@ -233,8 +234,7 @@ SfxItemSet* SwModule::CreateItemSet( USHORT nId ) ...@@ -233,8 +234,7 @@ SfxItemSet* SwModule::CreateItemSet( USHORT nId )
pRet->Put(aBool); pRet->Put(aBool);
} }
SwModuleOptions* pMCfg = GetModuleConfig(); pRet->Put(SfxUInt16Item( SID_ATTR_METRIC, pPref->GetMetric()));
pRet->Put(SfxUInt16Item( SID_ATTR_METRIC, pMCfg->GetMetric(!bTextDialog)));
if(bTextDialog) if(bTextDialog)
{ {
if(pAppView) if(pAppView)
...@@ -245,7 +245,7 @@ SfxItemSet* SwModule::CreateItemSet( USHORT nId ) ...@@ -245,7 +245,7 @@ SfxItemSet* SwModule::CreateItemSet( USHORT nId )
pRet->Put( SfxUInt16Item( SID_ATTR_DEFTABSTOP, (USHORT)::GetTabDist(rDefTabs))); pRet->Put( SfxUInt16Item( SID_ATTR_DEFTABSTOP, (USHORT)::GetTabDist(rDefTabs)));
} }
else else
pRet->Put(SfxUInt16Item( SID_ATTR_DEFTABSTOP, pMCfg->GetDefTab())); pRet->Put(SfxUInt16Item( SID_ATTR_DEFTABSTOP, pPref->GetDefTab()));
} }
/*-----------------01.02.97 11.13------------------- /*-----------------01.02.97 11.13-------------------
...@@ -368,7 +368,7 @@ void SwModule::ApplyItemSet( USHORT nId, const SfxItemSet& rSet ) ...@@ -368,7 +368,7 @@ void SwModule::ApplyItemSet( USHORT nId, const SfxItemSet& rSet )
FALSE, &pItem ) ) FALSE, &pItem ) )
{ {
USHORT nTabDist = ((const SfxUInt16Item*)pItem)->GetValue(); USHORT nTabDist = ((const SfxUInt16Item*)pItem)->GetValue();
pMCfg->SetDefTab(nTabDist); pUsrPref->SetDefTab(nTabDist);
if(pAppView) if(pAppView)
{ {
SvxTabStopItem aDefTabs( 0, 0 ); SvxTabStopItem aDefTabs( 0, 0 );
...@@ -545,6 +545,9 @@ SfxTabPage* SwModule::CreateTabPage( USHORT nId, Window* pParent, const SfxItem ...@@ -545,6 +545,9 @@ SfxTabPage* SwModule::CreateTabPage( USHORT nId, Window* pParent, const SfxItem
/*------------------------------------------------------------------------- /*-------------------------------------------------------------------------
$Log: not supported by cvs2svn $ $Log: not supported by cvs2svn $
Revision 1.1.1.1 2000/09/18 17:14:31 hr
initial import
Revision 1.163 2000/09/18 16:05:10 willem.vandorp Revision 1.163 2000/09/18 16:05:10 willem.vandorp
OpenOffice header added. OpenOffice header added.
......
...@@ -2,9 +2,9 @@ ...@@ -2,9 +2,9 @@
* *
* $RCSfile: docshini.cxx,v $ * $RCSfile: docshini.cxx,v $
* *
* $Revision: 1.1.1.1 $ * $Revision: 1.2 $
* *
* last change: $Author: hr $ $Date: 2000-09-18 17:14:31 $ * last change: $Author: os $ $Date: 2000-09-28 15:22:17 $
* *
* The Contents of this file are made available subject to the terms of * The Contents of this file are made available subject to the terms of
* either of the following licenses * either of the following licenses
...@@ -766,7 +766,7 @@ void SwDocShell::SubInitNew() ...@@ -766,7 +766,7 @@ void SwDocShell::SubInitNew()
aHyp.GetMinTrail() = sal_Int8(nVal); aHyp.GetMinTrail() = sal_Int8(nVal);
aDfltSet.Put( aHyp ); aDfltSet.Put( aHyp );
sal_uInt16 nNewPos = SW_MOD()->GetModuleConfig()->GetDefTab(); sal_uInt16 nNewPos = SW_MOD()->GetUsrPref(FALSE)->GetDefTab();
if( nNewPos ) if( nNewPos )
aDfltSet.Put( SvxTabStopItem( 1, nNewPos, aDfltSet.Put( SvxTabStopItem( 1, nNewPos,
SVX_TAB_ADJUST_DEFAULT ) ); SVX_TAB_ADJUST_DEFAULT ) );
...@@ -777,6 +777,9 @@ void SwDocShell::SubInitNew() ...@@ -777,6 +777,9 @@ void SwDocShell::SubInitNew()
/*------------------------------------------------------------------------ /*------------------------------------------------------------------------
$Log: not supported by cvs2svn $ $Log: not supported by cvs2svn $
Revision 1.1.1.1 2000/09/18 17:14:31 hr
initial import
Revision 1.209 2000/09/18 16:05:11 willem.vandorp Revision 1.209 2000/09/18 16:05:11 willem.vandorp
OpenOffice header added. OpenOffice header added.
......
...@@ -2,9 +2,9 @@ ...@@ -2,9 +2,9 @@
* *
* $RCSfile: swmodul1.cxx,v $ * $RCSfile: swmodul1.cxx,v $
* *
* $Revision: 1.1.1.1 $ * $Revision: 1.2 $
* *
* last change: $Author: hr $ $Date: 2000-09-18 17:14:31 $ * last change: $Author: os $ $Date: 2000-09-28 15:22:17 $
* *
* The Contents of this file are made available subject to the terms of * The Contents of this file are made available subject to the terms of
* either of the following licenses * either of the following licenses
...@@ -475,8 +475,8 @@ void SwModule::ApplyUsrPref(const SwViewOption &rUsrPref, SwView* pActView, ...@@ -475,8 +475,8 @@ void SwModule::ApplyUsrPref(const SwViewOption &rUsrPref, SwView* pActView,
if(!bViewOnly) if(!bViewOnly)
{ {
pPref->SetDefault( sal_False );
pPref->SetUsrPref( rUsrPref ); pPref->SetUsrPref( rUsrPref );
pPref->SetModified();
} }
if( !pView ) if( !pView )
...@@ -511,6 +511,42 @@ void SwModule::ApplyUsrPref(const SwViewOption &rUsrPref, SwView* pActView, ...@@ -511,6 +511,42 @@ void SwModule::ApplyUsrPref(const SwViewOption &rUsrPref, SwView* pActView,
// #42510# // #42510#
pPref->SetIdle(sal_True); pPref->SetIdle(sal_True);
}
/* -----------------------------28.09.00 12:36--------------------------------
---------------------------------------------------------------------------*/
void SwModule::ApplyUserMetric( FieldUnit eMetric, BOOL bWeb )
{
SwMasterUsrPref* pPref;
if(bWeb)
{
if(!pWebUsrPref)
GetUsrPref(sal_True);
pPref = pWebUsrPref;
}
else
{
if(!pUsrPref)
GetUsrPref(sal_False);
pPref = pUsrPref;
}
FieldUnit eOldMetric = pPref->GetMetric();
if(eOldMetric != eMetric)
pPref->SetMetric(eMetric);
SwView* pTmpView = SwModule::GetFirstView();
// fuer alle MDI-Fenster das Lineal umschalten
while(pTmpView)
{
if(bWeb == (0 != PTR_CAST(SwWebView, pTmpView)))
{
pTmpView->ChangeVLinealMetric(eMetric);
pTmpView->ChangeTabMetric(eMetric);
}
pTmpView = SwModule::GetNextView(pTmpView);
}
} }
/*-----------------13.11.96 11.57------------------- /*-----------------13.11.96 11.57-------------------
...@@ -891,25 +927,67 @@ const String& SwModule::GetDocStatWordDelim() const ...@@ -891,25 +927,67 @@ const String& SwModule::GetDocStatWordDelim() const
{ {
return pModuleConfig->GetWordDelimiter(); return pModuleConfig->GetWordDelimiter();
} }
/* ---------------------------------------------------------------------------
---------------------------------------------------------------------------*/
// Durchreichen der Metric von der ModuleConfig (fuer HTML-Export) // Durchreichen der Metric von der ModuleConfig (fuer HTML-Export)
sal_uInt16 SwModule::GetMetric( sal_Bool bWeb ) const sal_uInt16 SwModule::GetMetric( sal_Bool bWeb ) const
{ {
return pModuleConfig->GetMetric( bWeb ); SwMasterUsrPref* pPref;
if(bWeb)
{
if(!pWebUsrPref)
GetUsrPref(sal_True);
pPref = pWebUsrPref;
}
else
{
if(!pUsrPref)
GetUsrPref(sal_False);
pPref = pUsrPref;
}
return pPref->GetMetric();
} }
/* ---------------------------------------------------------------------------
---------------------------------------------------------------------------*/
// Update-Stati durchreichen // Update-Stati durchreichen
sal_uInt16 SwModule::GetLinkUpdMode( sal_Bool ) const sal_uInt16 SwModule::GetLinkUpdMode( sal_Bool ) const
{ {
return pModuleConfig->GetLinkMode(); if(!pUsrPref)
GetUsrPref(sal_False);
return pUsrPref->GetUpdateLinkMode();
} }
/* ---------------------------------------------------------------------------
---------------------------------------------------------------------------*/
sal_uInt16 SwModule::GetFldUpdateFlags( sal_Bool ) const sal_uInt16 SwModule::GetFldUpdateFlags( sal_Bool ) const
{ {
return pModuleConfig->GetFldUpdateFlags(); if(!pUsrPref)
GetUsrPref(sal_False);
return (sal_uInt16)pUsrPref->GetFldUpdateFlags();
}
/* -----------------------------28.09.00 14:18--------------------------------
---------------------------------------------------------------------------*/
void SwModule::ApplyFldUpdateFlags(sal_Int32 nFldFlags)
{
if(!pUsrPref)
GetUsrPref(sal_False);
pUsrPref->SetFldUpdateFlags(nFldFlags);
}
/* -----------------------------28.09.00 14:18--------------------------------
---------------------------------------------------------------------------*/
void SwModule::ApplyLinkMode(sal_Int32 nNewLinkMode)
{
if(!pUsrPref)
GetUsrPref(sal_False);
pUsrPref->SetUpdateLinkMode(nNewLinkMode);
} }
/* ---------------------------------------------------------------------------
---------------------------------------------------------------------------*/
void SwModule::CheckSpellChanges( sal_Bool bOnlineSpelling, void SwModule::CheckSpellChanges( sal_Bool bOnlineSpelling,
sal_Bool bIsSpellWrongAgain, sal_Bool bIsSpellAllAgain ) sal_Bool bIsSpellWrongAgain, sal_Bool bIsSpellAllAgain )
{ {
...@@ -931,162 +1009,4 @@ void SwModule::CheckSpellChanges( sal_Bool bOnlineSpelling, ...@@ -931,162 +1009,4 @@ void SwModule::CheckSpellChanges( sal_Bool bOnlineSpelling,
} }
} }
/*-------------------------------------------------------------------------
$Log: not supported by cvs2svn $
Revision 1.50 2000/09/18 16:05:12 willem.vandorp
OpenOffice header added.
Revision 1.49 2000/09/08 15:11:56 os
use configuration service
Revision 1.48 2000/09/07 15:59:20 os
change: SFX_DISPATCHER/SFX_BINDINGS removed
Revision 1.47 2000/09/07 08:25:24 os
SwPrintOptions uses configuration service
Revision 1.46 2000/07/18 12:50:07 os
replace ofadbmgr
Revision 1.45 2000/05/26 07:21:28 os
old SW Basic API Slots removed
Revision 1.44 2000/05/16 09:15:11 os
project usr removed
Revision 1.43 2000/05/11 12:05:29 tl
if[n]def ONE_LINGU entfernt
Revision 1.42 2000/03/30 13:28:04 os
UNO III
Revision 1.41 2000/03/29 12:46:55 jp
Bug #74570#: ShowDBObj - if no table and no query exist, set default to table
Revision 1.40 2000/03/21 15:47:50 os
UNOIII
Revision 1.39 2000/02/11 14:43:07 hr
#70473# changes for unicode ( patched by automated patchtool )
Revision 1.38 2000/02/09 07:58:08 os
#72824# check if beamer is available
Revision 1.37 2000/01/13 11:31:37 tl
#70735# fixed CheckSpellChanges bug
Revision 1.36 2000/01/11 10:33:54 tl
#70735# CheckSpellChanges moved from SwDoc to here
Revision 1.35 2000/01/06 12:54:01 hr
#65293#: END_CATCH
Revision 1.34 2000/01/06 07:32:38 os
#71436# mail merge dialog: execute via status method disposed
Revision 1.33 1999/06/22 15:37:58 JP
Bug #43028#: disableflag for edit in mailbody
Rev 1.32 22 Jun 1999 17:37:58 JP
Bug #43028#: disableflag for edit in mailbody
Rev 1.31 20 Apr 1999 18:59:24 JP
Task #65061#: neu: ZahlenFormaterkennung abschaltbar
Rev 1.30 12 Mar 1999 09:55:32 JP
Task #61405#: Optionen setzen
Rev 1.29 12 Mar 1999 09:45:04 OS
#63044# Datenbank-Fehlermeldung anzeigen
Rev 1.28 01 Mar 1999 16:20:52 MA
#62490# Altlast entfernt (Drucken und Briefumschlaege/Etiketten und Datenbank)
Rev 1.27 23 Feb 1999 16:19:38 OS
#62281# UsrPrefs per UNO nur auf aktuelle sdbcx::View anwenden
Rev 1.26 17 Feb 1999 08:37:24 OS
#58158# Einfuegen TabPage auch in HTML-Docs
Rev 1.25 27 Jan 1999 10:05:22 OS
#58677# Cursor in Readonly-Bereichen
Rev 1.24 26 Jan 1999 11:50:10 MIB
#60875#: Beim HTML-Export Einheit aus Extras/Optionen/Text-/HTML-Dokument nehmen
Rev 1.23 23 Nov 1998 17:36:52 JP
Bug #59754#: TerminateHdl wird nicht mehr fuers Clipboard benoetigt
Rev 1.22 20 Nov 1998 14:01:32 OM
#59720# Neue Tabellenoptionen beim Einfuegen
Rev 1.21 05 Oct 1998 17:16:54 OM
#57458# Auch Queries ueber F4 anzeigen
Rev 1.20 24 Sep 1998 13:33:02 OS
#52654# #56685# XTerminateListener fuer die Anmeldung an der Application
Rev 1.19 24 Aug 1998 12:20:54 OM
#54552# Serienbriefdialog: Statusupdate immer erzwingen
Rev 1.18 14 Jul 1998 12:09:06 OS
Scrollbars nur umschalten, wenn sich die ViewOptions wirklich veraendert haben #52708#
Rev 1.17 25 May 1998 12:41:28 JP
nMergeType wurde private, ueber SetMergeType setzen
Rev 1.16 15 May 1998 12:50:02 OM
Worttrenner
Rev 1.15 14 May 1998 16:46:00 OM
Worttrenner konfigurierbar
Rev 1.14 24 Apr 1998 19:36:54 JP
neu: DocStat WordDelimiter aus der Configuration holen
Rev 1.13 24 Mar 1998 17:45:28 OM
Formataenderung anzeigen
Rev 1.12 24 Mar 1998 13:43:56 JP
neu: Redline fuer harte Attributierung
Rev 1.11 16 Mar 1998 19:09:48 OM
Zugriff auf Ini optimiert
Rev 1.10 15 Mar 1998 16:57:22 MA
#48342# richtig initialisieren
Rev 1.9 10 Mar 1998 12:23:42 OM
Get...AuthorAttr
Rev 1.8 05 Mar 1998 14:44:08 OM
Redline-Attribute in Module-Cfg speichern
Rev 1.7 03 Mar 1998 17:00:46 OS
GetViewOption
Rev 1.6 28 Feb 1998 15:12:42 OM
Accept / reject changes
Rev 1.5 24 Feb 1998 15:32:04 OM
Redline-Darstellungsoptionen setzen
Rev 1.4 08 Dec 1997 11:46:16 OS
benannte Numerierungen entfernt
Rev 1.3 24 Nov 1997 14:22:36 MA
includes
Rev 1.2 18 Nov 1997 14:33:42 OM
Sba-Umstellung 372
Rev 1.1 02 Sep 1997 10:21:08 OS
includes
Rev 1.0 01 Sep 1997 13:09:16 OS
Initial revision.
-------------------------------------------------------------------------*/
...@@ -2,9 +2,9 @@ ...@@ -2,9 +2,9 @@
* *
* $RCSfile: modcfg.cxx,v $ * $RCSfile: modcfg.cxx,v $
* *
* $Revision: 1.1.1.1 $ * $Revision: 1.2 $
* *
* last change: $Author: hr $ $Date: 2000-09-18 17:14:33 $ * last change: $Author: os $ $Date: 2000-09-28 15:23:17 $
* *
* The Contents of this file are made available subject to the terms of * The Contents of this file are made available subject to the terms of
* either of the following licenses * either of the following licenses
...@@ -209,7 +209,7 @@ int SwModuleOptions::Load(SvStream& rStream) ...@@ -209,7 +209,7 @@ int SwModuleOptions::Load(SvStream& rStream)
UINT32 nColor; UINT32 nColor;
UINT16 nVal; UINT16 nVal;
rStream >> nVal; rStream >> nVal;
nDefTab = nVal; // nDefTab = nVal;
rStream >> nVal; rStream >> nVal;
nTblHMove = nVal; nTblHMove = nVal;
...@@ -225,11 +225,11 @@ int SwModuleOptions::Load(SvStream& rStream) ...@@ -225,11 +225,11 @@ int SwModuleOptions::Load(SvStream& rStream)
BYTE bVal; BYTE bVal;
rStream >> bVal; rStream >> bVal;
eUserMetric = (FieldUnit)bVal; // eUserMetric = (FieldUnit)bVal;
if (nVersion >= VERSION_08) if (nVersion >= VERSION_08)
{ {
rStream >> bVal; rStream >> bVal;
eWebUserMetric = (FieldUnit)bVal; // eWebUserMetric = (FieldUnit)bVal;
} }
...@@ -317,7 +317,7 @@ int SwModuleOptions::Load(SvStream& rStream) ...@@ -317,7 +317,7 @@ int SwModuleOptions::Load(SvStream& rStream)
{ {
rStream >> bVal; bInsTblFormatNum = bVal; rStream >> bVal; bInsTblFormatNum = bVal;
rStream >> bVal; bInsTblAlignNum = bVal; rStream >> bVal; bInsTblAlignNum = bVal;
rStream >> nVal; nLinkMode = nVal; rStream >> nVal; //nLinkMode = nVal;
if (nVersion == VERSION_12) if (nVersion == VERSION_12)
rStream >> bVal; // Flag gibts nicht mehr rStream >> bVal; // Flag gibts nicht mehr
...@@ -328,10 +328,10 @@ int SwModuleOptions::Load(SvStream& rStream) ...@@ -328,10 +328,10 @@ int SwModuleOptions::Load(SvStream& rStream)
} }
if(nVersion >= VERSION_14) if(nVersion >= VERSION_14)
{ {
rStream>> nVal; nFldUpdateFlags = nVal; rStream>> nVal; //nFldUpdateFlags = nVal;
} }
else // else
nFldUpdateFlags = AUTOUPD_OFF; // nFldUpdateFlags = AUTOUPD_OFF;
if(nVersion >= VERSION_15) if(nVersion >= VERSION_15)
{ {
rStream >> bVal; bHTMLInsWithCaption = bVal; rStream >> bVal; bHTMLInsWithCaption = bVal;
...@@ -387,13 +387,13 @@ BOOL SwModuleOptions::Store(SvStream& rStream) ...@@ -387,13 +387,13 @@ BOOL SwModuleOptions::Store(SvStream& rStream)
{ {
rtl_TextEncoding eEncoding = gsl_getSystemTextEncoding(); rtl_TextEncoding eEncoding = gsl_getSystemTextEncoding();
rStream << (UINT16) MODCFG_VERSION; rStream << (UINT16) MODCFG_VERSION;
rStream << (UINT16) nDefTab; rStream << (UINT16) 0;//nDefTab;
rStream << (UINT16) nTblHMove; rStream << (UINT16) nTblHMove;
rStream << (UINT16) nTblVMove; rStream << (UINT16) nTblVMove;
rStream << (UINT16) nTblHInsert; rStream << (UINT16) nTblHInsert;
rStream << (UINT16) nTblVInsert; rStream << (UINT16) nTblVInsert;
rStream << (BYTE) eUserMetric; rStream << (BYTE) 0;//eUserMetric;
rStream << (BYTE) eWebUserMetric; rStream << (BYTE) 0;//eWebUserMetric;
rStream << (BYTE) eTblChgMode; rStream << (BYTE) eTblChgMode;
rStream << (BYTE) bGrfToGalleryAsLnk; rStream << (BYTE) bGrfToGalleryAsLnk;
rStream << (BYTE) nMailingFormats; rStream << (BYTE) nMailingFormats;
...@@ -420,9 +420,9 @@ BOOL SwModuleOptions::Store(SvStream& rStream) ...@@ -420,9 +420,9 @@ BOOL SwModuleOptions::Store(SvStream& rStream)
rStream << *aCapOptions[i]; rStream << *aCapOptions[i];
rStream << (BYTE) bInsTblFormatNum; rStream << (BYTE) bInsTblFormatNum;
rStream << (BYTE) bInsTblAlignNum; rStream << (BYTE) bInsTblAlignNum;
rStream << (UINT16) nLinkMode; rStream << (UINT16) 0;//nLinkMode;
rStream << (UINT16) nInsTblFlags; rStream << (UINT16) nInsTblFlags;
rStream << (UINT16) nFldUpdateFlags; rStream << (UINT16) 0;//nFldUpdateFlags;
rStream << (BYTE) bHTMLInsWithCaption; rStream << (BYTE) bHTMLInsWithCaption;
rStream << (BYTE) bHTMLInsTblFormatNum; rStream << (BYTE) bHTMLInsTblFormatNum;
...@@ -446,7 +446,7 @@ BOOL SwModuleOptions::Store(SvStream& rStream) ...@@ -446,7 +446,7 @@ BOOL SwModuleOptions::Store(SvStream& rStream)
void SwModuleOptions::UseDefault() void SwModuleOptions::UseDefault()
{ {
MeasurementSystem eSys = Application::GetAppInternational().GetMeasurementSystem(); /* MeasurementSystem eSys = Application::GetAppInternational().GetMeasurementSystem();
if(MEASURE_METRIC != eSys) if(MEASURE_METRIC != eSys)
{ {
eUserMetric = eWebUserMetric = FUNIT_INCH; eUserMetric = eWebUserMetric = FUNIT_INCH;
...@@ -462,7 +462,7 @@ void SwModuleOptions::UseDefault() ...@@ -462,7 +462,7 @@ void SwModuleOptions::UseDefault()
nTblHMove = nTblVMove = MM50; // 0,5 cm nTblHMove = nTblVMove = MM50; // 0,5 cm
nTblHInsert = MM50; // 0,5 cm nTblHInsert = MM50; // 0,5 cm
nTblVInsert = 1415; // 2,5 cm nTblVInsert = 1415; // 2,5 cm
} }*/
eTblChgMode = TBLVAR_CHGABS; eTblChgMode = TBLVAR_CHGABS;
...@@ -494,8 +494,8 @@ void SwModuleOptions::UseDefault() ...@@ -494,8 +494,8 @@ void SwModuleOptions::UseDefault()
bHTMLInsTblChangeNumFormat = bInsTblChangeNumFormat = TRUE; bHTMLInsTblChangeNumFormat = bInsTblChangeNumFormat = TRUE;
bHTMLInsTblAlignNum = bInsTblAlignNum = TRUE; bHTMLInsTblAlignNum = bInsTblAlignNum = TRUE;
nLinkMode = MANUAL; // nLinkMode = MANUAL;
nFldUpdateFlags = AUTOUPD_FIELD_ONLY; // nFldUpdateFlags = AUTOUPD_FIELD_ONLY;
bShowAutoTextPreview = TRUE; bShowAutoTextPreview = TRUE;
bShowIndexPreview = TRUE; bShowIndexPreview = TRUE;
...@@ -530,6 +530,9 @@ String SwModuleOptions::GetName() const ...@@ -530,6 +530,9 @@ String SwModuleOptions::GetName() const
/*-------------------------------------------------------------------- /*--------------------------------------------------------------------
$Log: not supported by cvs2svn $ $Log: not supported by cvs2svn $
Revision 1.1.1.1 2000/09/18 17:14:33 hr
initial import
Revision 1.34 2000/09/18 16:05:15 willem.vandorp Revision 1.34 2000/09/18 16:05:15 willem.vandorp
OpenOffice header added. OpenOffice header added.
......
...@@ -2,9 +2,9 @@ ...@@ -2,9 +2,9 @@
* *
* $RCSfile: optload.cxx,v $ * $RCSfile: optload.cxx,v $
* *
* $Revision: 1.1.1.1 $ * $Revision: 1.2 $
* *
* last change: $Author: hr $ $Date: 2000-09-18 17:14:33 $ * last change: $Author: os $ $Date: 2000-09-28 15:23:17 $
* *
* The Contents of this file are made available subject to the terms of * The Contents of this file are made available subject to the terms of
* either of the following licenses * either of the following licenses
...@@ -78,8 +78,9 @@ ...@@ -78,8 +78,9 @@
#endif #endif
#include "swmodule.hxx" #include "swmodule.hxx"
#include "modcfg.hxx" #include "usrpref.hxx"
#include "wrtsh.hxx" #include "wrtsh.hxx"
#include "linkenum.hxx"
#include "globals.hrc" #include "globals.hrc"
#include "cmdid.h" #include "cmdid.h"
...@@ -151,7 +152,8 @@ SfxTabPage* __EXPORT SwLoadOptPage::Create( Window* pParent, ...@@ -151,7 +152,8 @@ SfxTabPage* __EXPORT SwLoadOptPage::Create( Window* pParent,
BOOL __EXPORT SwLoadOptPage::FillItemSet( SfxItemSet& rSet ) BOOL __EXPORT SwLoadOptPage::FillItemSet( SfxItemSet& rSet )
{ {
BOOL bRet = FALSE; BOOL bRet = FALSE;
SwModuleOptions* pModOpt = SW_MOD()->GetModuleConfig(); SwModule* pMod = SW_MOD();
// SwModuleOptions* pModOpt = SW_MOD()->GetModuleConfig();
BOOL bFldDocOnly = aFldDocOnlyCB.IsChecked(); BOOL bFldDocOnly = aFldDocOnlyCB.IsChecked();
BOOL bLinkDocOnly = aLinkDocOnlyCB.IsChecked(); BOOL bLinkDocOnly = aLinkDocOnlyCB.IsChecked();
...@@ -170,7 +172,7 @@ BOOL __EXPORT SwLoadOptPage::FillItemSet( SfxItemSet& rSet ) ...@@ -170,7 +172,7 @@ BOOL __EXPORT SwLoadOptPage::FillItemSet( SfxItemSet& rSet )
aAutoUpdateCharts.IsChecked() != aAutoUpdateCharts.GetSavedValue()) aAutoUpdateCharts.IsChecked() != aAutoUpdateCharts.GetSavedValue())
{ {
if (!bFldDocOnly || !pWrtShell) if (!bFldDocOnly || !pWrtShell)
pModOpt->SetFldUpdateFlags(nFldFlags); pMod->ApplyFldUpdateFlags(nFldFlags);
if(pWrtShell) if(pWrtShell)
{ {
USHORT nSet = bFldDocOnly ? nFldFlags : AUTOUPD_GLOBALSETTING; USHORT nSet = bFldDocOnly ? nFldFlags : AUTOUPD_GLOBALSETTING;
...@@ -182,7 +184,7 @@ BOOL __EXPORT SwLoadOptPage::FillItemSet( SfxItemSet& rSet ) ...@@ -182,7 +184,7 @@ BOOL __EXPORT SwLoadOptPage::FillItemSet( SfxItemSet& rSet )
if (nNewLinkMode != nOldLinkMode) if (nNewLinkMode != nOldLinkMode)
{ {
if (!bLinkDocOnly || !pWrtShell) if (!bLinkDocOnly || !pWrtShell)
pModOpt->SetLinkMode(nNewLinkMode); pMod->ApplyLinkMode(nNewLinkMode);
if (pWrtShell) if (pWrtShell)
{ {
...@@ -211,7 +213,7 @@ BOOL __EXPORT SwLoadOptPage::FillItemSet( SfxItemSet& rSet ) ...@@ -211,7 +213,7 @@ BOOL __EXPORT SwLoadOptPage::FillItemSet( SfxItemSet& rSet )
void __EXPORT SwLoadOptPage::Reset( const SfxItemSet& rSet) void __EXPORT SwLoadOptPage::Reset( const SfxItemSet& rSet)
{ {
const SwModuleOptions* pModOpt = SW_MOD()->GetModuleConfig(); const SwMasterUsrPref* pUsrPref = SW_MOD()->GetUsrPref(FALSE);
const SfxPoolItem* pItem; const SfxPoolItem* pItem;
if(SFX_ITEM_SET == rSet.GetItemState(FN_PARAM_WRTSHELL, FALSE, &pItem)) if(SFX_ITEM_SET == rSet.GetItemState(FN_PARAM_WRTSHELL, FALSE, &pItem))
...@@ -233,12 +235,12 @@ void __EXPORT SwLoadOptPage::Reset( const SfxItemSet& rSet) ...@@ -233,12 +235,12 @@ void __EXPORT SwLoadOptPage::Reset( const SfxItemSet& rSet)
} }
if(nOldLinkMode == GLOBALSETTING) if(nOldLinkMode == GLOBALSETTING)
{ {
nOldLinkMode = pModOpt->GetLinkMode(); nOldLinkMode = pUsrPref->GetUpdateLinkMode();
bLinkDocOnly = FALSE; bLinkDocOnly = FALSE;
} }
if(nFldFlags == AUTOUPD_GLOBALSETTING) if(nFldFlags == AUTOUPD_GLOBALSETTING)
{ {
nFldFlags = pModOpt->GetFldUpdateFlags(); nFldFlags = pUsrPref->GetFldUpdateFlags();
bFldDocOnly = FALSE; bFldDocOnly = FALSE;
} }
...@@ -268,6 +270,9 @@ void __EXPORT SwLoadOptPage::Reset( const SfxItemSet& rSet) ...@@ -268,6 +270,9 @@ void __EXPORT SwLoadOptPage::Reset( const SfxItemSet& rSet)
/*-------------------------------------------------------------------- /*--------------------------------------------------------------------
$Log: not supported by cvs2svn $ $Log: not supported by cvs2svn $
Revision 1.1.1.1 2000/09/18 17:14:33 hr
initial import
Revision 1.12 2000/09/18 16:05:17 willem.vandorp Revision 1.12 2000/09/18 16:05:17 willem.vandorp
OpenOffice header added. OpenOffice header added.
......
This diff is collapsed.
...@@ -2,9 +2,9 @@ ...@@ -2,9 +2,9 @@
* *
* $RCSfile: usrpref.hxx,v $ * $RCSfile: usrpref.hxx,v $
* *
* $Revision: 1.1.1.1 $ * $Revision: 1.2 $
* *
* last change: $Author: hr $ $Date: 2000-09-18 17:14:43 $ * last change: $Author: os $ $Date: 2000-09-28 15:23:36 $
* *
* The Contents of this file are made available subject to the terms of * The Contents of this file are made available subject to the terms of
* either of the following licenses * either of the following licenses
...@@ -62,24 +62,126 @@ ...@@ -62,24 +62,126 @@
#define _USRPREF_HXX #define _USRPREF_HXX
#ifndef _SFXCFGITEM_HXX //autogen
#include <sfx2/cfgitem.hxx> #ifndef _UTL_CONFIGITEM_HXX_
#include <unotools/configitem.hxx>
#endif
#ifndef _FLDUPDE_HXX
#include <fldupde.hxx>
#endif #endif
#include "viewopt.hxx" #include "viewopt.hxx"
class SwMasterUsrPref: public SwViewOption, public SfxConfigItem /* -----------------------------28.09.00 09:45--------------------------------
---------------------------------------------------------------------------*/
class SwMasterUsrPref;
class SwContentViewConfig : public utl::ConfigItem
{ {
protected: SwMasterUsrPref& rParent;
virtual int Load(SvStream&); BOOL bWeb;
virtual BOOL Store(SvStream&);
virtual void UseDefault();
public: com::sun::star::uno::Sequence<rtl::OUString> GetPropertyNames();
SwMasterUsrPref(USHORT nType); public:
SwContentViewConfig(BOOL bWeb, SwMasterUsrPref& rParent);
~SwContentViewConfig();
virtual void Notify( const com::sun::star::uno::Sequence<rtl::OUString>& aPropertyNames);
virtual void Commit();
void Load();
void SetModified(){ConfigItem::SetModified();}
};
/* -----------------------------28.09.00 09:45--------------------------------
---------------------------------------------------------------------------*/
class SwLayoutViewConfig : public utl::ConfigItem
{
SwMasterUsrPref& rParent;
BOOL bWeb;
com::sun::star::uno::Sequence<rtl::OUString> GetPropertyNames();
public:
SwLayoutViewConfig(BOOL bWeb, SwMasterUsrPref& rParent);
~SwLayoutViewConfig();
virtual void Notify( const com::sun::star::uno::Sequence<rtl::OUString>& aPropertyNames);
virtual void Commit();
void Load();
void SetModified(){ConfigItem::SetModified();}
};
/* -----------------------------28.09.00 09:45--------------------------------
---------------------------------------------------------------------------*/
class SwMasterUsrPref : public SwViewOption
{
friend class SwContentViewConfig;
friend class SwLayoutViewConfig;
SwContentViewConfig aContentConfig;
SwLayoutViewConfig aLayoutConfig;
sal_Int32 nFldUpdateFlags; //udpate of fields and charts
sal_Int32 nLinkUpdateMode;
FieldUnit eUserMetric;
virtual String GetName() const; sal_Int32 nDefTab; //default tab stop distance
public:
SwMasterUsrPref(BOOL bWeb);
void SetUsrPref(const SwViewOption &rCopy); void SetUsrPref(const SwViewOption &rCopy);
void Commit()
{
aContentConfig.Commit();
aLayoutConfig.Commit();
}
void SetModified()
{
aContentConfig.SetModified();
aLayoutConfig.SetModified();
}
void SetUpdateLinkMode(sal_Int32 nSet) {nLinkUpdateMode = nSet; SetModified();}
sal_Int32 GetUpdateLinkMode() const {return nLinkUpdateMode; }
void SetUpdateFields(BOOL bSet)
{
if(bSet && nFldUpdateFlags == AUTOUPD_OFF)
{
nFldUpdateFlags = AUTOUPD_FIELD_ONLY;
SetModified();
}
else if(!bSet)
{
nFldUpdateFlags = AUTOUPD_OFF;
SetModified();
}
};
sal_Bool IsUpdateFields()const {return nFldUpdateFlags != AUTOUPD_OFF; }
sal_Int32 GetFldUpdateFlags()const {return nFldUpdateFlags;}
void SetFldUpdateFlags(sal_Int32 nSet){nFldUpdateFlags = nSet;}
void SetUpdateCharts(BOOL bSet)
{
if(bSet)
{
nFldUpdateFlags = AUTOUPD_FIELD_AND_CHARTS;
SetModified();
}
else if(nFldUpdateFlags == AUTOUPD_FIELD_AND_CHARTS)
{
nFldUpdateFlags = AUTOUPD_FIELD_ONLY;
SetModified();
}
};
sal_Bool IsUpdateCharts()const {return nFldUpdateFlags == AUTOUPD_FIELD_AND_CHARTS; }
FieldUnit GetMetric() const { return eUserMetric;}
void SetMetric(FieldUnit eSet) { eUserMetric = eSet; SetModified();};
sal_Int32 GetDefTab() const { return nDefTab;}
void SetDefTab( sal_Int32 nSet ) { nDefTab = nSet; SetModified();}
}; };
#endif #endif
......
...@@ -2,9 +2,9 @@ ...@@ -2,9 +2,9 @@
* *
* $RCSfile: pview.cxx,v $ * $RCSfile: pview.cxx,v $
* *
* $Revision: 1.1.1.1 $ * $Revision: 1.2 $
* *
* last change: $Author: hr $ $Date: 2000-09-18 17:14:48 $ * last change: $Author: os $ $Date: 2000-09-28 15:24:06 $
* *
* The Contents of this file are made available subject to the terms of * The Contents of this file are made available subject to the terms of
* either of the following licenses * either of the following licenses
...@@ -403,8 +403,8 @@ SwPreviewPrintOptionsDialog::SwPreviewPrintOptionsDialog( SwPagePreViewWin& rPar ...@@ -403,8 +403,8 @@ SwPreviewPrintOptionsDialog::SwPreviewPrintOptionsDialog( SwPagePreViewWin& rPar
SwDocShell* pDocShell = rPreView.GetDocShell(); SwDocShell* pDocShell = rPreView.GetDocShell();
const SwModuleOptions* pModOpt = SW_MOD()->GetModuleConfig(); const SwMasterUsrPref *pUsrPref = SW_MOD()->GetUsrPref(0 != PTR_CAST(SwWebDocShell, pDocShell));
FieldUnit eFieldUnit = pModOpt->GetMetric(0 != PTR_CAST(SwWebDocShell, pDocShell)); FieldUnit eFieldUnit = pUsrPref->GetMetric();
::SetFieldUnit( aLSpaceMF, eFieldUnit ); ::SetFieldUnit( aLSpaceMF, eFieldUnit );
::SetFieldUnit( aRSpaceMF, eFieldUnit ); ::SetFieldUnit( aRSpaceMF, eFieldUnit );
::SetFieldUnit( aTSpaceMF, eFieldUnit ); ::SetFieldUnit( aTSpaceMF, eFieldUnit );
...@@ -1068,7 +1068,6 @@ void SwPagePreViewWin::SetPagePreview( BYTE nRow, BYTE nCol ) ...@@ -1068,7 +1068,6 @@ void SwPagePreViewWin::SetPagePreview( BYTE nRow, BYTE nCol )
pOpt->SetPagePrevRow( nRow ); pOpt->SetPagePrevRow( nRow );
pOpt->SetPagePrevCol( nCol ); pOpt->SetPagePrevCol( nCol );
pOpt->SetModified(); pOpt->SetModified();
pOpt->SetDefault( FALSE );
//VScrollbar updaten! //VScrollbar updaten!
if( rView.StatVScrollbar() ) if( rView.StatVScrollbar() )
...@@ -2221,6 +2220,9 @@ BOOL SwPagePreView::HandleWheelCommands( const CommandEvent& rCEvt ) ...@@ -2221,6 +2220,9 @@ BOOL SwPagePreView::HandleWheelCommands( const CommandEvent& rCEvt )
/************************************************************************* /*************************************************************************
$Log: not supported by cvs2svn $ $Log: not supported by cvs2svn $
Revision 1.1.1.1 2000/09/18 17:14:48 hr
initial import
Revision 1.201 2000/09/18 16:06:10 willem.vandorp Revision 1.201 2000/09/18 16:06:10 willem.vandorp
OpenOffice header added. OpenOffice header added.
......
...@@ -2,9 +2,9 @@ ...@@ -2,9 +2,9 @@
* *
* $RCSfile: viewmdi.cxx,v $ * $RCSfile: viewmdi.cxx,v $
* *
* $Revision: 1.1.1.1 $ * $Revision: 1.2 $
* *
* last change: $Author: hr $ $Date: 2000-09-18 17:14:49 $ * last change: $Author: os $ $Date: 2000-09-28 15:24:06 $
* *
* The Contents of this file are made available subject to the terms of * The Contents of this file are made available subject to the terms of
* either of the following licenses * either of the following licenses
...@@ -188,7 +188,7 @@ void SwView::_SetZoom( const Size &rEditSize, SvxZoomType eZoomType, ...@@ -188,7 +188,7 @@ void SwView::_SetZoom( const Size &rEditSize, SvxZoomType eZoomType,
pUsrPref->SetZoom ( USHORT(nFac) ); pUsrPref->SetZoom ( USHORT(nFac) );
pUsrPref->SetZoomType( BYTE( eZoomType ) ); pUsrPref->SetZoomType( BYTE( eZoomType ) );
SW_MOD()->ApplyUsrPref( *pUsrPref, 0 ); SW_MOD()->ApplyUsrPref( *pUsrPref, 0 );
pUsrPref->SetDefault ( FALSE ); pUsrPref->SetModified();
} }
if ( pOpt->GetZoom() != (USHORT) nFac ) if ( pOpt->GetZoom() != (USHORT) nFac )
{ {
...@@ -711,6 +711,9 @@ void SwView::SetImageButtonColor(Color& rColor) ...@@ -711,6 +711,9 @@ void SwView::SetImageButtonColor(Color& rColor)
/*------------------------------------------------------------------------ /*------------------------------------------------------------------------
$Log: not supported by cvs2svn $ $Log: not supported by cvs2svn $
Revision 1.1.1.1 2000/09/18 17:14:49 hr
initial import
Revision 1.126 2000/09/18 16:06:13 willem.vandorp Revision 1.126 2000/09/18 16:06:13 willem.vandorp
OpenOffice header added. OpenOffice header added.
......
...@@ -2,9 +2,9 @@ ...@@ -2,9 +2,9 @@
* *
* $RCSfile: uitool.cxx,v $ * $RCSfile: uitool.cxx,v $
* *
* $Revision: 1.1.1.1 $ * $Revision: 1.2 $
* *
* last change: $Author: hr $ $Date: 2000-09-18 17:14:50 $ * last change: $Author: os $ $Date: 2000-09-28 15:25:03 $
* *
* The Contents of this file are made available subject to the terms of * The Contents of this file are made available subject to the terms of
* either of the following licenses * either of the following licenses
...@@ -168,12 +168,12 @@ ...@@ -168,12 +168,12 @@
#ifndef _FMTCOL_HXX #ifndef _FMTCOL_HXX
#include <fmtcol.hxx> #include <fmtcol.hxx>
#endif #endif
#ifndef _MODCFG_HXX
#include <modcfg.hxx>
#endif
#ifndef _POOLFMT_HXX #ifndef _POOLFMT_HXX
#include <poolfmt.hxx> #include <poolfmt.hxx>
#endif #endif
#ifndef _USRPREF_HXX
#include "usrpref.hxx"
#endif
#ifndef _ERROR_H #ifndef _ERROR_H
#include <error.h> #include <error.h>
...@@ -703,7 +703,7 @@ void SwToSfxPageDescAttr( SfxItemSet& rCoreSet ) ...@@ -703,7 +703,7 @@ void SwToSfxPageDescAttr( SfxItemSet& rCoreSet )
FieldUnit GetDfltMetric(BOOL bWeb) FieldUnit GetDfltMetric(BOOL bWeb)
{ {
return SW_MOD()->GetModuleConfig()->GetMetric(bWeb); return SW_MOD()->GetUsrPref(bWeb)->GetMetric();
} }
/*-------------------------------------------------------------------- /*--------------------------------------------------------------------
...@@ -713,24 +713,7 @@ FieldUnit GetDfltMetric(BOOL bWeb) ...@@ -713,24 +713,7 @@ FieldUnit GetDfltMetric(BOOL bWeb)
void SetDfltMetric( FieldUnit eMetric, BOOL bWeb ) void SetDfltMetric( FieldUnit eMetric, BOOL bWeb )
{ {
SwModuleOptions* pCfg = SW_MOD()->GetModuleConfig(); SW_MOD()->ApplyUserMetric(eMetric, bWeb);
FieldUnit eOldMetric = pCfg->GetMetric(bWeb);
if(eOldMetric != eMetric)
pCfg->SetMetric(eMetric, bWeb);
SwView* pTmpView = SwModule::GetFirstView();
// fuer alle MDI-Fenster das Lineal umschalten
while(pTmpView)
{
if(bWeb == (0 != PTR_CAST(SwWebView, pTmpView)))
{
pTmpView->ChangeVLinealMetric(eMetric);
pTmpView->ChangeTabMetric(eMetric);
}
pTmpView = SwModule::GetNextView(pTmpView);
}
} }
/*-----------------15.07.97 10:49------------------- /*-----------------15.07.97 10:49-------------------
...@@ -895,6 +878,9 @@ SwTwips GetTableWidth( SwFrmFmt* pFmt, SwTabCols& rCols, USHORT *pPercent, ...@@ -895,6 +878,9 @@ SwTwips GetTableWidth( SwFrmFmt* pFmt, SwTabCols& rCols, USHORT *pPercent,
/*------------------------------------------------------------------------ /*------------------------------------------------------------------------
$Log: not supported by cvs2svn $ $Log: not supported by cvs2svn $
Revision 1.1.1.1 2000/09/18 17:14:50 hr
initial import
Revision 1.124 2000/09/18 16:06:19 willem.vandorp Revision 1.124 2000/09/18 16:06:19 willem.vandorp
OpenOffice header added. OpenOffice header added.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment