mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-12 15:53:40 +00:00
Implement quickfixes for Android Lint api issues
#KT-16624 Fixed #KT-16625 Fixed #KT-14947 Fixed
This commit is contained in:
@@ -0,0 +1,10 @@
|
||||
package com.myapp
|
||||
|
||||
import android.app.Activity
|
||||
import android.content.Context
|
||||
|
||||
fun foo(context: Context) {
|
||||
object {
|
||||
val text = context.getString(R.string.resource_id)
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
<resources>
|
||||
<string name="resource_id">some string</string>
|
||||
</resources>
|
||||
10
idea/testData/android/resourceIntention/kotlinAndroidAddStringResource/objectInFunction/main.kt
vendored
Normal file
10
idea/testData/android/resourceIntention/kotlinAndroidAddStringResource/objectInFunction/main.kt
vendored
Normal file
@@ -0,0 +1,10 @@
|
||||
package com.myapp
|
||||
|
||||
import android.app.Activity
|
||||
import android.content.Context
|
||||
|
||||
fun foo(context: Context) {
|
||||
object {
|
||||
val text = "some <caret>string"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"rFile": "../../R.kt",
|
||||
"resDirectory": "../../res",
|
||||
"intentionClass": "org.jetbrains.kotlin.android.intention.KotlinAndroidAddStringResource"
|
||||
}
|
||||
Reference in New Issue
Block a user