LEFT | RIGHT |
1 /* -*- Mode: Java; c-basic-offset: 4; tab-width: 20; indent-tabs-mode: nil; -*- | 1 /* -*- Mode: Java; c-basic-offset: 4; tab-width: 20; indent-tabs-mode: nil; -*- |
2 * This Source Code Form is subject to the terms of the Mozilla Public | 2 * This Source Code Form is subject to the terms of the Mozilla Public |
3 * License, v. 2.0. If a copy of the MPL was not distributed with this | 3 * License, v. 2.0. If a copy of the MPL was not distributed with this |
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ | 4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ |
5 | 5 |
6 package org.mozilla.gecko.toolbar; | 6 package org.mozilla.gecko.toolbar; |
7 | 7 |
8 import android.app.Activity; | 8 import android.app.Activity; |
9 import android.content.Intent; | 9 import android.content.Intent; |
10 import android.graphics.drawable.Drawable; | 10 import android.graphics.drawable.Drawable; |
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
144 return; | 144 return; |
145 } | 145 } |
146 | 146 |
147 // When on tablet show a magnifying glass in editing mode | 147 // When on tablet show a magnifying glass in editing mode |
148 final int searchDrawableId = R.drawable.search_icon_active; | 148 final int searchDrawableId = R.drawable.search_icon_active; |
149 final Drawable searchDrawable; | 149 final Drawable searchDrawable; |
150 if (!isActive) { | 150 if (!isActive) { |
151 searchDrawable = DrawableUtil.tintDrawable(getContext(), searchDrawa
bleId, R.color.placeholder_grey); | 151 searchDrawable = DrawableUtil.tintDrawable(getContext(), searchDrawa
bleId, R.color.placeholder_grey); |
152 } else { | 152 } else { |
153 if (isPrivateMode()) { | 153 if (isPrivateMode()) { |
| 154 // Modified in order to follow ABB style guide. See https://issu
es.adblockplus.org/ticket/3769 |
154 searchDrawable = DrawableUtil.tintDrawable(getContext(), searchD
rawableId, R.color.private_active_text); | 155 searchDrawable = DrawableUtil.tintDrawable(getContext(), searchD
rawableId, R.color.private_active_text); |
155 } else { | 156 } else { |
156 searchDrawable = getResources().getDrawable(searchDrawableId); | 157 searchDrawable = getResources().getDrawable(searchDrawableId); |
157 } | 158 } |
158 } | 159 } |
159 | 160 |
160 mSearchIcon.setImageDrawable(searchDrawable); | 161 mSearchIcon.setImageDrawable(searchDrawable); |
161 } | 162 } |
162 | 163 |
163 @Override | 164 @Override |
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
337 showKeyboardOnFocus = true; | 338 showKeyboardOnFocus = true; |
338 } | 339 } |
339 } | 340 } |
340 // We can get the SCAN_RESULT_FORMAT, SCAN_RESULT_BYTES, | 341 // We can get the SCAN_RESULT_FORMAT, SCAN_RESULT_BYTES, |
341 // SCAN_RESULT_ORIENTATION and SCAN_RESULT_ERROR_CORRECTION_LEVE
L | 342 // SCAN_RESULT_ORIENTATION and SCAN_RESULT_ERROR_CORRECTION_LEVE
L |
342 // as well as the actual result, which may hold a URL. | 343 // as well as the actual result, which may hold a URL. |
343 } | 344 } |
344 }); | 345 }); |
345 } | 346 } |
346 } | 347 } |
LEFT | RIGHT |