Add intentions for registering Android components in manifest
Activity, Service, BroadcastReceiver #KT-17389 Fixed
This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddActivityToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.app.Activity
|
||||
|
||||
|
||||
abstract class <caret>MyActivity : Activity()
|
||||
@@ -0,0 +1,8 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddActivityToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.app.Activity
|
||||
|
||||
|
||||
class <caret>MyActivity : Activity()
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="com.myapp"
|
||||
android:versionCode="1"
|
||||
android:versionName="1.0" >
|
||||
|
||||
|
||||
<application>
|
||||
<activity android:name=".MyActivity"/>
|
||||
</application>
|
||||
</manifest>
|
||||
@@ -0,0 +1,10 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddActivityToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.app.Activity
|
||||
|
||||
|
||||
class Test {
|
||||
inner class <caret>MyActivity : Activity()
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddActivityToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.app.Activity
|
||||
|
||||
|
||||
class MyActivity : Activity() {
|
||||
<caret>
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddActivityToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.app.Activity
|
||||
|
||||
|
||||
fun test() {
|
||||
class <caret>MyActivity : Activity()
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddActivityToManifest
|
||||
// CHECK_MANIFEST
|
||||
package com.myapp
|
||||
|
||||
import android.app.Activity
|
||||
|
||||
class Test {
|
||||
class <caret>MyActivity : Activity()
|
||||
}
|
||||
Vendored
+10
@@ -0,0 +1,10 @@
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="com.myapp"
|
||||
android:versionCode="1"
|
||||
android:versionName="1.0" >
|
||||
|
||||
|
||||
<application>
|
||||
<activity android:name=".Test$MyActivity"/>
|
||||
</application>
|
||||
</manifest>
|
||||
@@ -0,0 +1,6 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddActivityToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
|
||||
class <caret>MyActivity
|
||||
@@ -0,0 +1,8 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddActivityToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.app.Activity
|
||||
|
||||
|
||||
private class <caret>MyActivity : Activity()
|
||||
@@ -0,0 +1,10 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddActivityToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.app.Activity
|
||||
|
||||
|
||||
class Test {
|
||||
protected class <caret>MyActivity : Activity()
|
||||
}
|
||||
@@ -0,0 +1,8 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddActivityToManifest
|
||||
// CHECK_MANIFEST
|
||||
package com.myapp
|
||||
|
||||
import android.app.Activity
|
||||
|
||||
|
||||
class <caret>MyActivity : Activity()
|
||||
Vendored
+10
@@ -0,0 +1,10 @@
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="com.myapp"
|
||||
android:versionCode="1"
|
||||
android:versionName="1.0" >
|
||||
|
||||
|
||||
<application>
|
||||
<activity android:name=".MyActivity"/>
|
||||
</application>
|
||||
</manifest>
|
||||
@@ -0,0 +1,12 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddBroadcastReceiverToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.content.BroadcastReceiver
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
|
||||
abstract class <caret>MyReceiver : BroadcastReceiver() {
|
||||
override fun onReceive(context: Context?, intent: Intent?) {
|
||||
}
|
||||
}
|
||||
+12
@@ -0,0 +1,12 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddBroadcastReceiverToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.content.BroadcastReceiver
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
|
||||
class <caret>MyReceiver : BroadcastReceiver() {
|
||||
override fun onReceive(context: Context?, intent: Intent?) {
|
||||
}
|
||||
}
|
||||
Vendored
+10
@@ -0,0 +1,10 @@
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="com.myapp"
|
||||
android:versionCode="1"
|
||||
android:versionName="1.0" >
|
||||
|
||||
|
||||
<application>
|
||||
<receiver android:name=".MyReceiver"/>
|
||||
</application>
|
||||
</manifest>
|
||||
@@ -0,0 +1,14 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddBroadcastReceiverToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.content.BroadcastReceiver
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
|
||||
class Test {
|
||||
inner class MyReceiver : BroadcastReceiver() {
|
||||
override fun onReceive(context: Context?, intent: Intent?) {
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddBroadcastReceiverToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.content.BroadcastReceiver
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
|
||||
class MyReceiver : BroadcastReceiver() {
|
||||
override fun onReceive(context: Context?, intent: Intent?) {
|
||||
<caret>
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddBroadcastReceiverToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.content.BroadcastReceiver
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
|
||||
|
||||
fun test() {
|
||||
class <caret>MyReceiver : BroadcastReceiver() {
|
||||
override fun onReceive(context: Context?, intent: Intent?) {
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddBroadcastReceiverToManifest
|
||||
// CHECK_MANIFEST
|
||||
package com.myapp
|
||||
|
||||
import android.content.BroadcastReceiver
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
|
||||
|
||||
class Test {
|
||||
class <caret>MyReceiver : BroadcastReceiver() {
|
||||
override fun onReceive(context: Context?, intent: Intent?) {
|
||||
}
|
||||
}
|
||||
}
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="com.myapp"
|
||||
android:versionCode="1"
|
||||
android:versionName="1.0" >
|
||||
|
||||
|
||||
<application>
|
||||
<receiver android:name=".Test$MyReceiver"/>
|
||||
</application>
|
||||
</manifest>
|
||||
@@ -0,0 +1,6 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddBroadcastReceiverToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
|
||||
class <caret>MyReceiver
|
||||
@@ -0,0 +1,12 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddBroadcastReceiverToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.content.BroadcastReceiver
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
|
||||
private class <caret>MyReceiver : BroadcastReceiver() {
|
||||
override fun onReceive(context: Context?, intent: Intent?) {
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddBroadcastReceiverToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.content.BroadcastReceiver
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
|
||||
class Test {
|
||||
protected class <caret>MyReceiver : BroadcastReceiver() {
|
||||
override fun onReceive(context: Context?, intent: Intent?) {
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddBroadcastReceiverToManifest
|
||||
// CHECK_MANIFEST
|
||||
package com.myapp
|
||||
|
||||
import android.content.BroadcastReceiver
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
|
||||
class <caret>MyReceiver : BroadcastReceiver() {
|
||||
override fun onReceive(context: Context?, intent: Intent?) {
|
||||
}
|
||||
}
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="com.myapp"
|
||||
android:versionCode="1"
|
||||
android:versionName="1.0" >
|
||||
|
||||
|
||||
<application>
|
||||
<receiver android:name=".MyReceiver"/>
|
||||
</application>
|
||||
</manifest>
|
||||
@@ -0,0 +1,14 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddServiceToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.app.Service
|
||||
import android.content.Intent
|
||||
import android.os.IBinder
|
||||
|
||||
|
||||
abstract class <caret>MyService : Service() {
|
||||
override fun onBind(intent: Intent?): IBinder {
|
||||
TODO("not implemented")
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddServiceToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.app.Service
|
||||
import android.content.Intent
|
||||
import android.os.IBinder
|
||||
|
||||
|
||||
class <caret>MyService : Service() {
|
||||
override fun onBind(intent: Intent?): IBinder {
|
||||
TODO("not implemented")
|
||||
}
|
||||
}
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="com.myapp"
|
||||
android:versionCode="1"
|
||||
android:versionName="1.0" >
|
||||
|
||||
|
||||
<application>
|
||||
<service android:name=".MyService"/>
|
||||
</application>
|
||||
</manifest>
|
||||
@@ -0,0 +1,16 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddServiceToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.app.Service
|
||||
import android.content.Intent
|
||||
import android.os.IBinder
|
||||
|
||||
|
||||
class Test {
|
||||
inner class <caret>MyService : Service() {
|
||||
override fun onBind(intent: Intent?): IBinder {
|
||||
TODO("not implemented")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddServiceToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.app.Service
|
||||
import android.content.Intent
|
||||
import android.os.IBinder
|
||||
|
||||
|
||||
class MyService : Service() {
|
||||
override fun onBind(intent: Intent?): IBinder {
|
||||
<caret>
|
||||
TODO("not implemented")
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddServiceToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.app.Service
|
||||
import android.content.Intent
|
||||
import android.os.IBinder
|
||||
|
||||
|
||||
fun test() {
|
||||
class <caret>MyService : Service() {
|
||||
override fun onBind(intent: Intent?): IBinder {
|
||||
TODO("not implemented")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddServiceToManifest
|
||||
// CHECK_MANIFEST
|
||||
package com.myapp
|
||||
|
||||
import android.app.Service
|
||||
import android.content.Intent
|
||||
import android.os.IBinder
|
||||
|
||||
|
||||
class Test {
|
||||
class <caret>MyService : Service() {
|
||||
override fun onBind(intent: Intent?): IBinder {
|
||||
TODO("not implemented")
|
||||
}
|
||||
}
|
||||
}
|
||||
Vendored
+10
@@ -0,0 +1,10 @@
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="com.myapp"
|
||||
android:versionCode="1"
|
||||
android:versionName="1.0" >
|
||||
|
||||
|
||||
<application>
|
||||
<service android:name=".Test$MyService"/>
|
||||
</application>
|
||||
</manifest>
|
||||
@@ -0,0 +1,6 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddServiceToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
|
||||
class <caret>MyService
|
||||
@@ -0,0 +1,14 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddServiceToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.app.Service
|
||||
import android.content.Intent
|
||||
import android.os.IBinder
|
||||
|
||||
|
||||
private class <caret>MyService : Service() {
|
||||
override fun onBind(intent: Intent?): IBinder {
|
||||
TODO("not implemented")
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddServiceToManifest
|
||||
// NOT_AVAILABLE
|
||||
package com.myapp
|
||||
|
||||
import android.app.Service
|
||||
import android.content.Intent
|
||||
import android.os.IBinder
|
||||
|
||||
|
||||
class Test {
|
||||
protected class <caret>MyService : Service() {
|
||||
override fun onBind(intent: Intent?): IBinder {
|
||||
TODO("not implemented")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
// INTENTION_CLASS: org.jetbrains.kotlin.android.intention.AddServiceToManifest
|
||||
// CHECK_MANIFEST
|
||||
package com.myapp
|
||||
|
||||
import android.app.Service
|
||||
import android.content.Intent
|
||||
import android.os.IBinder
|
||||
|
||||
|
||||
class <caret>MyService : Service() {
|
||||
override fun onBind(intent: Intent?): IBinder {
|
||||
TODO("not implemented")
|
||||
}
|
||||
}
|
||||
Vendored
+10
@@ -0,0 +1,10 @@
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="com.myapp"
|
||||
android:versionCode="1"
|
||||
android:versionName="1.0" >
|
||||
|
||||
|
||||
<application>
|
||||
<service android:name=".MyService"/>
|
||||
</application>
|
||||
</manifest>
|
||||
Reference in New Issue
Block a user