forked from sannurmersan/mainsan
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- (중고거래 -> 상품선택 -> 구매하기) 현재 총 3페이지 전환 소스와 백그라운드 파일 추가 - 백그라운드 파일 drawble 디렉토리에 추가함 2. 유의사항 - 피그마 2번 방법 페이지에 이미지를 화면에 맞게 변경하였음 - 현재 버튼은 투명버튼이 아님. 우려한대로 백그라운드 이미지의 비율이 변하면 버튼의 위치와 호환되고 있지 않음
- Loading branch information
Showing
7 changed files
with
90 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
plugins { | ||
id 'com.android.application' | ||
id 'kotlin-android' | ||
id'kotlin-android-extensions' | ||
} | ||
|
||
android { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,18 @@ | ||
package com.mintcho.wwmarket2 | ||
|
||
import android.content.Intent | ||
import androidx.appcompat.app.AppCompatActivity | ||
import android.os.Bundle | ||
import kotlinx.android.synthetic.main.activity_main.* | ||
|
||
class MainActivity : AppCompatActivity() { | ||
override fun onCreate(savedInstanceState: Bundle?) { | ||
super.onCreate(savedInstanceState) | ||
setContentView(R.layout.activity_main) | ||
setContentView(R.layout.activity_main) //layout 디렉토리의 xml와 1대1 매칭되도록 activity_main | ||
|
||
mButton.setOnClickListener { | ||
val intent = Intent(this, SubActivity::class.java) //버튼 누르면 넘어갈 페이지를 Subactivity 위치에 알맞게 변경할것 | ||
startActivity(intent) | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
package com.mintcho.wwmarket2 | ||
|
||
import android.content.Intent | ||
import androidx.appcompat.app.AppCompatActivity | ||
import android.os.Bundle | ||
import kotlinx.android.synthetic.main.activity_main.* | ||
|
||
class SubActivity : AppCompatActivity() { | ||
override fun onCreate(savedInstanceState: Bundle?) { | ||
super.onCreate(savedInstanceState) | ||
setContentView(R.layout.activity_sub) | ||
|
||
mButton.setOnClickListener { | ||
val intent = Intent(this, SubActivity2::class.java) | ||
startActivity(intent) | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package com.mintcho.wwmarket2 | ||
|
||
import androidx.appcompat.app.AppCompatActivity | ||
import android.os.Bundle | ||
|
||
class SubActivity2 : AppCompatActivity() { | ||
override fun onCreate(savedInstanceState: Bundle?) { | ||
super.onCreate(savedInstanceState) | ||
setContentView(R.layout.activity_sub2) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,23 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android" | ||
xmlns:app="http://schemas.android.com/apk/res-auto" | ||
<androidx.constraintlayout.widget.ConstraintLayout | ||
xmlns:android="http://schemas.android.com/apk/res/android" | ||
xmlns:tools="http://schemas.android.com/tools" | ||
xmlns:app="http://schemas.android.com/apk/res-auto" | ||
android:layout_width="match_parent" | ||
android:layout_height="match_parent" | ||
tools:context=".MainActivity"> | ||
android:background="@drawable/main2" | ||
android:gravity="center" | ||
tools:context=".MainActivity"> <!--.MainActivity java디렉토리의 액티비티와 대응되도록 변경할것 --> | ||
|
||
<TextView | ||
android:layout_width="wrap_content" | ||
android:layout_height="wrap_content" | ||
android:text="Hello World!" | ||
app:layout_constraintBottom_toBottomOf="parent" | ||
app:layout_constraintLeft_toLeftOf="parent" | ||
app:layout_constraintRight_toRightOf="parent" | ||
app:layout_constraintTop_toTopOf="parent" /> | ||
|
||
<Button | ||
android:id="@+id/mButton" | ||
android:layout_width="66dp" | ||
android:layout_height="64dp" | ||
android:layout_marginStart="24dp" | ||
android:layout_marginLeft="24dp" | ||
android:layout_marginTop="68dp" | ||
android:text="화면전환" | ||
app:layout_constraintStart_toStartOf="parent" | ||
app:layout_constraintTop_toTopOf="parent" /> | ||
</androidx.constraintlayout.widget.ConstraintLayout> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<androidx.constraintlayout.widget.ConstraintLayout | ||
xmlns:android="http://schemas.android.com/apk/res/android" | ||
xmlns:app="http://schemas.android.com/apk/res-auto" | ||
xmlns:tools="http://schemas.android.com/tools" | ||
android:layout_width="match_parent" | ||
android:layout_height="match_parent" | ||
android:background="@drawable/main3" | ||
android:gravity="center" | ||
tools:context=".SubActivity"> | ||
|
||
|
||
<Button | ||
android:id="@+id/mButton" | ||
android:layout_width="161dp" | ||
android:layout_height="66dp" | ||
android:layout_marginStart="196dp" | ||
android:layout_marginLeft="196dp" | ||
android:layout_marginTop="648dp" | ||
android:text="화면전환" | ||
app:layout_constraintStart_toStartOf="parent" | ||
app:layout_constraintTop_toTopOf="parent" /> | ||
|
||
</androidx.constraintlayout.widget.ConstraintLayout> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<androidx.constraintlayout.widget.ConstraintLayout | ||
xmlns:android="http://schemas.android.com/apk/res/android" | ||
xmlns:app="http://schemas.android.com/apk/res-auto" | ||
xmlns:tools="http://schemas.android.com/tools" | ||
android:layout_width="match_parent" | ||
android:layout_height="match_parent" | ||
android:background="@drawable/main4" | ||
android:gravity="center" | ||
tools:context=".SubActivity2"> | ||
|
||
</androidx.constraintlayout.widget.ConstraintLayout> |