OLD | NEW |
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 |
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
126 .property("lastCheck", &DownloadableSubscription::GetLastCheck, &Downloa
dableSubscription::SetLastCheck) | 126 .property("lastCheck", &DownloadableSubscription::GetLastCheck, &Downloa
dableSubscription::SetLastCheck) |
127 .property("hardExpiration", &DownloadableSubscription::GetHardExpiration
, &DownloadableSubscription::SetHardExpiration) | 127 .property("hardExpiration", &DownloadableSubscription::GetHardExpiration
, &DownloadableSubscription::SetHardExpiration) |
128 .property("softExpiration", &DownloadableSubscription::GetSoftExpiration
, &DownloadableSubscription::SetSoftExpiration) | 128 .property("softExpiration", &DownloadableSubscription::GetSoftExpiration
, &DownloadableSubscription::SetSoftExpiration) |
129 .property("lastDownload", &DownloadableSubscription::GetLastDownload, &D
ownloadableSubscription::SetLastDownload) | 129 .property("lastDownload", &DownloadableSubscription::GetLastDownload, &D
ownloadableSubscription::SetLastDownload) |
130 .property("downloadStatus", &DownloadableSubscription::GetDownloadStatus
, &DownloadableSubscription::SetDownloadStatus) | 130 .property("downloadStatus", &DownloadableSubscription::GetDownloadStatus
, &DownloadableSubscription::SetDownloadStatus) |
131 .property("lastSuccess", &DownloadableSubscription::GetLastSuccess, &Dow
nloadableSubscription::SetLastSuccess) | 131 .property("lastSuccess", &DownloadableSubscription::GetLastSuccess, &Dow
nloadableSubscription::SetLastSuccess) |
132 .property("errorCount", &DownloadableSubscription::GetErrorCount, &Downl
oadableSubscription::SetErrorCount) | 132 .property("errorCount", &DownloadableSubscription::GetErrorCount, &Downl
oadableSubscription::SetErrorCount) |
133 .property("dataRevision", &DownloadableSubscription::GetDataRevision, &D
ownloadableSubscription::SetDataRevision) | 133 .property("dataRevision", &DownloadableSubscription::GetDataRevision, &D
ownloadableSubscription::SetDataRevision) |
134 .property("requiredVersion", &DownloadableSubscription::GetRequiredVersi
on, &DownloadableSubscription::SetRequiredVersion) | 134 .property("requiredVersion", &DownloadableSubscription::GetRequiredVersi
on, &DownloadableSubscription::SetRequiredVersion) |
135 .property("downloadCount", &DownloadableSubscription::GetDownloadCount,
&DownloadableSubscription::SetDownloadCount) | 135 .property("downloadCount", &DownloadableSubscription::GetDownloadCount,
&DownloadableSubscription::SetDownloadCount) |
| 136 .class_function("parseDownload", &DownloadableSubscription::ParseDownloa
d) |
136 .function("serialize", &DownloadableSubscription::Serialize); | 137 .function("serialize", &DownloadableSubscription::Serialize); |
137 | 138 |
| 139 class_<DownloadableSubscription_Parser>("DownloadableSubscription_Parser") |
| 140 .property("redirect", &DownloadableSubscription_Parser::GetRedirect) |
| 141 .property("homepage", &DownloadableSubscription_Parser::GetHomepage) |
| 142 .function("process", &DownloadableSubscription_Parser::Process) |
| 143 .function("verifyChecksum", &DownloadableSubscription_Parser::VerifyChec
ksum) |
| 144 .function("finalize", &DownloadableSubscription_Parser::Finalize); |
| 145 |
138 singleton<FilterStorage>("FilterStorage", &FilterStorage::GetInstance) | 146 singleton<FilterStorage>("FilterStorage", &FilterStorage::GetInstance) |
139 .property("subscriptionCount", &FilterStorage::GetSubscriptionCount) | 147 .property("subscriptionCount", &FilterStorage::GetSubscriptionCount) |
140 .function("subscriptionAt", &FilterStorage::SubscriptionAt) | 148 .function("subscriptionAt", &FilterStorage::SubscriptionAt) |
141 .function("indexOfSubscription", &FilterStorage::IndexOfSubscription) | 149 .function("indexOfSubscription", &FilterStorage::IndexOfSubscription) |
142 .function("getSubscriptionForFilter", &FilterStorage::GetSubscriptionFor
Filter) | 150 .function("getSubscriptionForFilter", &FilterStorage::GetSubscriptionFor
Filter) |
143 .function("addSubscription", &FilterStorage::AddSubscription) | 151 .function("addSubscription", &FilterStorage::AddSubscription) |
144 .function("removeSubscription", &FilterStorage::RemoveSubscription) | 152 .function("removeSubscription", &FilterStorage::RemoveSubscription) |
145 .function("moveSubscription", &FilterStorage::MoveSubscription); | 153 .function("moveSubscription", &FilterStorage::MoveSubscription) |
| 154 .function("clearSubscriptionFilters", &FilterStorage::ClearSubscriptionF
ilters); |
146 | 155 |
147 class_<ElemHide_SelectorList>("ElemHide_SelectorList") | 156 class_<ElemHide_SelectorList>("ElemHide_SelectorList") |
148 .property("selectorCount", &ElemHide_SelectorList::GetSelectorCount) | 157 .property("selectorCount", &ElemHide_SelectorList::GetSelectorCount) |
149 .function("selectorAt", &ElemHide_SelectorList::SelectorAt) | 158 .function("selectorAt", &ElemHide_SelectorList::SelectorAt) |
150 .function("filterKeyAt", &ElemHide_SelectorList::FilterKeyAt); | 159 .function("filterKeyAt", &ElemHide_SelectorList::FilterKeyAt); |
151 | 160 |
152 singleton<ElemHide>("ElemHide", &ElemHide::GetInstance) | 161 singleton<ElemHide>("ElemHide", &ElemHide::GetInstance) |
153 .function("add", &ElemHide::Add) | 162 .function("add", &ElemHide::Add) |
154 .function("remove", &ElemHide::Remove) | 163 .function("remove", &ElemHide::Remove) |
155 .function("clear", &ElemHide::Clear) | 164 .function("clear", &ElemHide::Clear) |
(...skipping 18 matching lines...) Expand all Loading... |
174 } | 183 } |
175 catch (const std::exception& e) | 184 catch (const std::exception& e) |
176 { | 185 { |
177 EM_ASM_ARGS( | 186 EM_ASM_ARGS( |
178 console.error("Error occurred generating JavaScript bindings: " + | 187 console.error("Error occurred generating JavaScript bindings: " + |
179 Module.AsciiToString($0)), e.what() | 188 Module.AsciiToString($0)), e.what() |
180 ); | 189 ); |
181 return 1; | 190 return 1; |
182 } | 191 } |
183 } | 192 } |
OLD | NEW |