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

Unified Diff: athena/activity/activity_widget_delegate.h

Issue 375143002: Use Widget frame and WidgetDelegate in ActvityWidget (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 5 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 | « athena/activity/activity_view_manager_impl.cc ('k') | athena/activity/activity_widget_delegate.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: athena/activity/activity_widget_delegate.h
diff --git a/athena/activity/activity_widget_delegate.h b/athena/activity/activity_widget_delegate.h
new file mode 100644
index 0000000000000000000000000000000000000000..70dcf8b3a47a28cb66082af81996851f4d765dbc
--- /dev/null
+++ b/athena/activity/activity_widget_delegate.h
@@ -0,0 +1,39 @@
+// 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 ATHENA_ACTIVITY_ACTIVITY_WIDGET_DELEGATE_H_
+#define ATHENA_ACTIVITY_ACTIVITY_WIDGET_DELEGATE_H_
+
+#include "base/macros.h"
+#include "ui/views/widget/widget_delegate.h"
+
+namespace athena {
+class ActivityViewModel;
+
+// A default WidgetDelegate for activities.
+// TODO(oshima): Allow AcitivyViewModel to create custom WidgetDelegate.
+class ActivityWidgetDelegate : public views::WidgetDelegate {
+ public:
+ explicit ActivityWidgetDelegate(ActivityViewModel* view_model);
+ virtual ~ActivityWidgetDelegate();
+
+ // views::WidgetDelegate:
+ virtual base::string16 GetWindowTitle() const OVERRIDE;
+ virtual void DeleteDelegate() OVERRIDE;
+ virtual views::Widget* GetWidget() OVERRIDE;
+ virtual const views::Widget* GetWidget() const OVERRIDE;
+ virtual views::View* GetContentsView() OVERRIDE;
+ virtual views::ClientView* CreateClientView(views::Widget* widget) OVERRIDE;
+ virtual views::NonClientFrameView* CreateNonClientFrameView(
+ views::Widget* widget) OVERRIDE;
+
+ private:
+ ActivityViewModel* view_model_;
+
+ DISALLOW_COPY_AND_ASSIGN(ActivityWidgetDelegate);
+};
+
+} // namespace athena
+
+#endif // ATHENA_ACTIVITY_ACTIVITY_WIDGET_DELEGATE_H_
« no previous file with comments | « athena/activity/activity_view_manager_impl.cc ('k') | athena/activity/activity_widget_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698