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

Unified Diff: src/plugin/PluginDebug.h

Issue 5743529531801600: Playing with Default behavior for catch-all blocks
Patch Set: Original patch set 9 Created March 31, 2015, 1:46 p.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 | « src/plugin/PluginClass.cpp ('k') | src/plugin/PluginDebug.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/plugin/PluginDebug.h
diff --git a/src/plugin/PluginDebug.h b/src/plugin/PluginDebug.h
index 4aea67b6239f78e1224f608d06f318d53b9ab4bd..0fdb9d7e8619e3dc1ad1371bd8dfb8d01afef5e1 100644
--- a/src/plugin/PluginDebug.h
+++ b/src/plugin/PluginDebug.h
@@ -1,47 +1,107 @@
-/*
- * This file is part of Adblock Plus <https://adblockplus.org/>,
- * Copyright (C) 2006-2015 Eyeo GmbH
- *
- * Adblock Plus is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License version 3 as
- * published by the Free Software Foundation.
- *
- * Adblock Plus is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * 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/>.
- */
-
-#ifndef _PLUGIN_DEBUG_H_
-#define _PLUGIN_DEBUG_H_
-
-class CPluginDebug
-{
-
-public:
- static void DebugSystemException(const std::system_error& ex, int errorId, int errorSubid, const std::string& description);
-
-#if (defined ENABLE_DEBUG_INFO)
- static void Debug(const std::string& text, DWORD processId=0, DWORD threadId=0);
- static void Debug(const std::wstring& text, DWORD processId=0, DWORD threadId=0);
- static void DebugException(const std::exception& ex);
- static void DebugErrorCode(DWORD errorCode, const std::string& error, DWORD processId=0, DWORD threadId=0);
-#endif
-
-#if (defined ENABLE_DEBUG_RESULT)
- static void DebugResult(const std::wstring& text);
- static void DebugResultDomain(const std::wstring& domain);
- static void DebugResultBlocking(const std::wstring& type, const std::wstring& src, const std::wstring& domain);
- static void DebugResultHiding(const std::wstring& tag, const std::wstring& id, const std::wstring& filter);
-#endif
-
-#if (defined ENABLE_DEBUG_RESULT_IGNORED)
- static void DebugResultIgnoring(const std::wstring& type, const std::wstring& src, const std::wstring& domain);
-#endif
-};
-
-
-#endif // _PLUGIN_DEBUG_H_
+/*
+ * This file is part of Adblock Plus <https://adblockplus.org/>,
+ * Copyright (C) 2006-2015 Eyeo GmbH
+ *
+ * Adblock Plus is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 3 as
+ * published by the Free Software Foundation.
+ *
+ * Adblock Plus is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * 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/>.
+ */
+
+#ifndef _PLUGIN_DEBUG_H_
+#define _PLUGIN_DEBUG_H_
+
+// Plugin errors
+
+#define PLUGIN_ERROR_SESSION 3
+#define PLUGIN_ERROR_SESSION_GET_INTERNET_SESSION 1
+#define PLUGIN_ERROR_SESSION_CREATE_HTTP_INSTANCE 2
+#define PLUGIN_ERROR_SESSION_REGISTER_HTTP_NAMESPACE 3
+#define PLUGIN_ERROR_SESSION_CREATE_HTTPS_INSTANCE 4
+#define PLUGIN_ERROR_SESSION_REGISTER_HTTPS_NAMESPACE 5
+
+#define PLUGIN_ERROR_THREAD 5
+#define PLUGIN_ERROR_MAIN_THREAD_CREATE_PROCESS 1
+#define PLUGIN_ERROR_TAB_THREAD_CREATE_PROCESS 2
+
+#define PLUGIN_ERROR_SYSINFO 7
+#define PLUGIN_ERROR_SYSINFO_BROWSER_LANGUAGE 3
+
+#define PLUGIN_ERROR_NAVIGATION 10
+#define PLUGIN_ERROR_NAVIGATION_WELCOME 1
+#define PLUGIN_ERROR_NAVIGATION_SETTINGS 7
+
+#define PLUGIN_ERROR_MUTEX 13
+#define PLUGIN_ERROR_MUTEX_CREATE 1
+#define PLUGIN_ERROR_MUTEX_RELEASE 2
+#define PLUGIN_ERROR_MUTEX_WAIT 3
+#define PLUGIN_ERROR_MUTEX_WAIT_TIMEOUT 4
+#define PLUGIN_ERROR_MUTEX_DEBUG_FILE 50
+#define PLUGIN_ERROR_MUTEX_SETTINGS_FILE_WHITELIST 90
+
+#define PLUGIN_ERROR_SET_SITE 16
+#define PLUGIN_ERROR_SET_SITE_ADVICE 1
+#define PLUGIN_ERROR_SET_SITE_UNADVISE 2
+#define PLUGIN_ERROR_SET_SITE_QUERY_BROWSER 3
+#define PLUGIN_ERROR_SET_SITE_QUERY_SERVICE_PROVIDER 4
+#define PLUGIN_ERROR_SET_SITE_COINIT 5
+#define PLUGIN_ERROR_SET_SITE_FIND_CONNECTION_POINT 6
+
+#define PLUGIN_ERROR_UI 17
+#define PLUGIN_ERROR_UI_GET_UXTHEME 1
+#define PLUGIN_ERROR_UI_GET_UXTHEME_OPEN 2
+#define PLUGIN_ERROR_UI_GET_UXTHEME_DRAW_BACKGROUND 3
+#define PLUGIN_ERROR_UI_GET_UXTHEME_CLOSE 4
+#define PLUGIN_ERROR_UI_GET_BROWSER_WINDOW 5
+#define PLUGIN_ERROR_UI_CREATE_STATUSBAR_PANE 6
+#define PLUGIN_ERROR_UI_REGISTER_PANE_CLASS 7
+#define PLUGIN_ERROR_UI_NO_STATUSBAR_BROWSER 8
+#define PLUGIN_ERROR_UI_LOAD_ICON 9
+#define PLUGIN_ERROR_UI_NO_STATUSBAR_WIN 10
+#define PLUGIN_ERROR_UI_INVALIDATE_STATUSBAR 11
+#define PLUGIN_ERROR_UI_GET_STATUSBAR 12
+#define PLUGIN_ERROR_UI_PUT_STATUSBAR 13
+
+#define PLUGIN_ERROR_CREATE_SETTINGS_JAVASCRIPT 25
+#define PLUGIN_ERROR_CREATE_SETTINGS_JAVASCRIPT_INVOKE 1
+
+#define PLUGIN_ERROR_ENTRY_POINT 99
+#define PLUGIN_ERROR_ENTRY_POINT_CATCHALL_EXCEPTION 1
+
+class CPluginDebug
+{
+
+public:
+ static void DebugSystemException(const std::system_error& ex, int errorId, int errorSubid, const std::string& description);
+
+#if (defined ENABLE_DEBUG_INFO)
+ static void Debug(const std::string& text, DWORD processId=0, DWORD threadId=0);
+ static void Debug(const std::wstring& text, DWORD processId=0, DWORD threadId=0);
+ static void DebugException(const std::exception& ex);
+ static void DebugErrorCode(DWORD errorCode, const std::string& error, DWORD processId=0, DWORD threadId=0);
+ static void DebugOrdinaryException(const std::exception& ex, int errorId, int errorSubid, const std::string& description);
+#endif
+
+#if (defined ENABLE_DEBUG_RESULT)
+ static void DebugResult(const std::wstring& text);
+ static void DebugResultDomain(const std::wstring& domain);
+ static void DebugResultBlocking(const std::wstring& type, const std::wstring& src, const std::wstring& domain);
+ static void DebugResultHiding(const std::wstring& tag, const std::wstring& id, const std::wstring& filter);
+#endif
+
+#if (defined ENABLE_DEBUG_RESULT_IGNORED)
+ static void DebugResultIgnoring(const std::wstring& type, const std::wstring& src, const std::wstring& domain);
+#endif
+};
+
+void ExceptionDefault(const std::string& name);
+void EntryPointExceptionDefault(const std::string& name);
+
+#endif // _PLUGIN_DEBUG_H_
« no previous file with comments | « src/plugin/PluginClass.cpp ('k') | src/plugin/PluginDebug.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld