[Libreoffice-commits] .: vcl/aqua vcl/inc
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Wed Sep 19 14:55:37 PDT 2012
vcl/aqua/source/a11y/aqua11ytextattributeswrapper.mm | 2 -
vcl/aqua/source/dtrans/DropTarget.cxx | 9 +++++
vcl/aqua/source/dtrans/PictToBmpFlt.cxx | 16 ++++++++--
vcl/aqua/source/gdi/atsui/salatslayout.cxx | 8 ++---
vcl/aqua/source/gdi/coretext/salcoretextlayout.cxx | 4 +-
vcl/aqua/source/gdi/coretext/salgdi.cxx | 2 -
vcl/aqua/source/gdi/salbmp.cxx | 2 -
vcl/aqua/source/gdi/salgdicommon.cxx | 30 +++++++++++++------
vcl/aqua/source/gdi/salnativewidgets.cxx | 2 -
vcl/aqua/source/gdi/salprn.cxx | 2 -
vcl/aqua/source/window/salframe.cxx | 6 +--
vcl/aqua/source/window/salframeview.mm | 6 +--
vcl/inc/aqua/atsui/salgdi.h | 8 ++---
vcl/inc/aqua/common.h | 2 -
vcl/inc/aqua/coretext/salcoretextlayout.hxx | 4 +-
vcl/inc/aqua/coretext/salgdi.h | 12 +++++--
vcl/inc/aqua/salframe.h | 2 -
vcl/inc/aqua/salgdicommon.hxx | 4 +-
18 files changed, 77 insertions(+), 44 deletions(-)
New commits:
commit 25f935bfb44b87271eb11e719c4d1fb8624bdd02
Author: Tor Lillqvist <tml at iki.fi>
Date: Thu Sep 20 00:54:36 2012 +0300
64-bit fixes
Change-Id: I268ccab01e030535f04ef1256dc702b07cbc6611
diff --git a/vcl/aqua/source/a11y/aqua11ytextattributeswrapper.mm b/vcl/aqua/source/a11y/aqua11ytextattributeswrapper.mm
index 31978a6..4b38b15 100644
--- a/vcl/aqua/source/a11y/aqua11ytextattributeswrapper.mm
+++ b/vcl/aqua/source/a11y/aqua11ytextattributeswrapper.mm
@@ -107,7 +107,7 @@ using namespace ::rtl;
+(void)addColor:(sal_Int32)salColor forAttribute:(NSString *)attribute andRange:(NSRange)range toString:(NSMutableAttributedString *)string {
if ( salColor != -1 ) {
- float elements[] = { salColor & 0x00ff0000, salColor & 0x0000ff00, salColor & 0x000000ff };
+ CGFloat elements[] = { salColor & 0x00ff0000, salColor & 0x0000ff00, salColor & 0x000000ff };
CGColorRef color = CGColorCreate ( CGColorSpaceCreateWithName ( kCGColorSpaceGenericRGB ), elements );
[ string addAttribute: attribute value: (id) color range: range ];
CGColorRelease ( color );
diff --git a/vcl/aqua/source/dtrans/DropTarget.cxx b/vcl/aqua/source/dtrans/DropTarget.cxx
index bb46e21..c799d92 100644
--- a/vcl/aqua/source/dtrans/DropTarget.cxx
+++ b/vcl/aqua/source/dtrans/DropTarget.cxx
@@ -296,6 +296,7 @@ NSDragOperation DropTarget::draggingUpdated(id sender)
//NSLog(@"Drag update: Source actions: %x proposed action %x selected action %x", mDragSourceSupportedActions, currentAction, mSelectedDropAction);
}
+#ifndef __LP64__
// Weird but it appears as if there is no method in Cocoa
// to create a kThemeCopyArrowCursor hence we have to use
// Carbon to do it
@@ -305,7 +306,9 @@ NSDragOperation DropTarget::draggingUpdated(id sender)
SetThemeCursor(kThemeCopyArrowCursor);
else
SetThemeCursor(kThemeArrowCursor);
-
+#else
+ // FIXME: SetThemeCursor replacement?
+#endif
return dragOp;
}
@@ -316,7 +319,9 @@ void DropTarget::draggingExited(id /*sender*/)
fire_dragExit(dte);
mDragSourceSupportedActions = DNDConstants::ACTION_NONE;
mSelectedDropAction = DNDConstants::ACTION_NONE;
+#ifndef __LP64__
SetThemeCursor(kThemeArrowCursor);
+#endif
}
@@ -370,7 +375,9 @@ void DropTarget::concludeDragOperation(id /*sender*/)
mDragSourceSupportedActions = DNDConstants::ACTION_NONE;
mSelectedDropAction = DNDConstants::ACTION_NONE;
mXCurrentDragClipboard = uno::Reference<XClipboard>();
+#ifndef __LP64__
SetThemeCursor(kThemeArrowCursor);
+#endif
}
diff --git a/vcl/aqua/source/dtrans/PictToBmpFlt.cxx b/vcl/aqua/source/dtrans/PictToBmpFlt.cxx
index 8a545da..0bbb33b 100644
--- a/vcl/aqua/source/dtrans/PictToBmpFlt.cxx
+++ b/vcl/aqua/source/dtrans/PictToBmpFlt.cxx
@@ -39,6 +39,11 @@ bool PICTtoBMP(com::sun::star::uno::Sequence<sal_Int8>& aPict,
bool result = false;
+#ifdef __LP64__
+ // FIXME
+ (void) aPict;
+ (void) aBmp;
+#else
ComponentInstance bmpExporter;
if (OpenADefaultComponent(GraphicsExporterComponentType,
kQTFileTypeBMP,
@@ -78,7 +83,7 @@ bool PICTtoBMP(com::sun::star::uno::Sequence<sal_Int8>& aPict,
DisposeHandle(hPict);
DisposeHandle(hBmp);
CloseComponent(bmpExporter);
-
+#endif
return result;
}
@@ -103,12 +108,17 @@ bool BMPtoPICT(com::sun::star::uno::Sequence<sal_Int8>& aBmp,
bool result = false;
Handle hBmp;
- ComponentInstance pictExporter;
if ((PtrToHand(aBmp.getArray(), &hBmp, aBmp.getLength()) != noErr))
{
return result;
}
+#ifdef __LP64__
+ // FIXME
+ (void) aPict;
+#else
+ ComponentInstance pictExporter;
+
if (OpenADefaultComponent(GraphicsImporterComponentType,
kQTFileTypeBMP,
&pictExporter) != noErr)
@@ -145,7 +155,7 @@ bool BMPtoPICT(com::sun::star::uno::Sequence<sal_Int8>& aBmp,
DisposeHandle(hBmp);
CloseComponent(pictExporter);
-
+#endif
return result;
}
diff --git a/vcl/aqua/source/gdi/atsui/salatslayout.cxx b/vcl/aqua/source/gdi/atsui/salatslayout.cxx
index 84e6ff2..4145dbf 100644
--- a/vcl/aqua/source/gdi/atsui/salatslayout.cxx
+++ b/vcl/aqua/source/gdi/atsui/salatslayout.cxx
@@ -63,9 +63,9 @@ public:
sal_Int32* pGlyphAdvances, int* pCharIndexes ) const;
virtual long GetTextWidth() const;
- virtual long FillDXArray( long* pDXArray ) const;
+ virtual long FillDXArray( sal_Int32* pDXArray ) const;
virtual int GetTextBreak( long nMaxWidth, long nCharExtra, int nFactor ) const;
- virtual void GetCaretPositions( int nArraySize, long* pCaretXArray ) const;
+ virtual void GetCaretPositions( int nArraySize, sal_Int32* pCaretXArray ) const;
virtual bool GetGlyphOutlines( SalGraphics&, PolyPolyVector& ) const;
virtual bool GetBoundRect( SalGraphics&, Rectangle& ) const;
@@ -683,7 +683,7 @@ long ATSLayout::GetTextWidth() const
*
* @return : typographical width of the complete text layout
**/
-long ATSLayout::FillDXArray( long* pDXArray ) const
+long ATSLayout::FillDXArray( sal_Int32* pDXArray ) const
{
// short circuit requests which don't need full details
if( !pDXArray )
@@ -809,7 +809,7 @@ int ATSLayout::GetTextBreak( long nMaxWidth, long nCharExtra, int nFactor ) cons
*
* @return : none
**/
-void ATSLayout::GetCaretPositions( int nMaxIndex, long* pCaretXArray ) const
+void ATSLayout::GetCaretPositions( int nMaxIndex, sal_Int32* pCaretXArray ) const
{
DBG_ASSERT( ((nMaxIndex>0)&&!(nMaxIndex&1)),
"ATSLayout::GetCaretPositions() : invalid number of caret pairs requested");
diff --git a/vcl/aqua/source/gdi/coretext/salcoretextlayout.cxx b/vcl/aqua/source/gdi/coretext/salcoretextlayout.cxx
index 07ff289..ff64207 100644
--- a/vcl/aqua/source/gdi/coretext/salcoretextlayout.cxx
+++ b/vcl/aqua/source/gdi/coretext/salcoretextlayout.cxx
@@ -134,7 +134,7 @@ void CoreTextLayout::DrawText( SalGraphics& rGraphics ) const
// not needed. CoreText manage fallback directly
void CoreTextLayout::DropGlyph( int /*nStart*/ ) {}
-long CoreTextLayout::FillDXArray( long* pDXArray ) const
+long CoreTextLayout::FillDXArray( sal_Int32* pDXArray ) const
{
msgs_debug(layout,"-->");
// short circuit requests which don't need full details
@@ -188,7 +188,7 @@ bool CoreTextLayout::GetBoundRect( SalGraphics& rGraphics, Rectangle& rVCLRect )
return true;
}
-void CoreTextLayout::GetCaretPositions( int max_index, long* caret_position) const
+void CoreTextLayout::GetCaretPositions( int max_index, sal_Int32* caret_position) const
{
msgs_debug(layout,"max_index %d -->", max_index);
int local_max = max_index < m_chars_count * 2 ? max_index : m_chars_count;
diff --git a/vcl/aqua/source/gdi/coretext/salgdi.cxx b/vcl/aqua/source/gdi/coretext/salgdi.cxx
index 7e822e0..57f72bd 100644
--- a/vcl/aqua/source/gdi/coretext/salgdi.cxx
+++ b/vcl/aqua/source/gdi/coretext/salgdi.cxx
@@ -167,7 +167,7 @@ const ImplFontCharMap* AquaSalGraphics::GetImplFontCharMap() const
{
if( !m_style )
{
- return false;
+ return NULL;
}
CoreTextPhysicalFontFace* font_face = m_style->GetFontFace();
if( !font_face)
diff --git a/vcl/aqua/source/gdi/salbmp.cxx b/vcl/aqua/source/gdi/salbmp.cxx
index 5323fb7..f14e1d5 100644
--- a/vcl/aqua/source/gdi/salbmp.cxx
+++ b/vcl/aqua/source/gdi/salbmp.cxx
@@ -781,7 +781,7 @@ CGImageRef AquaSalBitmap::CreateWithMask( const AquaSalBitmap& rMask,
CFRelease( xMask );
CGDataProviderRef xDataProvider( CGDataProviderCreateWithData( NULL,
pMaskMem, nHeight * nMaskBytesPerRow, &CFRTLFree ) );
- static const float* pDecode = NULL;
+ static const CGFloat* pDecode = NULL;
xMask = CGImageMaskCreate( nWidth, nHeight, 8, 8, nMaskBytesPerRow, xDataProvider, pDecode, false );
CFRelease( xDataProvider );
CFRelease( xMaskContext );
diff --git a/vcl/aqua/source/gdi/salgdicommon.cxx b/vcl/aqua/source/gdi/salgdicommon.cxx
index 72f97ed..8ae6c9c 100644
--- a/vcl/aqua/source/gdi/salgdicommon.cxx
+++ b/vcl/aqua/source/gdi/salgdicommon.cxx
@@ -1,3 +1,5 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+
#include <sal/types.h>
#include <osl/file.hxx>
@@ -118,7 +120,7 @@ static void AddPolyPolygonToPath( CGMutablePathRef xPath,
sal_Bool AquaSalGraphics::CreateFontSubset( const rtl::OUString& rToFile,
const PhysicalFontFace* pFontData,
- long* pGlyphIDs, sal_uInt8* pEncoding,
+ sal_Int32* pGlyphIDs, sal_uInt8* pEncoding,
sal_Int32* pGlyphWidths, int nGlyphCount,
FontSubsetInfo& rInfo )
{
@@ -148,8 +150,16 @@ sal_Bool AquaSalGraphics::CreateFontSubset( const rtl::OUString& rToFile,
// make the subsetter provide the requested subset
FILE* pOutFile = fopen( aToFile.getStr(), "wb" );
+#ifdef __LP64__
+ long *pLongGlyphIDs = (long*)alloca(nGlyphCount * sizeof(long));
+ for (int i = 0; i < nGlyphCount; i++)
+ pLongGlyphIDs[i] = pGlyphIDs[i];
+ bool bRC = rInfo.CreateFontSubset( FontSubsetInfo::TYPE1_PFB, pOutFile, NULL,
+ pLongGlyphIDs, pEncoding, nGlyphCount, pGlyphWidths );
+#else
bool bRC = rInfo.CreateFontSubset( FontSubsetInfo::TYPE1_PFB, pOutFile, NULL,
pGlyphIDs, pEncoding, nGlyphCount, pGlyphWidths );
+#endif
fclose( pOutFile );
return bRC;
}
@@ -798,7 +808,7 @@ bool AquaSalGraphics::drawPolyPolygon( const ::basegfx::B2DPolyPolygon& rPolyPol
return true;
}
-void AquaSalGraphics::drawPolyPolygon( sal_uLong nPolyCount, const sal_uLong *pPoints, PCONSTSALPOINT *ppPtAry )
+void AquaSalGraphics::drawPolyPolygon( sal_uInt32 nPolyCount, const sal_uInt32 *pPoints, PCONSTSALPOINT *ppPtAry )
{
if( nPolyCount <= 0 )
return;
@@ -957,7 +967,7 @@ sal_Bool AquaSalGraphics::drawPolygonBezier( sal_uLong, const SalPoint*, const s
return sal_False;
}
-sal_Bool AquaSalGraphics::drawPolyPolygonBezier( sal_uLong, const sal_uLong*,
+sal_Bool AquaSalGraphics::drawPolyPolygonBezier( sal_uInt32, const sal_uInt32*,
const SalPoint* const*, const sal_uInt8* const* )
{
return sal_False;
@@ -1106,15 +1116,15 @@ SalColor AquaSalGraphics::getPixel( long nX, long nY )
return nSalColor;
}
-void AquaSalGraphics::GetResolution( long& rDPIX, long& rDPIY )
+void AquaSalGraphics::GetResolution( sal_Int32& rDPIX, sal_Int32& rDPIY )
{
if( !mnRealDPIY )
{
initResolution( (mbWindow && mpFrame) ? mpFrame->mpWindow : nil );
}
- rDPIX = static_cast<long>(mfFakeDPIScale * mnRealDPIX);
- rDPIY = static_cast<long>(mfFakeDPIScale * mnRealDPIY);
+ rDPIX = static_cast<sal_Int32>(mfFakeDPIScale * mnRealDPIX);
+ rDPIY = static_cast<sal_Int32>(mfFakeDPIScale * mnRealDPIY);
}
void AquaSalGraphics::ImplDrawPixel( long nX, long nY, const RGBAColor& rColor )
@@ -1234,7 +1244,7 @@ void AquaSalGraphics::invert( long nX, long nY, long nWidth, long nHeight, SalIn
if ( nFlags & SAL_INVERT_TRACKFRAME )
{
- const float dashLengths[2] = { 4.0, 4.0 }; // for drawing dashed line
+ const CGFloat dashLengths[2] = { 4.0, 4.0 }; // for drawing dashed line
CGContextSetBlendMode( mrContext, kCGBlendModeDifference );
CGContextSetRGBStrokeColor ( mrContext, 1.0, 1.0, 1.0, 1.0 );
CGContextSetLineDash ( mrContext, 0, dashLengths, 2 );
@@ -1269,7 +1279,7 @@ void AquaSalGraphics::invert( sal_uLong nPoints, const SalPoint* pPtAry, SalInv
CGContextAddLines ( mrContext, CGpoints, nPoints );
if ( nSalFlags & SAL_INVERT_TRACKFRAME )
{
- const float dashLengths[2] = { 4.0, 4.0 }; // for drawing dashed line
+ const CGFloat dashLengths[2] = { 4.0, 4.0 }; // for drawing dashed line
CGContextSetBlendMode( mrContext, kCGBlendModeDifference );
CGContextSetRGBStrokeColor ( mrContext, 1.0, 1.0, 1.0, 1.0 );
CGContextSetLineDash ( mrContext, 0, dashLengths, 2 );
@@ -1296,7 +1306,7 @@ void AquaSalGraphics::invert( sal_uLong nPoints, const SalPoint* pPtAry, SalInv
void AquaSalGraphics::Pattern50Fill()
{
- static const float aFillCol[4] = { 1,1,1,1 };
+ static const CGFloat aFillCol[4] = { 1,1,1,1 };
static const CGPatternCallbacks aCallback = { 0, &DrawPattern50, NULL };
if( ! GetSalData()->mxP50Space )
{
@@ -1647,3 +1657,5 @@ bool XorEmulation::UpdateTarget()
// TODO: return FALSE if target was not changed
return true;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/vcl/aqua/source/gdi/salnativewidgets.cxx b/vcl/aqua/source/gdi/salnativewidgets.cxx
index bb7392e..b21cf2b 100644
--- a/vcl/aqua/source/gdi/salnativewidgets.cxx
+++ b/vcl/aqua/source/gdi/salnativewidgets.cxx
@@ -709,7 +709,7 @@ sal_Bool AquaSalGraphics::drawNativeControl(ControlType nType,
// Perhaps some other HIThemeButtonDrawInfo setting would do the trick ?
CGContextSetShouldAntialias( mrContext, true );
- float aGrey[] = { 0.45, 0.45, 0.45, 1.0 };
+ CGFloat aGrey[] = { 0.45, 0.45, 0.45, 1.0 };
CGContextSetFillColor( mrContext, aGrey );
CGContextBeginPath( mrContext );
float x = rc.origin.x + rc.size.width;
diff --git a/vcl/aqua/source/gdi/salprn.cxx b/vcl/aqua/source/gdi/salprn.cxx
index 384cf3a..f7ddea8 100644
--- a/vcl/aqua/source/gdi/salprn.cxx
+++ b/vcl/aqua/source/gdi/salprn.cxx
@@ -343,7 +343,7 @@ void AquaSalInfoPrinter::GetPageInfo( const ImplJobSetup*,
{
if( mpPrintInfo )
{
- long nDPIX = 72, nDPIY = 72;
+ sal_Int32 nDPIX = 72, nDPIY = 72;
mpGraphics->GetResolution( nDPIX, nDPIY );
const double fXScaling = static_cast<double>(nDPIX)/72.0,
fYScaling = static_cast<double>(nDPIY)/72.0;
diff --git a/vcl/aqua/source/window/salframe.cxx b/vcl/aqua/source/window/salframe.cxx
index b427e2e..924210d 100644
--- a/vcl/aqua/source/window/salframe.cxx
+++ b/vcl/aqua/source/window/salframe.cxx
@@ -1199,7 +1199,7 @@ static Color getColor( NSColor* pSysColor, const Color& rDefault, NSWindow* pWin
NSColor* pRBGColor = [pSysColor colorUsingColorSpaceName: NSDeviceRGBColorSpace device: [pWin deviceDescription]];
if( pRBGColor )
{
- float r = 0, g = 0, b = 0, a = 0;
+ CGFloat r = 0, g = 0, b = 0, a = 0;
[pRBGColor getRed: &r green: &g blue: &b alpha: &a];
aRet = Color( int(r*255.999), int(g*255.999), int(b*255.999) );
/*
@@ -1227,7 +1227,7 @@ static Font getFont( NSFont* pFont, long nDPIY, const Font& rDefault )
return aResult;
}
-void AquaSalFrame::getResolution( long& o_rDPIX, long& o_rDPIY )
+void AquaSalFrame::getResolution( sal_Int32& o_rDPIX, sal_Int32& o_rDPIY )
{
if( ! mpGraphics )
{
@@ -1271,7 +1271,7 @@ void AquaSalFrame::UpdateSettings( AllSettings& rSettings )
// get the system font settings
Font aAppFont = aStyleSettings.GetAppFont();
- long nDPIX = 72, nDPIY = 72;
+ sal_Int32 nDPIX = 72, nDPIY = 72;
getResolution( nDPIX, nDPIY );
aAppFont = getFont( [NSFont systemFontOfSize: 0], nDPIY, aAppFont );
diff --git a/vcl/aqua/source/window/salframeview.mm b/vcl/aqua/source/window/salframeview.mm
index 74f1685..b206357 100644
--- a/vcl/aqua/source/window/salframeview.mm
+++ b/vcl/aqua/source/window/salframeview.mm
@@ -133,9 +133,9 @@ static const struct ExceptionalKey
static AquaSalFrame* getMouseContainerFrame()
{
- int nWindows = 0;
+ NSInteger nWindows = 0;
NSCountWindows( &nWindows );
- int* pWindows = (int*)alloca( nWindows * sizeof(int) );
+ NSInteger* pWindows = (NSInteger*)alloca( nWindows * sizeof(NSInteger) );
// note: NSWindowList is supposed to be in z-order front to back
NSWindowList( nWindows, pWindows );
AquaSalFrame* pDispatchFrame = NULL;
@@ -1589,7 +1589,7 @@ private:
return nil;
}
-- (unsigned int)characterIndexForPoint:(NSPoint)thePoint
+- (NSUInteger)characterIndexForPoint:(NSPoint)thePoint
{
(void)thePoint;
// FIXME
diff --git a/vcl/inc/aqua/atsui/salgdi.h b/vcl/inc/aqua/atsui/salgdi.h
index 7580f4f..19fe1f4 100644
--- a/vcl/inc/aqua/atsui/salgdi.h
+++ b/vcl/inc/aqua/atsui/salgdi.h
@@ -181,11 +181,11 @@ public:
virtual void drawRect( long nX, long nY, long nWidth, long nHeight );
virtual void drawPolyLine( sal_uLong nPoints, const SalPoint* pPtAry );
virtual void drawPolygon( sal_uLong nPoints, const SalPoint* pPtAry );
- virtual void drawPolyPolygon( sal_uLong nPoly, const sal_uLong* pPoints, PCONSTSALPOINT* pPtAry );
+ virtual void drawPolyPolygon( sal_uInt32 nPoly, const sal_uLong* pPoints, PCONSTSALPOINT* pPtAry );
virtual bool drawPolyPolygon( const ::basegfx::B2DPolyPolygon&, double fTransparency );
virtual sal_Bool drawPolyLineBezier( sal_uLong nPoints, const SalPoint* pPtAry, const sal_uInt8* pFlgAry );
virtual sal_Bool drawPolygonBezier( sal_uLong nPoints, const SalPoint* pPtAry, const sal_uInt8* pFlgAry );
- virtual sal_Bool drawPolyPolygonBezier( sal_uLong nPoly, const sal_uLong* pPoints, const SalPoint* const* pPtAry, const sal_uInt8* const* pFlgAry );
+ virtual sal_Bool drawPolyPolygonBezier( sal_uInt32 nPoly, const sal_uInt32* pPoints, const SalPoint* const* pPtAry, const sal_uInt8* const* pFlgAry );
virtual bool drawPolyLine( const ::basegfx::B2DPolygon&, double fTransparency, const ::basegfx::B2DVector& rLineWidths, basegfx::B2DLineJoin );
// CopyArea --> No RasterOp, but ClipRegion
@@ -234,7 +234,7 @@ public:
Rectangle &rNativeBoundingRegion, Rectangle &rNativeContentRegion );
// get device resolution
- virtual void GetResolution( long& rDPIX, long& rDPIY );
+ virtual void GetResolution( sal_Int32& rDPIX, sal_Int32& rDPIY );
// get the depth of the device
virtual sal_uInt16 GetBitCount() const;
// get the width of the device
@@ -292,7 +292,7 @@ public:
// as "undefined character"
virtual sal_Bool CreateFontSubset( const rtl::OUString& rToFile,
const PhysicalFontFace* pFont,
- long* pGlyphIDs,
+ sal_Int32* pGlyphIDs,
sal_uInt8* pEncoding,
sal_Int32* pWidths,
int nGlyphs,
diff --git a/vcl/inc/aqua/common.h b/vcl/inc/aqua/common.h
index c3789a5..ba19ff2 100644
--- a/vcl/inc/aqua/common.h
+++ b/vcl/inc/aqua/common.h
@@ -26,6 +26,6 @@
// fprintf(stderr, "%s::%s(%p:%04.4x)\n", this, #c, __func__, 0, __VA_ARGS__ )
#define msgs_debug(c,f,...) \
- fprintf(stderr, "%s::%s(%p:%4.4u)" f "\n", #c, __func__, this, ((unsigned int)pthread_self() & 8191), ##__VA_ARGS__ );
+ fprintf(stderr, "%s::%s(%p:%4.4u)" f "\n", #c, __func__, this, (unsigned int)((sal_uInt64)pthread_self() & 0x1FFF), ##__VA_ARGS__ );
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/vcl/inc/aqua/coretext/salcoretextlayout.hxx b/vcl/inc/aqua/coretext/salcoretextlayout.hxx
index e427522..7574ecb 100644
--- a/vcl/inc/aqua/coretext/salcoretextlayout.hxx
+++ b/vcl/inc/aqua/coretext/salcoretextlayout.hxx
@@ -19,9 +19,9 @@ public:
virtual void AdjustLayout( ImplLayoutArgs& );
virtual void DrawText( SalGraphics& ) const;
virtual void DropGlyph( int nStart );
- virtual long FillDXArray( long* pDXArray ) const;
+ virtual long FillDXArray( sal_Int32* pDXArray ) const;
virtual bool GetBoundRect( SalGraphics&, Rectangle& ) const;
- virtual void GetCaretPositions( int nArraySize, long* pCaretXArray ) const;
+ virtual void GetCaretPositions( int nArraySize, sal_Int32* pCaretXArray ) const;
virtual bool GetGlyphOutlines( SalGraphics&, PolyPolyVector& ) const;
virtual int GetNextGlyphs( int nLen, sal_GlyphId* pGlyphs, Point& rPos, int&,
sal_Int32* pGlyphAdvances, int* pCharIndexes ) const;
diff --git a/vcl/inc/aqua/coretext/salgdi.h b/vcl/inc/aqua/coretext/salgdi.h
index f3f4462..e6101aa 100644
--- a/vcl/inc/aqua/coretext/salgdi.h
+++ b/vcl/inc/aqua/coretext/salgdi.h
@@ -84,7 +84,9 @@ public:
bool CheckContext();
CGContextRef GetContext();
void UpdateWindow( NSRect& ); // delivered in NSView coordinates
+#if !defined(__LP64__) && !defined(NS_BUILD_32_LIKE_64)
void RefreshRect( const CGRect& );
+#endif
void RefreshRect( const NSRect& );
void RefreshRect(float lX, float lY, float lWidth, float lHeight);
@@ -102,11 +104,11 @@ public:
virtual void drawRect( long nX, long nY, long nWidth, long nHeight );
virtual void drawPolyLine( sal_uLong nPoints, const SalPoint* pPtAry );
virtual void drawPolygon( sal_uLong nPoints, const SalPoint* pPtAry );
- virtual void drawPolyPolygon( sal_uLong nPoly, const sal_uLong* pPoints, PCONSTSALPOINT* pPtAry );
+ virtual void drawPolyPolygon( sal_uInt32 nPoly, const sal_uInt32* pPoints, PCONSTSALPOINT* pPtAry );
virtual bool drawPolyPolygon( const ::basegfx::B2DPolyPolygon&, double fTransparency );
virtual sal_Bool drawPolyLineBezier( sal_uLong nPoints, const SalPoint* pPtAry, const sal_uInt8* pFlgAry );
virtual sal_Bool drawPolygonBezier( sal_uLong nPoints, const SalPoint* pPtAry, const sal_uInt8* pFlgAry );
- virtual sal_Bool drawPolyPolygonBezier( sal_uLong nPoly, const sal_uLong* pPoints,
+ virtual sal_Bool drawPolyPolygonBezier( sal_uInt32 nPoly, const sal_uInt32* pPoints,
const SalPoint* const* pPtAry, const sal_uInt8* const* pFlgAry );
virtual bool drawPolyLine( const ::basegfx::B2DPolygon&, double fTransparency,
const ::basegfx::B2DVector& rLineWidths, basegfx::B2DLineJoin );
@@ -159,7 +161,7 @@ public:
Rectangle &rNativeContentRegion );
// get device resolution
- virtual void GetResolution( long& rDPIX, long& rDPIY );
+ virtual void GetResolution( sal_Int32& rDPIX, sal_Int32& rDPIY );
// get the depth of the device
virtual sal_uInt16 GetBitCount() const;
// get the width of the device
@@ -218,7 +220,7 @@ public:
// as "undefined character"
virtual sal_Bool CreateFontSubset( const rtl::OUString& rToFile,
const PhysicalFontFace* pFont,
- long* pGlyphIDs,
+ sal_Int32* pGlyphIDs,
sal_uInt8* pEncoding,
sal_Int32* pWidths,
int nGlyphs,
@@ -282,10 +284,12 @@ private:
bool* pJustCFF );
};
+#if !defined(__LP64__) && !defined(NS_BUILD_32_LIKE_64)
inline void AquaSalGraphics::RefreshRect( const CGRect& rRect )
{
RefreshRect( rRect.origin.x, rRect.origin.y, rRect.size.width, rRect.size.height );
}
+#endif
inline void AquaSalGraphics::RefreshRect( const NSRect& rRect )
{
diff --git a/vcl/inc/aqua/salframe.h b/vcl/inc/aqua/salframe.h
index e51035a..5d4142b 100644
--- a/vcl/inc/aqua/salframe.h
+++ b/vcl/inc/aqua/salframe.h
@@ -184,7 +184,7 @@ public:
NSView* getView() const { return mpView; }
unsigned int getStyleMask() const { return mnStyleMask; }
- void getResolution( long& o_rDPIX, long& o_rDPIY );
+ void getResolution( sal_Int32& o_rDPIX, sal_Int32& o_rDPIY );
// actually the follwing methods do the same thing: flipping y coordinates
// but having two of them makes clearer what the coordinate system
diff --git a/vcl/inc/aqua/salgdicommon.hxx b/vcl/inc/aqua/salgdicommon.hxx
index 6d674fd..8777286 100644
--- a/vcl/inc/aqua/salgdicommon.hxx
+++ b/vcl/inc/aqua/salgdicommon.hxx
@@ -9,11 +9,11 @@ class RGBAColor
public:
RGBAColor( SalColor );
RGBAColor( float fRed, float fGreen, float fBlue, float fAlpha ); //NOTUSEDYET
- const float* AsArray() const { return m_fRGBA; }
+ const CGFloat* AsArray() const { return m_fRGBA; }
bool IsVisible() const { return m_fRGBA[3] > 0; }
void SetAlpha( float fAlpha ) { m_fRGBA[3] = fAlpha; }
private:
- float m_fRGBA[4]; // red, green, blue, alpha
+ CGFloat m_fRGBA[4]; // red, green, blue, alpha
};
inline RGBAColor::RGBAColor( SalColor nSalColor )
More information about the Libreoffice-commits
mailing list