-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'develop' into design/#25
- Loading branch information
Showing
3 changed files
with
109 additions
and
0 deletions.
There are no files selected for viewing
41 changes: 41 additions & 0 deletions
41
app/src/main/java/com/sopt/umbba_android/presentation/qna/BackAnswerDialogFragment.kt
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,41 @@ | ||
package com.sopt.umbba_android.presentation.qna | ||
|
||
import android.os.Bundle | ||
import android.view.LayoutInflater | ||
import android.view.View | ||
import android.view.ViewGroup | ||
import android.view.WindowManager | ||
import androidx.fragment.app.DialogFragment | ||
import com.sopt.umbba_android.databinding.FragmentConfirmAnswerDialogBinding | ||
|
||
class BackAnswerDialogFragment : DialogFragment() { | ||
|
||
private var _binding: FragmentConfirmAnswerDialogBinding? = null | ||
private val binding get() = requireNotNull(_binding) { "BackAnswerDialogFragment is null" } | ||
|
||
override fun onCreateView( | ||
inflater: LayoutInflater, container: ViewGroup?, | ||
savedInstanceState: Bundle? | ||
): View { | ||
_binding = FragmentConfirmAnswerDialogBinding.inflate(inflater, container, false) | ||
return binding.root | ||
} | ||
|
||
override fun onViewCreated(view: View, savedInstanceState: Bundle?) { | ||
super.onViewCreated(view, savedInstanceState) | ||
|
||
} | ||
|
||
override fun onResume() { | ||
super.onResume() | ||
dialog?.window?.setLayout( | ||
WindowManager.LayoutParams.MATCH_PARENT, | ||
WindowManager.LayoutParams.WRAP_CONTENT | ||
) | ||
} | ||
|
||
override fun onDestroy() { | ||
super.onDestroy() | ||
_binding = null | ||
} | ||
} |
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,63 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<layout xmlns:android="http://schemas.android.com/apk/res/android" | ||
xmlns:app="http://schemas.android.com/apk/res-auto"> | ||
|
||
<data> | ||
|
||
</data> | ||
|
||
<androidx.constraintlayout.widget.ConstraintLayout | ||
android:layout_width="match_parent" | ||
android:layout_height="wrap_content" | ||
android:background="@drawable/inset_dialog_background"> | ||
|
||
<TextView | ||
android:id="@+id/tv_confirm" | ||
style="@style/AndroidBody1_2Regular16" | ||
android:layout_width="wrap_content" | ||
android:layout_height="wrap_content" | ||
android:layout_marginVertical="24dp" | ||
android:gravity="center" | ||
android:text="@string/back_confirm" | ||
android:textColor="@color/black" | ||
app:layout_constraintEnd_toEndOf="parent" | ||
app:layout_constraintStart_toStartOf="parent" | ||
app:layout_constraintTop_toTopOf="parent"/> | ||
|
||
<androidx.constraintlayout.widget.ConstraintLayout | ||
android:id="@+id/cl_button" | ||
android:layout_width="match_parent" | ||
android:layout_height="wrap_content" | ||
android:layout_marginHorizontal="33dp" | ||
android:layout_marginTop="12dp" | ||
android:layout_marginBottom="23dp" | ||
app:layout_constraintTop_toBottomOf="@id/tv_confirm" | ||
app:layout_constraintBottom_toBottomOf="parent"> | ||
|
||
<androidx.appcompat.widget.AppCompatButton | ||
android:id="@+id/btn_cancel" | ||
style="@style/AndroidBody1_2Regular16" | ||
android:layout_width="124dp" | ||
android:layout_height="48dp" | ||
android:background="@drawable/shape_grey_btn_r50_stroke_rect" | ||
android:text="@string/cancel" | ||
android:textColor="@color/grey_btn_text" | ||
app:layout_constraintStart_toStartOf="parent" | ||
app:layout_constraintTop_toTopOf="parent" /> | ||
|
||
<androidx.appcompat.widget.AppCompatButton | ||
android:id="@+id/btn_save" | ||
style="@style/AndroidBody1_2Regular16" | ||
android:layout_width="124dp" | ||
android:layout_height="48dp" | ||
android:layout_marginStart="13dp" | ||
android:background="@drawable/shape_grey74_btn_r50_rect" | ||
android:text="@string/confirm" | ||
android:textColor="@color/white" | ||
app:layout_constraintStart_toEndOf="@id/btn_cancel" | ||
app:layout_constraintTop_toTopOf="parent" /> | ||
|
||
</androidx.constraintlayout.widget.ConstraintLayout> | ||
|
||
</androidx.constraintlayout.widget.ConstraintLayout> | ||
</layout> |
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