summaryrefslogtreecommitdiff
path: root/app/src/main/java/se/leap/bitmaskclient/fragments
diff options
context:
space:
mode:
authorcyBerta <cyberta@riseup.net>2018-03-02 23:09:08 +0100
committercyBerta <cyberta@riseup.net>2018-03-02 23:09:08 +0100
commitb14e4b9a7940adb4580c0f3c7a0edcb339c73ae8 (patch)
treeb364d18a5934736c24a1667b4728fa1032b8d327 /app/src/main/java/se/leap/bitmaskclient/fragments
parent30244cbf5b7eaf6152bcdc2cb5b6848f6e10798d (diff)
#8808 adds an optional dialog that shows instruction hints for always-on vpn
Diffstat (limited to 'app/src/main/java/se/leap/bitmaskclient/fragments')
-rw-r--r--app/src/main/java/se/leap/bitmaskclient/fragments/AlwaysOnDialog.java8
1 files changed, 6 insertions, 2 deletions
diff --git a/app/src/main/java/se/leap/bitmaskclient/fragments/AlwaysOnDialog.java b/app/src/main/java/se/leap/bitmaskclient/fragments/AlwaysOnDialog.java
index 80510b86..4e8e3d79 100644
--- a/app/src/main/java/se/leap/bitmaskclient/fragments/AlwaysOnDialog.java
+++ b/app/src/main/java/se/leap/bitmaskclient/fragments/AlwaysOnDialog.java
@@ -15,6 +15,7 @@ import android.widget.CheckBox;
import butterknife.ButterKnife;
import butterknife.InjectView;
import se.leap.bitmaskclient.R;
+import se.leap.bitmaskclient.views.IconTextView;
import static se.leap.bitmaskclient.ConfigHelper.saveShowAlwaysOnDialog;
@@ -31,6 +32,9 @@ public class AlwaysOnDialog extends AppCompatDialogFragment {
@InjectView(R.id.do_not_show_again)
CheckBox doNotShowAgainCheckBox;
+ @InjectView(R.id.user_message)
+ IconTextView userMessage;
+
@Override
public void onCreate(@Nullable Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
@@ -44,8 +48,9 @@ public class AlwaysOnDialog extends AppCompatDialogFragment {
View view = inflater.inflate(R.layout.checkbox_confirm_dialog, null);
ButterKnife.inject(this, view);
+ userMessage.setIcon(R.drawable.ic_settings);
+ userMessage.setText(getString(R.string.always_on_vpn_user_message));
builder.setView(view)
- .setMessage(R.string.always_on_vpn_user_message)
.setPositiveButton(android.R.string.ok, new DialogInterface.OnClickListener() {
public void onClick(DialogInterface dialog, int id) {
if (doNotShowAgainCheckBox.isChecked()) {
@@ -61,7 +66,6 @@ public class AlwaysOnDialog extends AppCompatDialogFragment {
dialog.cancel();
}
});
- // Create the AlertDialog object and return it
return builder.create();
}
}