Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Side by Side Diff: mobile/android/search/java/org/mozilla/search/PreSearchFragment.java

Issue 29479633: Issue 2606 - Firefox logo shown in background on empty Adblock Browser New Tab and Search pages (Closed)
Patch Set: Created July 4, 2017, 7:50 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « mobile/android/base/resources/drawable-xxhdpi/icon_search_empty_firefox.png ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* This Source Code Form is subject to the terms of the Mozilla Public 1 /* This Source Code Form is subject to the terms of the Mozilla Public
2 * License, v. 2.0. If a copy of the MPL was not distributed with this 2 * License, v. 2.0. If a copy of the MPL was not distributed with this
3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
4 4
5 package org.mozilla.search; 5 package org.mozilla.search;
6 6
7 import android.content.Context; 7 import android.content.Context;
8 import android.database.Cursor; 8 import android.database.Cursor;
9 import android.graphics.Rect; 9 import android.graphics.Rect;
10 import android.net.Uri; 10 import android.net.Uri;
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after
175 175
176 private void updateUiFromCursor(Cursor c) { 176 private void updateUiFromCursor(Cursor c) {
177 if (c != null && c.getCount() > 0) { 177 if (c != null && c.getCount() > 0) {
178 return; 178 return;
179 } 179 }
180 180
181 if (emptyView == null) { 181 if (emptyView == null) {
182 final ViewStub emptyViewStub = (ViewStub) getView().findViewById(R.i d.empty_view_stub); 182 final ViewStub emptyViewStub = (ViewStub) getView().findViewById(R.i d.empty_view_stub);
183 emptyView = emptyViewStub.inflate(); 183 emptyView = emptyViewStub.inflate();
184 184
185 ((ImageView) emptyView.findViewById(R.id.empty_image)).setImageResou rce(R.drawable.icon_search_empty_firefox); 185 // Changed icon. See https://issues.adblockplus.org/ticket/2606
186 ((ImageView) emptyView.findViewById(R.id.empty_image)).setImageResou rce(R.drawable.abb_icon_search_empty);
186 ((TextView) emptyView.findViewById(R.id.empty_title)).setText(R.stri ng.search_empty_title); 187 ((TextView) emptyView.findViewById(R.id.empty_title)).setText(R.stri ng.search_empty_title);
187 ((TextView) emptyView.findViewById(R.id.empty_message)).setText(R.st ring.search_empty_message); 188 ((TextView) emptyView.findViewById(R.id.empty_message)).setText(R.st ring.search_empty_message);
188 189
189 listView.setEmptyView(emptyView); 190 listView.setEmptyView(emptyView);
190 } 191 }
191 } 192 }
192 193
193 private class SearchHistoryLoaderCallbacks implements LoaderManager.LoaderCa llbacks<Cursor> { 194 private class SearchHistoryLoaderCallbacks implements LoaderManager.LoaderCa llbacks<Cursor> {
194 @Override 195 @Override
195 public Loader<Cursor> onCreateLoader(int id, Bundle args) { 196 public Loader<Cursor> onCreateLoader(int id, Bundle args) {
(...skipping 10 matching lines...) Expand all
206 } 207 }
207 208
208 @Override 209 @Override
209 public void onLoaderReset(Loader<Cursor> loader) { 210 public void onLoaderReset(Loader<Cursor> loader) {
210 if (cursorAdapter != null) { 211 if (cursorAdapter != null) {
211 cursorAdapter.swapCursor(null); 212 cursorAdapter.swapCursor(null);
212 } 213 }
213 } 214 }
214 } 215 }
215 } 216 }
OLDNEW
« no previous file with comments | « mobile/android/base/resources/drawable-xxhdpi/icon_search_empty_firefox.png ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld