Commit 8d727b4a authored by Daniel Wolf's avatar Daniel Wolf
Browse files

Use the close button instead of the ok button to be more aligned with other dialogs

parent 2a14c671
......@@ -48,6 +48,13 @@ fun showPrivacyPolicyDialog(context: Context) {
dialog.show()
}
fun showInfoTextDialogWithClose(
context: Context,
title: String,
text: String,
withDialog: (AlertDialog.() -> Unit)? = null,
) = showInfoTextDialog(context, title, text, neutralButton = null, positiveButton = context.getString(R.string.all_close) to null, withDialog = withDialog)
fun showInfoTextDialog(context:Context,
title:String,
text:String,
......
......@@ -126,11 +126,9 @@ class MainActivity : NavigationDrawerActivity() {
}
}
view.infoButton.setOnClickListener {
showInfoTextDialog(this,
showInfoTextDialogWithClose(this,
getString(R.string.dialog_latency_sidebar_title),
getString(R.string.dialog_latency_sidebar_message),
)
getString(R.string.dialog_latency_sidebar_message))
}
networkManager.registerNetworkCallback(NetworkRequest.Builder().apply {
addCapability(NetworkCapabilities.NET_CAPABILITY_NOT_VPN)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment