Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
skiko
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
liuqiang
skiko
Commits
2d070a54
Unverified
Commit
2d070a54
authored
Sep 05, 2021
by
Nikolay Igotti
Committed by
GitHub
Sep 05, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move to Gradle 7.1 (#166)
parent
5d041475
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
7 additions
and
23 deletions
+7
-23
gradle-wrapper.properties
gradle/wrapper/gradle-wrapper.properties
+1
-1
gradle-wrapper.properties
...es/SkiaJvmSample/gradle/wrapper/gradle-wrapper.properties
+1
-1
gradle-wrapper.properties
skiko/gradle/wrapper/gradle-wrapper.properties
+1
-1
ColorInfo.kt
skiko/src/commonMain/kotlin/org/jetbrains/skia/ColorInfo.kt
+4
-20
No files found.
gradle/wrapper/gradle-wrapper.properties
View file @
2d070a54
distributionBase
=
GRADLE_USER_HOME
distributionBase
=
GRADLE_USER_HOME
distributionPath
=
wrapper/dists
distributionPath
=
wrapper/dists
distributionUrl
=
https
\:
//services.gradle.org/distributions/gradle-
6.7
-bin.zip
distributionUrl
=
https
\:
//services.gradle.org/distributions/gradle-
7.1
-bin.zip
zipStoreBase
=
GRADLE_USER_HOME
zipStoreBase
=
GRADLE_USER_HOME
zipStorePath
=
wrapper/dists
zipStorePath
=
wrapper/dists
samples/SkiaJvmSample/gradle/wrapper/gradle-wrapper.properties
View file @
2d070a54
distributionBase
=
GRADLE_USER_HOME
distributionBase
=
GRADLE_USER_HOME
distributionPath
=
wrapper/dists
distributionPath
=
wrapper/dists
distributionUrl
=
https
\:
//services.gradle.org/distributions/gradle-
6.5
-bin.zip
distributionUrl
=
https
\:
//services.gradle.org/distributions/gradle-
7.1
-bin.zip
zipStoreBase
=
GRADLE_USER_HOME
zipStoreBase
=
GRADLE_USER_HOME
zipStorePath
=
wrapper/dists
zipStorePath
=
wrapper/dists
skiko/gradle/wrapper/gradle-wrapper.properties
View file @
2d070a54
distributionBase
=
GRADLE_USER_HOME
distributionBase
=
GRADLE_USER_HOME
distributionPath
=
wrapper/dists
distributionPath
=
wrapper/dists
distributionUrl
=
https
\:
//services.gradle.org/distributions/gradle-
6.5
-bin.zip
distributionUrl
=
https
\:
//services.gradle.org/distributions/gradle-
7.1
-bin.zip
zipStoreBase
=
GRADLE_USER_HOME
zipStoreBase
=
GRADLE_USER_HOME
zipStorePath
=
wrapper/dists
zipStorePath
=
wrapper/dists
skiko/src/commonMain/kotlin/org/jetbrains/skia/ColorInfo.kt
View file @
2d070a54
...
@@ -9,10 +9,7 @@ package org.jetbrains.skia
...
@@ -9,10 +9,7 @@ package org.jetbrains.skia
* It encodes how pixel bits describe alpha, transparency; color components red, blue,
* It encodes how pixel bits describe alpha, transparency; color components red, blue,
* and green; and ColorSpace, the range and linearity of colors.
* and green; and ColorSpace, the range and linearity of colors.
*/
*/
class
ColorInfo
(
colorType
:
ColorType
,
alphaType
:
ColorAlphaType
,
colorSpace
:
ColorSpace
?)
{
class
ColorInfo
(
val
colorType
:
ColorType
,
val
alphaType
:
ColorAlphaType
,
val
colorSpace
:
ColorSpace
?)
{
val
colorType
:
ColorType
val
alphaType
:
ColorAlphaType
val
colorSpace
:
ColorSpace
?
val
isOpaque
:
Boolean
val
isOpaque
:
Boolean
get
()
=
alphaType
==
ColorAlphaType
.
OPAQUE
||
colorType
.
isAlwaysOpaque
get
()
=
alphaType
==
ColorAlphaType
.
OPAQUE
||
colorType
.
isAlwaysOpaque
...
@@ -40,10 +37,9 @@ class ColorInfo(colorType: ColorType, alphaType: ColorAlphaType, colorSpace: Col
...
@@ -40,10 +37,9 @@ class ColorInfo(colorType: ColorType, alphaType: ColorAlphaType, colorSpace: Col
val
isGammaCloseToSRGB
:
Boolean
val
isGammaCloseToSRGB
:
Boolean
get
()
=
colorSpace
!=
null
&&
colorSpace
.
isGammaCloseToSRGB
get
()
=
colorSpace
!=
null
&&
colorSpace
.
isGammaCloseToSRGB
override
fun
equals
(
o
:
Any
?):
Boolean
{
override
fun
equals
(
other
:
Any
?):
Boolean
{
if
(
o
===
this
)
return
true
if
(
other
===
this
)
return
true
if
(
o
!
is
ColorInfo
)
return
false
if
(
other
!
is
ColorInfo
)
return
false
val
other
=
o
if
(!
other
.
canEqual
(
this
as
Any
))
return
false
if
(!
other
.
canEqual
(
this
as
Any
))
return
false
val
`
this
$
_colorType
`
:
Any
=
colorType
val
`
this
$
_colorType
`
:
Any
=
colorType
val
`
other
$
_colorType
`
:
Any
=
other
.
colorType
val
`
other
$
_colorType
`
:
Any
=
other
.
colorType
...
@@ -77,16 +73,10 @@ class ColorInfo(colorType: ColorType, alphaType: ColorAlphaType, colorSpace: Col
...
@@ -77,16 +73,10 @@ class ColorInfo(colorType: ColorType, alphaType: ColorAlphaType, colorSpace: Col
}
}
fun
withColorType
(
_colorType
:
ColorType
):
ColorInfo
{
fun
withColorType
(
_colorType
:
ColorType
):
ColorInfo
{
if
(
_colorType
==
null
)
{
throw
NullPointerException
(
"_colorType is marked non-null but is null"
)
}
return
if
(
colorType
==
_colorType
)
this
else
ColorInfo
(
_colorType
,
alphaType
,
colorSpace
)
return
if
(
colorType
==
_colorType
)
this
else
ColorInfo
(
_colorType
,
alphaType
,
colorSpace
)
}
}
fun
withAlphaType
(
_alphaType
:
ColorAlphaType
):
ColorInfo
{
fun
withAlphaType
(
_alphaType
:
ColorAlphaType
):
ColorInfo
{
if
(
_alphaType
==
null
)
{
throw
NullPointerException
(
"_alphaType is marked non-null but is null"
)
}
return
if
(
alphaType
==
_alphaType
)
this
else
ColorInfo
(
colorType
,
_alphaType
,
colorSpace
)
return
if
(
alphaType
==
_alphaType
)
this
else
ColorInfo
(
colorType
,
_alphaType
,
colorSpace
)
}
}
...
@@ -101,10 +91,4 @@ class ColorInfo(colorType: ColorType, alphaType: ColorAlphaType, colorSpace: Col
...
@@ -101,10 +91,4 @@ class ColorInfo(colorType: ColorType, alphaType: ColorAlphaType, colorSpace: Col
*/
*/
val
DEFAULT
=
ColorInfo
(
ColorType
.
UNKNOWN
,
ColorAlphaType
.
UNKNOWN
,
null
)
val
DEFAULT
=
ColorInfo
(
ColorType
.
UNKNOWN
,
ColorAlphaType
.
UNKNOWN
,
null
)
}
}
init
{
this
.
colorType
=
colorType
this
.
alphaType
=
alphaType
this
.
colorSpace
=
colorSpace
}
}
}
\ No newline at end of file
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