Backed out 2 changesets (bug 1390203) to help back out another patch a=backout

Backed out changeset b1779a4ff84a (bug 1390203)
Backed out changeset 772283005b0d (bug 1390203)

MozReview-Commit-ID: AS7NfLgQfq9

--HG--
extra : rebase_source : 6d9aa0b04eb7bc308767b7a51aef587b4ed0771c
This commit is contained in:
Wes Kocher 2017-08-23 14:08:12 -07:00
Родитель 3ce0ddebd5
Коммит 842a3e50aa
2 изменённых файлов: 1 добавлений и 10 удалений

Просмотреть файл

@ -19,7 +19,6 @@ import org.mozilla.gecko.R;
import org.mozilla.gecko.icons.IconCallback;
import org.mozilla.gecko.icons.IconResponse;
import org.mozilla.gecko.icons.Icons;
import org.mozilla.gecko.util.NetworkUtils;
import org.mozilla.gecko.widget.FaviconView;
import java.util.concurrent.Future;
@ -59,10 +58,7 @@ public class StreamOverridablePageIconLayout extends FrameLayout implements Icon
public void updateIcon(@NonNull final String pageURL, @Nullable final String overrideImageURL) {
cancelPendingRequests();
// We don't know how the large the non-favicon images could be (bug 1388415) so for now we're only going
// to download them on wifi. Alternatively, we could get these from the Gecko cache (see below).
if (NetworkUtils.isWifi(getContext()) &&
!TextUtils.isEmpty(overrideImageURL)) {
if (!TextUtils.isEmpty(overrideImageURL)) {
setUIMode(UIMode.NONFAVICON_IMAGE);
// TODO (bug 1322501): Optimization: since we've already navigated to these pages, there's a chance

Просмотреть файл

@ -110,11 +110,6 @@ public class NetworkUtils {
}
}
public static boolean isWifi(@NonNull final Context context) {
final ConnectivityManager connectivityManager = (ConnectivityManager) context.getSystemService(Context.CONNECTIVITY_SERVICE);
return getConnectionType(connectivityManager) == ConnectionType.WIFI;
}
public static ConnectionType getConnectionType(ConnectivityManager connectivityManager) {
if (connectivityManager == null) {
return ConnectionType.NONE;