Skip to main content
The 2024 Developer Survey results are live! See the results

Questions tagged [kotlin]

Kotlin is a cross-platform, statically typed, general-purpose high-level programming language with type inference. This tag is often used alongside additional tags for the different targets (JVM, JavaScript, native, etc.) and libraries/frameworks (Android, Spring, etc.) used by Kotlin developers, if the question relates specifically to those topics.

0 votes
0 answers
5 views

Kotlin cameraManager.cameraIdList returns only 2 ID'd

I'm setting up a camera in Kotlin using the camera2 API, but I need to use the wide-angle lens of my device. In the code cameraManager.cameraIdList only returns the id [0, 1] referring to the rear and ...
Angelo Pavani Neto's user avatar
0 votes
0 answers
6 views

Kotlin/JS: `types` not included in generated package.json

Running jsBrowserProductionRun with generateTypeScriptDefinitions() set on js(IR) does not seem to include types in my package.json
Nestor Ledon's user avatar
  • 1,986
0 votes
0 answers
16 views

How to send data throught Wi-Fi with Kotlin to an Arduino with ESP8266-01S

I'm working on a project where I send information via Wi-Fi between an app and an Arduino Nano. I need to send simple text to an ESP8266-01S Wi-Fi module, which then communicates with the Arduino. The ...
Joaquin Hazzi's user avatar
0 votes
0 answers
20 views

Event from ViewModel to View to cancel and relaunch LaunchedEffect

I am remaking the Simon Says game in Kotin. I try to make a good pattern between my viewModel and my view but here i don't know if there is a better way to execute what i want. So, i need to make my ...
TheIsNoW's user avatar
1 vote
1 answer
15 views

How to start MainActivity after SplashScreen?

I want to run my app on devices below android 12. The app will have a splash screen, the app can't use splash screen api becuase it does not work sufficiently in devices below android 12. How to ...
Fatima Jamal's user avatar
0 votes
0 answers
10 views

How to Detect Mouse Events like Left, Right Clicks, Scrolling and Taps in Compose Multiplatform?

I'm working on a Compose Multiplatform project (wasm only) where I need to detect left and right mouse clicks, as well as simple taps through the notebook's mousepad. I am using the following function ...
Ojav's user avatar
  • 860
0 votes
0 answers
9 views

How to open Flutter app from foreground mode?

I am making an alarm application with Flutter, I coded a foreground service with PlatformChannel and MethodChannel. When countdown finishes I want to show an Alarm page but I can't deal with it. The ...
Serhan Ergül's user avatar
0 votes
0 answers
12 views

How can I determine if a Java/Kotiln/JVM (AWT / Compose multiplatform) application is running within a window manager on linux?

I am creating a desktop application using Compose multiplatform. More specifically, using the JetBrainsRuntime via the glue provided by jewel. I am looking for a way to determine if my application is ...
tealsnow's user avatar
  • 133
0 votes
0 answers
20 views

AOSP Development: Kotlin cannot access R class id, but Java can! Why?

I started diving into AOSP development recently and I am following some code labs originally written in Java on how to customize the SystemUI (for Automotive AOSP). I have checked that parts of ...
seriouslysupersonic's user avatar
0 votes
0 answers
13 views

Glide GIF performance is worse after Glide.with(this).clear

I am experimenting with animated buttons using GIF files and I encountered a strange error that I can't seem to fix without messing up something else. Let me explain. I have these 4 buttons (2 static ...
Lekstadt's user avatar
  • 588
0 votes
0 answers
12 views

Capture Composable to bitmap without rendering them

i made a simple app which makes you an id card when you open the id card it shows the details with the card design that you can print. the whole card design looks good in preview but when i use ...
Jaimin Vashi's user avatar
1 vote
0 answers
12 views

Jetpack Compose with just one button uses too much CPU

I'm new to Jetpack Compose, and I was trying it. I'm using IntelliJ IDEA, and I'm making one for desktop. I created a new Jetpack Compose with IntelliJ IDEA, and I runned it nothing changed with ...
E221_'s user avatar
  • 13
0 votes
0 answers
6 views

PMD Cyclomatic Complexity Causing Problem - Can I Disable?

I'm running a Gradle (Kotlin) build in Java, and overall it's going well. However, the PMD report is set to automatically stop the build if the cyclomatic complexity is 5 or more. This hasn't been too ...
SimicSlaw's user avatar
0 votes
0 answers
9 views

How to add adsense to Kotlin mutiplatform (KMM) web app?

I want to menotize my webapp which i created on kotlin multiplatform(KMM) and for web apps i feel adsense is best but i am unable to find a proper solution how to integrate adsense to a webapp built ...
Jasvir's user avatar
  • 81
-1 votes
0 answers
7 views

i have RecyclerView in kotlin project this recycler shows list of mp3 files and i want to when mp3 finish jump automatically to next itemView

i can't jump from current itemView to Next ItemView in recyclerView but this within recyclerView i have RecyclerView in kotlin project this recycler shows list of mp3 files and i want to when mp3 ...
learn map's user avatar

15 30 50 per page