From fd571c53ce20897969e957158097c2f16206d73d Mon Sep 17 00:00:00 2001 From: Harsh Shandilya Date: Thu, 3 May 2018 23:05:51 +0530 Subject: [PATCH] TunnelEditor: Add toast messages to success events Letting the user know that the operation went successfully via visual cues is a nice UX touch. Signed-off-by: Harsh Shandilya --- .../com/wireguard/android/fragment/TunnelEditorFragment.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/src/main/java/com/wireguard/android/fragment/TunnelEditorFragment.java b/app/src/main/java/com/wireguard/android/fragment/TunnelEditorFragment.java index 3eb98584..91d5131b 100644 --- a/app/src/main/java/com/wireguard/android/fragment/TunnelEditorFragment.java +++ b/app/src/main/java/com/wireguard/android/fragment/TunnelEditorFragment.java @@ -20,6 +20,7 @@ import android.view.MenuItem; import android.view.View; import android.view.ViewGroup; import android.view.inputmethod.InputMethodManager; +import android.widget.Toast; import com.wireguard.android.Application; import com.wireguard.android.R; @@ -51,6 +52,7 @@ public class TunnelEditorFragment extends BaseFragment { if (throwable == null) { message = getString(R.string.config_save_success, savedTunnel.getName()); Log.d(TAG, message); + Toast.makeText(getContext(), message, Toast.LENGTH_SHORT).show(); onFinished(); } else { final String error = ExceptionLoggers.unwrap(throwable).getMessage();