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

Side by Side Diff: adblockplussbrowser/src/main/java/org/adblockplus/sbrowser/contentblocker/util/SubscriptionUtils.java

Issue 29760569: Issue 6238 - Download/store notifications.json (Closed)
Patch Set: Created May 15, 2018, 9:57 a.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 | « adblockplussbrowser/src/main/java/org/adblockplus/sbrowser/contentblocker/util/SharedPrefsUtils.java ('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 /* 1 /*
2 * This file is part of Adblock Plus <https://adblockplus.org/>, 2 * This file is part of Adblock Plus <https://adblockplus.org/>,
3 * Copyright (C) 2006-present eyeo GmbH 3 * Copyright (C) 2006-present eyeo GmbH
4 * 4 *
5 * Adblock Plus is free software: you can redistribute it and/or modify 5 * Adblock Plus is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as 6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
8 * 8 *
9 * Adblock Plus is distributed in the hope that it will be useful, 9 * Adblock Plus is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details. 12 * GNU General Public License for more details.
13 * 13 *
14 * You should have received a copy of the GNU General Public License 14 * You should have received a copy of the GNU General Public License
15 * along with Adblock Plus. If not, see <http://www.gnu.org/licenses/>. 15 * along with Adblock Plus. If not, see <http://www.gnu.org/licenses/>.
16 */ 16 */
17 17
18 package org.adblockplus.sbrowser.contentblocker.util; 18 package org.adblockplus.sbrowser.contentblocker.util;
19 19
20 import java.util.List; 20 import java.util.List;
21 import java.util.Locale; 21 import java.util.Locale;
22 22
23 import org.adblockplus.adblockplussbrowser.BuildConfig; 23 import org.adblockplus.adblockplussbrowser.BuildConfig;
24 import org.adblockplus.sbrowser.contentblocker.engine.Notification;
24 import org.adblockplus.sbrowser.contentblocker.engine.DefaultSubscriptionInfo; 25 import org.adblockplus.sbrowser.contentblocker.engine.DefaultSubscriptionInfo;
25 import org.adblockplus.sbrowser.contentblocker.engine.Engine; 26 import org.adblockplus.sbrowser.contentblocker.engine.Engine;
26 27
27 import android.content.res.Resources; 28 import android.content.res.Resources;
28 29
29 public class SubscriptionUtils 30 public class SubscriptionUtils
30 { 31 {
31 32
32 public static final String EASYLIST_URL = "https://easylist-downloads.adblockp lus.org/easylist.txt"; 33 public static final String EASYLIST_URL = "https://easylist-downloads.adblockp lus.org/easylist.txt";
33 private static final String EASYLIST_CHINA_URL ="https://easylist-downloads.ad blockplus.org/easylistchina+easylist.txt"; 34 private static final String EASYLIST_CHINA_URL ="https://easylist-downloads.ad blockplus.org/easylistchina+easylist.txt";
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 case HEBREW_OLD: 90 case HEBREW_OLD:
90 return HEBREW_NEW; 91 return HEBREW_NEW;
91 case YIDDISH_OLD: 92 case YIDDISH_OLD:
92 return YIDDISH_NEW; 93 return YIDDISH_NEW;
93 case INDONESIAN_OLD: 94 case INDONESIAN_OLD:
94 return INDONESIAN_NEW; 95 return INDONESIAN_NEW;
95 default: 96 default:
96 return language; 97 return language;
97 } 98 }
98 } 99 }
100
101 public static boolean isNotificationSubscription(final String id)
102 {
103 return id != null && id.contains(Notification.NOTIFICATION_URL);
104 }
99 } 105 }
OLDNEW
« no previous file with comments | « adblockplussbrowser/src/main/java/org/adblockplus/sbrowser/contentblocker/util/SharedPrefsUtils.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld