Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1921)

Unified Diff: chrome/browser/extensions/api/system_info_display/display_info_provider.h

Issue 16817006: Add ability to change display settings to chrome.systemInfo.display (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: win compile Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/browser/extensions/api/system_info_display/display_info_provider_chromeos.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/extensions/api/system_info_display/display_info_provider.h
diff --git a/chrome/browser/extensions/api/system_info_display/display_info_provider.h b/chrome/browser/extensions/api/system_info_display/display_info_provider.h
index aab10c1cb4ed34e88eb1db52ff232752b713f35f..5820ff502975098f2ef51d9332145ffdd13e8c66 100644
--- a/chrome/browser/extensions/api/system_info_display/display_info_provider.h
+++ b/chrome/browser/extensions/api/system_info_display/display_info_provider.h
@@ -5,6 +5,8 @@
#ifndef CHROME_BROWSER_EXTENSIONS_API_SYSTEM_INFO_DISPLAY_DISPLAY_INFO_PROVIDER_H_
#define CHROME_BROWSER_EXTENSIONS_API_SYSTEM_INFO_DISPLAY_DISPLAY_INFO_PROVIDER_H_
+#include <string>
+
#include "chrome/browser/extensions/api/system_info/system_info_provider.h"
#include "chrome/common/extensions/api/system_info_display.h"
@@ -17,6 +19,8 @@ class DisplayInfoProvider : public SystemInfoProvider<DisplayInfo> {
public:
typedef base::Callback<void(const DisplayInfo& info, bool success)>
RequestInfoCallback;
+ typedef base::Callback<void(bool success, const std::string& error)>
+ SetInfoCallback;
// Gets a DisplayInfoProvider instance.
static DisplayInfoProvider* GetProvider();
@@ -27,6 +31,17 @@ class DisplayInfoProvider : public SystemInfoProvider<DisplayInfo> {
// The implementation is platform specific.
void RequestInfo(const RequestInfoCallback& callback);
+ // Updates the display parameters for a display with the provided id.
+ // The parameters are updated according to content of |info|. After the
+ // display is updated, callback is called with the success status, and error
+ // message. If the method succeeds, the error message is empty.
+ // The callback will be called asynchronously.
+ // This functionality is exposed only on ChromeOS.
+ virtual void SetInfo(
+ const std::string& display_id,
+ const api::system_info_display::DisplayProperties& info,
+ const SetInfoCallback& callback);
+
protected:
// Overriden from SystemInfoProvider<DisplayInfo>.
// The implementation is platform specific.
« no previous file with comments | « no previous file | chrome/browser/extensions/api/system_info_display/display_info_provider_chromeos.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698