Skip to content

Commit

Permalink
[Maro/#47] feat :: 10주차 구현 완료 (#48)
Browse files Browse the repository at this point in the history
* [maro/#47] feat :: 패키지 구조화

* [maro/#47] feat :: 카카오 로그인 구현
  • Loading branch information
leesumin0526 authored Jun 25, 2024
1 parent 255a4d8 commit d2e06f4
Show file tree
Hide file tree
Showing 60 changed files with 307 additions and 219 deletions.
86 changes: 57 additions & 29 deletions .idea/workspace.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 5 additions & 0 deletions UMC_6th/app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ plugins {
id("kotlin-kapt")
}



android {
namespace = "com.example.umc_6th"
compileSdk = 34
Expand All @@ -16,6 +18,7 @@ android {
dataBinding = true
}


defaultConfig {
applicationId = "com.example.umc_6th"
minSdk = 24
Expand Down Expand Up @@ -43,9 +46,11 @@ android {
jvmTarget = JavaVersion.VERSION_1_8.toString()
}


}

dependencies {
implementation("com.kakao.sdk:v2-user:2.12.1")
implementation("com.google.android.material:material:1.10.0")
implementation("androidx.room:room-migration:2.6.0")
implementation("androidx.room:room-runtime:2.6.0")
Expand Down
13 changes: 9 additions & 4 deletions UMC_6th/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
<uses-permission android:name="android.permission.INTERNET" />

<application
android:name=".GlobalApplication"
android:allowBackup="true"
android:dataExtractionRules="@xml/data_extraction_rules"
android:fullBackupContent="@xml/backup_rules"
Expand All @@ -17,12 +18,16 @@
android:supportsRtl="true"
android:theme="@style/Theme.UMC_6th"
tools:targetApi="31">
<meta-data
android:name="com.kakao.sdk.AppKey"
android:value="9869def2f21ef97ba7f905ec34960cbb"/>

<activity android:name=".SignUpActivity" />
<activity android:name=".LoginActivity"/>
<activity android:name=".auth.SignUpActivity" />
<activity android:name=".auth.LoginActivity"/>
<activity android:name=".GlobalApplication"/>

<activity
android:name=".MainActivity"
android:name=".ui.MainActivity"
android:exported="true"
android:theme="@style/SplashTheme">
<intent-filter>
Expand All @@ -32,7 +37,7 @@
</intent-filter>
</activity>
<activity
android:name=".SongActivity"
android:name=".music.SongActivity"
android:exported="true" />
</application>

Expand Down
13 changes: 13 additions & 0 deletions UMC_6th/app/src/main/java/com/example/umc_6th/GlobalApplication.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
package com.example.umc_6th

import android.app.Application
import com.kakao.sdk.common.KakaoSdk

class GlobalApplication : Application() {
override fun onCreate() {
super.onCreate()

// Kakao Sdk 초기화
KakaoSdk.init(this, "9869def2f21ef97ba7f905ec34960cbb")
}
}
93 changes: 0 additions & 93 deletions UMC_6th/app/src/main/java/com/example/umc_6th/LoginActivity.kt

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
package com.example.umc_6th
package com.example.umc_6th.adapters

import android.view.LayoutInflater
import android.view.ViewGroup
import androidx.recyclerview.widget.RecyclerView
import com.example.umc_6th.databinding.ItemAlbumBinding
import com.example.umc_6th.music.Album

class AlbumRVAdapter(private val albumList:ArrayList<Album>) : RecyclerView.Adapter<AlbumRVAdapter.ViewHolder>() {

Expand Down Expand Up @@ -32,13 +33,13 @@ class AlbumRVAdapter(private val albumList:ArrayList<Album>) : RecyclerView.Adap
notifyDataSetChanged()
}

override fun onCreateViewHolder(viewGroup: ViewGroup, viewType: Int): AlbumRVAdapter.ViewHolder {
override fun onCreateViewHolder(viewGroup: ViewGroup, viewType: Int): ViewHolder {
val binding: ItemAlbumBinding = ItemAlbumBinding.inflate(LayoutInflater.from(viewGroup.context),viewGroup,false)

return ViewHolder(binding)
}

override fun onBindViewHolder(holder: AlbumRVAdapter.ViewHolder, position: Int) {
override fun onBindViewHolder(holder: ViewHolder, position: Int) {
holder.bind(albumList[position])
holder.itemView.setOnClickListener{
mItemClickListener.onItemClick(albumList[position]) }
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
package com.example.umc_6th
package com.example.umc_6th.adapters

import androidx.fragment.app.Fragment
import androidx.viewpager2.adapter.FragmentStateAdapter
import com.example.umc_6th.music.SongFragment
import com.example.umc_6th.ui.DetailFragment
import com.example.umc_6th.ui.VideoFragment

class AlbumVPAdapter(fragment:Fragment) : FragmentStateAdapter(fragment){
override fun getItemCount(): Int = 3
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.example.umc_6th
package com.example.umc_6th.adapters

import androidx.fragment.app.Fragment
import androidx.viewpager2.adapter.FragmentStateAdapter
Expand Down
Loading

0 comments on commit d2e06f4

Please sign in to comment.