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

Unified Diff: ui/app_list/views/views_demo_app.h

Issue 303543004: MacViews: views_examples_with_content_exe working! Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: add files Created 6 years, 7 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 | « ui/app_list/views/search_result_list_view_unittest.cc ('k') | ui/app_list/views/views_demo_app.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/app_list/views/views_demo_app.h
diff --git a/ui/app_list/views/views_demo_app.h b/ui/app_list/views/views_demo_app.h
new file mode 100644
index 0000000000000000000000000000000000000000..f4489c777cb404984df0f678c5bb439b9a0bc1b3
--- /dev/null
+++ b/ui/app_list/views/views_demo_app.h
@@ -0,0 +1,54 @@
+// Copyright 2014 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 UI_APP_LIST_VIEWS_VIEWS_DEMO_APP_H_
+#define UI_APP_LIST_VIEWS_VIEWS_DEMO_APP_H_
+
+#include "base/callback_forward.h"
+#include "base/macros.h"
+#include "base/memory/scoped_ptr.h"
+#include "base/run_loop.h"
+
+class ViewsDemoAppDelegate {
+ public:
+ ViewsDemoAppDelegate();
+ virtual ~ViewsDemoAppDelegate();
+
+ virtual void Init();
+ void Run();
+
+ protected:
+ base::RunLoop* run_loop() { return run_loop_.get(); }
+
+ private:
+ scoped_ptr<base::RunLoop> run_loop_;
+};
+
+class ViewsDemoApp {
+ public:
+ static scoped_ptr<ViewsDemoApp> Create(
+ scoped_ptr<ViewsDemoAppDelegate> delegate);
+ static int RunSubProcess(int argc, char** argv);
+
+ virtual ~ViewsDemoApp();
+
+ virtual void Run() = 0;
+ virtual void AddOption(const char* description,
+ const base::Callback<void(bool)>& callback,
+ bool initial_state);
+
+ void InitOnMainThread();
+
+ protected:
+ ViewsDemoApp();
+
+ private:
+ class Impl;
+
+ scoped_ptr<Impl> impl_;
+
+ DISALLOW_COPY_AND_ASSIGN(ViewsDemoApp);
+};
+
+#endif // UI_APP_LIST_VIEWS_VIEWS_DEMO_APP_H_
« no previous file with comments | « ui/app_list/views/search_result_list_view_unittest.cc ('k') | ui/app_list/views/views_demo_app.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698