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

Unified Diff: chrome/browser/labs.h

Issue 3152055: Implement about:labs (Closed)
Patch Set: chromeos fix Created 10 years, 4 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 | « chrome/browser/dom_ui/plugins_ui.cc ('k') | chrome/browser/labs.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/labs.h
diff --git a/chrome/browser/labs.h b/chrome/browser/labs.h
new file mode 100644
index 0000000000000000000000000000000000000000..0c61b95af2fec5bfe7ddb961b5357176e47b630b
--- /dev/null
+++ b/chrome/browser/labs.h
@@ -0,0 +1,37 @@
+// Copyright (c) 2010 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_BROWSER_LABS_H_
+#define CHROME_BROWSER_LABS_H_
+#pragma once
+
+#include <string>
+
+class CommandLine;
+class ListValue;
+class Profile;
+
+// Can't be called "labs", that collides with the C function |labs()|.
+namespace about_labs {
+
+// Returns if Labs is enabled (it isn't on the stable channel).
+bool IsEnabled();
+
+// Reads the Labs pref from |profile| and adds the commandline flags belonging
+// to the active experiments to |command_line|.
+void ConvertLabsToSwitches(Profile* profile, CommandLine* command_line);
+
+// Get a list of all available experiments. The caller owns the result.
+ListValue* GetLabsExperimentsData(Profile* profile);
+
+// Returns true if one of the experiment flags has been flipped since startup.
+bool IsRestartNeededToCommitChanges();
+
+// Enables or disables the experiment with id |internal_name|.
+void SetExperimentEnabled(
+ Profile* profile, const std::string& internal_name, bool enable);
+
+} // namespace Labs
+
+#endif // CHROME_BROWSER_LABS_H_
« no previous file with comments | « chrome/browser/dom_ui/plugins_ui.cc ('k') | chrome/browser/labs.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698