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

Unified Diff: src/plugin/PluginUtil.h

Issue 6032593782833152: Issue 1173 - proposal for entry point (Closed)
Patch Set: base on current tip Created Jan. 29, 2015, 1:29 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/PluginUtil.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/plugin/PluginUtil.h
diff --git a/src/plugin/PluginUtil.h b/src/plugin/PluginUtil.h
index 51556cf8104be8cda6e42ccec6b0a27319219008..ecf0c604997832cf63a177446213b01977d0c002 100644
--- a/src/plugin/PluginUtil.h
+++ b/src/plugin/PluginUtil.h
@@ -1,24 +1,30 @@
-/*
- * 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/>.
- */
-
+/*
+ * 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/>.
+ */
+
#pragma once
#include <string>
+#include <functional>
std::wstring HtmlFolderPath();
std::wstring UserSettingsFileUrl();
std::wstring FirstRunPageFileUrl();
std::wstring FileUrl(const std::wstring& url);
+
+// Wraps EntryPoint and eats C++ exceptions.
+// Returns `false` if caught exception.
+bool EntryPoint(const std::function<void()>& functionBody);
+HRESULT EntryPointWithHResult(const std::function<HRESULT()>& functionBody);
« no previous file with comments | « src/plugin/PluginClass.cpp ('k') | src/plugin/PluginUtil.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld