summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Lohmaier <lohmaier+LibreOffice@googlemail.com>2015-10-01 15:05:43 +0200
committerChristian Lohmaier <lohmaier+LibreOffice@googlemail.com>2015-10-01 15:05:43 +0200
commitc0ba3b39b0856d92b47890f90eda8e5df63456ea (patch)
treefc852f3359229f037cb69cda0e0cd5a82e2589e5
parent72947311e997c7131a1aee7722999654c4c295c0 (diff)
Version 4.4.6.1, tag libreoffice-4.4.6.1 libreoffice-4.4.6.1
Change-Id: I6529d3a811c8aade8a519542536f15c6d6df55d8
0 files changed, 0 insertions, 0 deletions
'>feature/pyweb-wizard LibreOffice 核心代码仓库文档基金会
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRüdiger Timm <rt@openoffice.org>2008-12-09 08:43:20 +0000
committerRüdiger Timm <rt@openoffice.org>2008-12-09 08:43:20 +0000
commitb8db9514147779737d0db35c82a3b680b36e3f9f (patch)
treeccac9396d5368064c8a9e3dc32f81b6fd39cdf20
parent28bbe98abeef2ca37413405d3d94321353084390 (diff)
CWS-TOOLING: integrate CWS os2port04
2008-11-27 13:22:38 +0100 ydario r264480 : #i96439#: fix build for unix platforms. 2008-11-26 18:32:42 +0100 ydario r264433 : #i96439#: os2 systemshell code (dummy code). 2008-11-26 16:33:48 +0100 ydario r264421 : #i96439#: vcl fix for pdf export of truetype fonts. 2008-11-26 15:04:44 +0100 ydario r264399 : #i96439#: build macros fix scripts, gcc specific flags. 2008-11-26 15:00:15 +0100 ydario r264398 : #i96439#: vcl source code updates. 2008-11-26 13:21:37 +0100 ydario r264378 : #i96439#: os2 build system fixes. 2008-11-26 13:20:27 +0100 ydario r264377 : #i96439#: configuration and build macros updates. 2008-11-26 13:16:35 +0100 ydario r264375 : #i96439#: new launcher code, build system updates. 2008-11-26 13:12:49 +0100 ydario r264373 : #i96439#: use OSL endian macro. 2008-11-26 12:54:50 +0100 ydario r264371 : #i96439#: os2 build system fixes. 2008-11-26 12:30:46 +0100 ydario r264367 : #i96439#: os2 build system fixes. 2008-11-26 12:09:33 +0100 ydario r264365 : #i96439#: _Export is a reserved keyword under gcc for os2. 2008-11-26 12:08:12 +0100 ydario r264364 : #i96439#: new libpath handling. 2008-11-26 11:57:51 +0100 ydario r264363 : #i96439#: use C call, generates proper stabs; fix rtti names.
Diffstat
-rw-r--r--psprint/source/fontsubset/sft.c2
-rw-r--r--tools/source/fsys/os2.cxx4
-rw-r--r--transex3/source/gsicheck.cxx4
-rw-r--r--transex3/source/gsiconv.cxx2
-rw-r--r--transex3/source/helpex.cxx2
-rw-r--r--transex3/source/helpmerge.cxx8
-rw-r--r--transex3/source/lngex.cxx2
-rw-r--r--transex3/source/localize.cxx2
-rw-r--r--transex3/source/txtconv.cxx2
-rw-r--r--transex3/source/xgfconv.cxx2
-rw-r--r--transex3/source/xmlparse.cxx2
-rw-r--r--vcl/os2/inc/salframe.h1
-rw-r--r--vcl/os2/inc/salgdi.h25
-rw-r--r--vcl/os2/inc/salinst.h6
-rw-r--r--vcl/os2/inc/salobj.h1
-rw-r--r--vcl/os2/source/app/makefile.mk6
-rw-r--r--vcl/os2/source/app/salinst.cxx8
-rw-r--r--vcl/os2/source/app/sallang.cxx490
-rw-r--r--vcl/os2/source/app/salsound.cxx422
-rw-r--r--vcl/os2/source/app/salsys.cxx246
-rw-r--r--vcl/os2/source/gdi/os2layout.cxx12
-rw-r--r--vcl/os2/source/gdi/salgdi.cxx29
-rw-r--r--vcl/os2/source/gdi/salgdi3.cxx36
-rw-r--r--vcl/os2/source/window/salframe.cxx44
24 files changed, 241 insertions, 1117 deletions
diff --git a/psprint/source/fontsubset/sft.c b/psprint/source/fontsubset/sft.c
index cc63a7f3a897..c3a8ce377282 100644
--- a/psprint/source/fontsubset/sft.c
+++ b/psprint/source/fontsubset/sft.c
@@ -323,7 +323,7 @@ _inline void PutInt16(sal_Int16 val, sal_uInt8 *ptr, size_t offset, int bigendia
}
-#if defined(_BIG_ENDIAN)
+#if defined(OSL_BIG_ENDIAN)
#define Int16FromMOTA(a) (a)
#define Int32FromMOTA(a) (a)
#else
diff --git a/tools/source/fsys/os2.cxx b/tools/source/fsys/os2.cxx
index 6357c9746306..fd5ffa9291a3 100644
--- a/tools/source/fsys/os2.cxx
+++ b/tools/source/fsys/os2.cxx
@@ -38,9 +38,9 @@
#include <malloc.h>
#endif
#include <tools/debug.hxx>
-#include <list.hxx>
+#include <tools/list.hxx>
#include <tools/bigint.hxx>
-#include <fsys.hxx>
+#include <tools/fsys.hxx>
#include "comdep.hxx"
#ifdef OS2
diff --git a/transex3/source/gsicheck.cxx b/transex3/source/gsicheck.cxx
index cb8ded314d8a..99183602f951 100644
--- a/transex3/source/gsicheck.cxx
+++ b/transex3/source/gsicheck.cxx
@@ -444,7 +444,7 @@ BOOL GSIBlock::IsUTF8( const ByteString &aTestee, BOOL bFixTags, USHORT &nErrorP
}
}
- ByteString aDelimiter( String( sal_Unicode(0x2016) ), RTL_TEXTENCODING_UTF8 );
+ ByteString aDelimiter( (String)String( sal_Unicode(0x2016) ), RTL_TEXTENCODING_UTF8 );
if ( aID.Equals( aDelimiter, 6, aDelimiter.Len() ) )
{ // New KeyId 6 Letters, digits and spechial chars followed by delimiter
@@ -780,7 +780,7 @@ void Help()
}
/*****************************************************************************/
-#if defined( UNX )
+#if defined(UNX) || defined(OS2)
int main( int argc, char *argv[] )
#else
int _cdecl main( int argc, char *argv[] )
diff --git a/transex3/source/gsiconv.cxx b/transex3/source/gsiconv.cxx
index 67eb6215335c..f6dea76ebb51 100644
--- a/transex3/source/gsiconv.cxx
+++ b/transex3/source/gsiconv.cxx
@@ -201,7 +201,7 @@ void Help()
}
/*****************************************************************************/
-#if defined( UNX )
+#if defined(UNX) || defined(OS2)
int main( int argc, char *argv[] )
#else
int _cdecl main( int argc, char *argv[] )
diff --git a/transex3/source/helpex.cxx b/transex3/source/helpex.cxx
index bb7362914b72..f4a1589b530e 100644
--- a/transex3/source/helpex.cxx
+++ b/transex3/source/helpex.cxx
@@ -210,7 +210,7 @@ void Help()
/*****************************************************************************/
#ifndef TESTDRIVER
-#if defined( UNX )
+#if defined(UNX) || defined(OS2)
int main( int argc, char *argv[] )
#else
int _cdecl main( int argc, char *argv[] )
diff --git a/transex3/source/helpmerge.cxx b/transex3/source/helpmerge.cxx
index 27ee6b2d047a..8aafc692f14c 100644
--- a/transex3/source/helpmerge.cxx
+++ b/transex3/source/helpmerge.cxx
@@ -493,7 +493,7 @@ bool HelpParser::MergeSingleFile( XMLFile* file , MergeDataFile& aMergeDataFile
if( !Export::CopyFile( sTempFile , sTempFileCopy ) )
{
-#ifdef UNX
+#if defined(UNX) || defined(OS2)
sleep( 3 );
#else
Sleep( 3 );
@@ -512,7 +512,7 @@ bool HelpParser::MergeSingleFile( XMLFile* file , MergeDataFile& aMergeDataFile
remove( sTargetFile.GetBuffer() );
}
int rc;
-#ifdef UNX
+#if defined(UNX) || defined(OS2)
rc = rename( sTempFile.GetBuffer() , sTargetFile.GetBuffer() );
#else
rc = MoveFileEx( sTempFile.GetBuffer() , sTargetFile.GetBuffer(), MOVEFILE_REPLACE_EXISTING );
@@ -528,7 +528,7 @@ bool HelpParser::MergeSingleFile( XMLFile* file , MergeDataFile& aMergeDataFile
// if( aFS.GetSize() < 1 )
//#endif
{
-#ifdef UNX
+#if defined(UNX) || defined(OS2)
sleep( 3 );
#else
Sleep( 3 );
@@ -538,7 +538,7 @@ bool HelpParser::MergeSingleFile( XMLFile* file , MergeDataFile& aMergeDataFile
{
remove( sTargetFile.GetBuffer() );
}
-#ifdef UNX
+#if defined(UNX) || defined(OS2)
rc = rename( sTempFileCopy.GetBuffer() , sTargetFile.GetBuffer() );
#else
rc = MoveFileEx( sTempFileCopy.GetBuffer() , sTargetFile.GetBuffer() , MOVEFILE_REPLACE_EXISTING );
diff --git a/transex3/source/lngex.cxx b/transex3/source/lngex.cxx
index a73afb09d59c..53c97de6e045 100644
--- a/transex3/source/lngex.cxx
+++ b/transex3/source/lngex.cxx
@@ -191,7 +191,7 @@ void Help()
}
/*****************************************************************************/
-#if defined( UNX )
+#if defined(UNX) || defined(OS2)
int main( int argc, char *argv[] )
#else
int _cdecl main( int argc, char *argv[] )
diff --git a/transex3/source/localize.cxx b/transex3/source/localize.cxx
index c03c885b0c51..1d7e17c7df7c 100644
--- a/transex3/source/localize.cxx
+++ b/transex3/source/localize.cxx
@@ -835,7 +835,7 @@ BOOL CheckLanguages( ByteString &rLanguages )
}
/*****************************************************************************/
-#if defined( UNX )
+#if defined(UNX) || defined(OS2)
int main( int argc, char *argv[] )
#else
int _cdecl main( int argc, char *argv[] )
diff --git a/transex3/source/txtconv.cxx b/transex3/source/txtconv.cxx
index a497a925b56e..2f442b80a83d 100644
--- a/transex3/source/txtconv.cxx
+++ b/transex3/source/txtconv.cxx
@@ -70,7 +70,7 @@ void Help()
}
/*****************************************************************************/
-#if defined( UNX )
+#if defined(UNX) || defined(OS2)
int main( int argc, char *argv[] )
#else
int _cdecl main( int argc, char *argv[] )
diff --git a/transex3/source/xgfconv.cxx b/transex3/source/xgfconv.cxx
index 21b2ae484e17..76ea1a2906a8 100644
--- a/transex3/source/xgfconv.cxx
+++ b/transex3/source/xgfconv.cxx
@@ -7,7 +7,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_transex3.hxx"
-#if defined( UNX )
+#if defined(UNX) || defined(OS2)
int main( int argc, char *argv[] )
#else
int _cdecl main( int argc, char *argv[] )
diff --git a/transex3/source/xmlparse.cxx b/transex3/source/xmlparse.cxx
index 61fada5b0d3e..eefcfc9b3de6 100644
--- a/transex3/source/xmlparse.cxx
+++ b/transex3/source/xmlparse.cxx
@@ -278,7 +278,7 @@ BOOL XMLFile::Write( ByteString &aFilename )
if( !aFStream ) // From time to time the stream can not be opened the first time on NFS volumes,
{ // I wasn't able to track this down. I think this is an NFS issue .....
//cerr << "ERROR: - helpex - Can't write to tempfile " << aFilename.GetBuffer() << " No#" << x << "\n";
-#ifdef UNX
+#if defined(UNX) || defined(OS2)
sleep( 3 );
#else
Sleep( 3 );
diff --git a/vcl/os2/inc/salframe.h b/vcl/os2/inc/salframe.h
index d3c0ec8ca233..dd8c441ca255 100644
--- a/vcl/os2/inc/salframe.h
+++ b/vcl/os2/inc/salframe.h
@@ -158,6 +158,7 @@ public:
virtual void SetParent( SalFrame* pNewParent );
virtual bool SetPluginParent( SystemParentData* pNewParent );
virtual void SetBackgroundBitmap( SalBitmap* );
+ virtual void SetScreenNumber( unsigned int );
virtual void ResetClipRegion();
virtual void BeginSetClipRegion( ULONG nRects );
virtual void UnionClipRegion( long nX, long nY, long nWidth, long nHeight );
diff --git a/vcl/os2/inc/salgdi.h b/vcl/os2/inc/salgdi.h
index 6f319a32064e..5e70f50ada79 100644
--- a/vcl/os2/inc/salgdi.h
+++ b/vcl/os2/inc/salgdi.h
@@ -64,7 +64,7 @@ public:
virtual ImplFontEntry* CreateFontInstance( ImplFontSelectData& ) const;
virtual sal_IntPtr GetFontId() const;
void SetFontId( sal_IntPtr nId ) { mnId = nId; }
- void UpdateFromHPS( HPS );
+ void UpdateFromHPS( HPS ) const;
bool HasChar( sal_uInt32 cChar ) const;
@@ -77,15 +77,15 @@ public:
bool AliasSymbolsHigh() const { return mbAliasSymbolsHigh; }
bool AliasSymbolsLow() const { return mbAliasSymbolsLow; }
- ImplFontCharMap* GetImplFontCharMap();
+ ImplFontCharMap* GetImplFontCharMap() const;
private:
sal_IntPtr mnId;
- bool mbDisableGlyphApi;
- bool mbHasKoreanRange;
- bool mbHasCJKSupport;
+ mutable bool mbDisableGlyphApi;
+ mutable bool mbHasKoreanRange;
+ mutable bool mbHasCJKSupport;
- ImplFontCharMap* mpUnicodeMap;
+ mutable ImplFontCharMap* mpUnicodeMap;
// TODO: get rid of the members below needed to work with the Win9x non-unicode API
BYTE* mpFontCharSets; // all Charsets for the current font (used on W98 for kerning)
@@ -97,8 +97,8 @@ private:
PFONTMETRICS pFontMetric;
private:
- void ReadCmapTable( HDC );
- void ReadOs2Table( HDC );
+ void ReadCmapTable( HDC ) const;
+ void ReadOs2Table( HDC ) const;
#ifdef GNG_VERT_HACK
void ReadGsubTable( HDC ) const;
@@ -139,7 +139,7 @@ public:
BOOL mbScreen; // is Screen compatible
bool mbXORMode; // _every_ output with RasterOp XOR
ULONG mhFonts[ MAX_FALLBACK ]; // Font + Fallbacks
- ImplOs2FontData* mpOs2FontData[ MAX_FALLBACK ]; // pointer to the most recent font face
+ const ImplOs2FontData* mpOs2FontData[ MAX_FALLBACK ]; // pointer to the most recent font face
ImplOs2FontEntry* mpOs2FontEntry[ MAX_FALLBACK ]; // pointer to the most recent font instance
ULONG mhDefFont; // DefaultFont
float mfFontScale; // allows metrics emulation of huge font sizes
@@ -155,6 +155,7 @@ public:
protected:
virtual BOOL unionClipRegion( long nX, long nY, long nWidth, long nHeight );
+ virtual bool unionClipRegion( const ::basegfx::B2DPolyPolygon& );
// draw --> LineColor and FillColor and RasterOp and ClipRegion
virtual void drawPixel( long nX, long nY );
virtual void drawPixel( long nX, long nY, SalColor nSalColor );
@@ -163,6 +164,8 @@ protected:
virtual void drawPolyLine( ULONG nPoints, const SalPoint* pPtAry );
virtual void drawPolygon( ULONG nPoints, const SalPoint* pPtAry );
virtual void drawPolyPolygon( ULONG nPoly, const ULONG* pPoints, PCONSTSALPOINT* pPtAry );
+ virtual bool drawPolyPolygon( const ::basegfx::B2DPolyPolygon&, double fTransparency );
+ virtual bool drawPolyLine( const ::basegfx::B2DPolygon&, const ::basegfx::B2DVector& rLineWidth, basegfx::B2DLineJoin);
virtual sal_Bool drawPolyLineBezier( ULONG nPoints, const SalPoint* pPtAry, const BYTE* pFlgAry );
virtual sal_Bool drawPolygonBezier( ULONG nPoints, const SalPoint* pPtAry, const BYTE* pFlgAry );
virtual sal_Bool drawPolyPolygonBezier( ULONG nPoly, const ULONG* pPoints, const SalPoint* const* pPtAry, const BYTE* const* pFlgAry );
@@ -277,7 +280,7 @@ public:
// implementation note: encoding 0 with glyph id 0 should be added implicitly
// as "undefined character"
virtual BOOL CreateFontSubset( const rtl::OUString& rToFile,
- ImplFontData* pFont,
+ const ImplFontData* pFont,
long* pGlyphIDs,
sal_uInt8* pEncoding,
sal_Int32* pWidths,
@@ -309,7 +312,7 @@ public:
// frees the font data again
virtual void FreeEmbedFontData( const void* pData, long nDataLen );
- virtual void GetGlyphWidths( ImplFontData* pFont,
+ virtual void GetGlyphWidths( const ImplFontData* pFont,
bool bVertical,
Int32Vector& rWidths,
Ucs2UIntMap& rUnicodeEnc );
diff --git a/vcl/os2/inc/salinst.h b/vcl/os2/inc/salinst.h
index 83d736592a93..119324c1acd6 100644
--- a/vcl/os2/inc/salinst.h
+++ b/vcl/os2/inc/salinst.h
@@ -41,9 +41,6 @@ namespace vos { class OMutex; }
// -------------------
class SalYieldMutex;
-//class SalInstance;
-//class SalFrame;
-//class SalObject;
#define SAL_COMMANDLINENOINIT ((USHORT)0xFFFF)
#define SAL_MAXPARAM 40
@@ -57,8 +54,6 @@ public:
int mnArgc; // commandline param count
char** mpArgv; // commandline
HWND mhComWnd; // window, for communication (between threads and the main thread)
- //void* mpFilterInst; // hack for clipboard
- //void* mpFilterCallback; // hack for clipboard
SalYieldMutex* mpSalYieldMutex; // Sal-Yield-Mutex
vos::OMutex* mpSalWaitMutex; // Sal-Wait-Mutex
USHORT mnYieldWaitCount; // Wait-Count
@@ -86,7 +81,6 @@ public:
virtual void GetPrinterQueueState( SalPrinterQueueInfo* pInfo );
virtual void DeletePrinterQueueInfo( SalPrinterQueueInfo* pInfo );
virtual String GetDefaultPrinter();
- virtual SalSound* CreateSalSound();
virtual SalTimer* CreateSalTimer();
virtual SalI18NImeStatus* CreateI18NImeStatus();
virtual SalSystem* CreateSalSystem();
diff --git a/vcl/os2/inc/salobj.h b/vcl/os2/inc/salobj.h
index 9fefa2ddc54a..aa566808a41f 100644
--- a/vcl/os2/inc/salobj.h
+++ b/vcl/os2/inc/salobj.h
@@ -32,7 +32,6 @@
#define _SV_SALOBJ_H
#include <vcl/sv.h>
-#include <sysdata.hxx>
#include <vcl/salobj.hxx>
// -----------------
diff --git a/vcl/os2/source/app/makefile.mk b/vcl/os2/source/app/makefile.mk
index b3349d9f32ee..e2c14fb1744a 100644
--- a/vcl/os2/source/app/makefile.mk
+++ b/vcl/os2/source/app/makefile.mk
@@ -49,7 +49,6 @@ YD00_CXXFILES=\
salinst.cxx \
sallang.cxx \
saltimer.cxx \
- salsound.cxx \
salsys.cxx
SLOFILES= $(SLO)$/salshl.obj \
@@ -57,10 +56,7 @@ SLOFILES= $(SLO)$/salshl.obj \
$(SLO)$/salinfo.obj \
$(SLO)$/salinst.obj \
$(SLO)$/sallang.obj \
- $(SLO)$/saltimer.obj \
- $(SLO)$/salsound.obj
-
-# $(SLO)$/salsys.obj
+ $(SLO)$/saltimer.obj
# --- Targets ------------------------------------------------------
diff --git a/vcl/os2/source/app/salinst.cxx b/vcl/os2/source/app/salinst.cxx
index 6632daff90ef..a14881c253ee 100644
--- a/vcl/os2/source/app/salinst.cxx
+++ b/vcl/os2/source/app/salinst.cxx
@@ -52,7 +52,6 @@
#include <salframe.h>
#include <salobj.h>
#include <saltimer.h>
-#include <salsound.h>
#include <salbmp.h>
#include <vcl/salimestatus.hxx>
#include <vcl/timer.hxx>
@@ -821,13 +820,6 @@ SalTimer* Os2SalInstance::CreateSalTimer()
// -----------------------------------------------------------------------
-SalSound* Os2SalInstance::CreateSalSound()
-{
- return new Os2SalSound();
-}
-
-// -----------------------------------------------------------------------
-
SalBitmap* Os2SalInstance::CreateSalBitmap()
{
return new Os2SalBitmap();
diff --git a/vcl/os2/source/app/sallang.cxx b/vcl/os2/source/app/sallang.cxx
index f27398b3c463..c15a61332aa4 100644
--- a/vcl/os2/source/app/sallang.cxx
+++ b/vcl/os2/source/app/sallang.cxx
@@ -1,370 +1,120 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2008 by Sun Microsystems, Inc.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * $RCSfile: sallang.cxx,v $
- * $Revision: 1.5 $
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#include <sallang.hxx>
-
-// =======================================================================
-
-// -----------------------------------------------------------------------
-// Danish
-
-static const wchar_t* aImplLangDanishTab[LSTR_COUNT] =
-{
- L"Skift", // LSTR_KEY_SHIFT
- L"Ctrl", // LSTR_KEY_CTRL
- L"Alt", // LSTR_KEY_ALT
- L"Op", // LSTR_KEY_UP
- L"Ned", // LSTR_KEY_DOWN
- L"Venstre", // LSTR_KEY_LEFT
- L"Hjre", // LSTR_KEY_RIGHT
- L"Home", // LSTR_KEY_HOME
- L"End", // LSTR_KEY_END
- L"PageUp", // LSTR_KEY_PAGEUP
- L"PageDown", // LSTR_KEY_PAGEDOWN
- L"Enter", // LSTR_KEY_RETURN
- L"Esc", // LSTR_KEY_ESC
- L"Tab", // LSTR_KEY_TAB
- L"Tilbage", // LSTR_KEY_BACKSPACE
- L"Mellemrum", // LSTR_KEY_SPACE
- L"Insert", // LSTR_KEY_INSERT
- L"Delete", // LSTR_KEY_DELETE
-};
-
-// -----------------------------------------------------------------------
-// Dutch (Netherland/Belgian)
-
-static const wchar_t* aImplLangDutchTab[LSTR_COUNT] =
-{
- L"Shift", // LSTR_KEY_SHIFT
- L"Ctrl", // LSTR_KEY_CTRL
- L"Alt", // LSTR_KEY_ALT
- L"Boven", // LSTR_KEY_UP
- L"Onder", // LSTR_KEY_DOWN
- L"Links", // LSTR_KEY_LEFT
- L"Links", // LSTR_KEY_RIGHT
- L"Pos1", // LSTR_KEY_HOME
- L"Einde", // LSTR_KEY_END
- L"PageUp", // LSTR_KEY_PAGEUP
- L"PageDown", // LSTR_KEY_PAGEDOWN
- L"Return", // LSTR_KEY_RETURN
- L"Esc", // LSTR_KEY_ESC
- L"Tab", // LSTR_KEY_TAB
- L"Backspace", // LSTR_KEY_BACKSPACE
- L"Spatiebalk", // LSTR_KEY_SPACE
- L"Ins", // LSTR_KEY_INSERT
- L"Verwijderen", // LSTR_KEY_DELETE
-};
-
-// -----------------------------------------------------------------------
-// English (US/UK/AUS/CAN/NZ/EIRE/SAFRICA/JAMAICA/CARRIBEAN)
-
-static const wchar_t* aImplLangEnglishTab[LSTR_COUNT] =
-{
- L"Shift", // LSTR_KEY_SHIFT
- L"Ctrl", // LSTR_KEY_CTRL
- L"Alt", // LSTR_KEY_ALT
- L"Up", // LSTR_KEY_UP
- L"Down", // LSTR_KEY_DOWN
- L"Left", // LSTR_KEY_LEFT
- L"Right", // LSTR_KEY_RIGHT
- L"Home", // LSTR_KEY_HOME
- L"End", // LSTR_KEY_END
- L"PageUp", // LSTR_KEY_PAGEUP
- L"PageDown", // LSTR_KEY_PAGEDOWN
- L"Enter", // LSTR_KEY_RETURN
- L"Esc", // LSTR_KEY_ESC
- L"Tab", // LSTR_KEY_TAB
- L"Backspace", // LSTR_KEY_BACKSPACE
- L"Space", // LSTR_KEY_SPACE
- L"Insert", // LSTR_KEY_INSERT
- L"Del", // LSTR_KEY_DELETE
-};
-
-// -----------------------------------------------------------------------
-// Finnish
-
-static const wchar_t* aImplLangFinnishTab[LSTR_COUNT] =
-{
- L"Vaihtonppain", // LSTR_KEY_SHIFT
- L"Ctrl", // LSTR_KEY_CTRL
- L"Alt", // LSTR_KEY_ALT
- L"Yl", // LSTR_KEY_UP
- L"Ala", // LSTR_KEY_DOWN
- L"Vasen", // LSTR_KEY_LEFT
- L"Oikea", // LSTR_KEY_RIGHT
- L"Home", // LSTR_KEY_HOME
- L"End", // LSTR_KEY_END
- L"PageUp", // LSTR_KEY_PAGEUP
- L"PageDown", // LSTR_KEY_PAGEDOWN
- L"Enter", // LSTR_KEY_RETURN
- L"Esc", // LSTR_KEY_ESC
- L"Sarkain", // LSTR_KEY_TAB
- L"Askelpalautin", // LSTR_KEY_BACKSPACE
- L"Vlinppin", // LSTR_KEY_SPACE
- L"Insert", // LSTR_KEY_INSERT
- L"Delete", // LSTR_KEY_DELETE
-};
-
-// -----------------------------------------------------------------------
-// French (French/Belgian/Canadian/Swiss/Luxenbourg)
-
-static const wchar_t* aImplLangFrenchTab[LSTR_COUNT] =
-{
- L"Maj", // LSTR_KEY_SHIFT
- L"Ctrl", // LSTR_KEY_CTRL
- L"Alt", // LSTR_KEY_ALT
- L"Haut", // LSTR_KEY_UP
- L"Bas", // LSTR_KEY_DOWN
- L"Gauche", // LSTR_KEY_LEFT
- L"Droite", // LSTR_KEY_RIGHT
- L"Origine", // LSTR_KEY_HOME
- L"Fin", // LSTR_KEY_END
- L"Pg. Prc", // LSTR_KEY_PAGEUP
- L"Pg. Suiv", // LSTR_KEY_PAGEDOWN
- L"Entre", // LSTR_KEY_RETURN
- L"Esc", // LSTR_KEY_ESC
- L"Tab", // LSTR_KEY_TAB
- L"Ret. Arr", // LSTR_KEY_BACKSPACE
- L"Espace", // LSTR_KEY_SPACE
- L"Insrer", // LSTR_KEY_INSERT
- L"Suppr", // LSTR_KEY_DELETE
-};
-
-// -----------------------------------------------------------------------
-// German (German/Swiss/Austrian/Luxembourg/Liechtenstein)
-
-static const wchar_t* aImplLangGermanTab[LSTR_COUNT] =
-{
- L"Umschalt", // LSTR_KEY_SHIFT
- L"Strg", // LSTR_KEY_CTRL
- L"Alt", // LSTR_KEY_ALT
- L"Nach-Oben", // LSTR_KEY_UP
- L"Nach-Unten", // LSTR_KEY_DOWN
- L"Nach-Links", // LSTR_KEY_LEFT
- L"Nach-Rechts", // LSTR_KEY_RIGHT
- L"Pos1", // LSTR_KEY_HOME
- L"Ende", // LSTR_KEY_END
- L"Bild-Nach-Oben", // LSTR_KEY_PAGEUP
- L"Bild-Nach-Unten", // LSTR_KEY_PAGEDOWN
- L"Eingabe", // LSTR_KEY_RETURN
- L"Esc", // LSTR_KEY_ESC
- L"Tab", // LSTR_KEY_TAB
- L"Rck", // LSTR_KEY_BACKSPACE
- L"Leer", // LSTR_KEY_SPACE
- L"Einfg", // LSTR_KEY_INSERT
- L"Entf", // LSTR_KEY_DELETE
-};
-
-// -----------------------------------------------------------------------
-// Italian (Italian/Swiss)
-
-static const wchar_t* aImplLangItalianTab[LSTR_COUNT] =
-{
- L"Maiusc", // LSTR_KEY_SHIFT
- L"Ctrl", // LSTR_KEY_CTRL
- L"Alt", // LSTR_KEY_ALT
- L"Sposta verso l'alto", // LSTR_KEY_UP
- L"Sposta verso il basso", // LSTR_KEY_DOWN
- L"A sinistra", // LSTR_KEY_LEFT
- L"A destra", // LSTR_KEY_RIGHT
- L"Home", // LSTR_KEY_HOME
- L"Fine", // LSTR_KEY_END
- L"PgSu", // LSTR_KEY_PAGEUP
- L"PgGi", // LSTR_KEY_PAGEDOWN
- L"Invio", // LSTR_KEY_RETURN
- L"Esc", // LSTR_KEY_ESC
- L"Tab", // LSTR_KEY_TAB
- L"Backspace", // LSTR_KEY_BACKSPACE
- L"Spaziatrice", // LSTR_KEY_SPACE
- L"Ins", // LSTR_KEY_INSERT
- L"Canc", // LSTR_KEY_DELETE
-};
-
-// -----------------------------------------------------------------------
-// Norwegian (Bokmal)
-
-static const wchar_t* aImplLangNorwegianTab[LSTR_COUNT] =
-{
- L"Skift", // LSTR_KEY_SHIFT
- L"Ctrl", // LSTR_KEY_CTRL
- L"Alt", // LSTR_KEY_ALT
- L"Opp", // LSTR_KEY_UP
- L"Ned", // LSTR_KEY_DOWN
- L"Venstre", // LSTR_KEY_LEFT
- L"Hyre", // LSTR_KEY_RIGHT
- L"Home", // LSTR_KEY_HOME
- L"End", // LSTR_KEY_END
- L"PageUp", // LSTR_KEY_PAGEUP
- L"PageDown", // LSTR_KEY_PAGEDOWN
- L"Enter", // LSTR_KEY_RETURN
- L"Esc", // LSTR_KEY_ESC
- L"Tab", // LSTR_KEY_TAB
- L"Tilbake", // LSTR_KEY_BACKSPACE
- L"Mellomrom", // LSTR_KEY_SPACE
- L"Insert", // LSTR_KEY_INSERT
- L"Delete", // LSTR_KEY_DELETE
-};
-
-// -----------------------------------------------------------------------
-// Portuguse (Portuguse/Brazilian)
-
-static const wchar_t* aImplLangPortugueseTab[LSTR_COUNT] =
-{
- L"Shift", // LSTR_KEY_SHIFT
- L"Ctrl", // LSTR_KEY_CTRL
- L"Alt", // LSTR_KEY_ALT
- L"Acima", // LSTR_KEY_UP
- L"Abaixo", // LSTR_KEY_DOWN
- L"Esquerda", // LSTR_KEY_LEFT
- L"Direita", // LSTR_KEY_RIGHT
- L"Home", // LSTR_KEY_HOME
- L"End", // LSTR_KEY_END
- L"PageUp", // LSTR_KEY_PAGEUP
- L"PageDown", // LSTR_KEY_PAGEDOWN
- L"Enter", // LSTR_KEY_RETURN
- L"Esc", // LSTR_KEY_ESC
- L"Tab", // LSTR_KEY_TAB
- L"Backspace", // LSTR_KEY_BACKSPACE
- L"Space", // LSTR_KEY_SPACE
- L"Insert", // LSTR_KEY_INSERT
- L"Delete", // LSTR_KEY_DELETE
-};
-
-// -----------------------------------------------------------------------
-// Spanish (Spanish/Mexican/Modern/Guatemala/Costarica/Panama/Dominican/
-// Venezuela/Colombia/Peru/Argentina/Ecuador/Chile/Uruguay/
-// Paraguay/Bolivia)
-
-static const wchar_t* aImplLangSpanishTab[LSTR_COUNT] =
-{
- L"Mays", // LSTR_KEY_SHIFT
- L"Control", // LSTR_KEY_CTRL
- L"Alt", // LSTR_KEY_ALT
- L"Hacia arriba", // LSTR_KEY_UP
- L"Hacia abajo", // LSTR_KEY_DOWN
- L"Hacia la izquierda", // LSTR_KEY_LEFT
- L"Hacia la derecha", // LSTR_KEY_RIGHT
- L"Home", // LSTR_KEY_HOME
- L"Fin", // LSTR_KEY_END
- L"RePg", // LSTR_KEY_PAGEUP
- L"AvPg", // LSTR_KEY_PAGEDOWN
- L"Entrada", // LSTR_KEY_RETURN
- L"Esc", // LSTR_KEY_ESC
- L"Tab", // LSTR_KEY_TAB
- L"Ret", // LSTR_KEY_BACKSPACE
- L"Espacio", // LSTR_KEY_SPACE
- L"Insert", // LSTR_KEY_INSERT
- L"Supr", // LSTR_KEY_DELETE
-};
-
-// -----------------------------------------------------------------------
-// Swedish
-
-static const wchar_t* aImplLangSwedishTab[LSTR_COUNT] =
-{
- L"Skift", // LSTR_KEY_SHIFT
- L"Ctrl", // LSTR_KEY_CTRL
- L"Alt", // LSTR_KEY_ALT
- L"Up", // LSTR_KEY_UP
- L"Ned", // LSTR_KEY_DOWN
- L"Vnster", // LSTR_KEY_LEFT
- L"Hger", // LSTR_KEY_RIGHT
- L"Home", // LSTR_KEY_HOME
- L"End", // LSTR_KEY_END
- L"PageUp", // LSTR_KEY_PAGEUP
- L"PageDown", // LSTR_KEY_PAGEDOWN
- L"Retur", // LSTR_KEY_RETURN
- L"Esc", // LSTR_KEY_ESC
- L"Tab", // LSTR_KEY_TAB
- L"Backsteg", // LSTR_KEY_BACKSPACE
- L"Blank", // LSTR_KEY_SPACE
- L"Insert", // LSTR_KEY_INSERT
- L"Delete", // LSTR_KEY_DELETE
-};
-
-// =======================================================================
-
-const sal_Unicode** ImplGetLangTab( LanguageType eLang )
-{
- // Sprachtabelle ermitteln
- const wchar_t** pLangTab;
- //switch ( International::GetNeutralLanguage( eLang ) )
- switch ( eLang )
- {
- case LANGUAGE_DANISH:
- pLangTab = aImplLangDanishTab;
- break;
-
- case LANGUAGE_DUTCH:
- case LANGUAGE_DUTCH_BELGIAN:
- pLangTab = aImplLangDutchTab;
- break;
-
- case LANGUAGE_FINNISH:
- pLangTab = aImplLangFinnishTab;
- break;
-
- case LANGUAGE_FRENCH:
- pLangTab = aImplLangFrenchTab;
- break;
-
- case LANGUAGE_GERMAN:
- pLangTab = aImplLangGermanTab;
- break;
-
- case LANGUAGE_ITALIAN:
- pLangTab = aImplLangItalianTab;
- break;
-
- case LANGUAGE_NORWEGIAN:
- case LANGUAGE_NORWEGIAN_BOKMAL:
- pLangTab = aImplLangNorwegianTab;
- break;
-
- case LANGUAGE_PORTUGUESE:
- case LANGUAGE_PORTUGUESE_BRAZILIAN:
- pLangTab = aImplLangPortugueseTab;
- break;
-
- case LANGUAGE_SPANISH:
- pLangTab = aImplLangSpanishTab;
- break;
-
- case LANGUAGE_SWEDISH:
- pLangTab = aImplLangSwedishTab;
- break;
-
- default:
- pLangTab = aImplLangEnglishTab;
- break;
- }
-
- return (const sal_Unicode**)pLangTab;
-}
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * $RCSfile: sallang.cxx,v $
+ * $Revision: 1.4 $
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#ifndef _SALLANG_HXX
+#include <sallang.hxx>
+#endif
+
+// =======================================================================
+
+// -----------------------------------------------------------------------
+// English (US/UK/AUS/CAN/NZ/EIRE/SAFRICA/JAMAICA/CARRIBEAN)
+static const wchar_t* aImplLangEnglishTab[LSTR_COUNT] =
+{
+ L"Shift", // LSTR_KEY_SHIFT
+ L"Ctrl", // LSTR_KEY_CTRL
+ L"Alt", // LSTR_KEY_ALT
+ L"Up", // LSTR_KEY_UP
+ L"Down", // LSTR_KEY_DOWN
+ L"Left", // LSTR_KEY_LEFT
+ L"Right", // LSTR_KEY_RIGHT
+ L"Home", // LSTR_KEY_HOME
+ L"End", // LSTR_KEY_END
+ L"PageUp", // LSTR_KEY_PAGEUP
+ L"PageDown", // LSTR_KEY_PAGEDOWN
+ L"Enter", // LSTR_KEY_RETURN
+ L"Esc", // LSTR_KEY_ESC
+ L"Tab", // LSTR_KEY_TAB
+ L"Backspace", // LSTR_KEY_BACKSPACE
+ L"Space", // LSTR_KEY_SPACE
+ L"Insert", // LSTR_KEY_INSERT
+ L"Del", // LSTR_KEY_DELETE
+};
+
+// =======================================================================
+
+const sal_Unicode** ImplGetLangTab( LanguageType eLang )
+{
+ // Sprachtabelle ermitteln
+ const wchar_t** pLangTab;
+ //switch ( International::GetNeutralLanguage( eLang ) )
+ switch ( eLang )
+ {
+#if 0
+ case LANGUAGE_DANISH:
+ pLangTab = aImplLangDanishTab;
+ break;
+
+ case LANGUAGE_DUTCH:
+ case LANGUAGE_DUTCH_BELGIAN:
+ pLangTab = aImplLangDutchTab;
+ break;
+
+ case LANGUAGE_FINNISH:
+ pLangTab = aImplLangFinnishTab;
+ break;
+
+ case LANGUAGE_FRENCH:
+ pLangTab = aImplLangFrenchTab;
+ break;
+
+ case LANGUAGE_GERMAN:
+ pLangTab = aImplLangGermanTab;
+ break;
+
+ case LANGUAGE_ITALIAN:
+ pLangTab = aImplLangItalianTab;
+ break;
+
+ case LANGUAGE_NORWEGIAN:
+ case LANGUAGE_NORWEGIAN_BOKMAL:
+ pLangTab = aImplLangNorwegianTab;
+ break;
+
+ case LANGUAGE_PORTUGUESE:
+ case LANGUAGE_PORTUGUESE_BRAZILIAN:
+ pLangTab = aImplLangPortugueseTab;
+ break;
+
+ case LANGUAGE_SPANISH:
+ pLangTab = aImplLangSpanishTab;
+ break;
+
+ case LANGUAGE_SWEDISH:
+ pLangTab = aImplLangSwedishTab;
+ break;
+#endif
+ default:
+ pLangTab = aImplLangEnglishTab;
+ break;
+ }
+
+ return (const sal_Unicode**)pLangTab;
+}
diff --git a/vcl/os2/source/app/salsound.cxx b/vcl/os2/source/app/salsound.cxx
deleted file mode 100644
index ff3c7f1be8c3..000000000000
--- a/vcl/os2/source/app/salsound.cxx
+++ /dev/null
@@ -1,422 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2008 by Sun Microsystems, Inc.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * $RCSfile: salsound.cxx,v $
- * $Revision: 1.5 $
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#define _SV_SALSOUND_CXX
-
-// ------------
-// - Includes -
-// ------------
-
-#include <string.h>
-
-#define INCL_DOSMODULEMGR
-#include <svpm.h>
-#include <saldata.hxx>
-#include <salinst.h>
-#include <salsound.h>
-
-#define INCL_MCIOS2
-#include <os2me.h>
-
-// ---------
-// - Names -
-// ---------
-
-#define SOUND_LIBNAME "MDM"
-#define SOUND_PROCNAME "mciSendCommand"
-
-// ------------
-// - Fnc cast -
-// ------------
-
-typedef ULONG (_cdecl *SALMCIPROC)( USHORT nDeviceId, USHORT nMessage, ULONG nFlags, void* pParam, USHORT );
-#define MCIFNC ( (SALMCIPROC) Os2SalSound::mpMCIFnc )
-
-// -----------------
-// - Statics init. -
-// -----------------
-
-HMODULE Os2SalSound::mhMCILib = 0;
-ULONG Os2SalSound::mnSoundState = SOUND_STATE_UNLOADED;
-void* Os2SalSound::mpMCIFnc = NULL;
-
-// -------------------
-// - Window-Callback -
-// -------------------
-
-MRESULT EXPENTRY SoundWndProc( HWND hWnd, ULONG nMsg, MPARAM nPar1, MPARAM nPar2 )
-{
- if( MM_MCINOTIFY == nMsg )
- {
- USHORT nNotify = (USHORT)(ULONG) nPar1;
- SoundNotification eNotification;
- BOOL bNotify = TRUE;
-
- switch( nNotify )
- {
- case( MCI_NOTIFY_SUCCESSFUL ):
- eNotification = SOUND_NOTIFY_SUCCESS;
- break;
-
- case( MCI_NOTIFY_ABORTED ):
- eNotification = SOUND_NOTIFY_ABORTED;
- break;
-
- case( MCI_NOTIFY_SUPERSEDED ):
- bNotify = FALSE;
- break;
-
- default:
- eNotification = SOUND_NOTIFY_ERROR;
- break;
- }
-
- if( bNotify )
- ( (Os2SalSound*) WinQueryWindowULong( hWnd, 0 ) )->ImplNotify( eNotification, 0 );
- }
-
- return WinDefWindowProc( hWnd, nMsg, nPar1, nPar2 );
-}
-
-// ------------
-// - Os2SalSound -
-// ------------
-
-Os2SalSound::Os2SalSound() :
- mpProc ( NULL ),
- mhSoundWnd ( 0 ),
- mnDeviceId ( 0 ),
- mbLoop ( FALSE ),
- mbPaused ( FALSE )
-{
-}
-
-// ------------------------------------------------------------------------
-
-Os2SalSound::~Os2SalSound()
-{
- Stop();
-
- if( mnDeviceId )
- {
- MCI_GENERIC_PARMS aGenericParams;
- memset( &aGenericParams, 0, sizeof( aGenericParams ) );
- aGenericParams.hwndCallback = mhSoundWnd;
- MCIFNC( mnDeviceId, MCI_CLOSE, MCI_WAIT, &aGenericParams, 0 );
- }
-
- if( mhSoundWnd )
- WinDestroyWindow( mhSoundWnd );
-}
-
-// ------------------------------------------------------------------------
-
-void Os2SalSound::ImplSetError( ULONG nMciErr )
-{
- struct aMapper { DWORD nMci; ULONG nSv; };
-
- ULONG nError = SOUNDERR_GENERAL_ERROR;
- static aMapper aErrArr[] =
- {
- { 0, SOUNDERR_SUCCESS },
- { MCIERR_CANNOT_LOAD_DRIVER, SOUNDERR_CANNOT_LOAD_DRIVER },
- { MCIERR_DEVICE_LOCKED, SOUNDERR_DEVICE_LOCKED },
- { MCIERR_DEVICE_NOT_READY, SOUNDERR_DEVICE_NOT_READY },
- { MCIERR_DEVICE_TYPE_REQUIRED, SOUNDERR_DEVICE_NOT_FOUND },
- { MCIERR_DRIVER, SOUNDERR_CANNOT_LOAD_DRIVER },
- { MCIERR_DRIVER_INTERNAL, SOUNDERR_CANNOT_LOAD_DRIVER },
- { MCIERR_EXTENSION_NOT_FOUND, SOUNDERR_SOUND_NOT_FOUND },
- { MCIERR_FILE_NOT_FOUND, SOUNDERR_SOUND_NOT_FOUND },
- { MCIERR_HARDWARE, SOUNDERR_HARDWARE_ERROR },
- { MCIERR_INVALID_DEVICE_NAME, SOUNDERR_DEVICE_NOT_FOUND },
- { MCIERR_OUT_OF_MEMORY, SOUNDERR_OUT_OF_MEMORY },
- { MCIERR_UNSUPPORTED_FUNCTION, SOUNDERR_UNSUPPORTED_FUNCTION }
- };
-
- for( USHORT n=0; n < (sizeof( aErrArr ) / sizeof( aMapper ) ); n++ )
- {
- if( aErrArr[ n ].nMci == nMciErr )
- {
- nError = aErrArr[ n ].nSv;
- break;
- }
- }
-
- if( nError )
- ImplNotify( SOUND_NOTIFY_ERROR, nError );
-}
-
-// ------------------------------------------------------------------------
-
-void Os2SalSound::ImplNotify( SoundNotification eNotification, ULONG nError )
-{
- if( mbLoop && ( SOUND_NOTIFY_SUCCESS == eNotification ) && !nError )
- Play( mnStartTime, mnPlayLen, TRUE );
-
- if( mpProc && mpInst )
- mpProc( mpInst, eNotification, nError );
-}
-
-// ------------------------------------------------------------------------
-
-BOOL Os2SalSound::Create()
-{
- SalData* pData = GetSalData();
- BOOL bRet = FALSE;
-
- if( SOUND_STATE_UNLOADED == Os2SalSound::mnSoundState )
- {
- if( DosLoadModule( 0, 0, (PCSZ)SOUND_LIBNAME, &Os2SalSound::mhMCILib ) == 0 &&
- DosQueryProcAddr( Os2SalSound::mhMCILib, 0, (PCSZ)SOUND_PROCNAME, (PFN*) &Os2SalSound::mpMCIFnc ) == 0 )
- {
- char* pszClassName = "SoundWin";
- PFNWP pWindowProc = SoundWndProc;
-
- WinRegisterClass( pData->mhAB, (PCSZ)pszClassName, pWindowProc, 0L, 4 );
- Os2SalSound::mnSoundState = SOUND_STATE_VALID;
- bRet = TRUE;
- }
- else
- {
- if( Os2SalSound::mhMCILib )
- DosFreeModule( Os2SalSound::mhMCILib );
-
- Os2SalSound::mnSoundState = SOUND_STATE_INVALID;
- ImplNotify( SOUND_NOTIFY_ERROR, SOUNDERR_CANNOT_LOAD_DRIVER );
- }
- }
- else if( SOUND_STATE_VALID == Os2SalSound::mnSoundState )
- bRet = TRUE;
-
- if( bRet )
- {
- mhSoundWnd = WinCreateWindow( HWND_OBJECT, (PCSZ)"SoundWin", (PCSZ)"Sound", 0, 0, 0, 0, 0, HWND_DESKTOP, HWND_BOTTOM, 0, 0, 0 );
- WinSetWindowULong( mhSoundWnd, 0, (ULONG) this );
- }
- else
- mhSoundWnd = 0;
-
- return bRet;
-}
-
-// ------------------------------------------------------------------------
-
-void Os2SalSound::Release()
-{
- if( Os2SalSound::mhMCILib )
- DosFreeModule( Os2SalSound::mhMCILib );
-
- Os2SalSound::mnSoundState = SOUND_STATE_UNLOADED;
-}
-
-// ------------------------------------------------------------------------
-
-bool Os2SalSound::IsValid()
-{
- return (Os2SalSound::mnSoundState == SOUND_STATE_VALID);
-}
-
-// ------------------------------------------------------------------------
-
-bool Os2SalSound::Init( const XubString& rSoundName, ULONG& rSoundLen )
-{
- MCI_OPEN_PARMS aOpenParams;
- ULONG nMciErr = 0;
-
- rSoundLen = 0;
-
- // clear old device
- if( mnDeviceId )
- {
- Stop();
-
- MCI_GENERIC_PARMS aGenericParams;
- memset( &aGenericParams, 0, sizeof( aGenericParams ) );
- aGenericParams.hwndCallback = mhSoundWnd;
- nMciErr = MCIFNC( mnDeviceId, MCI_CLOSE, MCI_WAIT, &aGenericParams, 0 );
- mnDeviceId = 0;
- }
-
- if( rSoundName.Len() )
- {
- // init new device with sound name
- memset( &aOpenParams, 0, sizeof( aOpenParams ) );
- aOpenParams.pszElementName = (PSZ) rSoundName.GetBuffer();
- aOpenParams.hwndCallback = mhSoundWnd;
- nMciErr = MCIFNC( 0, MCI_OPEN, MCI_WAIT | MCI_OPEN_ELEMENT, &aOpenParams, 0 );
-
- if( !nMciErr )
- {
- // set time format
- MCI_SET_PARMS aSetParams;
- memset( &aSetParams, 0, sizeof( aSetParams ) );
- mnDeviceId = aOpenParams.usDeviceID;
- aSetParams.ulTimeFormat = MCI_FORMAT_MILLISECONDS;
- nMciErr = MCIFNC( mnDeviceId, MCI_SET, MCI_WAIT | MCI_SET_TIME_FORMAT, &aSetParams, 0 );
-
- if( !nMciErr )
- {
- // get length of sound
- MCI_STATUS_PARMS aStatus;
- memset( &aStatus, 0, sizeof( aStatus ) );
- aStatus.ulItem = MCI_STATUS_LENGTH;
- MCIFNC( mnDeviceId, MCI_STATUS, MCI_WAIT | MCI_STATUS_ITEM, &aStatus, 0 );
- rSoundLen = (ULONG) aStatus.ulReturn;
- }
- }
- }
-
- if( nMciErr )
- ImplSetError( nMciErr );
-
- return( nMciErr ? FALSE : TRUE );
-}
-
-// ------------------------------------------------------------------------
-#if 0
-BOOL Os2SalSound::Init( SalFrame* pFrame, const BYTE* pSound, ULONG nDataLen, ULONG& rSoundLen )
-{
- rSoundLen = 0UL;
- ImplSetError( MCIERR_FILE_NOT_FOUND );
-
- return FALSE;
-}
-#endif
-
-// ------------------------------------------------------------------------
-
-void Os2SalSound::Play( ULONG nStartTime, ULONG nPlayLen, bool bLoop )
-{
- if( mnDeviceId )
- {
- ULONG nMciErr = 0;
-
- if( !mbPaused )
- {
- MCI_SEEK_PARMS aSeekParams;
- memset( &aSeekParams, 0, sizeof( aSeekParams ) );
- aSeekParams.hwndCallback = mhSoundWnd;
- aSeekParams.ulTo = 0;
- nMciErr = MCIFNC( mnDeviceId, MCI_SEEK,MCI_WAIT | MCI_TO, &aSeekParams, 0 );
- }
-
- mnStartTime = nStartTime;
- mnPlayLen = nPlayLen;
- mbLoop = bLoop;
- mbPaused = FALSE;
-
- if( !nMciErr )
- {
- MCI_PLAY_PARMS aPlayParams;
- DWORD nFlags = MCI_NOTIFY;
-
- memset( &aPlayParams, 0, sizeof( aPlayParams ) );
- aPlayParams.hwndCallback = mhSoundWnd;
-
- if( nStartTime )
- {
- aPlayParams.ulFrom = nStartTime;
- nFlags |= MCI_FROM;
- }
-
- if( nPlayLen != SOUND_PLAYALL )
- {
- aPlayParams.ulTo = nStartTime + nPlayLen;
- nFlags |= MCI_TO;
- }
-
- nMciErr = MCIFNC( mnDeviceId, MCI_PLAY, nFlags, &aPlayParams, 0 );
-
- if( !nMciErr )
- mbPaused = FALSE;
- }
-
- if( nMciErr )
- ImplSetError( nMciErr );
- }
- else
- ImplSetError( MCIERR_EXTENSION_NOT_FOUND );
-}
-
-// ------------------------------------------------------------------------
-
-void Os2SalSound::Stop()
-{
- if( mnDeviceId )
- {
- MCI_GENERIC_PARMS aGenericParams;
- memset( &aGenericParams, 0, sizeof( aGenericParams ) );
- aGenericParams.hwndCallback = mhSoundWnd;
- mbLoop = mbPaused = FALSE;
- MCIFNC( mnDeviceId, MCI_STOP, MCI_WAIT, &aGenericParams, 0 );
- }
-}
-
-// ------------------------------------------------------------------------
-
-void Os2SalSound::Pause()
-{
- if( mnDeviceId )
- {
- MCI_GENERIC_PARMS aGenericParams;
- memset( &aGenericParams, 0, sizeof( aGenericParams ) );
- aGenericParams.hwndCallback = mhSoundWnd;
- mbPaused = TRUE;
- MCIFNC( mnDeviceId, MCI_PAUSE, MCI_WAIT, &aGenericParams, 0 );
- }
-}
-
-// ------------------------------------------------------------------------
-
-void Os2SalSound::Continue()
-{
- Play( 0, 0, mbLoop );
-}
-
-// ------------------------------------------------------------------------
-
-bool Os2SalSound::IsLoopMode() const
-{
- return mbLoop;
-}
-
-// ------------------------------------------------------------------------
-
-bool Os2SalSound::IsPlaying() const
-{
- return !mbPaused;
-}
-
-// ------------------------------------------------------------------------
-
-bool Os2SalSound::IsPaused() const
-{
- return mbPaused;
-}
diff --git a/vcl/os2/source/app/salsys.cxx b/vcl/os2/source/app/salsys.cxx
deleted file mode 100644
index 35319c1d3cfc..000000000000
--- a/vcl/os2/source/app/salsys.cxx
+++ /dev/null
@@ -1,246 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2008 by Sun Microsystems, Inc.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * $RCSfile: salsys.cxx,v $
- * $Revision: 1.5 $
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#define _SV_SALSYS_CXX
-
-#include <string.h>
-
-#define INCL_DOS
-#define INCL_DOSERRORS
-#ifndef _SVPM_H
-#include <svpm.h>
-#endif
-#include <saldata.hxx>
-#include <salinst.hxx>
-#include <salframe.hxx>
-#include <salbmp.hxx>
-#include <salsys.hxx>
-#ifndef _VOS_PROCESS_HXX
-#include <vos/process.hxx>
-#endif
-#ifndef _TOOLS_FASTFSYS_HXX
-#include <tools/fastfsys.hxx>
-#endif
-
-#include <stdlib.h>
-#include <stdio.h>
-#include <string.h>
-#include <ctype.h>
-
-// =======================================================================
-
-SalSystem* SalInstance::CreateSystem()
-{
- return new SalSystem();
-}
-
-// -----------------------------------------------------------------------
-
-void SalInstance::DestroySystem( SalSystem* pSystem )
-{
- delete pSystem;
-}
-
-// -----------------------------------------------------------------------
-
-SalSystem::SalSystem()
-{
-}
-
-// -----------------------------------------------------------------------
-
-SalSystem::~SalSystem()
-{
-}
-
-// -----------------------------------------------------------------------
-
-BOOL SalSystem::StartProcess( SalFrame* pFrame, const XubString& rFileName,
- const XubString& rParam,
- const XubString& rWorkingDirectory )
-{
- ItemIDPath aFile(rFileName);
-
- //
- // first check if item has a context menu with open command
- //
-
- ItemIDPath aParent, aChild;
-
- if(aFile.Split(aParent, aChild))
- {
- IfcContextMenu *pConMenu = Folder(aParent).GetContextMenu(1, &aChild);
-
- if(pConMenu)
- {
- UINT32 nCount = pConMenu->GetItemCount();
-
- for(UINT32 n = 0; n < nCount; n++)
- {
- MenuItem aMenuItem;
-
- if(pConMenu->GetMenuItem(n, aMenuItem) &&
- aMenuItem.aVerb.Compare("open") == COMPARE_EQUAL)
- {
- return pConMenu->ExecuteCommand(aMenuItem.aCommand);
- }
- }
- }
- }
-
- // Dateinamen mit Wildcards lehnen wir ab
- if ( (rFileName.Search( '*' ) != STRING_NOTFOUND) ||
- (rFileName.Search( '?' ) != STRING_NOTFOUND) )
- return FALSE;
-
- XubString aFileName = aFile.GetHostNotationPath();
- char* aStdExtAry[] = { "exe", "com", "cmd", "bat" };
- const char* pStdExt;
- const xub_Unicode* pFileName = aFileName.GetStr();
- const xub_Unicode* pParam = rParam.GetStr();
- XubString aSearchFileName;
- XubString aExt;
- BOOL bExe = FALSE;
- BOOL bProcess = FALSE;
- BOOL bRet = FALSE;
- BOOL bExtension;
- int i;
-
- // Parameter und Extension ermitteln
- if ( !rParam.Len() )
- pParam = NULL;
- // Wenn keine Extension, dann versuchen wir eine zu ermitteln,
- // indem wir nach EXE-, COM-, CMD- oder BAT-Dateien suchen.
- bExtension = ImplSalGetExtension( aFileName, aExt );
- if ( !bExtension )
- {
- i = 0;
- do
- {
- pStdExt = aStdExtAry[i];
- aSearchFileName = aFileName;
- aSearchFileName += '.';
- aSearchFileName += pStdExt;
- if ( ImplSalFindFile( aSearchFileName.GetStr(), aSearchFileName ) )
- {
- pFileName = aSearchFileName.GetStr();
- bExtension = ImplSalGetExtension( aSearchFileName, aExt );
- break;
- }
- i++;
- }
- while ( i < 4 );
- }
- else
- {
- // Ansonsten Filename im Pfad suchen
- if ( ImplSalFindFile( pFileName, aSearchFileName ) )
- {
- pFileName = aSearchFileName.GetStr();
- bExtension = ImplSalGetExtension( aSearchFileName, aExt );
- }
- }
- // Wenn wir eine Extension haben, testen wir, ob es eine
- // Standard-Extension ist, womit wir einen Process starten koennen
- if ( bExtension )
- {
- aExt.ToLower();
- i = 0;
- do
- {
- if ( aExt == aStdExtAry[i] )
- {
- bExe = TRUE;
- break;
- }
- i++;
- }
- while ( i < 4 );
- }
-
- // change to path of executable if no working dir set
- XubString aWorkingDir(rWorkingDirectory);
-
- if(aWorkingDir.Len() == 0)
- {
- USHORT nIndex;
-
- aWorkingDir = pFileName;
- nIndex = aWorkingDir.SearchCharBackward("\\/:");
-
- if(nIndex == STRING_NOTFOUND)
- nIndex = 0;
- else if(aWorkingDir.GetChar(nIndex) == ':')
- aWorkingDir[nIndex++] = '\\';
-
- aWorkingDir.Erase(nIndex);
- }
-
- // start executables with process execute
- if ( bExe )
- {
- NAMESPACE_VOS( OProcess )::TProcessError nProcessError;
- NAMESPACE_VOS( OProcess ) aProcess( pFileName, pParam );
-
- aProcess.setDirectory(aWorkingDir.GetStr());
-
- nProcessError = aProcess.execute( (NAMESPACE_VOS(OProcess)::TProcessOption)
- (NAMESPACE_VOS(OProcess)::TOption_Detached) );
- bRet = nProcessError == NAMESPACE_VOS( OProcess )::E_None;
- }
-
- // when not startet, start programm with WPS
- if ( !bRet )
- {
- HOBJECT hObject = WinQueryObject( pFileName );
- if ( hObject )
- {
- if ( WinOpenObject( hObject, 0, FALSE ) )
- bRet = TRUE;
- }
- }
-
- return bRet;
-}
-
-// -----------------------------------------------------------------------
-
-BOOL SalSystem::AddRecentDoc( SalFrame* pFrame, const XubString& rFileName )
-{
- return FALSE;
-}
-
-// -----------------------------------------------------------------------
-
-String SalSystem::GetSummarySystemInfos( ULONG nFlags )
-{
- return String();
-}
-
diff --git a/vcl/os2/source/gdi/os2layout.cxx b/vcl/os2/source/gdi/os2layout.cxx
index 07fdb6c38927..dffb6a412f9b 100644
--- a/vcl/os2/source/gdi/os2layout.cxx
+++ b/vcl/os2/source/gdi/os2layout.cxx
@@ -107,7 +107,7 @@ inline int ImplOs2FontEntry::GetCachedGlyphWidth( int nCharCode ) const
class Os2Layout : public SalLayout
{
public:
- Os2Layout( HDC, ImplOs2FontData&, ImplOs2FontEntry& );
+ Os2Layout( HDC, const ImplOs2FontData&, ImplOs2FontEntry& );
virtual void InitFont() const;
void SetFontScale( float f ) { mfFontScale = f; }
float GetFontScale() const { return mfFontScale; }
@@ -118,7 +118,7 @@ protected:
int mnBaseAdv; // x-offset relative to Layout origin
float mfFontScale; // allows metrics emulation of huge font sizes
- ImplOs2FontData& mrOs2FontData;
+ const ImplOs2FontData& mrOs2FontData;
ImplOs2FontEntry& mrOs2FontEntry;
};
@@ -127,7 +127,7 @@ protected:
class Os2SalLayout : public Os2Layout
{
public:
- Os2SalLayout( HPS, BYTE nCharSet, ImplOs2FontData&, ImplOs2FontEntry& );
+ Os2SalLayout( HPS, BYTE nCharSet, const ImplOs2FontData&, ImplOs2FontEntry& );
virtual ~Os2SalLayout();
virtual bool LayoutText( ImplLayoutArgs& );
@@ -172,7 +172,7 @@ private:
// =======================================================================
-Os2Layout::Os2Layout( HPS hPS, ImplOs2FontData& rWFD, ImplOs2FontEntry& rWFE )
+Os2Layout::Os2Layout( HPS hPS, const ImplOs2FontData& rWFD, ImplOs2FontEntry& rWFE )
: mhPS( hPS ),
mnBaseAdv( 0 ),
mfFontScale( 1.0 ),
@@ -194,7 +194,7 @@ void Os2Layout::InitFont() const
// =======================================================================
Os2SalLayout::Os2SalLayout( HPS hPS, BYTE nCharSet,
- ImplOs2FontData& rOs2FontData, ImplOs2FontEntry& rOs2FontEntry )
+ const ImplOs2FontData& rOs2FontData, ImplOs2FontEntry& rOs2FontEntry )
: Os2Layout( hPS, rOs2FontData, rOs2FontEntry ),
mnGlyphCount( 0 ),
mnCharCount( 0 ),
@@ -950,7 +950,7 @@ SalLayout* Os2SalGraphics::GetTextLayout( ImplLayoutArgs& rArgs, int nFallbackLe
Os2SalLayout* pLayout = NULL;
DBG_ASSERT( mpOs2FontEntry[nFallbackLevel], "WinSalGraphics mpWinFontEntry==NULL");
- ImplOs2FontData& rFontFace = *mpOs2FontData[ nFallbackLevel ];
+ const ImplOs2FontData& rFontFace = *mpOs2FontData[ nFallbackLevel ];
ImplOs2FontEntry& rFontInstance = *mpOs2FontEntry[ nFallbackLevel ];
{
diff --git a/vcl/os2/source/gdi/salgdi.cxx b/vcl/os2/source/gdi/salgdi.cxx
index 04516cf1d0f5..b6616eb3a24b 100644
--- a/vcl/os2/source/gdi/salgdi.cxx
+++ b/vcl/os2/source/gdi/salgdi.cxx
@@ -242,6 +242,14 @@ BOOL Os2SalGraphics::unionClipRegion( long nX, long nY, long nWidth, long nHeigh
// -----------------------------------------------------------------------
+bool Os2SalGraphics::unionClipRegion( const ::basegfx::B2DPolyPolygon& )
+{
+ // TODO: implement and advertise OutDevSupport_B2DClip support
+ return false;
+}
+
+// -----------------------------------------------------------------------
+
void Os2SalGraphics::EndSetClipRegion()
{
#ifdef SAL_PRINTER_CLIPPATH
@@ -655,6 +663,25 @@ void Os2SalGraphics::drawPolyPolygon( ULONG nPoly, const ULONG* pPoints,
// -----------------------------------------------------------------------
+bool Os2SalGraphics::drawPolyPolygon( const ::basegfx::B2DPolyPolygon&, double /*fTransparency*/ )
+{
+ // TODO: implement and advertise OutDevSupport_B2DDraw support
+ return false;
+}
+
+// -----------------------------------------------------------------------
+
+bool Os2SalGraphics::drawPolyLine(
+ const basegfx::B2DPolygon& /*rPolygon*/,
+ const basegfx::B2DVector& /*rLineWidths*/,
+ basegfx::B2DLineJoin /*eLineJoin*/)
+{
+ // TODO: implement
+ return false;
+}
+
+// -----------------------------------------------------------------------
+
sal_Bool Os2SalGraphics::drawPolyLineBezier( ULONG nPoints, const SalPoint* pPtAry, const BYTE* pFlgAry )
{
return sal_False;
@@ -1010,7 +1037,9 @@ SystemGraphicsData Os2SalGraphics::GetGraphicsData() const
{
SystemGraphicsData aRes;
aRes.nSize = sizeof(aRes);
+#if 0
aRes.hDC = mhDC;
+#endif
return aRes;
}
diff --git a/vcl/os2/source/gdi/salgdi3.cxx b/vcl/os2/source/gdi/salgdi3.cxx
index e72ad9a0ad29..e6a5788b401c 100644
--- a/vcl/os2/source/gdi/salgdi3.cxx
+++ b/vcl/os2/source/gdi/salgdi3.cxx
@@ -52,7 +52,6 @@
#include <vcl/svapp.hxx>
#include <saldata.hxx>
#include <salgdi.h>
-#include <vcl/outfont.hxx>
#include <vcl/font.hxx>
#include <vcl/sallayout.hxx>
#include <tools/poly.hxx>
@@ -61,7 +60,9 @@
#include <tools/debug.hxx>
#include <saldata.hxx>
#include <salgdi.h>
-#include <outfont.hxx>
+#ifndef _SV_OUTFONT_HXX
+#include <vcl/outfont.hxx>
+#endif
#include <sallayout.h>
#include <tools/poly.hxx>
#include <basegfx/polygon/b2dpolygon.hxx>
@@ -400,7 +401,7 @@ sal_IntPtr ImplOs2FontData::GetFontId() const
// -----------------------------------------------------------------------
-void ImplOs2FontData::UpdateFromHPS( HPS hPS )
+void ImplOs2FontData::UpdateFromHPS( HPS hPS ) const
{
// short circuit if already initialized
if( mpUnicodeMap != NULL )
@@ -437,7 +438,7 @@ bool ImplOs2FontData::IsGSUBstituted( sal_Ucs cChar ) const
// -----------------------------------------------------------------------
-ImplFontCharMap* ImplOs2FontData::GetImplFontCharMap()
+ImplFontCharMap* ImplOs2FontData::GetImplFontCharMap() const