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

Unified Diff: src/org/adblockplus/android/ABPEngine.java

Issue 6603326711922688: Issue 328 - ABP doesn't respect the system locale when adding a filter list (Closed)
Patch Set: Created June 11, 2014, 8:42 a.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/org/adblockplus/android/ABPEngine.java
diff --git a/src/org/adblockplus/android/ABPEngine.java b/src/org/adblockplus/android/ABPEngine.java
index ab56b87a439eac785c444605d22e7554e2685ec7..a58ba578226430558daa1f4fcaf0a83ffbab4ed5 100644
--- a/src/org/adblockplus/android/ABPEngine.java
+++ b/src/org/adblockplus/android/ABPEngine.java
@@ -18,6 +18,7 @@
package org.adblockplus.android;
import java.util.List;
+import java.util.Locale;
import org.adblockplus.libadblockplus.AppInfo;
import org.adblockplus.libadblockplus.EventCallback;
@@ -79,7 +80,7 @@ public final class ABPEngine
Log.e(TAG, "Failed to get the application version number", e);
}
final String sdkVersion = String.valueOf(VERSION.SDK_INT);
- final String locale = context.getResources().getConfiguration().locale.toString();
+ final String locale = Locale.getDefault().toString().replace('_', '-');
final boolean developmentBuild = !context.getResources().getBoolean(R.bool.def_release);
return AppInfo.builder()
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld