feat: 스플래시 변경
This commit is contained in:
@@ -6,7 +6,7 @@ import android.net.Uri
|
|||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.os.Handler
|
import android.os.Handler
|
||||||
import android.os.Looper
|
import android.os.Looper
|
||||||
import android.widget.ImageView
|
import android.view.View
|
||||||
import androidx.annotation.OptIn
|
import androidx.annotation.OptIn
|
||||||
import androidx.constraintlayout.widget.ConstraintLayout
|
import androidx.constraintlayout.widget.ConstraintLayout
|
||||||
import androidx.media3.common.util.UnstableApi
|
import androidx.media3.common.util.UnstableApi
|
||||||
@@ -30,21 +30,20 @@ class SplashActivity : BaseActivity<ActivitySplashBinding>(ActivitySplashBinding
|
|||||||
override fun onCreate(savedInstanceState: Bundle?) {
|
override fun onCreate(savedInstanceState: Bundle?) {
|
||||||
super.onCreate(savedInstanceState)
|
super.onCreate(savedInstanceState)
|
||||||
|
|
||||||
setLayoutParams(binding.ivText, start = 0, end = 0, top = 150, bottom = 0)
|
setLayoutParams(binding.llText, start = 0, end = 0, top = 615, bottom = 0)
|
||||||
setLayoutParams(binding.ivText2, start = 0, end = 0, top = 0, bottom = 180)
|
|
||||||
|
|
||||||
setupRemoteConfig()
|
setupRemoteConfig()
|
||||||
fetchAndroidLatestVersion()
|
fetchAndroidLatestVersion()
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun setLayoutParams(
|
private fun setLayoutParams(
|
||||||
imageView: ImageView,
|
view: View,
|
||||||
start: Int = 0,
|
start: Int = 0,
|
||||||
end: Int = 0,
|
end: Int = 0,
|
||||||
top: Int = 0,
|
top: Int = 0,
|
||||||
bottom: Int = 0
|
bottom: Int = 0
|
||||||
) {
|
) {
|
||||||
val lp = imageView.layoutParams as ConstraintLayout.LayoutParams
|
val lp = view.layoutParams as ConstraintLayout.LayoutParams
|
||||||
|
|
||||||
if (top > 0) {
|
if (top > 0) {
|
||||||
lp.topMargin = screenHeight * top / 2337
|
lp.topMargin = screenHeight * top / 2337
|
||||||
@@ -62,7 +61,7 @@ class SplashActivity : BaseActivity<ActivitySplashBinding>(ActivitySplashBinding
|
|||||||
lp.rightMargin = screenWidth * end / 1080
|
lp.rightMargin = screenWidth * end / 1080
|
||||||
}
|
}
|
||||||
|
|
||||||
imageView.layoutParams = lp
|
view.layoutParams = lp
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun setupRemoteConfig() {
|
private fun setupRemoteConfig() {
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 3.1 MiB After Width: | Height: | Size: 1.4 MiB |
Binary file not shown.
|
Before Width: | Height: | Size: 17 KiB After Width: | Height: | Size: 7.8 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 12 KiB |
@@ -15,25 +15,28 @@
|
|||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/ll_text"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="vertical"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent">
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/iv_text"
|
android:id="@+id/iv_text"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:contentDescription="@null"
|
android:contentDescription="@null"
|
||||||
android:src="@drawable/splash_text1"
|
android:src="@drawable/splash_text1" />
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
/>
|
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/iv_text2"
|
android:id="@+id/iv_text2"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="6dp"
|
||||||
android:contentDescription="@null"
|
android:contentDescription="@null"
|
||||||
android:src="@drawable/splash_text2"
|
android:src="@drawable/splash_text2" />
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
</LinearLayout>
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
/>
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|||||||
Reference in New Issue
Block a user