Kaydet (Commit) c2ec783a authored tarafından Oliver Bolte's avatar Oliver Bolte

INTEGRATION: CWS basemodelrefactoring (1.69.102); FILE MERGED

2007/03/26 13:23:40 mba 1.69.102.2: warning problem fixed
2007/03/23 15:55:05 mba 1.69.102.1: #i75677#: remove obsolete settings
üst 7c5b83eb
...@@ -4,9 +4,9 @@ ...@@ -4,9 +4,9 @@
* *
* $RCSfile: appcfg.cxx,v $ * $RCSfile: appcfg.cxx,v $
* *
* $Revision: 1.70 $ * $Revision: 1.71 $
* *
* last change: $Author: hr $ $Date: 2007-06-27 22:55:07 $ * last change: $Author: obo $ $Date: 2007-07-17 13:40:11 $
* *
* The Contents of this file are made available subject to * The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1. * the terms of GNU Lesser General Public License Version 2.1.
...@@ -319,34 +319,6 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet ) ...@@ -319,34 +319,6 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
bRet = FALSE; bRet = FALSE;
} }
break; break;
case SID_OPT_SAVEGRAPHICSCOMPRESSED :
{
{
bRet = TRUE;
if (!aSaveOptions.IsReadOnly(SvtSaveOptions::E_SAVEGRAPHICS))
{
SfxDocumentInfo *pDocInf = SfxObjectShell::Current() ? &SfxObjectShell::Current()->GetDocInfo() : 0;
bool bComprGraph = pDocInf ? pDocInf->IsSaveGraphicsCompressed() : aSaveOptions.GetSaveGraphicsMode() == SvtSaveOptions::SaveGraphicsCompressed;
if (!rSet.Put( SfxBoolItem( rPool.GetWhich( SID_OPT_SAVEGRAPHICSCOMPRESSED ),bComprGraph )))
bRet = FALSE;
}
}
break;
}
case SID_OPT_SAVEORIGINALGRAPHICS :
{
{
bRet = TRUE;
if (!aSaveOptions.IsReadOnly(SvtSaveOptions::E_SAVEGRAPHICS))
{
SfxDocumentInfo *pDocInf = SfxObjectShell::Current() ? &SfxObjectShell::Current()->GetDocInfo() : 0;
bool bOrigGraph = pDocInf ? pDocInf->IsSaveOriginalGraphics() : aSaveOptions.GetSaveGraphicsMode() == SvtSaveOptions::SaveGraphicsOriginal;
if (!rSet.Put( SfxBoolItem( rPool.GetWhich( SID_OPT_SAVEORIGINALGRAPHICS ), bOrigGraph )))
bRet = FALSE;
}
}
break;
}
case SID_ATTR_WORKINGSET : case SID_ATTR_WORKINGSET :
{ {
bRet = TRUE; bRet = TRUE;
...@@ -708,28 +680,6 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet ) ...@@ -708,28 +680,6 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
aSaveOptions.SetDocInfoSave(((const SfxBoolItem *)pItem)->GetValue()); aSaveOptions.SetDocInfoSave(((const SfxBoolItem *)pItem)->GetValue());
} }
// Grafiken komprimiert speichern
SvtSaveOptions::SaveGraphicsMode eMode = SvtSaveOptions::SaveGraphicsNormal;
if ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_OPT_SAVEGRAPHICSCOMPRESSED), TRUE, &pItem))
{
DBG_ASSERT(pItem->ISA(SfxBoolItem), "BoolItem expected");
BOOL b = ((const SfxBoolItem *)pItem)->GetValue();
if ( b )
eMode = SvtSaveOptions::SaveGraphicsCompressed;
}
// Grafiken im Original speichern
if ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_OPT_SAVEORIGINALGRAPHICS), TRUE, &pItem))
{
DBG_ASSERT(pItem->ISA(SfxBoolItem), "BoolItem expected");
BOOL b = ((const SfxBoolItem *)pItem)->GetValue();
if ( b )
eMode = SvtSaveOptions::SaveGraphicsOriginal;
}
if ( eMode != aSaveOptions.GetSaveGraphicsMode() )
aSaveOptions.SetSaveGraphicsMode( eMode );
// offende Dokumente merken // offende Dokumente merken
if ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_ATTR_WORKINGSET), TRUE, &pItem)) if ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_ATTR_WORKINGSET), TRUE, &pItem))
{ {
...@@ -976,41 +926,11 @@ void SfxApplication::SetOptions(const SfxItemSet &rSet) ...@@ -976,41 +926,11 @@ void SfxApplication::SetOptions(const SfxItemSet &rSet)
SvtPathOptions aPathOptions; SvtPathOptions aPathOptions;
// Daten werden in DocInfo und IniManager gespeichert // Daten werden in DocInfo und IniManager gespeichert
SfxDocumentInfo *pDocInf = SfxObjectShell::Current()
? &SfxObjectShell::Current()->GetDocInfo()
: 0;
const SfxPoolItem *pItem = 0; const SfxPoolItem *pItem = 0;
SfxItemPool &rPool = GetPool(); SfxItemPool &rPool = GetPool();
SfxAllItemSet aSendSet( rSet ); SfxAllItemSet aSendSet( rSet );
// portable Grafiken
if ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_ATTR_INDEP_METAFILE), TRUE, &pItem))
{
DBG_ASSERT(pItem->ISA(SfxBoolItem), "BoolItem expected");
BOOL b = ((const SfxBoolItem *)pItem)->GetValue();
if ( pDocInf )
pDocInf->SetPortableGraphics(b);
}
// Grafiken komprimiert speichern
if ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_OPT_SAVEGRAPHICSCOMPRESSED), TRUE, &pItem))
{
DBG_ASSERT(pItem->ISA(SfxBoolItem), "BoolItem expected");
BOOL b = ((const SfxBoolItem *)pItem)->GetValue();
if ( pDocInf )
pDocInf->SetSaveGraphicsCompressed(b);
}
// Grafiken im Original speichern
if ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_OPT_SAVEORIGINALGRAPHICS), TRUE, &pItem))
{
DBG_ASSERT(pItem->ISA(SfxBoolItem), "BoolItem expected");
BOOL b = ((const SfxBoolItem *)pItem)->GetValue();
if ( pDocInf )
pDocInf->SetSaveOriginalGraphics(b);
}
// PathName // PathName
if ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_ATTR_PATHNAME), TRUE, &pItem)) if ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_ATTR_PATHNAME), TRUE, &pItem))
{ {
......
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