Index: chrome/browser/extensions/api/tabs/tabs.cc |
diff --git a/chrome/browser/extensions/api/tabs/tabs.cc b/chrome/browser/extensions/api/tabs/tabs.cc |
index 3d80a52e7ef640dd813a48194a717a80f717f276..eb620349d0cfa3ccc47c1f6c32df86dbc246abdd 100644 |
--- a/chrome/browser/extensions/api/tabs/tabs.cc |
+++ b/chrome/browser/extensions/api/tabs/tabs.cc |
@@ -79,6 +79,11 @@ |
#include "chrome/browser/ui/views/ash/panel_view_aura.h" |
#endif |
+#if defined(OS_CHROMEOS) |
Mattias Nissler (ping if slow)
2012/07/06 15:15:52
no need for preprocessor guards
qfel
2012/07/06 17:00:39
Done
|
+#include "chrome/browser/browser_process.h" |
+#include "chrome/browser/prefs/pref_service.h" |
+#endif |
+ |
#if defined(OS_WIN) |
#include "base/win/metro.h" |
#endif // OS_WIN |
@@ -1599,6 +1604,10 @@ bool CaptureVisibleTabFunction::GetTabToCapture( |
}; |
bool CaptureVisibleTabFunction::RunImpl() { |
+ PrefService* service = g_browser_process->local_state(); |
Mattias Nissler (ping if slow)
2012/07/06 15:15:52
Have you thought about registering this as a Profi
qfel
2012/07/06 17:00:39
Done.
|
+ if (service->GetBoolean(prefs::kDisableScreenshots)) |
+ EXTENSION_FUNCTION_ERROR("keys::kXXX"); |
Mattias Nissler (ping if slow)
2012/07/06 15:15:52
add proper constants.
qfel
2012/07/06 17:00:39
Done.
|
+ |
WebContents* web_contents = NULL; |
TabContents* tab_contents = NULL; |
if (!GetTabToCapture(&web_contents, &tab_contents)) |