Switch to 181 platform
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintNewApiInspection
|
||||
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
import kotlin.reflect.KClass
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
import kotlin.reflect.KClass
|
||||
|
||||
annotation class SomeAnnotationWithClass(val cls: KClass<*>)
|
||||
|
||||
@SomeAnnotationWithClass(<caret>VectorDrawable::class)
|
||||
class VectorDrawableProvider {
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintNewApiInspection
|
||||
|
||||
import android.annotation.TargetApi
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
@@ -0,0 +1,14 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
|
||||
import android.annotation.TargetApi
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
import android.os.Build
|
||||
import kotlin.reflect.KClass
|
||||
|
||||
annotation class SomeAnnotationWithClass(val cls: KClass<*>)
|
||||
|
||||
@TargetApi(Build.VERSION_CODES.LOLLIPOP)
|
||||
@SomeAnnotationWithClass(VectorDrawable::class)
|
||||
class VectorDrawableProvider {
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintNewApiInspection
|
||||
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
class VectorDrawableProvider {
|
||||
companion object {
|
||||
val VECTOR_DRAWABLE = <caret>VectorDrawable()
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintNewApiInspection
|
||||
|
||||
import android.annotation.TargetApi
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
|
||||
import android.annotation.TargetApi
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
import android.os.Build
|
||||
|
||||
class VectorDrawableProvider {
|
||||
@TargetApi(Build.VERSION_CODES.LOLLIPOP)
|
||||
companion object {
|
||||
val VECTOR_DRAWABLE = VectorDrawable()
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintNewApiInspection
|
||||
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
|
||||
fun withDefaultParameter(vector: VectorDrawable = <caret>VectorDrawable()) {
|
||||
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintNewApiInspection
|
||||
|
||||
import android.annotation.TargetApi
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
+12
@@ -0,0 +1,12 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
|
||||
import android.annotation.TargetApi
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
import android.os.Build
|
||||
|
||||
|
||||
@TargetApi(Build.VERSION_CODES.LOLLIPOP)
|
||||
fun withDefaultParameter(vector: VectorDrawable = VectorDrawable()) {
|
||||
|
||||
}
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintNewApiInspection
|
||||
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
class MyVectorDrawable : <caret>VectorDrawable() {
|
||||
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintNewApiInspection
|
||||
|
||||
import android.annotation.TargetApi
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
|
||||
import android.annotation.TargetApi
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
import android.os.Build
|
||||
|
||||
@TargetApi(Build.VERSION_CODES.LOLLIPOP)
|
||||
class MyVectorDrawable : VectorDrawable() {
|
||||
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintNewApiInspection
|
||||
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
class VectorDrawableProvider {
|
||||
fun getVectorDrawable(): VectorDrawable {
|
||||
with(this) {
|
||||
return <caret>VectorDrawable()
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintNewApiInspection
|
||||
|
||||
import android.annotation.TargetApi
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
|
||||
import android.annotation.TargetApi
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
import android.os.Build
|
||||
|
||||
class VectorDrawableProvider {
|
||||
@TargetApi(Build.VERSION_CODES.LOLLIPOP)
|
||||
fun getVectorDrawable(): VectorDrawable {
|
||||
with(this) {
|
||||
return VectorDrawable()
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(KITKAT) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintInlinedApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintInlinedApiInspection
|
||||
|
||||
class Test {
|
||||
fun foo(): Int {
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(KITKAT) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintInlinedApiInspection
|
||||
|
||||
class Test {
|
||||
fun foo(): Int {
|
||||
return android.R.attr.<caret>windowTranslucentStatus
|
||||
}
|
||||
}
|
||||
@@ -2,7 +2,7 @@ import android.annotation.TargetApi
|
||||
import android.os.Build
|
||||
|
||||
// INTENTION_TEXT: Add @TargetApi(KITKAT) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintInlinedApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintInlinedApiInspection
|
||||
|
||||
class Test {
|
||||
@TargetApi(Build.VERSION_CODES.KITKAT)
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
import android.annotation.TargetApi
|
||||
import android.os.Build
|
||||
|
||||
// INTENTION_TEXT: Add @TargetApi(KITKAT) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintInlinedApiInspection
|
||||
|
||||
class Test {
|
||||
@TargetApi(Build.VERSION_CODES.KITKAT)
|
||||
fun foo(): Int {
|
||||
return android.R.attr.windowTranslucentStatus
|
||||
}
|
||||
}
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintNewApiInspection
|
||||
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
class VectorDrawableProvider {
|
||||
fun getVectorDrawable(): VectorDrawable {
|
||||
return <caret>VectorDrawable()
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintNewApiInspection
|
||||
|
||||
import android.annotation.TargetApi
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
|
||||
import android.annotation.TargetApi
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
import android.os.Build
|
||||
|
||||
class VectorDrawableProvider {
|
||||
@TargetApi(Build.VERSION_CODES.LOLLIPOP)
|
||||
fun getVectorDrawable(): VectorDrawable {
|
||||
return VectorDrawable()
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintNewApiInspection
|
||||
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
class VectorDrawableProvider {
|
||||
val VECTOR_DRAWABLE = <caret>VectorDrawable()
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintNewApiInspection
|
||||
|
||||
import android.annotation.TargetApi
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
|
||||
import android.annotation.TargetApi
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
import android.os.Build
|
||||
|
||||
@TargetApi(Build.VERSION_CODES.LOLLIPOP)
|
||||
class VectorDrawableProvider {
|
||||
val VECTOR_DRAWABLE = VectorDrawable()
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(M) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintNewApiInspection
|
||||
import android.app.Activity
|
||||
|
||||
val top: Int
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(M) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
import android.app.Activity
|
||||
|
||||
val top: Int
|
||||
get() = Activity().<caret>checkSelfPermission(READ_CONTACTS)
|
||||
@@ -1,5 +1,5 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(M) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintNewApiInspection
|
||||
import android.annotation.TargetApi
|
||||
import android.app.Activity
|
||||
import android.os.Build
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(M) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
import android.annotation.TargetApi
|
||||
import android.app.Activity
|
||||
import android.os.Build
|
||||
|
||||
val top: Int
|
||||
@TargetApi(Build.VERSION_CODES.M)
|
||||
get() = Activity().checkSelfPermission(READ_CONTACTS)
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintNewApiInspection
|
||||
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
|
||||
@@ -0,0 +1,14 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
class VectorDrawableProvider {
|
||||
val flag = false
|
||||
fun getVectorDrawable(): VectorDrawable {
|
||||
return when (flag) {
|
||||
true -> <caret>VectorDrawable()
|
||||
else -> VectorDrawable()
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
// INSPECTION_CLASS: com.android.tools.idea.lint.AndroidLintNewApiInspection
|
||||
|
||||
import android.annotation.TargetApi
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
// INTENTION_TEXT: Add @TargetApi(LOLLIPOP) Annotation
|
||||
// INSPECTION_CLASS: org.jetbrains.android.inspections.klint.AndroidLintInspectionToolProvider$AndroidKLintNewApiInspection
|
||||
|
||||
import android.annotation.TargetApi
|
||||
import android.graphics.drawable.VectorDrawable
|
||||
import android.os.Build
|
||||
|
||||
class VectorDrawableProvider {
|
||||
val flag = false
|
||||
@TargetApi(Build.VERSION_CODES.LOLLIPOP)
|
||||
fun getVectorDrawable(): VectorDrawable {
|
||||
return when (flag) {
|
||||
true -> VectorDrawable()
|
||||
else -> VectorDrawable()
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user