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
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
zipStorePath
=
wrapper/dists
samples/SkiaJvmSample/gradle/wrapper/gradle-wrapper.properties
View file @
2d070a54
distributionBase
=
GRADLE_USER_HOME
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
zipStorePath
=
wrapper/dists
skiko/gradle/wrapper/gradle-wrapper.properties
View file @
2d070a54
distributionBase
=
GRADLE_USER_HOME
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
zipStorePath
=
wrapper/dists
skiko/src/commonMain/kotlin/org/jetbrains/skia/ColorInfo.kt
View file @
2d070a54
...
...
@@ -9,10 +9,7 @@ package org.jetbrains.skia
* It encodes how pixel bits describe alpha, transparency; color components red, blue,
* and green; and ColorSpace, the range and linearity of colors.
*/
class
ColorInfo
(
colorType
:
ColorType
,
alphaType
:
ColorAlphaType
,
colorSpace
:
ColorSpace
?)
{
val
colorType
:
ColorType
val
alphaType
:
ColorAlphaType
val
colorSpace
:
ColorSpace
?
class
ColorInfo
(
val
colorType
:
ColorType
,
val
alphaType
:
ColorAlphaType
,
val
colorSpace
:
ColorSpace
?)
{
val
isOpaque
:
Boolean
get
()
=
alphaType
==
ColorAlphaType
.
OPAQUE
||
colorType
.
isAlwaysOpaque
...
...
@@ -40,10 +37,9 @@ class ColorInfo(colorType: ColorType, alphaType: ColorAlphaType, colorSpace: Col
val
isGammaCloseToSRGB
:
Boolean
get
()
=
colorSpace
!=
null
&&
colorSpace
.
isGammaCloseToSRGB
override
fun
equals
(
o
:
Any
?):
Boolean
{
if
(
o
===
this
)
return
true
if
(
o
!
is
ColorInfo
)
return
false
val
other
=
o
override
fun
equals
(
other
:
Any
?):
Boolean
{
if
(
other
===
this
)
return
true
if
(
other
!
is
ColorInfo
)
return
false
if
(!
other
.
canEqual
(
this
as
Any
))
return
false
val
`
this
$
_colorType
`
:
Any
=
colorType
val
`
other
$
_colorType
`
:
Any
=
other
.
colorType
...
...
@@ -77,16 +73,10 @@ class ColorInfo(colorType: ColorType, alphaType: ColorAlphaType, colorSpace: Col
}
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
)
}
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
)
}
...
...
@@ -101,10 +91,4 @@ class ColorInfo(colorType: ColorType, alphaType: ColorAlphaType, colorSpace: Col
*/
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