Archive
-
안드로이드 앱 개발 연습 - 3 | Spinner & RecyclerViewArchive/캡스톤디자인 2022. 3. 24. 18:39
Spinner MainActivity.kt class MainActivity : AppCompatActivity() { private val binding by lazy { ActivityMainBinding.inflate(layoutInflater) } override fun onCreate(savedInstanceState: Bundle?) { super.onCreate(savedInstanceState) setContentView(binding.root) val spinnerData = listOf("First", "Second", "Third") val spinnerAdapter = ArrayAdapter(this, android.R.layout.simple_list_item_1, spinnerD..
-
안드로이드 앱 개발 연습 - 2 | ActivityArchive/캡스톤디자인 2022. 3. 23. 15:02
SubActivity 실행 및 데이터 넘기기 MainActivity.kt class MainActivity : AppCompatActivity() { private val binding by lazy { ActivityMainBinding.inflate(layoutInflater) } override fun onCreate(savedInstanceState: Bundle?) { super.onCreate(savedInstanceState) setContentView(binding.root) val intent = Intent(this, SubActivity::class.java) intent.putExtra("data1", "First Data") intent.putExtra("data2", 2022) ..
-
안드로이드 앱 개발 연습 - 1 | Basic Setting & EventArchive/캡스톤디자인 2022. 3. 22. 19:32
Basic Setting build.gradle (:app) android { buildFeatures { viewBinding true } ... } MainActivity.kt class MainActivity : AppCompatActivity() { private val binding by lazy { ActivityMainBinding.inflate(layoutInflater) } override fun onCreate(savedInstanceState: Bundle?) { super.onCreate(savedInstanceState) setContentView(binding.root) } } Button Event Basic Button class MainActivity : AppCompatA..