OLD | NEW |
1 #ifndef _SIMPLE_ADBLOCK_CLIENT_H_ | 1 #ifndef _SIMPLE_ADBLOCK_CLIENT_H_ |
2 #define _SIMPLE_ADBLOCK_CLIENT_H_ | 2 #define _SIMPLE_ADBLOCK_CLIENT_H_ |
3 | 3 |
4 | 4 |
5 #include "PluginTypedef.h" | 5 #include "PluginTypedef.h" |
6 #include "PluginClientBase.h" | 6 #include "PluginClientBase.h" |
7 #include "AdblockPlus.h" | 7 #include "AdblockPlus.h" |
8 | 8 |
9 | 9 |
10 using namespace AdblockPlus; | 10 using namespace AdblockPlus; |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
56 CAdblockPlusClient(); | 56 CAdblockPlusClient(); |
57 | 57 |
58 public: | 58 public: |
59 | 59 |
60 static CAdblockPlusClient* s_instance; | 60 static CAdblockPlusClient* s_instance; |
61 | 61 |
62 ~CAdblockPlusClient(); | 62 ~CAdblockPlusClient(); |
63 | 63 |
64 static CAdblockPlusClient* GetInstance(); | 64 static CAdblockPlusClient* GetInstance(); |
65 | 65 |
66 bool LoadFilters(); | |
67 | |
68 AdblockPlus::FilterEngine* GetFilterEngine(); | 66 AdblockPlus::FilterEngine* GetFilterEngine(); |
69 | 67 |
70 // Removes the url from the list of whitelisted urls if present | 68 // Removes the url from the list of whitelisted urls if present |
71 // Only called from ui thread | 69 // Only called from ui thread |
72 bool ShouldBlock(CString src, int contentType, const CString& domain, bool add
Debug=false); | 70 bool ShouldBlock(CString src, int contentType, const CString& domain, bool add
Debug=false); |
73 | 71 |
74 bool IsElementHidden(const CString& tag, IHTMLElement* pEl, const CString& dom
ain, const CString& indent); | 72 bool IsElementHidden(const CString& tag, IHTMLElement* pEl, const CString& dom
ain, const CString& indent, CPluginFilter* filter); |
75 bool IsUrlWhiteListed(const CString& url); | 73 bool IsUrlWhiteListed(const CString& url); |
76 | 74 |
77 int GetIEVersion(); | 75 int GetIEVersion(); |
78 | 76 |
79 }; | 77 }; |
80 | 78 |
81 #endif // _SIMPLE_ADBLOCK_CLIENT_H_ | 79 #endif // _SIMPLE_ADBLOCK_CLIENT_H_ |
OLD | NEW |