| LEFT | RIGHT |
| 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-2016 Eyeo GmbH | 3 * Copyright (C) 2006-2016 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 |
| (...skipping 18 matching lines...) Expand all Loading... |
| 29 public void onCreate() | 29 public void onCreate() |
| 30 { | 30 { |
| 31 super.onCreate(); | 31 super.onCreate(); |
| 32 | 32 |
| 33 // init Adblock | 33 // init Adblock |
| 34 | 34 |
| 35 // provide preloaded subscriptions | 35 // provide preloaded subscriptions |
| 36 Map<String, Integer> map = new HashMap<String, Integer>(); | 36 Map<String, Integer> map = new HashMap<String, Integer>(); |
| 37 map.put(AndroidWebRequestResourceWrapper.EASYLIST, R.raw.easylist_min); | 37 map.put(AndroidWebRequestResourceWrapper.EASYLIST, R.raw.easylist_min); |
| 38 map.put(AndroidWebRequestResourceWrapper.EASYLIST_CHINESE, R.raw.easylist_mi
n); | 38 map.put(AndroidWebRequestResourceWrapper.EASYLIST_CHINESE, R.raw.easylist_mi
n); |
| 39 map.put(AndroidWebRequestResourceWrapper.ACCEPTABLE_ADS, R.raw.keypartner_wh
itelist); | 39 map.put(AndroidWebRequestResourceWrapper.ACCEPTABLE_ADS, R.raw.exceptionrule
s_minimal); |
| 40 | 40 |
| 41 AdblockHelper | 41 AdblockHelper |
| 42 .get() | 42 .get() |
| 43 .init(this, true, AdblockHelper.PREFERENCE_NAME) | 43 .init(this, true, AdblockHelper.PREFERENCE_NAME) |
| 44 .preloadSubscriptions(AdblockHelper.PRELOAD_PREFERENCE_NAME, map); | 44 .preloadSubscriptions(AdblockHelper.PRELOAD_PREFERENCE_NAME, map); |
| 45 } | 45 } |
| 46 } | 46 } |
| LEFT | RIGHT |