Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
305ccd4f
Kaydet (Commit)
305ccd4f
authored
Ara 22, 2012
tarafından
Tor Lillqvist
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
WaE: non-constant-expression cannot be narrowed
Change-Id: I401fd149e62d74a96edfc2a7e5105fb2cc95f0c7
üst
bbfd7f0d
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
24 additions
and
24 deletions
+24
-24
salbmp.cxx
vcl/ios/source/gdi/salbmp.cxx
+2
-2
salcoretextstyle.cxx
vcl/ios/source/gdi/salcoretextstyle.cxx
+1
-1
salgdicommon.cxx
vcl/ios/source/gdi/salgdicommon.cxx
+17
-17
salvd.cxx
vcl/ios/source/gdi/salvd.cxx
+1
-1
salframe.cxx
vcl/ios/source/window/salframe.cxx
+1
-1
salobj.cxx
vcl/ios/source/window/salobj.cxx
+2
-2
No files found.
vcl/ios/source/gdi/salbmp.cxx
Dosyayı görüntüle @
305ccd4f
...
...
@@ -88,7 +88,7 @@ bool IosSalBitmap::Create( CGLayerRef xLayer, int nBitmapBits,
CreateContext
();
// copy layer content into the bitmap buffer
const
CGPoint
aSrcPoint
=
{
-
nX
,
-
nY
};
const
CGPoint
aSrcPoint
=
{
static_cast
<
CGFloat
>
(
-
nX
),
static_cast
<
CGFloat
>
(
-
nY
)
};
::
CGContextDrawLayerAtPoint
(
mxGraphicContext
,
aSrcPoint
,
xLayer
);
return
true
;
}
...
...
@@ -731,7 +731,7 @@ CGImageRef IosSalBitmap::CreateCroppedImage( int nX, int nY, int nNewWidth, int
else
{
nY
=
mnHeight
-
(
nY
+
nNewHeight
);
// adjust for y-mirrored context
const
CGRect
aCropRect
=
{
{
nX
,
nY
},
{
nNewWidth
,
nNewHeight
}
};
const
CGRect
aCropRect
=
{
{
static_cast
<
CGFloat
>
(
nX
),
static_cast
<
CGFloat
>
(
nY
)},
{
static_cast
<
CGFloat
>
(
nNewWidth
),
static_cast
<
CGFloat
>
(
nNewHeight
)
}
};
xCroppedImage
=
CGImageCreateWithImageInRect
(
mxCachedImage
,
aCropRect
);
}
...
...
vcl/ios/source/gdi/salcoretextstyle.cxx
Dosyayı görüntüle @
305ccd4f
...
...
@@ -98,7 +98,7 @@ void CoreTextStyleInfo::SetColor(SalColor color)
msgs_debug
(
style
,
"r:%d g:%d b:%d -->"
,
SALCOLOR_RED
(
color
),
SALCOLOR_GREEN
(
color
),
SALCOLOR_BLUE
(
color
));
SafeCFRelease
(
m_color
);
CGColorSpaceRef
rgb_space
=
CGColorSpaceCreateDeviceRGB
();
CGFloat
c
[]
=
{
SALCOLOR_RED
(
color
)
/
255.0
,
SALCOLOR_GREEN
(
color
)
/
255.0
,
SALCOLOR_BLUE
(
color
)
/
255.0
,
1.0
};
CGFloat
c
[]
=
{
SALCOLOR_RED
(
color
)
/
255.0
f
,
SALCOLOR_GREEN
(
color
)
/
255.0
f
,
SALCOLOR_BLUE
(
color
)
/
255.0
f
,
1.0
};
m_color
=
CGColorCreate
(
rgb_space
,
c
);
CGColorSpaceRelease
(
rgb_space
);
msgs_debug
(
style
,
"color=%p <--"
,
m_color
);
...
...
vcl/ios/source/gdi/salgdicommon.cxx
Dosyayı görüntüle @
305ccd4f
...
...
@@ -314,7 +314,7 @@ void IosSalGraphics::copyBits( const SalTwoRect *pPosAry, SalGraphics *pSrcGraph
DBG_ASSERT
(
pSrc
->
mxLayer
!=
NULL
,
"IosSalGraphics::copyBits() from non-layered graphics"
);
const
CGPoint
aDstPoint
=
{
+
pPosAry
->
mnDestX
-
pPosAry
->
mnSrcX
,
pPosAry
->
mnDestY
-
pPosAry
->
mnSrcY
};
const
CGPoint
aDstPoint
=
{
static_cast
<
CGFloat
>
(
+
pPosAry
->
mnDestX
-
pPosAry
->
mnSrcX
),
static_cast
<
CGFloat
>
(
pPosAry
->
mnDestY
-
pPosAry
->
mnSrcY
)
};
if
(
(
pPosAry
->
mnSrcWidth
==
pPosAry
->
mnDestWidth
&&
pPosAry
->
mnSrcHeight
==
pPosAry
->
mnDestHeight
)
&&
(
!
mnBitmapDepth
||
(
aDstPoint
.
x
+
pSrc
->
mnWidth
)
<=
mnWidth
)
)
// workaround a Quartz crasher
...
...
@@ -330,7 +330,7 @@ void IosSalGraphics::copyBits( const SalTwoRect *pPosAry, SalGraphics *pSrcGraph
}
}
CGContextSaveGState
(
xCopyContext
);
const
CGRect
aDstRect
=
{
{
pPosAry
->
mnDestX
,
pPosAry
->
mnDestY
},
{
pPosAry
->
mnDestWidth
,
pPosAry
->
mnDestHeight
}
};
const
CGRect
aDstRect
=
{
{
static_cast
<
CGFloat
>
(
pPosAry
->
mnDestX
),
static_cast
<
CGFloat
>
(
pPosAry
->
mnDestY
)
},
{
static_cast
<
CGFloat
>
(
pPosAry
->
mnDestWidth
),
static_cast
<
CGFloat
>
(
pPosAry
->
mnDestHeight
)
}
};
CGContextClipToRect
(
xCopyContext
,
aDstRect
);
// draw at new destination
...
...
@@ -447,10 +447,10 @@ void IosSalGraphics::copyArea( long nDstX, long nDstY,long nSrcX, long nSrcY,
CGLayerRef
xSrcLayer
=
mxLayer
;
// TODO: if( mnBitmapDepth > 0 )
{
const
CGSize
aSrcSize
=
{
nSrcWidth
,
nSrcHeight
};
const
CGSize
aSrcSize
=
{
static_cast
<
CGFloat
>
(
nSrcWidth
),
static_cast
<
CGFloat
>
(
nSrcHeight
)
};
xSrcLayer
=
::
CGLayerCreateWithContext
(
xCopyContext
,
aSrcSize
,
NULL
);
const
CGContextRef
xSrcContext
=
CGLayerGetContext
(
xSrcLayer
);
CGPoint
aSrcPoint
=
{
-
nSrcX
,
-
nSrcY
};
CGPoint
aSrcPoint
=
{
static_cast
<
CGFloat
>
(
-
nSrcX
),
static_cast
<
CGFloat
>
(
-
nSrcY
)
};
if
(
IsFlipped
()
)
{
::
CGContextTranslateCTM
(
xSrcContext
,
0
,
+
nSrcHeight
);
...
...
@@ -461,7 +461,7 @@ void IosSalGraphics::copyArea( long nDstX, long nDstY,long nSrcX, long nSrcY,
}
// draw at new destination
const
CGPoint
aDstPoint
=
{
+
nDstX
,
+
nDstY
};
const
CGPoint
aDstPoint
=
{
static_cast
<
CGFloat
>
(
+
nDstX
),
static_cast
<
CGFloat
>
(
+
nDstY
)
};
::
CGContextDrawLayerAtPoint
(
xCopyContext
,
aDstPoint
,
xSrcLayer
);
// cleanup
...
...
@@ -512,7 +512,7 @@ bool IosSalGraphics::drawAlphaBitmap( const SalTwoRect& rTR,
}
if
(
CheckContext
()
)
{
const
CGRect
aDstRect
=
{
{
rTR
.
mnDestX
,
rTR
.
mnDestY
},
{
rTR
.
mnDestWidth
,
rTR
.
mnDestHeight
}
};
const
CGRect
aDstRect
=
{
{
static_cast
<
CGFloat
>
(
rTR
.
mnDestX
),
static_cast
<
CGFloat
>
(
rTR
.
mnDestY
)
},
{
static_cast
<
CGFloat
>
(
rTR
.
mnDestWidth
),
static_cast
<
CGFloat
>
(
rTR
.
mnDestHeight
)
}
};
CGContextDrawImage
(
mrContext
,
aDstRect
,
xMaskedImage
);
RefreshRect
(
aDstRect
);
}
...
...
@@ -532,7 +532,7 @@ bool IosSalGraphics::drawAlphaRect( long nX, long nY, long nWidth,
CGContextSaveGState
(
mrContext
);
CGContextSetAlpha
(
mrContext
,
(
100
-
nTransparency
)
*
(
1.0
/
100
)
);
CGRect
aRect
=
{
{
nX
,
nY
},{
nWidth
-
1
,
nHeight
-
1
}
};
CGRect
aRect
=
{
{
static_cast
<
CGFloat
>
(
nX
),
static_cast
<
CGFloat
>
(
nY
)
},
{
static_cast
<
CGFloat
>
(
nWidth
-
1
),
static_cast
<
CGFloat
>
(
nHeight
-
1
)
}
};
if
(
IsPenVisible
()
)
{
aRect
.
origin
.
x
+=
0.5
;
...
...
@@ -562,8 +562,8 @@ void IosSalGraphics::drawBitmap( const SalTwoRect* pPosAry, const SalBitmap& rSa
{
return
;
}
const
CGRect
aDstRect
=
{
{
pPosAry
->
mnDestX
,
pPosAry
->
mnDestY
},
{
pPosAry
->
mnDestWidth
,
pPosAry
->
mnDestHeight
}
};
const
CGRect
aDstRect
=
{
{
static_cast
<
CGFloat
>
(
pPosAry
->
mnDestX
),
static_cast
<
CGFloat
>
(
pPosAry
->
mnDestY
)
},
{
static_cast
<
CGFloat
>
(
pPosAry
->
mnDestWidth
),
static_cast
<
CGFloat
>
(
pPosAry
->
mnDestHeight
)
}
};
CGContextDrawImage
(
mrContext
,
aDstRect
,
xImage
);
CGImageRelease
(
xImage
);
RefreshRect
(
aDstRect
);
...
...
@@ -590,8 +590,8 @@ void IosSalGraphics::drawBitmap( const SalTwoRect* pPosAry, const SalBitmap& rSa
{
return
;
}
const
CGRect
aDstRect
=
{
{
pPosAry
->
mnDestX
,
pPosAry
->
mnDestY
},
{
pPosAry
->
mnDestWidth
,
pPosAry
->
mnDestHeight
}
};
const
CGRect
aDstRect
=
{
{
static_cast
<
CGFloat
>
(
pPosAry
->
mnDestX
),
static_cast
<
CGFloat
>
(
pPosAry
->
mnDestY
)
},
{
static_cast
<
CGFloat
>
(
pPosAry
->
mnDestWidth
),
static_cast
<
CGFloat
>
(
pPosAry
->
mnDestHeight
)
}
};
CGContextDrawImage
(
mrContext
,
aDstRect
,
xMaskedImage
);
CGImageRelease
(
xMaskedImage
);
RefreshRect
(
aDstRect
);
...
...
@@ -640,8 +640,8 @@ void IosSalGraphics::drawMask( const SalTwoRect* pPosAry,
{
return
;
}
const
CGRect
aDstRect
=
{
{
pPosAry
->
mnDestX
,
pPosAry
->
mnDestY
},
{
pPosAry
->
mnDestWidth
,
pPosAry
->
mnDestHeight
}
};
const
CGRect
aDstRect
=
{
{
static_cast
<
CGFloat
>
(
pPosAry
->
mnDestX
),
static_cast
<
CGFloat
>
(
pPosAry
->
mnDestY
)
},
{
static_cast
<
CGFloat
>
(
pPosAry
->
mnDestWidth
),
static_cast
<
CGFloat
>
(
pPosAry
->
mnDestHeight
)
}
};
CGContextDrawImage
(
mrContext
,
aDstRect
,
xImage
);
CGImageRelease
(
xImage
);
RefreshRect
(
aDstRect
);
...
...
@@ -1103,7 +1103,7 @@ SalColor IosSalGraphics::getPixel( long nX, long nY )
{
nY
=
mnHeight
-
nY
;
}
const
CGPoint
aCGPoint
=
{
-
nX
,
-
nY
};
const
CGPoint
aCGPoint
=
{
static_cast
<
CGFloat
>
(
-
nX
),
static_cast
<
CGFloat
>
(
-
nY
)
};
CGContextDrawLayerAtPoint
(
xOnePixelContext
,
aCGPoint
,
mxLayer
);
CGContextRelease
(
xOnePixelContext
);
...
...
@@ -1131,7 +1131,7 @@ void IosSalGraphics::ImplDrawPixel( long nX, long nY, const RGBAColor& rColor )
// overwrite the fill color
CGContextSetFillColor
(
mrContext
,
rColor
.
AsArray
()
);
// draw 1x1 rect, there is no pixel drawing in Quartz
CGRect
aDstRect
=
{
{
nX
,
nY
,},{
1
,
1
}
};
CGRect
aDstRect
=
{
{
static_cast
<
CGFloat
>
(
nX
),
static_cast
<
CGFloat
>
(
nY
)
},
{
1
,
1
}
};
CGContextFillRect
(
mrContext
,
aDstRect
);
RefreshRect
(
aDstRect
);
// reset the fill color
...
...
@@ -1352,7 +1352,7 @@ bool IosSalGraphics::setClipRegion( const Region& i_rClip )
{
if
(
nW
&&
nH
)
{
CGRect
aRect
=
{
{
nX
,
nY
},
{
nW
,
nH
}
};
CGRect
aRect
=
{
{
static_cast
<
CGFloat
>
(
nX
),
static_cast
<
CGFloat
>
(
nY
)
},
{
static_cast
<
CGFloat
>
(
nW
),
static_cast
<
CGFloat
>
(
nH
)
}
};
CGPathAddRect
(
mxClipPath
,
NULL
,
aRect
);
}
bRegionRect
=
i_rClip
.
ImplGetNextRect
(
aInfo
,
nX
,
nY
,
nW
,
nH
);
...
...
@@ -1582,7 +1582,7 @@ bool XorEmulation::UpdateTarget()
const
int
nWidth
=
(
int
)
CGImageGetWidth
(
xXorImage
);
const
int
nHeight
=
(
int
)
CGImageGetHeight
(
xXorImage
);
// TODO: update minimal changerect
const
CGRect
aFullRect
=
{
{
0
,
0
},{
nWidth
,
nHeight
}
};
const
CGRect
aFullRect
=
{
{
0
,
0
},
{
static_cast
<
CGFloat
>
(
nWidth
),
static_cast
<
CGFloat
>
(
nHeight
)
}
};
CGContextDrawImage
(
m_xTargetContext
,
aFullRect
,
xXorImage
);
CGImageRelease
(
xXorImage
);
}
...
...
vcl/ios/source/gdi/salvd.cxx
Dosyayı görüntüle @
305ccd4f
...
...
@@ -216,7 +216,7 @@ sal_Bool IosSalVirtualDevice::SetSize( long nDX, long nDY )
DBG_ASSERT
(
xCGContext
,
"no context"
);
const
CGSize
aNewSize
=
{
nDX
,
nDY
};
const
CGSize
aNewSize
=
{
static_cast
<
CGFloat
>
(
nDX
),
static_cast
<
CGFloat
>
(
nDY
)
};
mxLayer
=
CGLayerCreateWithContext
(
xCGContext
,
aNewSize
,
NULL
);
if
(
mxLayer
&&
mpGraphics
)
...
...
vcl/ios/source/window/salframe.cxx
Dosyayı görüntüle @
305ccd4f
...
...
@@ -1076,7 +1076,7 @@ void IosSalFrame::UnionClipRegion( long nX, long nY, long nWidth, long nHeight )
if
(
nWidth
&&
nHeight
)
{
CGRect
aRect
=
{
{
nX
,
nY
},
{
nWidth
,
nHeight
}
};
CGRect
aRect
=
{
{
static_cast
<
CGFloat
>
(
nX
),
static_cast
<
CGFloat
>
(
nY
)
},
{
static_cast
<
CGFloat
>
(
nWidth
),
static_cast
<
CGFloat
>
(
nHeight
)
}
};
VCLToCocoaTouch
(
aRect
,
false
);
maClippingRects
.
push_back
(
CGRectMake
(
aRect
.
origin
.
x
,
aRect
.
origin
.
y
,
aRect
.
size
.
width
,
aRect
.
size
.
height
)
);
}
...
...
vcl/ios/source/window/salobj.cxx
Dosyayı görüntüle @
305ccd4f
...
...
@@ -153,14 +153,14 @@ void IosSalObject::SetPosSize( long nX, long nY, long nWidth, long nHeight )
void
IosSalObject
::
setClippedPosSize
()
{
CGRect
aViewRect
=
{
{
0
,
0
},
{
mnWidth
,
mnHeight
}
};
CGRect
aViewRect
=
{
{
0
,
0
},
{
static_cast
<
CGFloat
>
(
mnWidth
),
static_cast
<
CGFloat
>
(
mnHeight
)
}
};
if
(
maSysData
.
pView
)
{
UIView
*
pView
=
maSysData
.
pView
;
[
pView
setFrame
:
aViewRect
];
}
CGRect
aClipViewRect
=
{
{
mnX
,
mnY
},
{
mnWidth
,
mnHeight
}
};
CGRect
aClipViewRect
=
{
{
static_cast
<
CGFloat
>
(
mnX
),
static_cast
<
CGFloat
>
(
mnY
)
},
{
static_cast
<
CGFloat
>
(
mnWidth
),
static_cast
<
CGFloat
>
(
mnHeight
)
}
};
CGPoint
aClipPt
=
{
0
,
0
};
if
(
mbClip
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment