summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVladimir Glazunov <vg@openoffice.org>2011-01-06 12:12:27 +0100
committerVladimir Glazunov <vg@openoffice.org>2011-01-06 12:12:27 +0100
commit367e1d80d1c1179d8cb215c160de95825dba87bd (patch)
tree82eb55bc87a498e2cb1d11936554dbe8dd87e0c9
parenteda44ce2057d1dd909ae32156679ddc288c418f7 (diff)
parentfdff83134b3fbff51de1dd06399458d39417f129 (diff)
CWS-TOOLING: integrate CWS vcl117
-rw-r--r--basic/inc/pch/precompiled_basic.hxx2
-rw-r--r--basic/source/runtime/methods.cxx2
-rw-r--r--desktop/inc/app.hxx2
-rw-r--r--desktop/source/app/app.cxx100
-rw-r--r--drawinglayer/source/processor2d/vclhelperbitmaprender.cxx39
-rwxr-xr-x[-rw-r--r--]editeng/inc/pch/precompiled_editeng.hxx4
-rw-r--r--fpicker/source/office/OfficeFilePicker.hxx2
-rw-r--r--framework/inc/pch/precompiled_framework.hxx4
-rw-r--r--framework/inc/services/layoutmanager.hxx2
-rw-r--r--framework/source/helper/tagwindowasmodified.cxx2
-rw-r--r--framework/source/uielement/fontsizemenucontroller.cxx2
-rw-r--r--officecfg/registry/schema/org/openoffice/Office/Common.xcs55
-rw-r--r--sfx2/inc/pch/precompiled_sfx2.hxx2
-rw-r--r--sfx2/inc/sfx2/event.hxx1
-rw-r--r--sfx2/inc/sfx2/mnumgr.hxx2
-rw-r--r--sfx2/inc/sfx2/module.hxx2
-rw-r--r--sfx2/inc/sfx2/printer.hxx60
-rw-r--r--sfx2/inc/sfx2/viewsh.hxx5
-rw-r--r--sfx2/source/appl/appmain.cxx15
-rwxr-xr-xsfx2/source/doc/printhelper.cxx74
-rw-r--r--sfx2/source/view/printer.cxx314
-rw-r--r--sfx2/source/view/viewprn.cxx155
-rw-r--r--svx/inc/pch/precompiled_svx.hxx4
-rw-r--r--svx/inc/svx/fmgridif.hxx2
-rw-r--r--svx/inc/svx/fmtools.hxx2
-rw-r--r--svx/source/fmcomp/gridcell.cxx11
-rw-r--r--svx/source/gallery2/gallery1.cxx2
-rw-r--r--svx/source/unodraw/unoprov.cxx2
-rwxr-xr-x[-rw-r--r--]uui/source/iahndl.hxx2
29 files changed, 111 insertions, 760 deletions
diff --git a/basic/inc/pch/precompiled_basic.hxx b/basic/inc/pch/precompiled_basic.hxx
index e8f9e004ca6a..ae45c383c74d 100644
--- a/basic/inc/pch/precompiled_basic.hxx
+++ b/basic/inc/pch/precompiled_basic.hxx
@@ -272,7 +272,7 @@
#include "vcl/timer.hxx"
#include "vcl/toolbox.hxx"
#include "vcl/window.hxx"
-#include "vcl/wintypes.hxx"
+#include "tools/wintypes.hxx"
#include "vcl/wrkwin.hxx"
#include "vos/diagnose.hxx"
diff --git a/basic/source/runtime/methods.cxx b/basic/source/runtime/methods.cxx
index 97f6ed227d47..cfd84567644a 100644
--- a/basic/source/runtime/methods.cxx
+++ b/basic/source/runtime/methods.cxx
@@ -37,7 +37,7 @@
#include <vcl/svapp.hxx>
#include <vcl/settings.hxx>
#include <vcl/sound.hxx>
-#include <vcl/wintypes.hxx>
+#include <tools/wintypes.hxx>
#include <vcl/msgbox.hxx>
#include <basic/sbx.hxx>
#include <svl/zforlist.hxx>
diff --git a/desktop/inc/app.hxx b/desktop/inc/app.hxx
index 8eb4dd3cc25b..b64327bd7232 100644
--- a/desktop/inc/app.hxx
+++ b/desktop/inc/app.hxx
@@ -65,6 +65,8 @@ class Desktop : public Application
{
friend class UserInstall;
+ void doShutdown();
+
public:
enum BootstrapError
{
diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index d569b1f61d1e..82af26653b84 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -1531,8 +1531,26 @@ void Desktop::AppEvent( const ApplicationEvent& rAppEvent )
HandleAppEvent( rAppEvent );
}
+struct ExecuteGlobals
+{
+ Reference < css::document::XEventListener > xGlobalBroadcaster;
+ sal_Bool bRestartRequested;
+ sal_Bool bUseSystemFileDialog;
+ std::auto_ptr<SvtLanguageOptions> pLanguageOptions;
+ std::auto_ptr<SvtPathOptions> pPathOptions;
+
+ ExecuteGlobals()
+ : bRestartRequested( sal_False )
+ , bUseSystemFileDialog( sal_True )
+ {}
+};
+
+static ExecuteGlobals* pExecGlobals = NULL;
+
void Desktop::Main()
{
+ pExecGlobals = new ExecuteGlobals();
+
RTL_LOGFILE_CONTEXT( aLog, "desktop (cd100003) ::Desktop::Main" );
// Remember current context object
@@ -1590,14 +1608,8 @@ void Desktop::Main()
Reference< XMultiServiceFactory > xSMgr =
::comphelper::getProcessServiceFactory();
- std::auto_ptr<SvtLanguageOptions> pLanguageOptions;
- std::auto_ptr<SvtPathOptions> pPathOptions;
-
Reference< ::com::sun::star::task::XRestartManager > xRestartManager;
- sal_Bool bRestartRequested( sal_False );
- sal_Bool bUseSystemFileDialog(sal_True);
int nAcquireCount( 0 );
- Reference < css::document::XEventListener > xGlobalBroadcaster;
try
{
RegisterServices( xSMgr );
@@ -1683,7 +1695,7 @@ void Desktop::Main()
SetDisplayName( aTitle );
RTL_LOGFILE_CONTEXT_TRACE( aLog, "{ create SvtPathOptions and SvtLanguageOptions" );
- pPathOptions.reset( new SvtPathOptions);
+ pExecGlobals->pPathOptions.reset( new SvtPathOptions);
SetSplashScreenProgress(40);
RTL_LOGFILE_CONTEXT_TRACE( aLog, "} create SvtPathOptions and SvtLanguageOptions" );
@@ -1700,7 +1712,7 @@ void Desktop::Main()
}
// create service for loadin SFX (still needed in startup)
- xGlobalBroadcaster = Reference < css::document::XEventListener >
+ pExecGlobals->xGlobalBroadcaster = Reference < css::document::XEventListener >
( xSMgr->createInstance(
DEFINE_CONST_UNICODE( "com.sun.star.frame.GlobalEventBroadcaster" ) ), UNO_QUERY );
@@ -1756,13 +1768,13 @@ void Desktop::Main()
}
// keep a language options instance...
- pLanguageOptions.reset( new SvtLanguageOptions(sal_True));
+ pExecGlobals->pLanguageOptions.reset( new SvtLanguageOptions(sal_True));
- if (xGlobalBroadcaster.is())
+ if (pExecGlobals->xGlobalBroadcaster.is())
{
css::document::EventObject aEvent;
aEvent.EventName = ::rtl::OUString::createFromAscii("OnStartApp");
- xGlobalBroadcaster->notifyEvent(aEvent);
+ pExecGlobals->xGlobalBroadcaster->notifyEvent(aEvent);
}
SetSplashScreenProgress(50);
@@ -1782,7 +1794,7 @@ void Desktop::Main()
}
// check whether the shutdown is caused by restart
- bRestartRequested = ( xRestartManager.is() && xRestartManager->isRestartRequested( sal_True ) );
+ pExecGlobals->bRestartRequested = ( xRestartManager.is() && xRestartManager->isRestartRequested( sal_True ) );
if ( pCmdLineArgs->IsHeadless() )
{
@@ -1790,11 +1802,11 @@ void Desktop::Main()
// headless mode relies on Application::EnableHeadlessMode()
// which does only work for VCL dialogs!!
SvtMiscOptions aMiscOptions;
- bUseSystemFileDialog = aMiscOptions.UseSystemFileDialog();
+ pExecGlobals->bUseSystemFileDialog = aMiscOptions.UseSystemFileDialog();
aMiscOptions.SetUseSystemFileDialog( sal_False );
}
- if ( !bRestartRequested )
+ if ( !pExecGlobals->bRestartRequested )
{
if ((!pCmdLineArgs->WantsToLoadDocument() ) &&
(SvtModuleOptions().IsModuleInstalled(SvtModuleOptions::E_SSTARTMODULE)) &&
@@ -1866,10 +1878,9 @@ void Desktop::Main()
SvtAccessibilityOptions aOptions;
aOptions.SetVCLSettings();
- if ( !bRestartRequested )
+ if ( !pExecGlobals->bRestartRequested )
{
Application::SetFilterHdl( LINK( this, Desktop, ImplInitFilterHdl ) );
-
sal_Bool bTerminateRequested = sal_False;
// Preload function depends on an initialized sfx application!
@@ -1925,9 +1936,9 @@ void Desktop::Main()
new svt::JavaContext( com::sun::star::uno::getCurrentContext() ) );
// check whether the shutdown is caused by restart just before entering the Execute
- bRestartRequested = bRestartRequested || ( xRestartManager.is() && xRestartManager->isRestartRequested( sal_True ) );
+ pExecGlobals->bRestartRequested = pExecGlobals->bRestartRequested || ( xRestartManager.is() && xRestartManager->isRestartRequested( sal_True ) );
- if ( !bRestartRequested )
+ if ( !pExecGlobals->bRestartRequested )
{
// if this run of the office is triggered by restart, some additional actions should be done
DoRestartActionsIfNecessary( !pCmdLineArgs->IsInvisible() && !pCmdLineArgs->IsNoQuickstart() );
@@ -1946,44 +1957,57 @@ void Desktop::Main()
FatalError( MakeStartupErrorMessage(exAnyCfg.Message) );
}
}
+ // CAUTION: you do not necessarily get here e.g. on the Mac.
+ // please put all deinitialization code into doShutdown
+ doShutdown();
+}
+
+void Desktop::doShutdown()
+{
+ if( ! pExecGlobals )
+ return;
- if ( bRestartRequested )
+ if ( pExecGlobals->bRestartRequested )
SetRestartState();
- if (xGlobalBroadcaster.is())
+ if (pExecGlobals->xGlobalBroadcaster.is())
{
css::document::EventObject aEvent;
aEvent.EventName = ::rtl::OUString::createFromAscii("OnCloseApp");
- xGlobalBroadcaster->notifyEvent(aEvent);
+ pExecGlobals->xGlobalBroadcaster->notifyEvent(aEvent);
}
- delete pResMgr;
+ delete pResMgr, pResMgr = NULL;
// Restore old value
+ CommandLineArgs* pCmdLineArgs = GetCommandLineArgs();
if ( pCmdLineArgs->IsHeadless() )
- SvtMiscOptions().SetUseSystemFileDialog( bUseSystemFileDialog );
+ SvtMiscOptions().SetUseSystemFileDialog( pExecGlobals->bUseSystemFileDialog );
// remove temp directory
RemoveTemporaryDirectory();
FlushConfiguration();
// The acceptors in the AcceptorMap must be released (in DeregisterServices)
// with the solar mutex unlocked, to avoid deadlock:
- nAcquireCount = Application::ReleaseSolarMutex();
+ ULONG nAcquireCount = Application::ReleaseSolarMutex();
DeregisterServices();
Application::AcquireSolarMutex(nAcquireCount);
tools::DeInitTestToolLib();
// be sure that path/language options gets destroyed before
// UCB is deinitialized
RTL_LOGFILE_CONTEXT_TRACE( aLog, "-> dispose path/language options" );
- pLanguageOptions.reset( 0 );
- pPathOptions.reset( 0 );
+ pExecGlobals->pLanguageOptions.reset( 0 );
+ pExecGlobals->pPathOptions.reset( 0 );
RTL_LOGFILE_CONTEXT_TRACE( aLog, "<- dispose path/language options" );
RTL_LOGFILE_CONTEXT_TRACE( aLog, "-> deinit ucb" );
::ucbhelper::ContentBroker::deinitialize();
RTL_LOGFILE_CONTEXT_TRACE( aLog, "<- deinit ucb" );
+ sal_Bool bRR = pExecGlobals->bRestartRequested;
+ delete pExecGlobals, pExecGlobals = NULL;
+
RTL_LOGFILE_CONTEXT_TRACE( aLog, "FINISHED WITH Destop::Main" );
- if ( bRestartRequested )
+ if ( bRR )
{
restartOnMac(true);
// wouldn't the solution be more clean if SalMain returns the exit code to the system?
@@ -2098,9 +2122,9 @@ sal_Bool Desktop::InitializeQuickstartMode( Reference< XMultiServiceFactory >& r
// unfortunately this broke the QUARTZ behavior which is to always run
// in quickstart mode since Mac applications do not usually quit
// when the last document closes
- #ifndef QUARTZ
+ //#ifndef QUARTZ
if ( bQuickstart )
- #endif
+ //#endif
{
Reference < XComponent > xQuickstart( rSMgr->createInstanceWithArguments(
DEFINE_CONST_UNICODE( "com.sun.star.office.Quickstart" ), aSeq ),
@@ -2168,17 +2192,6 @@ void Desktop::SystemSettingsChanging( AllSettings& rSettings, Window* )
}
hStyleSettings.SetUseImagesInMenus(bUseImagesInMenus);
- sal_uInt16 nTabStyle = hStyleSettings.GetTabControlStyle();
- nTabStyle &= ~STYLE_TABCONTROL_SINGLELINE;
- if( aAppearanceCfg.IsSingleLineTabCtrl() )
- nTabStyle |=STYLE_TABCONTROL_SINGLELINE;
-
- nTabStyle &= ~STYLE_TABCONTROL_COLOR;
- if( aAppearanceCfg.IsColoredTabCtrl() )
- nTabStyle |= STYLE_TABCONTROL_COLOR;
-
- hStyleSettings.SetTabControlStyle(nTabStyle);
-
hStyleSettings.SetDragFullOptions( nDragFullOptions );
rSettings.SetStyleSettings ( hStyleSettings );
}
@@ -3180,6 +3193,13 @@ void Desktop::HandleAppEvent( const ApplicationEvent& rAppEvent )
catch(const css::uno::Exception&)
{}
}
+ else if( rAppEvent.GetEvent() == "PRIVATE:DOSHUTDOWN" )
+ {
+ Desktop* pD = dynamic_cast<Desktop*>(GetpApp());
+ OSL_ENSURE( pD, "no desktop ?!?" );
+ if( pD )
+ pD->doShutdown();
+ }
}
void Desktop::OpenSplashScreen()
diff --git a/drawinglayer/source/processor2d/vclhelperbitmaprender.cxx b/drawinglayer/source/processor2d/vclhelperbitmaprender.cxx
index 80e34ba27701..752bf6d13849 100644
--- a/drawinglayer/source/processor2d/vclhelperbitmaprender.cxx
+++ b/drawinglayer/source/processor2d/vclhelperbitmaprender.cxx
@@ -84,19 +84,18 @@ namespace drawinglayer
aOutlineRange.transform(aSimpleObjectMatrix);
}
- // prepare dest coor
- const sal_uInt32 nDiscreteWidth(basegfx::fround(aOutlineRange.getMaxX()));
- const sal_uInt32 nDiscreteHeight(basegfx::fround(aOutlineRange.getMaxY()));
- const Rectangle aDestRectPixel(
- basegfx::fround(aOutlineRange.getMinX()),
- basegfx::fround(aOutlineRange.getMinY()),
- nDiscreteWidth > 0 ? nDiscreteWidth - 1 : 0,
- nDiscreteHeight > 0 ? nDiscreteHeight - 1 : 0);
+ // prepare dest coordinates
+ const Point aPoint(
+ basegfx::fround(aOutlineRange.getMinX()),
+ basegfx::fround(aOutlineRange.getMinY()));
+ const Size aSize(
+ basegfx::fround(aOutlineRange.getWidth()),
+ basegfx::fround(aOutlineRange.getHeight()));
// paint it using GraphicManager
Graphic aGraphic(rBitmapEx);
GraphicObject aGraphicObject(aGraphic);
- aGraphicObject.Draw(&rOutDev, aDestRectPixel.TopLeft(), aDestRectPixel.GetSize(), &aAttributes);
+ aGraphicObject.Draw(&rOutDev, aPoint, aSize, &aAttributes);
}
void RenderBitmapPrimitive2D_BitmapEx(
@@ -110,13 +109,13 @@ namespace drawinglayer
// prepare dest coor. Necessary to expand since vcl's DrawBitmapEx draws one pix less
basegfx::B2DRange aOutlineRange(0.0, 0.0, 1.0, 1.0);
aOutlineRange.transform(rTransform);
- const sal_uInt32 nDiscreteWidth(basegfx::fround(aOutlineRange.getMaxX()));
- const sal_uInt32 nDiscreteHeight(basegfx::fround(aOutlineRange.getMaxY()));
- const Rectangle aDestRectPixel(
- basegfx::fround(aOutlineRange.getMinX()),
- basegfx::fround(aOutlineRange.getMinY()),
- nDiscreteWidth > 0 ? nDiscreteWidth - 1 : 0,
- nDiscreteHeight > 0 ? nDiscreteHeight - 1 : 0);
+ // prepare dest coordinates
+ const Point aPoint(
+ basegfx::fround(aOutlineRange.getMinX()),
+ basegfx::fround(aOutlineRange.getMinY()));
+ const Size aSize(
+ basegfx::fround(aOutlineRange.getWidth()),
+ basegfx::fround(aOutlineRange.getHeight()));
// decompose matrix to check for shear, rotate and mirroring
basegfx::B2DVector aScale, aTranslate;
@@ -142,7 +141,7 @@ namespace drawinglayer
}
// draw bitmap
- rOutDev.DrawBitmapEx(aDestRectPixel.TopLeft(), aDestRectPixel.GetSize(), aContent);
+ rOutDev.DrawBitmapEx(aPoint, aSize, aContent);
}
void RenderBitmapPrimitive2D_self(
@@ -153,13 +152,11 @@ namespace drawinglayer
// process self with free transformation (containing shear and rotate). Get dest rect in pixels.
basegfx::B2DRange aOutlineRange(0.0, 0.0, 1.0, 1.0);
aOutlineRange.transform(rTransform);
- const sal_uInt32 nDiscreteWidth(basegfx::fround(aOutlineRange.getMaxX()));
- const sal_uInt32 nDiscreteHeight(basegfx::fround(aOutlineRange.getMaxY()));
const Rectangle aDestRectLogic(
basegfx::fround(aOutlineRange.getMinX()),
basegfx::fround(aOutlineRange.getMinY()),
- nDiscreteWidth > 0 ? nDiscreteWidth - 1 : 0,
- nDiscreteHeight > 0 ? nDiscreteHeight - 1 : 0);
+ basegfx::fround(aOutlineRange.getMaxX()),
+ basegfx::fround(aOutlineRange.getMaxY()));
const Rectangle aDestRectPixel(rOutDev.LogicToPixel(aDestRectLogic));
// #i96708# check if Metafile is recorded
diff --git a/editeng/inc/pch/precompiled_editeng.hxx b/editeng/inc/pch/precompiled_editeng.hxx
index d53bfcf1aaf2..83f0ab6c54e8 100644..100755
--- a/editeng/inc/pch/precompiled_editeng.hxx
+++ b/editeng/inc/pch/precompiled_editeng.hxx
@@ -853,7 +853,7 @@
#include "vcl/cursor.hxx"
#include "vcl/decoview.hxx"
#include "vcl/dndhelp.hxx"
-#include "vcl/fldunit.hxx"
+#include "tools/fldunit.hxx"
#include "vcl/fntstyle.hxx"
#include "unotools/fontcvt.hxx"
#include "vcl/gdimtf.hxx"
@@ -872,7 +872,7 @@
#include "vcl/unohelp.hxx"
#include "vcl/unohelp2.hxx"
#include "vcl/wall.hxx"
-#include "vcl/wintypes.hxx"
+#include "tools/wintypes.hxx"
#include "vos/mutex.hxx"
#include "vos/ref.hxx"
#include "vos/refernce.hxx"
diff --git a/fpicker/source/office/OfficeFilePicker.hxx b/fpicker/source/office/OfficeFilePicker.hxx
index 21839554aefc..c203924f6e51 100644
--- a/fpicker/source/office/OfficeFilePicker.hxx
+++ b/fpicker/source/office/OfficeFilePicker.hxx
@@ -42,7 +42,7 @@
#endif
-#include <vcl/wintypes.hxx>
+#include <tools/wintypes.hxx>
#include "commonpicker.hxx"
#include "pickercallbacks.hxx"
diff --git a/framework/inc/pch/precompiled_framework.hxx b/framework/inc/pch/precompiled_framework.hxx
index 45919a31047b..b4afb017ebab 100644
--- a/framework/inc/pch/precompiled_framework.hxx
+++ b/framework/inc/pch/precompiled_framework.hxx
@@ -463,7 +463,7 @@
#include "vcl/keycod.hxx"
#include "vcl/keycodes.hxx"
#include "vcl/lstbox.hxx"
-#include "vcl/mapunit.hxx"
+#include "tools/mapunit.hxx"
#include "vcl/menu.hxx"
#include "vcl/mnemonic.hxx"
#include "vcl/morebtn.hxx"
@@ -482,7 +482,7 @@
#include "vcl/timer.hxx"
#include "vcl/wall.hxx"
#include "vcl/window.hxx"
-#include "vcl/wintypes.hxx"
+#include "tools/wintypes.hxx"
#include "vos/mutex.hxx"
#include "vos/process.hxx"
diff --git a/framework/inc/services/layoutmanager.hxx b/framework/inc/services/layoutmanager.hxx
index 0110a0b40b9e..e6a638c654e9 100644
--- a/framework/inc/services/layoutmanager.hxx
+++ b/framework/inc/services/layoutmanager.hxx
@@ -85,7 +85,7 @@
#include <cppuhelper/implbase8.hxx>
#include <cppuhelper/interfacecontainer.hxx>
#include <comphelper/propertycontainer.hxx>
-#include <vcl/wintypes.hxx>
+#include <tools/wintypes.hxx>
#include <svtools/miscopt.hxx>
#include <vcl/toolbox.hxx>
#include <vcl/timer.hxx>
diff --git a/framework/source/helper/tagwindowasmodified.cxx b/framework/source/helper/tagwindowasmodified.cxx
index a71c5263455b..67c047dfefd4 100644
--- a/framework/source/helper/tagwindowasmodified.cxx
+++ b/framework/source/helper/tagwindowasmodified.cxx
@@ -61,7 +61,7 @@
#include <vcl/syswin.hxx>
#include <vcl/svapp.hxx>
#include <vcl/wrkwin.hxx>
-#include <vcl/wintypes.hxx>
+#include <tools/wintypes.hxx>
//_________________________________________________________________________________________________________________
// namespace
diff --git a/framework/source/uielement/fontsizemenucontroller.cxx b/framework/source/uielement/fontsizemenucontroller.cxx
index 58cf3a3b02be..0b1a0d003133 100644
--- a/framework/source/uielement/fontsizemenucontroller.cxx
+++ b/framework/source/uielement/fontsizemenucontroller.cxx
@@ -51,7 +51,7 @@
#ifndef _VCL_MENU_HXX_
#include <vcl/menu.hxx>
#endif
-#include <vcl/mapunit.hxx>
+#include <tools/mapunit.hxx>
#ifndef _VCL_SVAPP_HXX_
#include <vcl/svapp.hxx>
#endif
diff --git a/officecfg/registry/schema/org/openoffice/Office/Common.xcs b/officecfg/registry/schema/org/openoffice/Office/Common.xcs
index 9bc07c592f0f..ae171230dd13 100644
--- a/officecfg/registry/schema/org/openoffice/Office/Common.xcs
+++ b/officecfg/registry/schema/org/openoffice/Office/Common.xcs
@@ -2600,39 +2600,6 @@
</constraints>
<value>100</value>
</prop>
- <prop oor:name="LookAndFeel" oor:type="xs:short">
- <!-- OldPath: General/View -->
- <!-- OldLocation: soffice.cfg -->
- <!-- UIHints: Tools Options - General View [Section] Display -->
- <info>
- <author>PB</author>
- <desc>Determines the look and feel of the application.</desc>
- <label>Look &amp; Feel</label>
- </info>
- <constraints>
- <enumeration oor:value="0">
- <info>
- <desc>Standard</desc>
- </info>
- </enumeration>
- <enumeration oor:value="1">
- <info>
- <desc>Macintosh</desc>
- </info>
- </enumeration>
- <enumeration oor:value="2">
- <info>
- <desc>X Window</desc>
- </info>
- </enumeration>
- <enumeration oor:value="3">
- <info>
- <desc>OS/2</desc>
- </info>
- </enumeration>
- </constraints>
- <value>0</value>
- </prop>
<group oor:name="NewDocumentHandling">
<info>
<author>CD</author>
@@ -2714,17 +2681,6 @@
</info>
<value>true</value>
</prop>
- <prop oor:name="ColoredTab" oor:type="xs:boolean">
- <!-- OldPath: General/View -->
- <!-- OldLocation: soffice.cfg -->
- <!-- UIHints: Tools Options - General View [Section] Options -->
- <info>
- <author>PB</author>
- <desc>Specifies TabDialogs with colored tab control (True)</desc>
- <label>Colored tab controls</label>
- </info>
- <value>false</value>
- </prop>
<prop oor:name="MousePositioning" oor:type="xs:short">
<!-- OldPath: General/View -->
<!-- OldLocation: soffice.cfg -->
@@ -2780,17 +2736,6 @@
</constraints>
<value>1</value>
</prop>
- <prop oor:name="SingleLineTab" oor:type="xs:boolean">
- <!-- OldPath: General/View -->
- <!-- OldLocation: soffice.cfg -->
- <!-- UIHints: Tools Options - General View [Section] Options -->
- <info>
- <author>PB</author>
- <desc>Specifies TabDialogs with single line tab control (True).</desc>
- <label>Single line tab controls</label>
- </info>
- <value>false</value>
- </prop>
</group>
<group oor:name="Localisation">
<info>
diff --git a/sfx2/inc/pch/precompiled_sfx2.hxx b/sfx2/inc/pch/precompiled_sfx2.hxx
index 1d4003fa44e6..45755cdd8799 100644
--- a/sfx2/inc/pch/precompiled_sfx2.hxx
+++ b/sfx2/inc/pch/precompiled_sfx2.hxx
@@ -654,7 +654,7 @@
#include "vcl/stdtext.hxx"
#include "vcl/timer.hxx"
#include "vcl/unohelp.hxx"
-#include "vcl/wintypes.hxx"
+#include "tools/wintypes.hxx"
#include "vos/diagnose.hxx"
#include "vos/module.hxx"
#include "vos/mutex.hxx"
diff --git a/sfx2/inc/sfx2/event.hxx b/sfx2/inc/sfx2/event.hxx
index b9beb12bfeff..9b144b3c20b6 100644
--- a/sfx2/inc/sfx2/event.hxx
+++ b/sfx2/inc/sfx2/event.hxx
@@ -119,7 +119,6 @@ public:
SfxObjectShell* GetObjShell() const { return _pObjShell; }
};
-class PrintDialog;
class Printer;
class SfxPrintingHint : public SfxHint
{
diff --git a/sfx2/inc/sfx2/mnumgr.hxx b/sfx2/inc/sfx2/mnumgr.hxx
index f1df0f0aa547..f5cc509dbf0a 100644
--- a/sfx2/inc/sfx2/mnumgr.hxx
+++ b/sfx2/inc/sfx2/mnumgr.hxx
@@ -32,7 +32,7 @@
#ifndef _MENU_HXX //autogen //wg. MENU_APPEND !!!!
#include <vcl/menu.hxx>
#endif
-#include <vcl/wintypes.hxx>
+#include <tools/wintypes.hxx>
#include <tools/link.hxx>
#include <com/sun/star/embed/VerbDescriptor.hpp>
#include <com/sun/star/uno/Sequence.hxx>
diff --git a/sfx2/inc/sfx2/module.hxx b/sfx2/inc/sfx2/module.hxx
index ad83bb4a7418..3cf84cf6139e 100644
--- a/sfx2/inc/sfx2/module.hxx
+++ b/sfx2/inc/sfx2/module.hxx
@@ -33,7 +33,7 @@
#include <sfx2/shell.hxx>
#include <sfx2/imgdef.hxx>
#include <sal/types.h>
-#include <vcl/fldunit.hxx>
+#include <tools/fldunit.hxx>
class ImageList;
diff --git a/sfx2/inc/sfx2/printer.hxx b/sfx2/inc/sfx2/printer.hxx
index a96033835a84..11f07ea9e7db 100644
--- a/sfx2/inc/sfx2/printer.hxx
+++ b/sfx2/inc/sfx2/printer.hxx
@@ -34,60 +34,11 @@
#include <vcl/print.hxx>
#endif
-class SfxFont;
class SfxTabPage;
class SfxItemSet;
struct SfxPrinter_Impl;
-#define SFX_RANGE_NOTSET ((USHORT)0xFFFF)
-
-// class SfxFontSizeInfo -------------------------------------------------
-
-class SfxFontSizeInfo
-{
-private:
- static USHORT pStaticSizes[];
- Size* pSizes;
- USHORT nSizes;
- BOOL bScalable;
-
-public:
- SfxFontSizeInfo( const SfxFont& rFont, const OutputDevice& rDevice );
- ~SfxFontSizeInfo();
-
- BOOL HasSize(const Size &rSize) const;
- BOOL IsScalable() const { return bScalable; }
-
- USHORT SizeCount() const { return nSizes; }
- const Size& GetSize( USHORT nNo ) const
- { return pSizes[nNo]; }
-};
-
-// class SfxFont ---------------------------------------------------------
-
-class SFX2_DLLPUBLIC SfxFont
-{
-private:
- String aName;
- FontFamily eFamily;
- FontPitch ePitch;
- CharSet eCharSet;
-
- SfxFont& operator=(const SfxFont& rFont); // not implemented
-
-public:
- SfxFont( const FontFamily eFam,
- const String& aName,
- const FontPitch eFontPitch = PITCH_DONTKNOW,
- const CharSet eFontCharSet = RTL_TEXTENCODING_DONTKNOW );
- // ZugriffsMethoden:
- inline const String& GetName() const { return aName; }
- inline FontFamily GetFamily() const { return eFamily; }
- inline FontPitch GetPitch() const { return ePitch; }
- inline CharSet GetCharSet() const { return eCharSet; }
-};
-
// class SfxPrinter ------------------------------------------------------
class SFX2_DLLPUBLIC SfxPrinter : public Printer
@@ -125,19 +76,8 @@ public:
const SfxItemSet& GetOptions() const { return *pOptions; }
void SetOptions( const SfxItemSet &rNewOptions );
- void EnableRange( USHORT nRange );
- void DisableRange( USHORT nRange );
- BOOL IsRangeEnabled( USHORT nRange ) const;
-
BOOL IsKnown() const { return bKnown; }
BOOL IsOriginal() const { return bKnown; }
-
- using OutputDevice::GetFont;
- USHORT GetFontCount();
- const SfxFont* GetFont( USHORT nNo ) const;
- const SfxFont* GetFontByName( const String &rFontName );
-
- BOOL InitJob( Window* pUIParent, BOOL bAskAboutTransparentObjects );
};
#endif
diff --git a/sfx2/inc/sfx2/viewsh.hxx b/sfx2/inc/sfx2/viewsh.hxx
index b58a9e7bdf73..70e7b08319e5 100644
--- a/sfx2/inc/sfx2/viewsh.hxx
+++ b/sfx2/inc/sfx2/viewsh.hxx
@@ -59,7 +59,6 @@ class SfxItemPool;
class SfxTabPage;
class SfxPrintMonitor;
class SfxFrameSetDescriptor;
-class PrintDialog;
class Printer;
class SfxPrinter;
class SfxProgress;
@@ -239,13 +238,9 @@ public:
void AdjustVisArea(const Rectangle& rRect);
// Printing Interface
- virtual void PreparePrint( PrintDialog *pPrintDialog = 0 );
- virtual ErrCode DoPrint( SfxPrinter *pPrinter, PrintDialog *pPrintDialog, BOOL bSilent, BOOL bIsAPI );
- virtual USHORT Print( SfxProgress &rProgress, BOOL bIsAPI, PrintDialog *pPrintDialog = 0 );
virtual SfxPrinter* GetPrinter( BOOL bCreate = FALSE );
virtual USHORT SetPrinter( SfxPrinter *pNewPrinter, USHORT nDiffFlags = SFX_PRINTER_ALL, bool bIsAPI=FALSE );
virtual SfxTabPage* CreatePrintOptionsPage( Window *pParent, const SfxItemSet &rOptions );
- virtual PrintDialog* CreatePrintDialog( Window *pParent );
void LockPrinter( BOOL bLock = TRUE );
BOOL IsPrinterLocked() const;
virtual JobSetup GetJobSetup() const;
diff --git a/sfx2/source/appl/appmain.cxx b/sfx2/source/appl/appmain.cxx
index 546b6b1c6558..1bde50fec224 100644
--- a/sfx2/source/appl/appmain.cxx
+++ b/sfx2/source/appl/appmain.cxx
@@ -116,21 +116,6 @@ void SfxApplication::Init
<SfxApplication::OpenClients()>
*/
{
-#ifdef DDE_AVAILABLE
-#ifndef DBG_UTIL
- InitializeDde();
-#else
- if( !InitializeDde() )
- {
- ByteString aStr( "Kein DDE-Service moeglich. Fehler: " );
- if( GetDdeService() )
- aStr += GetDdeService()->GetError();
- else
- aStr += '?';
- DBG_ASSERT( sal_False, aStr.GetBuffer() )
- }
-#endif
-#endif
}
//--------------------------------------------------------------------
diff --git a/sfx2/source/doc/printhelper.cxx b/sfx2/source/doc/printhelper.cxx
index 2cd195976832..1dc2423bcdaf 100755
--- a/sfx2/source/doc/printhelper.cxx
+++ b/sfx2/source/doc/printhelper.cxx
@@ -53,7 +53,6 @@
#include <ucbhelper/content.hxx>
#include <cppuhelper/interfacecontainer.hxx>
#include <vos/mutex.hxx>
-#include <svtools/printdlg.hxx>
#include <cppuhelper/implbase1.hxx>
#include <sfx2/viewfrm.hxx>
@@ -799,81 +798,8 @@ void IMPL_PrintListener_DataContainer::Notify( SfxBroadcaster& rBC, const SfxHin
{
if ( !m_xPrintJob.is() )
m_xPrintJob = new SfxPrintJob_Impl( this );
-/*
- PrintDialog* pDlg = pPrintHint->GetPrintDialog();
- Printer* pPrinter = pPrintHint->GetPrinter();
- ::rtl::OUString aPrintFile ( ( pPrinter && pPrinter->IsPrintFileEnabled() ) ? pPrinter->GetPrintFile() : String() );
- ::rtl::OUString aRangeText ( ( pDlg && pDlg->IsRangeChecked(PRINTDIALOG_RANGE) ) ? pDlg->GetRangeText() : String() );
- sal_Bool bSelectionOnly = ( ( pDlg && pDlg->IsRangeChecked(PRINTDIALOG_SELECTION) ) ? sal_True : sal_False );
-
- sal_Int32 nArgs = 2;
- if ( aPrintFile.getLength() )
- nArgs++;
- if ( aRangeText.getLength() )
- nArgs++;
- else if ( bSelectionOnly )
- nArgs++;
-
- m_aPrintOptions.realloc(nArgs);
- m_aPrintOptions[0].Name = DEFINE_CONST_UNICODE("CopyCount");
- m_aPrintOptions[0].Value <<= (sal_Int16) (pPrinter ? pPrinter->GetCopyCount() : 1 );
- m_aPrintOptions[1].Name = DEFINE_CONST_UNICODE("Collate");
- m_aPrintOptions[1].Value <<= (sal_Bool) (pDlg ? pDlg->IsCollateChecked() : sal_False );
-
- if ( bSelectionOnly )
- {
- m_aPrintOptions[2].Name = DEFINE_CONST_UNICODE("Selection");
- m_aPrintOptions[2].Value <<= bSelectionOnly;
- }
- else if ( aRangeText.getLength() )
- {
- m_aPrintOptions[2].Name = DEFINE_CONST_UNICODE("Pages");
- m_aPrintOptions[2].Value <<= aRangeText;
- }
-
- if ( aPrintFile.getLength() )
- {
- m_aPrintOptions[nArgs-1].Name = DEFINE_CONST_UNICODE("FileName");
- m_aPrintOptions[nArgs-1].Value <<= aPrintFile;
- }
-*/
m_aPrintOptions = pPrintHint->GetOptions();
}
-/*
- else if ( pPrintHint->GetWhich() == -3 ) // -3 : AdditionalPrintOptions
- {
- uno::Sequence < beans::PropertyValue >& lOldOpts = m_aPrintOptions;
- const uno::Sequence < beans::PropertyValue >& lNewOpts = pPrintHint->GetAdditionalOptions();
- sal_Int32 nOld = lOldOpts.getLength();
- sal_Int32 nAdd = lNewOpts.getLength();
- lOldOpts.realloc( nOld + nAdd );
-
- // assume that all new elements are overwriting old ones and so don't need to be added
- sal_Int32 nTotal = nOld;
- for ( sal_Int32 n=0; n<nAdd; n++ )
- {
- sal_Int32 m;
- for ( m=0; m<nOld; m++ )
- if ( lNewOpts[n].Name == lOldOpts[m].Name )
- // new option overwrites old one
- break;
-
- if ( m == nOld )
- {
- // this is a new option, so add it to the resulting sequence - counter must be incremented
- lOldOpts[nTotal].Name = lNewOpts[n].Name;
- lOldOpts[nTotal++].Value = lNewOpts[n].Value;
- }
- else
- // overwrite old option with new value, counter stays unmodified
- lOldOpts[m].Value = lNewOpts[n].Value;
- }
-
- if ( nTotal != lOldOpts.getLength() )
- // at least one new options has overwritten an old one, so we allocated too much
- lOldOpts.realloc( nTotal );
- }
-*/
else if ( pPrintHint->GetWhich() != -2 ) // -2 : CancelPrintJob
{
view::PrintJobEvent aEvent;
diff --git a/sfx2/source/view/printer.cxx b/sfx2/source/view/printer.cxx
index 310c1a58a578..64bebccd60fd 100644
--- a/sfx2/source/view/printer.cxx
+++ b/sfx2/source/view/printer.cxx
@@ -30,7 +30,6 @@
#include <vcl/virdev.hxx>
#include <vcl/metric.hxx>
#include <vcl/msgbox.hxx>
-#include <svtools/printdlg.hxx>
#include <unotools/printwarningoptions.hxx>
#include <svtools/printoptions.hxx>
#include <vector>
@@ -47,54 +46,23 @@
#include "sfx2/sfxresid.hxx"
#include "view.hrc"
-#ifdef MSC
-// der ist buggy
-#define NEW_OBJECTS(Class, nCount) ((Class*) new char[ sizeof(Class) * (nCount) ])
-#else
-#define NEW_OBJECTS(Class, nCount) (new Class[nCount])
-#endif
-
-
-USHORT SfxFontSizeInfo::pStaticSizes[] =
-{
- 60,
- 80,
- 100,
- 120,
- 140,
- 180,
- 240,
- 360,
- 480,
- 600,
- 720
-};
-
-//--------------------------------------------------------------------
-
-SV_DECL_PTRARR_DEL(SfxFontArr_Impl,SfxFont*,10,5)
-
// struct SfxPrinter_Impl ------------------------------------------------
struct SfxPrinter_Impl
{
- SfxFontArr_Impl* mpFonts;
BOOL mbAll;
BOOL mbSelection;
BOOL mbFromTo;
BOOL mbRange;
SfxPrinter_Impl() :
- mpFonts ( NULL ),
mbAll ( TRUE ),
mbSelection ( TRUE ),
mbFromTo ( TRUE ),
mbRange ( TRUE ) {}
- ~SfxPrinter_Impl() { delete mpFonts; }
+ ~SfxPrinter_Impl() {}
};
-#define FONTS() pImpl->mpFonts
-
struct SfxPrintOptDlg_Impl
{
sal_Bool mbHelpDisabled;
@@ -103,98 +71,6 @@ struct SfxPrintOptDlg_Impl
mbHelpDisabled ( sal_False ) {}
};
-//--------------------------------------------------------------------
-
-SfxFontSizeInfo::SfxFontSizeInfo( const SfxFont &rFont,
- const OutputDevice &rDevice ) :
-
- pSizes(0),
- nSizes(0),
- bScalable(TRUE)
-
-{
- if ( 0 == rDevice.GetDevFontCount() )
- bScalable = FALSE;
- else
- {
- OutputDevice &rDev = (OutputDevice&) rDevice;
- Font aFont(rFont.GetName(), Size(0,12));
- aFont.SetFamily(rFont.GetFamily());
- aFont.SetPitch(rFont.GetPitch());
- aFont.SetCharSet(rFont.GetCharSet());
-
- // verfuegbare Groessen in die Liste eintragen, Groesse in 10tel Punkt
- int nSizeCount = rDev.GetDevFontSizeCount(aFont);
- pSizes = NEW_OBJECTS(Size, nSizeCount);
- const MapMode aOldMapMode = rDev.GetMapMode();
- MapMode aMap(aOldMapMode);
- aMap.SetMapUnit(MAP_POINT);
- const Fraction aTen(1, 10);
- aMap.SetScaleX(aTen);
- aMap.SetScaleY(aTen);
- rDev.SetMapMode(aMap);
-
- // Es gibt Fonts mit Bitmaps und skalierbaren Groessen
- // In diesem Fall wird der Fonts als skalierbar behandelt.
- BOOL bFoundScalable = FALSE;
- for ( int i = 0; i < nSizeCount; ++i )
- {
- const Size aSize( rDev.GetDevFontSize(aFont, i) );
- if ( aSize.Height() != 0 )
- pSizes[nSizes++] = aSize;
- else
- bFoundScalable |= TRUE;
- }
- if( !bFoundScalable )
- bScalable = FALSE;
- else
- {
- // statische Font-Sizes verwenden
- delete [] pSizes;
- nSizes = 0;
- }
- rDev.SetMapMode(aOldMapMode);
- }
-
- if ( 0 == nSizes )
- {
- nSizes = sizeof(pStaticSizes) / sizeof(USHORT);
- pSizes = NEW_OBJECTS(Size, nSizes);
- for ( USHORT nPos = 0; nPos <nSizes; ++nPos )
- pSizes[nPos] = Size( 0, pStaticSizes[nPos] );
- }
-}
-
-//--------------------------------------------------------------------
-
-SfxFontSizeInfo::~SfxFontSizeInfo()
-{
- delete [] pSizes;
-}
-
-//--------------------------------------------------------------------
-
-BOOL SfxFontSizeInfo::HasSize(const Size &rSize) const
-{
- if ( bScalable )
- return TRUE;
- for ( USHORT i = 0; i < nSizes; ++i)
- if ( pSizes[i] == rSize )
- return TRUE;
- return FALSE;
-}
-
-//--------------------------------------------------------------------
-
-SfxFont::SfxFont( const FontFamily eFontFamily, const String& aFontName,
- const FontPitch eFontPitch, const CharSet eFontCharSet ):
- aName( aFontName ),
- eFamily( eFontFamily ),
- ePitch( eFontPitch ),
- eCharSet( eFontCharSet )
-{
-}
-
// class SfxPrinter ------------------------------------------------------
SfxPrinter* SfxPrinter::Create( SvStream& rStream, SfxItemSet* pOptions )
@@ -335,194 +211,6 @@ void SfxPrinter::SetOptions( const SfxItemSet &rNewOptions )
//--------------------------------------------------------------------
-void SfxPrinter::EnableRange( USHORT nRange )
-{
- PrintDialogRange eRange = (PrintDialogRange)nRange;
-
- if ( eRange == PRINTDIALOG_ALL )
- pImpl->mbAll = TRUE;
- else if ( eRange == PRINTDIALOG_SELECTION )
- pImpl->mbSelection = TRUE;
- else if ( eRange == PRINTDIALOG_FROMTO )
- pImpl->mbFromTo = TRUE;
- else if ( eRange == PRINTDIALOG_RANGE )
- pImpl->mbRange = TRUE;
-}
-
-//--------------------------------------------------------------------
-
-void SfxPrinter::DisableRange( USHORT nRange )
-{
- PrintDialogRange eRange = (PrintDialogRange)nRange;
-
- if ( eRange == PRINTDIALOG_ALL )
- pImpl->mbAll = FALSE;
- else if ( eRange == PRINTDIALOG_SELECTION )
- pImpl->mbSelection = FALSE;
- else if ( eRange == PRINTDIALOG_FROMTO )
- pImpl->mbFromTo = FALSE;
- else if ( eRange == PRINTDIALOG_RANGE )
- pImpl->mbRange = FALSE;
-}
-
-//--------------------------------------------------------------------
-
-BOOL SfxPrinter::IsRangeEnabled( USHORT nRange ) const
-{
- PrintDialogRange eRange = (PrintDialogRange)nRange;
- BOOL bRet = FALSE;
-
- if ( eRange == PRINTDIALOG_ALL )
- bRet = pImpl->mbAll;
- else if ( eRange == PRINTDIALOG_SELECTION )
- bRet = pImpl->mbSelection;
- else if ( eRange == PRINTDIALOG_FROMTO )
- bRet = pImpl->mbFromTo;
- else if ( eRange == PRINTDIALOG_RANGE )
- bRet = pImpl->mbRange;
-
- return bRet;
-}
-
-//--------------------------------------------------------------------
-
-SV_IMPL_PTRARR(SfxFontArr_Impl,SfxFont*)
-
-//--------------------------------------------------------------------
-
-const SfxFont* SfxFindFont_Impl( const SfxFontArr_Impl& rArr,
- const String& rName )
-{
- const USHORT nCount = rArr.Count();
- for ( USHORT i = 0; i < nCount; ++i )
- {
- const SfxFont *pFont = rArr[i];
- if ( pFont->GetName() == rName )
- return pFont;
- }
- return NULL;
-}
-
-//--------------------------------------------------------------------
-
-void SfxPrinter::UpdateFonts_Impl()
-{
- VirtualDevice *pVirDev = 0;
- const OutputDevice *pOut = this;
-
- // falls kein Drucker gefunden werden konnte, ein
- // temp. Device erzeugen fuer das Erfragen der Fonts
- if( !IsValid() )
- pOut = pVirDev = new VirtualDevice;
-
- int nCount = pOut->GetDevFontCount();
- FONTS() = new SfxFontArr_Impl((BYTE)nCount);
-
- std::vector< Font > aNonRegularFonts;
- for(int i = 0;i < nCount;++i)
- {
- Font aFont(pOut->GetDevFont(i));
- if ( (aFont.GetItalic() != ITALIC_NONE) ||
- (aFont.GetWeight() != WEIGHT_MEDIUM) )
- {
- // First: Don't add non-regular fonts. The font name is not unique so we have
- // to filter the device font list.
- aNonRegularFonts.push_back( aFont );
- }
- else if ( FONTS()->Count() == 0 ||
- (*FONTS())[FONTS()->Count()-1]->GetName() != aFont.GetName() )
- {
- DBG_ASSERT(0 == SfxFindFont_Impl(*FONTS(), aFont.GetName()), "Doppelte Fonts vom SV-Device!");
- SfxFont* pTmp = new SfxFont( aFont.GetFamily(), aFont.GetName(),
- aFont.GetPitch(), aFont.GetCharSet() );
- FONTS()->C40_INSERT(SfxFont, pTmp, FONTS()->Count());
- }
- }
- delete pVirDev;
-
- // Try to add all non-regular fonts. It could be that there was no regular font
- // with the same name added.
- std::vector< Font >::const_iterator pIter;
- for ( pIter = aNonRegularFonts.begin(); pIter != aNonRegularFonts.end(); pIter++ )
- {
- if ( SfxFindFont_Impl( *FONTS(), pIter->GetName() ) == 0 )
- {
- SfxFont* pTmp = new SfxFont( pIter->GetFamily(), pIter->GetName(),
- pIter->GetPitch(), pIter->GetCharSet() );
- FONTS()->C40_INSERT( SfxFont, pTmp, FONTS()->Count() );
- }
- }
-}
-
-//--------------------------------------------------------------------
-
-USHORT SfxPrinter::GetFontCount()
-{
- if ( !FONTS() )
- UpdateFonts_Impl();
- return FONTS()->Count();
-}
-
-//--------------------------------------------------------------------
-
-const SfxFont* SfxPrinter::GetFont( USHORT nNo ) const
-{
- DBG_ASSERT( FONTS(), "bitte erst GetFontCount() abfragen!" );
- return (*FONTS())[ nNo ];
-}
-
-//--------------------------------------------------------------------
-
-const SfxFont* SfxPrinter::GetFontByName( const String &rFontName )
-{
- if ( !FONTS() )
- UpdateFonts_Impl();
- return SfxFindFont_Impl(*FONTS(), rFontName);
-}
-
-//--------------------------------------------------------------------
-
-BOOL SfxPrinter::InitJob( Window* pUIParent, BOOL bAskAboutTransparentObjects )
-{
- const SvtPrinterOptions aPrinterOpt;
- const SvtPrintFileOptions aPrintFileOpt;
- const SvtBasePrintOptions* pPrinterOpt = &aPrinterOpt;
- const SvtBasePrintOptions* pPrintFileOpt = &aPrintFileOpt;
- PrinterOptions aNewPrinterOptions;
- BOOL bRet = TRUE;
-
- ( ( IsPrintFileEnabled() && GetPrintFile().Len() ) ? pPrintFileOpt : pPrinterOpt )->GetPrinterOptions( aNewPrinterOptions );
-
- if( bAskAboutTransparentObjects && !aNewPrinterOptions.IsReduceTransparency() )
- {
- if ( !Application::IsHeadlessModeEnabled() )
- {
- SvtPrintWarningOptions aWarnOpt;
-
- if( aWarnOpt.IsTransparency() )
- {
- TransparencyPrintWarningBox aWarnBox( pUIParent );
- const USHORT nRet = aWarnBox.Execute();
-
- if( nRet == RET_CANCEL )
- bRet = FALSE;
- else
- {
- aNewPrinterOptions.SetReduceTransparency( nRet != RET_NO );
- aWarnOpt.SetTransparency( !aWarnBox.IsNoWarningChecked() );
- }
- }
- }
- }
-
- if( bRet )
- SetPrinterOptions( aNewPrinterOptions );
-
- return bRet;
-}
-
-//--------------------------------------------------------------------
-
SfxPrintOptionsDialog::SfxPrintOptionsDialog( Window *pParent,
SfxViewShell *pViewShell,
const SfxItemSet *pSet ) :
diff --git a/sfx2/source/view/viewprn.cxx b/sfx2/source/view/viewprn.cxx
index 4ef4244f28e6..24ed85556466 100644
--- a/sfx2/source/view/viewprn.cxx
+++ b/sfx2/source/view/viewprn.cxx
@@ -34,7 +34,6 @@
#include <svl/itempool.hxx>
#include <vcl/msgbox.hxx>
-#include <svtools/printdlg.hxx>
#include <svtools/prnsetup.hxx>
#include <svl/flagitem.hxx>
#include <svl/stritem.hxx>
@@ -352,30 +351,6 @@ void SfxPrinterController::jobFinished( com::sun::star::view::PrintableState nSt
}
}
-// -----------------------------------------------------------------------
-
-void DisableRanges( PrintDialog& rDlg, SfxPrinter* pPrinter )
-
-/* [Beschreibung]
-
- Mit dieser Funktion werden die nicht verf"ugbaren Ranges
- vom Printer zum PrintDialog geforwarded.
-*/
-
-{
- if ( !pPrinter )
- return;
-
- if ( !pPrinter->IsRangeEnabled( PRINTDIALOG_ALL ) )
- rDlg.DisableRange( PRINTDIALOG_ALL );
- if ( !pPrinter->IsRangeEnabled( PRINTDIALOG_SELECTION ) )
- rDlg.DisableRange( PRINTDIALOG_SELECTION );
- if ( !pPrinter->IsRangeEnabled( PRINTDIALOG_FROMTO ) )
- rDlg.DisableRange( PRINTDIALOG_FROMTO );
- if ( !pPrinter->IsRangeEnabled( PRINTDIALOG_RANGE ) )
- rDlg.DisableRange( PRINTDIALOG_RANGE );
-}
-
//====================================================================
class SfxDialogExecutor_Impl
@@ -392,7 +367,6 @@ class SfxDialogExecutor_Impl
{
private:
SfxViewShell* _pViewSh;
- PrintDialog* _pPrintParent;
PrinterSetupDialog* _pSetupParent;
SfxItemSet* _pOptions;
sal_Bool _bModified;
@@ -401,7 +375,6 @@ private:
DECL_LINK( Execute, void * );
public:
- SfxDialogExecutor_Impl( SfxViewShell* pViewSh, PrintDialog* pParent );
SfxDialogExecutor_Impl( SfxViewShell* pViewSh, PrinterSetupDialog* pParent );
~SfxDialogExecutor_Impl() { delete _pOptions; }
@@ -412,22 +385,9 @@ public:
//--------------------------------------------------------------------
-SfxDialogExecutor_Impl::SfxDialogExecutor_Impl( SfxViewShell* pViewSh, PrintDialog* pParent ) :
-
- _pViewSh ( pViewSh ),
- _pPrintParent ( pParent ),
- _pSetupParent ( NULL ),
- _pOptions ( NULL ),
- _bModified ( sal_False ),
- _bHelpDisabled ( sal_False )
-
-{
-}
-
SfxDialogExecutor_Impl::SfxDialogExecutor_Impl( SfxViewShell* pViewSh, PrinterSetupDialog* pParent ) :
_pViewSh ( pViewSh ),
- _pPrintParent ( NULL ),
_pSetupParent ( pParent ),
_pOptions ( NULL ),
_bModified ( sal_False ),
@@ -443,27 +403,13 @@ IMPL_LINK( SfxDialogExecutor_Impl, Execute, void *, EMPTYARG )
// Options lokal merken
if ( !_pOptions )
{
- DBG_ASSERT( _pPrintParent || _pSetupParent, "no dialog parent" );
- if( _pPrintParent )
- _pOptions = ( (SfxPrinter*)_pPrintParent->GetPrinter() )->GetOptions().Clone();
- else if( _pSetupParent )
+ DBG_ASSERT( _pSetupParent, "no dialog parent" );
+ if( _pSetupParent )
_pOptions = ( (SfxPrinter*)_pSetupParent->GetPrinter() )->GetOptions().Clone();
}
- if ( _pOptions && _pPrintParent && _pPrintParent->IsSheetRangeAvailable() )
- {
- SfxItemState eState = _pOptions->GetItemState( SID_PRINT_SELECTEDSHEET );
- if ( eState != SFX_ITEM_UNKNOWN )
- {
- PrintSheetRange eRange = _pPrintParent->GetCheckedSheetRange();
- BOOL bValue = ( PRINTSHEETS_ALL != eRange );
- _pOptions->Put( SfxBoolItem( SID_PRINT_SELECTEDSHEET, bValue ) );
- }
- }
-
// Dialog ausf"uhren
- SfxPrintOptionsDialog* pDlg = new SfxPrintOptionsDialog( _pPrintParent ? static_cast<Window*>(_pPrintParent)
- : static_cast<Window*>(_pSetupParent),
+ SfxPrintOptionsDialog* pDlg = new SfxPrintOptionsDialog( static_cast<Window*>(_pSetupParent),
_pViewSh, _pOptions );
if ( _bHelpDisabled )
pDlg->DisableHelp();
@@ -472,15 +418,6 @@ IMPL_LINK( SfxDialogExecutor_Impl, Execute, void *, EMPTYARG )
delete _pOptions;
_pOptions = pDlg->GetOptions().Clone();
- if ( _pOptions && _pPrintParent && _pPrintParent->IsSheetRangeAvailable() )
- {
- const SfxPoolItem* pItem;
- if ( SFX_ITEM_SET == _pOptions->GetItemState( SID_PRINT_SELECTEDSHEET, FALSE , &pItem ) )
- {
- _pPrintParent->CheckSheetRange( ( (const SfxBoolItem*)pItem )->GetValue()
- ? PRINTSHEETS_SELECTED_SHEETS : PRINTSHEETS_ALL );
- }
- }
}
delete pDlg;
@@ -687,7 +624,6 @@ void SfxViewShell::ExecPrint_Impl( SfxRequest &rReq )
USHORT nDialogRet = RET_CANCEL;
// BOOL bCollate=FALSE;
SfxPrinter* pPrinter = 0;
- PrintDialog* pPrintDlg = 0;
SfxDialogExecutor_Impl* pExecutor = 0;
bool bSilent = false;
BOOL bIsAPI = rReq.GetArgs() && rReq.GetArgs()->Count();
@@ -895,16 +831,12 @@ void SfxViewShell::ExecPrint_Impl( SfxRequest &rReq )
// forget new printer, it was taken over (as pPrinter) or deleted
pDlgPrinter = NULL;
- /* Now lets reset the Dialog printer, since its freed */
- if (pPrintDlg)
- pPrintDlg->SetPrinter (pPrinter);
}
else
{
// PrinterDialog is used to transfer information on printing,
// so it will only be deleted here if dialog was cancelled
DELETEZ( pDlgPrinter );
- DELETEZ( pPrintDlg );
rReq.Ignore();
if ( SID_PRINTDOC == nId )
rReq.SetReturnValue(SfxBoolItem(0,FALSE));
@@ -923,80 +855,6 @@ void SfxViewShell::ExecPrint_Impl( SfxRequest &rReq )
//--------------------------------------------------------------------
-PrintDialog* SfxViewShell::CreatePrintDialog( Window* /*pParent*/ )
-
-/* [Beschreibung]
-
- Diese Methode kann "uberladen werden, um einen speziellen PrintDialog
- zu erzeugen. Dies ist z.B. notwendig wenn spezielle <StarView> Features
- wie drucken von Seitenbereichen.
-*/
-
-{
- #if 0
- PrintDialog *pDlg = new PrintDialog( pParent, false );
- pDlg->SetFirstPage( 1 );
- pDlg->SetLastPage( 9999 );
- pDlg->EnableCollate();
- return pDlg;
- #else
- return NULL;
- #endif
-}
-
-//--------------------------------------------------------------------
-
-void SfxViewShell::PreparePrint( PrintDialog * )
-{
-}
-
-//--------------------------------------------------------------------
-
-
-ErrCode SfxViewShell::DoPrint( SfxPrinter* /*pPrinter*/,
- PrintDialog* /*pPrintDlg*/,
- BOOL /*bSilent*/, BOOL /*bIsAPI*/ )
-{
- #if 0
- // Printer-Dialogbox waehrend des Ausdrucks mu\s schon vor
- // StartJob erzeugt werden, da SV bei einem Quit-Event h"angt
- SfxPrintProgress *pProgress = new SfxPrintProgress( this, !bSilent );
- SfxPrinter *pDocPrinter = GetPrinter(TRUE);
- if ( !pPrinter )
- pPrinter = pDocPrinter;
- else if ( pDocPrinter != pPrinter )
- {
- pProgress->RestoreOnEndPrint( pDocPrinter->Clone() );
- SetPrinter( pPrinter, SFX_PRINTER_PRINTER );
- }
- pProgress->SetWaitMode(FALSE);
-
- // Drucker starten
- PreparePrint( pPrintDlg );
- SfxObjectShell *pObjShell = GetViewFrame()->GetObjectShell();
- if ( pPrinter->StartJob(pObjShell->GetTitle(0)) )
- {
- // Drucken
- Print( *pProgress, bIsAPI, pPrintDlg );
- pProgress->Stop();
- pProgress->DeleteOnEndPrint();
- pPrinter->EndJob();
- }
- else
- {
- // Printer konnte nicht gestartet werden
- delete pProgress;
- }
-
- return pPrinter->GetError();
- #else
- DBG_ERROR( "DoPrint called, dead code !" );
- return ERRCODE_IO_NOTSUPPORTED;
- #endif
-}
-
-//--------------------------------------------------------------------
-
BOOL SfxViewShell::IsPrinterLocked() const
{
return pImp->m_nPrinterLocks > 0;
@@ -1026,13 +884,6 @@ void SfxViewShell::LockPrinter( BOOL bLock)
//--------------------------------------------------------------------
-USHORT SfxViewShell::Print( SfxProgress& /*rProgress*/, BOOL /*bIsAPI*/, PrintDialog* /*pDlg*/ )
-{
- return 0;
-}
-
-//--------------------------------------------------------------------
-
SfxPrinter* SfxViewShell::GetPrinter( BOOL /*bCreate*/ )
{
return 0;
diff --git a/svx/inc/pch/precompiled_svx.hxx b/svx/inc/pch/precompiled_svx.hxx
index 59d156f82018..f6c1a594fdd5 100644
--- a/svx/inc/pch/precompiled_svx.hxx
+++ b/svx/inc/pch/precompiled_svx.hxx
@@ -919,7 +919,7 @@
#include "vcl/cursor.hxx"
#include "vcl/decoview.hxx"
#include "vcl/dndhelp.hxx"
-#include "vcl/fldunit.hxx"
+#include "tools/fldunit.hxx"
#include "vcl/fntstyle.hxx"
#include "unotools/fontcvt.hxx"
#include "vcl/gdimtf.hxx"
@@ -938,7 +938,7 @@
#include "vcl/unohelp.hxx"
#include "vcl/unohelp2.hxx"
#include "vcl/wall.hxx"
-#include "vcl/wintypes.hxx"
+#include "tools/wintypes.hxx"
#include "vos/mutex.hxx"
#include "vos/ref.hxx"
#include "vos/refernce.hxx"
diff --git a/svx/inc/svx/fmgridif.hxx b/svx/inc/svx/fmgridif.hxx
index 886db3280d60..df21245bc99b 100644
--- a/svx/inc/svx/fmgridif.hxx
+++ b/svx/inc/svx/fmgridif.hxx
@@ -49,7 +49,7 @@
#include <com/sun/star/util/XModifyListener.hpp>
#include <com/sun/star/util/XModifyBroadcaster.hpp>
-#include <vcl/wintypes.hxx>
+#include <tools/wintypes.hxx>
#include <toolkit/controls/unocontrol.hxx>
#include <toolkit/awt/vclxwindow.hxx>
#include <comphelper/uno3.hxx>
diff --git a/svx/inc/svx/fmtools.hxx b/svx/inc/svx/fmtools.hxx
index b39f46e85d14..f98919fe47d8 100644
--- a/svx/inc/svx/fmtools.hxx
+++ b/svx/inc/svx/fmtools.hxx
@@ -71,7 +71,7 @@
#include <com/sun/star/util/XNumberFormatter.hpp>
#include <com/sun/star/util/XNumberFormats.hpp>
-#include <vcl/wintypes.hxx>
+#include <tools/wintypes.hxx>
#include <cppuhelper/weakref.hxx>
#include <comphelper/uno3.hxx>
#include <comphelper/stl_types.hxx>
diff --git a/svx/source/fmcomp/gridcell.cxx b/svx/source/fmcomp/gridcell.cxx
index 7fb9d8330cf6..7cdf707eb811 100644
--- a/svx/source/fmcomp/gridcell.cxx
+++ b/svx/source/fmcomp/gridcell.cxx
@@ -1653,11 +1653,14 @@ DbCheckBox::DbCheckBox( DbGridColumn& _rColumn )
namespace
{
- void setCheckBoxStyle( Window* _pWindow, USHORT nStyle )
+ void setCheckBoxStyle( Window* _pWindow, bool bMono )
{
AllSettings aSettings = _pWindow->GetSettings();
StyleSettings aStyleSettings = aSettings.GetStyleSettings();
- aStyleSettings.SetCheckBoxStyle( nStyle );
+ if( bMono )
+ aStyleSettings.SetOptions( aStyleSettings.GetOptions() | STYLE_OPTION_MONO );
+ else
+ aStyleSettings.SetOptions( aStyleSettings.GetOptions() & (~STYLE_OPTION_MONO) );
aSettings.SetStyleSettings( aStyleSettings );
_pWindow->SetSettings( aSettings );
}
@@ -1683,8 +1686,8 @@ void DbCheckBox::Init( Window& rParent, const Reference< XRowSet >& xCursor )
sal_Int16 nStyle = awt::VisualEffect::LOOK3D;
OSL_VERIFY( xModel->getPropertyValue( FM_PROP_VISUALEFFECT ) >>= nStyle );
- setCheckBoxStyle( m_pWindow, nStyle == awt::VisualEffect::FLAT ? STYLE_CHECKBOX_MONO : STYLE_CHECKBOX_WIN );
- setCheckBoxStyle( m_pPainter, nStyle == awt::VisualEffect::FLAT ? STYLE_CHECKBOX_MONO : STYLE_CHECKBOX_WIN );
+ setCheckBoxStyle( m_pWindow, nStyle == awt::VisualEffect::FLAT );
+ setCheckBoxStyle( m_pPainter, nStyle == awt::VisualEffect::FLAT );
sal_Bool bTristate = sal_True;
OSL_VERIFY( xModel->getPropertyValue( FM_PROP_TRISTATE ) >>= bTristate );
diff --git a/svx/source/gallery2/gallery1.cxx b/svx/source/gallery2/gallery1.cxx
index 32ad01aca4a2..9198f02278bb 100644
--- a/svx/source/gallery2/gallery1.cxx
+++ b/svx/source/gallery2/gallery1.cxx
@@ -626,7 +626,7 @@ BOOL Gallery::CreateTheme( const String& rThemeName, UINT32 nNumFrom )
if( !HasTheme( rThemeName ) && ( GetUserURL().GetProtocol() != INET_PROT_NOT_VALID ) )
{
- nLastFileNumber=nNumFrom > nLastFileNumber ? nNumFrom : ++nLastFileNumber;
+ nLastFileNumber = nNumFrom > nLastFileNumber ? nNumFrom : nLastFileNumber + 1;
GalleryThemeEntry* pNewEntry = new GalleryThemeEntry( GetUserURL(), rThemeName,
nLastFileNumber,
FALSE, FALSE, TRUE, 0, FALSE );
diff --git a/svx/source/unodraw/unoprov.cxx b/svx/source/unodraw/unoprov.cxx
index ffc6c28f9fec..6132139e0164 100644
--- a/svx/source/unodraw/unoprov.cxx
+++ b/svx/source/unodraw/unoprov.cxx
@@ -39,7 +39,7 @@
#include <com/sun/star/media/ZoomLevel.hpp>
#include <com/sun/star/io/XInputStream.hpp>
#include <com/sun/star/beans/PropertyAttribute.hpp>
-#include <vcl/fldunit.hxx>
+#include <tools/fldunit.hxx>
#include <tools/shl.hxx>
#include <vos/mutex.hxx>
#include <vcl/svapp.hxx>
diff --git a/uui/source/iahndl.hxx b/uui/source/iahndl.hxx
index 6402653d3bda..b0630a5514b2 100644..100755
--- a/uui/source/iahndl.hxx
+++ b/uui/source/iahndl.hxx
@@ -42,7 +42,7 @@
#include "tools/solar.h" // USHORT
#include "tools/errcode.hxx" // ErrCode
#include "tools/rc.hxx" // Resource
-#include "vcl/wintypes.hxx" // WinBits
+#include "tools/wintypes.hxx" // WinBits
namespace com { namespace sun { namespace star {
namespace awt {