mirror of
https://github.com/SimpleMobileTools/Simple-Camera.git
synced 2025-06-27 09:02:59 +02:00
create a dialog for changing resolutions
This commit is contained in:
@ -0,0 +1,28 @@
|
||||
package com.simplemobiletools.camera.dialogs
|
||||
|
||||
import android.support.v7.app.AlertDialog
|
||||
import android.view.LayoutInflater
|
||||
import com.simplemobiletools.camera.R
|
||||
import com.simplemobiletools.camera.activities.SimpleActivity
|
||||
import com.simplemobiletools.commons.extensions.setupDialogStuff
|
||||
import kotlinx.android.synthetic.main.dialog_change_resolution.view.*
|
||||
|
||||
class ChangeResolutionDialog(val activity: SimpleActivity, val backCamera: Boolean, val callback: () -> Unit) {
|
||||
init {
|
||||
val view = LayoutInflater.from(activity).inflate(R.layout.dialog_change_resolution, null).apply {
|
||||
change_resolution_photo_holder.setOnClickListener {
|
||||
|
||||
}
|
||||
|
||||
change_resolution_video_holder.setOnClickListener {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
AlertDialog.Builder(activity)
|
||||
.setPositiveButton(R.string.ok, null)
|
||||
.create().apply {
|
||||
activity.setupDialogStuff(view, this, if (backCamera) R.string.back_camera else R.string.front_camera)
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user