Support Fragment in android-compiler-plugin
This commit is contained in:
+4
@@ -1,9 +1,13 @@
|
||||
package kotlinx.android.synthetic.layout
|
||||
|
||||
import android.app.Activity
|
||||
import android.app.Fragment
|
||||
import android.view.View
|
||||
import android.widget.*
|
||||
|
||||
val Activity.MyButton: org.my.cool.Button
|
||||
get() = findViewById(0) as org.my.cool.Button
|
||||
|
||||
val Fragment.MyButton: org.my.cool.Button
|
||||
get() = getView().findViewById(0) as org.my.cool.Button
|
||||
|
||||
|
||||
+4
@@ -1,9 +1,13 @@
|
||||
package kotlinx.android.synthetic.layout
|
||||
|
||||
import android.app.Activity
|
||||
import android.app.Fragment
|
||||
import android.view.View
|
||||
import android.widget.*
|
||||
|
||||
val Activity.MyButton: org.my.cool.Button
|
||||
get() = findViewById(0) as org.my.cool.Button
|
||||
|
||||
val Fragment.MyButton: org.my.cool.Button
|
||||
get() = getView().findViewById(0) as org.my.cool.Button
|
||||
|
||||
|
||||
@@ -1,18 +1,31 @@
|
||||
package kotlinx.android.synthetic.layout
|
||||
|
||||
import android.app.Activity
|
||||
import android.app.Fragment
|
||||
import android.view.View
|
||||
import android.widget.*
|
||||
|
||||
val Activity.item_detail_container: FrameLayout
|
||||
get() = findViewById(0) as FrameLayout
|
||||
|
||||
val Fragment.item_detail_container: FrameLayout
|
||||
get() = getView().findViewById(0) as FrameLayout
|
||||
|
||||
val Activity.textView1: TextView
|
||||
get() = findViewById(0) as TextView
|
||||
|
||||
val Fragment.textView1: TextView
|
||||
get() = getView().findViewById(0) as TextView
|
||||
|
||||
val Activity.password: EditText
|
||||
get() = findViewById(0) as EditText
|
||||
|
||||
val Fragment.password: EditText
|
||||
get() = getView().findViewById(0) as EditText
|
||||
|
||||
val Activity.login: Button
|
||||
get() = findViewById(0) as Button
|
||||
|
||||
val Fragment.login: Button
|
||||
get() = getView().findViewById(0) as Button
|
||||
|
||||
|
||||
+12
@@ -1,18 +1,30 @@
|
||||
package kotlinx.android.synthetic.layout1
|
||||
|
||||
import android.app.Activity
|
||||
import android.app.Fragment
|
||||
import android.view.View
|
||||
import android.widget.*
|
||||
|
||||
val Activity.frameLayout: FrameLayout
|
||||
get() = findViewById(0) as FrameLayout
|
||||
|
||||
val Fragment.frameLayout: FrameLayout
|
||||
get() = getView().findViewById(0) as FrameLayout
|
||||
|
||||
val Activity.passwordField: TextView
|
||||
get() = findViewById(0) as TextView
|
||||
|
||||
val Fragment.passwordField: TextView
|
||||
get() = getView().findViewById(0) as TextView
|
||||
|
||||
val Activity.passwordCaption: EditText
|
||||
get() = findViewById(0) as EditText
|
||||
|
||||
val Fragment.passwordCaption: EditText
|
||||
get() = getView().findViewById(0) as EditText
|
||||
|
||||
val Activity.loginButton: Button
|
||||
get() = findViewById(0) as Button
|
||||
|
||||
val Fragment.loginButton: Button
|
||||
get() = getView().findViewById(0) as Button
|
||||
|
||||
+13
@@ -1,18 +1,31 @@
|
||||
package kotlinx.android.synthetic.layout
|
||||
|
||||
import android.app.Activity
|
||||
import android.app.Fragment
|
||||
import android.view.View
|
||||
import android.widget.*
|
||||
|
||||
val Activity.item_detail_container: FrameLayout
|
||||
get() = findViewById(0) as FrameLayout
|
||||
|
||||
val Fragment.item_detail_container: FrameLayout
|
||||
get() = getView().findViewById(0) as FrameLayout
|
||||
|
||||
val Activity.textView1: TextView
|
||||
get() = findViewById(0) as TextView
|
||||
|
||||
val Fragment.textView1: TextView
|
||||
get() = getView().findViewById(0) as TextView
|
||||
|
||||
val Activity.password: EditText
|
||||
get() = findViewById(0) as EditText
|
||||
|
||||
val Fragment.password: EditText
|
||||
get() = getView().findViewById(0) as EditText
|
||||
|
||||
val Activity.login: Button
|
||||
get() = findViewById(0) as Button
|
||||
|
||||
val Fragment.login: Button
|
||||
get() = getView().findViewById(0) as Button
|
||||
|
||||
|
||||
Reference in New Issue
Block a user