OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef EXTENSIONS_BROWSER_API_RUNTIME_RUNTIME_API_DELEGATE_H | 5 #ifndef EXTENSIONS_BROWSER_API_RUNTIME_RUNTIME_API_DELEGATE_H |
6 #define EXTENSIONS_BROWSER_API_RUNTIME_RUNTIME_API_DELEGATE_H | 6 #define EXTENSIONS_BROWSER_API_RUNTIME_RUNTIME_API_DELEGATE_H |
7 | 7 |
8 #include "base/callback.h" | 8 #include "base/callback.h" |
9 #include "base/version.h" | 9 #include "base/version.h" |
10 | 10 |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
63 // Navigates the browser to a URL on behalf of the runtime API. | 63 // Navigates the browser to a URL on behalf of the runtime API. |
64 virtual void OpenURL(const GURL& uninstall_url) = 0; | 64 virtual void OpenURL(const GURL& uninstall_url) = 0; |
65 | 65 |
66 // Populates platform info to be provided by the getPlatformInfo function. | 66 // Populates platform info to be provided by the getPlatformInfo function. |
67 // Returns false iff no info is provided. | 67 // Returns false iff no info is provided. |
68 virtual bool GetPlatformInfo(core_api::runtime::PlatformInfo* info) = 0; | 68 virtual bool GetPlatformInfo(core_api::runtime::PlatformInfo* info) = 0; |
69 | 69 |
70 // Request a restart of the host device. Returns false iff the device | 70 // Request a restart of the host device. Returns false iff the device |
71 // will not be restarted. | 71 // will not be restarted. |
72 virtual bool RestartDevice(std::string* error_message) = 0; | 72 virtual bool RestartDevice(std::string* error_message) = 0; |
| 73 |
| 74 // Open |extension|'s options page, if it has one. Returns true if an |
| 75 // options page was opened, false otherwise. See the docs of the |
| 76 // chrome.runtime.openOptionsPage function for the gritty details. |
| 77 virtual bool OpenOptionsPage(const Extension* extension); |
73 }; | 78 }; |
74 | 79 |
75 } // namespace extensions | 80 } // namespace extensions |
76 | 81 |
77 #endif // EXTENSIONS_BROWSER_API_RUNTIME_RUNTIME_API_DELEGATE_H | 82 #endif // EXTENSIONS_BROWSER_API_RUNTIME_RUNTIME_API_DELEGATE_H |
OLD | NEW |