зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1411654 - Part 5b: Work through WrongConstant lint issues. r=mcomella
MozReview-Commit-ID: 6zJ7EMu9rgO --HG-- extra : rebase_source : d3a228caa4c21ce17184302559f3a8e233fb00b7 extra : source : c5bf85d56fedf600363dda3b077fdf950ba60688
This commit is contained in:
Родитель
6ee03c9306
Коммит
c4499269d8
|
@ -38,7 +38,6 @@
|
|||
<issue id="ResourceAsColor" severity="warning" />
|
||||
<issue id="ResourceType" severity="warning" />
|
||||
<issue id="ValidFragment" severity="warning" />
|
||||
<issue id="WrongConstant" severity="warning" />
|
||||
|
||||
<!-- New Android-Gradle lint integration regressed this check. -->
|
||||
<issue id="MissingRegistered" severity="warning" />
|
||||
|
|
|
@ -5,6 +5,7 @@
|
|||
|
||||
package org.mozilla.gecko.activitystream;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.content.Context;
|
||||
import android.content.SharedPreferences;
|
||||
import android.content.res.Resources;
|
||||
|
@ -216,8 +217,7 @@ public class ActivityStreamTelemetry {
|
|||
break;
|
||||
// While we also have a "blank" type, it is not used by Activity Stream.
|
||||
case BrowserContract.TopSites.TYPE_BLANK:
|
||||
default:
|
||||
throw new IllegalStateException("Unknown top site type: " + topSite.getType());
|
||||
throw new IllegalStateException("Unknown top site type :" + (int) topSite.getType());
|
||||
}
|
||||
|
||||
return this;
|
||||
|
|
|
@ -5,6 +5,7 @@
|
|||
|
||||
package org.mozilla.gecko.dlc;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.content.Context;
|
||||
import android.support.annotation.IntDef;
|
||||
import android.util.Log;
|
||||
|
@ -100,7 +101,7 @@ public abstract class BaseAction {
|
|||
} else if (content.isHyphenationDictionary()) {
|
||||
destinationDirectory = new File(context.getApplicationInfo().dataDir, "hyphenation");
|
||||
} else {
|
||||
throw new UnrecoverableDownloadContentException("Can't determine destination for kind: " + content.getKind());
|
||||
throw new UnrecoverableDownloadContentException("Can't determine destination for kind: " + (String) content.getKind());
|
||||
}
|
||||
|
||||
if (!destinationDirectory.exists() && !destinationDirectory.mkdirs()) {
|
||||
|
|
|
@ -5,6 +5,7 @@
|
|||
|
||||
package org.mozilla.gecko.dlc;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.content.Context;
|
||||
import android.net.ConnectivityManager;
|
||||
import android.net.NetworkInfo;
|
||||
|
@ -106,7 +107,7 @@ public class DownloadAction extends BaseAction {
|
|||
}
|
||||
|
||||
if (!content.isAssetArchive()) {
|
||||
Log.e(LOGTAG, "Downloaded content is not of type 'asset-archive': " + content.getType());
|
||||
Log.e(LOGTAG, "Downloaded content is not of type 'asset-archive': " + (String) content.getType());
|
||||
temporaryFile.delete();
|
||||
DownloadContentTelemetry.eventDownloadFailure(content, DownloadContentTelemetry.ERROR_LOGIC);
|
||||
continue;
|
||||
|
|
|
@ -1160,7 +1160,7 @@ gbjar.extra_jars += [CONFIG['ANDROID_DESIGN_AAR_LIB']]
|
|||
gbjar.extra_jars += [CONFIG['ANDROID_RECYCLERVIEW_V7_AAR_LIB']]
|
||||
gbjar.extra_jars += [CONFIG['ANDROID_CUSTOMTABS_AAR_LIB']]
|
||||
|
||||
gbjar.javac_flags += ['-Xlint:all,-deprecation,-fallthrough', '-J-Xmx512m', '-J-Xms128m']
|
||||
gbjar.javac_flags += ['-Xlint:all,-deprecation,-fallthrough,-cast', '-J-Xmx512m', '-J-Xms128m']
|
||||
|
||||
# gecko-thirdparty is a good place to put small independent libraries
|
||||
gtjar = add_java_jar('gecko-thirdparty')
|
||||
|
|
Загрузка…
Ссылка в новой задаче