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

Unified Diff: compiled/filter/ActiveFilter.h

Issue 29425555: Issue 5201 - [emscripten] Replace EM_ASM calls by a custom JavaScript library (Closed) Base URL: https://hg.adblockplus.org/adblockpluscore
Patch Set: Abstracted away all Emscripten dependencies Created May 3, 2017, 11:54 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 | « compiled/debug.h ('k') | compiled/filter/ElemHideBase.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: compiled/filter/ActiveFilter.h
===================================================================
--- a/compiled/filter/ActiveFilter.h
+++ b/compiled/filter/ActiveFilter.h
@@ -12,31 +12,30 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Adblock Plus. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
-#include <emscripten.h>
-
#include "Filter.h"
#include "../StringMap.h"
#include "../FilterNotifier.h"
+#include "../bindings/runtime.h"
#define FILTER_PROPERTY(type, name, topic, getter, setter) \
private:\
type name;\
public:\
- type EMSCRIPTEN_KEEPALIVE getter() const\
+ type BINDINGS_EXPORTED getter() const\
{\
return name;\
}\
- void EMSCRIPTEN_KEEPALIVE setter(type value)\
+ void BINDINGS_EXPORTED setter(type value)\
{\
if (name != value)\
{\
name = value;\
if (FilterNotifier::Topic::topic != FilterNotifier::Topic::NONE)\
{\
FilterNotifier::FilterChange(FilterNotifier::Topic::topic, this);\
}\
@@ -58,14 +57,14 @@ private:
bool mIgnoreTrailingDot;
public:
explicit ActiveFilter(Type type, const String& text, bool ignoreTrailingDot);
FILTER_PROPERTY(bool, mDisabled, FILTER_DISABLED, GetDisabled, SetDisabled);
FILTER_PROPERTY(unsigned int, mHitCount, FILTER_HITCOUNT,
GetHitCount, SetHitCount);
FILTER_PROPERTY(unsigned int, mLastHit, FILTER_LASTHIT,
GetLastHit, SetLastHit);
- bool EMSCRIPTEN_KEEPALIVE IsActiveOnDomain(DependentString& docDomain,
+ bool BINDINGS_EXPORTED IsActiveOnDomain(DependentString& docDomain,
const String& sitekey) const;
- bool EMSCRIPTEN_KEEPALIVE IsActiveOnlyOnDomain(DependentString& docDomain) const;
- bool EMSCRIPTEN_KEEPALIVE IsGeneric() const;
- OwnedString EMSCRIPTEN_KEEPALIVE Serialize() const;
+ bool BINDINGS_EXPORTED IsActiveOnlyOnDomain(DependentString& docDomain) const;
+ bool BINDINGS_EXPORTED IsGeneric() const;
+ OwnedString BINDINGS_EXPORTED Serialize() const;
};
« no previous file with comments | « compiled/debug.h ('k') | compiled/filter/ElemHideBase.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld