- 20 Oct, 2023 1 commit
-
-
Igor Demin authored
After https://github.com/JetBrains/skiko/pull/798, we changed Dispatcher.IO to custom dispatcher. Dispatcher.IO is based on daemon threads (thread that receives InterruptException on application exit). Our new dispatcher isn't. The proof: ``` import java.util.concurrent.Executors import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.asCoroutineDispatcher import kotlinx.coroutines.runBlocking fun main() { runBlocking(Dispatchers.IO) { println(Thread.currentThread().isDaemon) // prints true } runBlocking(Executors.newCachedThreadPool().asCoroutineDispatcher()) { println(Thread.currentThread().isDaemon) // prints false } val defaultFactory = Executors.defaultThreadFactory() runBlocking(Executors.newCachedThreadPool { defaultFactory.newThread(it).apply { isDaemon = true } }.asCoroutineDispatcher()) { println(Thread.currentThread().isDaemon) // prints true } } ``` This PR makes threads daemon. Reported in [Kotlin Slack](https://kotlinlang.slack.com/archives/C01D6HTPATV/p1697400320739369) - applications exits too long.
-
- 12 Oct, 2023 2 commits
-
-
Pavel authored
-
Felix Mujkanovic authored
Passing null into the "positions" parameter of a gradient shader factory that accepts a custom ColorSpace caused a segfault prior to this fix.
-
- 09 Oct, 2023 2 commits
-
-
Igor Demin authored
* Fix crash on Windows machines without OpenGL Some Windows CI machines don't contain OpenGL, so Skiko/Compose will crash on them. It shouldn't crash, it should fallback to Software rendering To properly fallback, we need to load opengl32.dll dynamically in runtime. Fixes https://github.com/JetBrains/compose-multiplatform/issues/3243 # Test 1 - `gradlew publishToMavenLocal` is successful (if we use functions directly, it fails with "error LNK2019: unresolved external symbol") - `SkiaLayerTest` is successful (it tests OpenGL as well) # Test 2 1. Remove `C:\Windows\System32\opengl32.dll` 2. `SkiaLayerTest` still should be successful, but logs should contain that it fallbacks to Software rendering. # Test 3 1. Compile local skiko 2. Run Compose run1 and tests * Refactor * Discussions * Discussions * Split throwJavaRenderException It isn't valid to use FormatMessage for code from GetLastError
-
Oleksandr Karpovich authored
* Add more checks * Update skiko/src/awtMain/kotlin/org/jetbrains/skiko/redrawer/WindowsOpenGLRedrawer.kt * Update skiko/src/awtMain/kotlin/org/jetbrains/skiko/AWT.kt Co-authored-by:
Igor Demin <igordmn@users.noreply.github.com> * Update skiko/src/awtMain/kotlin/org/jetbrains/skiko/redrawer/WindowsOpenGLRedrawer.kt Co-authored-by:
Igor Demin <igordmn@users.noreply.github.com> --------- Co-authored-by:
Igor Demin <igordmn@users.noreply.github.com>
-
- 04 Oct, 2023 1 commit
-
-
Oleksandr Karpovich authored
* Make CI choose iPhone for tests * fix * fix * fix * enable all other jobs back
-
- 28 Sep, 2023 1 commit
-
-
Pavel authored
Add comment about clangd, generate compilation database even if compilation wasn't successful (#806) * ignore .clangd * add comment about clangd * generate `compile_commands.json` even if compilation wasn't successful
-
- 27 Sep, 2023 2 commits
-
-
Oleksandr Karpovich authored
* Update IOS_SIM_UUID Co-authored-by:dima.avdeev <dima.avdeev@jetbrains.com>
-
Oleksandr Karpovich authored
Fix SVGLength.withUnit: create a new SVGLength with a `_unit` from the input and not `this.unit` (#804)
-
- 26 Sep, 2023 1 commit
-
-
Ilya Ryzhenkov authored
-
- 15 Sep, 2023 1 commit
-
-
Pavel authored
* set `kotlinx.coroutines` to `1.7.3` * update tests after coroutines.tests update * use `limitedParallelism` instead of bare `Dispatchers.IO` rename * use virtual time aware dispatchers in tests that use `runTest` * better naming * remove usages of experimental coroutines api * remove usages of experimental time api * use dispatcher from `coroutineScope` in `FrameLimiter` `FrameLimiter` must cancel waiting when its scope canceled * extract the `dispatcherToBlockOn` into separate file * use dispatcher from `coroutineScope` in `FrameLimiter` * Fix FrameLimiterTest --------- Co-authored-by:Igor Demin <igor.demin@jetbrains.com>
-
- 11 Sep, 2023 1 commit
-
-
Nikolai Rykunov authored
-
- 04 Sep, 2023 1 commit
-
-
Nikolai Rykunov authored
* Introduce a way to initialize CAccessible for Accessible to build proper context -> accessible mapping * Add test for getCAccessible call
-
- 22 Aug, 2023 1 commit
-
-
Nikolai Rykunov authored
-
- 15 Aug, 2023 1 commit
-
-
Elijah Semyonov authored
* Pause metal redrawer when app is background. * Add comment * Add logic for synchronous scheduling * Add logic for synchronous scheduling * Add correct initial state
-
- 14 Aug, 2023 1 commit
-
-
Pavel authored
Add comment to clarify that coordinates refer a baseline position, not a top left angle of text rectangle (#788)
-
- 11 Aug, 2023 1 commit
-
-
Elijah Semyonov authored
* Fix memory leak on iOS * Add check for caDisplayLink being disposed before drawing * Add logger warn
-
- 08 Aug, 2023 1 commit
-
-
Elijah Semyonov authored
* Correctly handle nulls when working with Obj-C API. Throw RenderException if MTLDevice is null to allow RedrawerManager fallback to software renderer. * Perform minor refactor
-
- 07 Aug, 2023 3 commits
-
-
Elijah Semyonov authored
* Update RELEASE.md * Update skiko/RELEASE.md Co-authored-by:
dima.avdeev <dima.avdeev@jetbrains.com> --------- Co-authored-by:
dima.avdeev <dima.avdeev@jetbrains.com>
-
dima.avdeev authored
-
Elijah Semyonov authored
* Break strong cycle * Add test proving it * Remove dead code * Explain test * Add remark about two passes * Add temporary ignore on test * Use assertTrue instead of assertEquals * Update test to ignore CI failure on Metal not supported * Update test * Refactor to reflect insight about memory model * Add contract comment. * Break strong reference from CADisplayLink -> MetalRedrawer * Bind logical lifetime of MetalRedrawer to caDisplayLink * Bind logical lifetime of MetalRedrawer to caDisplayLink * Close skia context on MetalRedrawer dispose. * Use `check` * Fix tests on iOS with Metal on GitHub Actions (#783) * iOS simulator warmup * comment redundant for now * sim ID * iPhone 8 * iPhone 14 * env.IOS_SIM_UUID * remove redundant * one line cmd * one line cmd * device * device * property * retry 3 times * retry 3 times * retry 5 times * retry 10 times * testMetalIosX64 * test test fails * kotlin 1.8.20 * success test * success test * temp fail * success test * simplify * simplify * simplify * Added iOS Metal tests only on MacOS * Gradle, check targets before adding iosX64TestWithMetal task --------- Co-authored-by:dima.avdeev <dima.avdeev@jetbrains.com>
-
- 03 Aug, 2023 1 commit
-
-
Elijah Semyonov authored
* Refactor SkikoUIView and Metal interaction * Move load logic to init * Remove dead code * Use contentScaleFactor for calculating drawable size * Move UITouch.isPressed to filescope * Add trace logs for anomaly situations
-
- 31 Jul, 2023 3 commits
-
-
Nikolai Rykunov authored
-
Elijah Semyonov authored
--------- Co-authored-by:
Nikolay Rykunov <nikolay.rykunov@jetbrains.com> Co-authored-by:
Ivan Matkov <ivan.matkov@jetbrains.com>
-
Elijah Semyonov authored
-
- 26 Jul, 2023 1 commit
-
-
Elijah Semyonov authored
-
- 24 Jul, 2023 1 commit
-
-
Elijah Semyonov authored
* Move flush to `finally` block. * Prevent reentry when scene is invalidated within draw. * Revert "Move flush to `finally` block." This reverts commit 25b04b811c2425c27a04b7508dbd7de70b8ef735. * Prevent within frameListener as well.
-
- 21 Jul, 2023 2 commits
-
-
Alexey Tsvetkov authored
Resolves #766
-
Nikolai Rykunov authored
* Reuse Metal texture if size is not changed * Reuse bitmap storage and recreate it only when size is changed * Reuse ByteArrays if size is not changed
-
- 19 Jul, 2023 1 commit
-
-
Nikolai Rykunov authored
-
- 18 Jul, 2023 2 commits
-
-
Alexey Tsvetkov authored
* Fix dynamic framework support and fix binary compatibility of SkikoUIView This change configures Kotlin Gradle plugin to include a CInterop def file (https://kotlinlang.org/docs/native-c-interop.html) to fix linking a dynamic framework for iOS Also helps with https://youtrack.jetbrains.com/issue/KT-60399 (at least in some cases). Internal discussion https://jetbrains.slack.com/archives/G017NLN12D8/p1689594898607469 * CR fix: use flatmap
-
Elijah Semyonov authored
-
- 10 Jul, 2023 1 commit
-
-
Elijah Semyonov authored
* Add repro * Add ignore * Remove redundant retain * Add DisplayLinkThrottler implementation * Create Kotlin wrapper and JNI wrapper. * Integrate throttler into redrawer * Release CVDisplayLink in case of error * Fix wrong screen dictionary retrieval. * Remove temporary changes. * Rename test. * Add overcommitment prevention mechanism (#754) * Add overcommitment prevention mechanism * Replace hardcoded value with CAMetalLayer property * Update skiko/src/awtMain/objectiveC/macos/MetalContextHandler.mm Co-authored-by:
Igor Demin <igordmn@users.noreply.github.com> --------- Co-authored-by:
Igor Demin <igordmn@users.noreply.github.com> * Remove _displayLinkOk (#756) * Remove _displayLinkOk * Discussions * Fix build --------- Co-authored-by:
Igor Demin <igordmn@users.noreply.github.com>
-
- 07 Jul, 2023 1 commit
-
-
Elijah Semyonov authored
-
- 06 Jul, 2023 4 commits
-
-
dima.avdeev authored
Workaround was added in this PR: https://github.com/JetBrains/skiko/pull/682
-
dima.avdeev authored
-
dima.avdeev authored
Use workaround with Java sources. Because a platform Java type can be used as a platform type MotionEvent!
-
dima.avdeev authored
Rename interface to SkikoUITextInputTraits Also added missing functions from https://developer.apple.com/documentation/uikit/uitextinputtraits?language=objc
-
- 05 Jul, 2023 2 commits
-
-
dima.avdeev authored
Fixes after removing `fun onTouchEvent(events: Array<SkikoTouchEvent>)` in this PR: https://github.com/JetBrains/skiko/pull/725
-
dima.avdeev authored
-