-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Open
Labels
needs-area-labelAn area label is needed to ensure this gets routed to the appropriate area ownersAn area label is needed to ensure this gets routed to the appropriate area ownersuntriagedNew issue has not been triaged by the area ownerNew issue has not been triaged by the area owner
Description
<Button
android:id="@+id/btn_flash"
android:text="Flash Phone"
android:layout_width="match_parent"
android:layout_height="wrap_content"/>
<Button
android:id="@+id/btn_adb"
android:text="ADB Tools"
android:layout_width="match_parent"
android:layout_height="wrap_content"/>
<Button
android:id="@+id/btn_pc"
android:text="PC Programming"
android:layout_width="match_parent"
android:layout_height="wrap_content"/>
<Button
android:id="@+id/btn_diagnostics"
android:text="Diagnostics"
android:layout_width="match_parent"
android:layout_height="wrap_content"/>
package com.yourname.tclprogrammerpackage com.yourname.tclprogrammer
import android.content.Intent
import android.os.Bundle
import android.widget.Button
import androidx.appcompat.app.AppCompatActivity
class MainActivity : AppCompatActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.activity_main)
findViewById<Button>(R.id.btn_flash).setOnClickListener {
startActivity(Intent(this, FlashActivity::class.java))
}
findViewById<Button>(R.id.btn_adb).setOnClickListener {
startActivity(Intent(this, AdbToolsActivity::class.java))
}
findViewById<Button>(R.id.btn_pc).setOnClickListener {
startActivity(Intent(this, PcControlActivity::class.java))
}
findViewById<Button>(R.id.btn_diagnostics).setOnClickListener {
startActivity(Intent(this, DiagnosticsActivity::class.java))
}
}
}
import android.content.Intent
import android.os.Bundle
import android.widget.Button
import androidx.appcompat.app.AppCompatActivity
class MainActivity : AppCompatActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.activity_main)
val btnFlash = findViewById<Button>(R.id.btn_flash)
val btnAdb = findViewById<Button>(R.id.btn_adb)
val btnPc = findViewById<Button>(R.id.btn_pc)
val btnDiag = findViewById<Button>(R.id.btn_diagnostics)
btnFlash.setOnClickListener {
// You will create these activities later
startActivity(Intent(this, FlashActivity::class.java))
}
btnAdb.setOnClickListener {
startActivity(Intent(this, AdbToolsActivity::class.java))
}
btnPc.setOnClickListener {
startActivity(Intent(this, PcControlActivity::class.java))
}
btnDiag.setOnClickListener {
startActivity(Intent(this, DiagnosticsActivity::class.java))
}
}
}
Metadata
Metadata
Assignees
Labels
needs-area-labelAn area label is needed to ensure this gets routed to the appropriate area ownersAn area label is needed to ensure this gets routed to the appropriate area ownersuntriagedNew issue has not been triaged by the area ownerNew issue has not been triaged by the area owner