From a1f5e3dae57803eea5bbc2222c646b080476ad41 Mon Sep 17 00:00:00 2001 From: Margaret Leibovic Date: Wed, 28 Mar 2012 16:18:16 -0700 Subject: [PATCH] backout cecf156d7869 because of talos fail --- mobile/android/base/DoorHanger.java | 27 +------------------ .../base/resources/layout/doorhanger.xml | 6 ----- mobile/android/chrome/content/browser.js | 9 ++----- 3 files changed, 3 insertions(+), 39 deletions(-) diff --git a/mobile/android/base/DoorHanger.java b/mobile/android/base/DoorHanger.java index 2f4864aa12b6..372fba2f0906 100644 --- a/mobile/android/base/DoorHanger.java +++ b/mobile/android/base/DoorHanger.java @@ -43,11 +43,9 @@ import android.text.SpannableString; import android.text.method.LinkMovementMethod; import android.text.style.ForegroundColorSpan; import android.text.style.URLSpan; -import android.util.Log; import android.view.LayoutInflater; import android.view.View; import android.widget.Button; -import android.widget.CheckBox; import android.widget.LinearLayout; import android.widget.TextView; @@ -55,8 +53,6 @@ import org.json.JSONObject; import org.json.JSONException; public class DoorHanger extends LinearLayout implements Button.OnClickListener { - private static final String LOGTAG = "DoorHanger"; - private Context mContext; private LinearLayout mChoicesLayout; private TextView mTextView; @@ -65,9 +61,6 @@ public class DoorHanger extends LinearLayout implements Button.OnClickListener { // value used to identify the notification private String mValue; - // Optional checkbox added underneath message text - private CheckBox mCheckBox; - static private LayoutInflater mInflater; private int mPersistence = 0; @@ -106,18 +99,7 @@ public class DoorHanger extends LinearLayout implements Button.OnClickListener { } public void onClick(View v) { - JSONObject response = new JSONObject(); - try { - response.put("callback", v.getTag().toString()); - - // If the checkbox is being used, pass its value - if (mCheckBox != null) - response.put("checked", mCheckBox.isChecked()); - } catch (JSONException ex) { - Log.e(LOGTAG, "Error creating onClick response: " + ex); - } - - GeckoEvent e = GeckoEvent.createBroadcastEvent("Doorhanger:Reply", response.toString()); + GeckoEvent e = GeckoEvent.createBroadcastEvent("Doorhanger:Reply", v.getTag().toString()); GeckoAppShell.sendEventToGecko(e); mTab.removeDoorHanger(mValue); @@ -184,13 +166,6 @@ public class DoorHanger extends LinearLayout implements Button.OnClickListener { mTextView.setText(titleWithLink); mTextView.setMovementMethod(LinkMovementMethod.getInstance()); } catch (JSONException e) { } - - try { - String checkBoxText = options.getString("checkbox"); - mCheckBox = (CheckBox) findViewById(R.id.doorhanger_checkbox); - mCheckBox.setText(checkBoxText); - mCheckBox.setVisibility(VISIBLE); - } catch (JSONException e) { } } // This method checks with persistence and timeout options to see if diff --git a/mobile/android/base/resources/layout/doorhanger.xml b/mobile/android/base/resources/layout/doorhanger.xml index 1f8516105479..9df165dcdf4b 100644 --- a/mobile/android/base/resources/layout/doorhanger.xml +++ b/mobile/android/base/resources/layout/doorhanger.xml @@ -9,12 +9,6 @@ android:textColorLink="@color/doorhanger_link" android:padding="10dp"/> - -