Brion VIBBER has submitted this change and it was merged.

Change subject: Don't ask to log in more than once
......................................................................


Don't ask to log in more than once

Is annoying.

Change-Id: Ic3989cf79ac7daea84ee8f1a47737dd2d3ba4ecf
---
M wikipedia/src/main/java/org/wikipedia/editing/EditSectionActivity.java
1 file changed, 9 insertions(+), 1 deletion(-)

Approvals:
  Brion VIBBER: Verified; Looks good to me, approved
  jenkins-bot: Verified



diff --git 
a/wikipedia/src/main/java/org/wikipedia/editing/EditSectionActivity.java 
b/wikipedia/src/main/java/org/wikipedia/editing/EditSectionActivity.java
index d69a1f3..449caa0 100644
--- a/wikipedia/src/main/java/org/wikipedia/editing/EditSectionActivity.java
+++ b/wikipedia/src/main/java/org/wikipedia/editing/EditSectionActivity.java
@@ -123,6 +123,7 @@
         editSaveOptionAnon.setOnClickListener(new View.OnClickListener() {
             @Override
             public void onClick(View view) {
+                wasSaveOptionsUsed = true;
                 Utils.fadeOut(editSaveOptionsContainer);
                 doSave();
             }
@@ -131,6 +132,7 @@
         editSaveOptionLogIn.setOnClickListener(new View.OnClickListener() {
             @Override
             public void onClick(View view) {
+                wasSaveOptionsUsed = true;
                 Intent loginIntent = new Intent(EditSectionActivity.this, 
LoginActivity.class);
                 startActivityForResult(loginIntent, 
LoginActivity.REQUEST_LOGIN);
             }
@@ -269,8 +271,14 @@
         Utils.crossFade(abusefilterContainer, sectionContainer);
     }
 
+    /**
+     * Set to true if the Save Options were ever used - if any one was tapped 
on.
+     * If they were, we do not show it again.
+     */
+    private boolean wasSaveOptionsUsed = false;
     private void showSaveOptions() {
-        if (editSaveOptionsContainer.getVisibility() == View.VISIBLE) {
+        if (editSaveOptionsContainer.getVisibility() == View.VISIBLE
+                || wasSaveOptionsUsed) {
             doSave();
         } else {
             Utils.fadeIn(editSaveOptionsContainer);

-- 
To view, visit https://gerrit.wikimedia.org/r/127421
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ic3989cf79ac7daea84ee8f1a47737dd2d3ba4ecf
Gerrit-PatchSet: 2
Gerrit-Project: apps/android/wikipedia
Gerrit-Branch: master
Gerrit-Owner: Yuvipanda <yuvipa...@gmail.com>
Gerrit-Reviewer: Brion VIBBER <br...@wikimedia.org>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to