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

Unified Diff: athena/main/web_activity.h

Issue 302683002: athena: Add the concept of Activity and related managers. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . 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 | « athena/main/sample_activity.cc ('k') | athena/main/web_activity.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: athena/main/web_activity.h
diff --git a/athena/main/web_activity.h b/athena/main/web_activity.h
new file mode 100644
index 0000000000000000000000000000000000000000..7d1867e8fc920a0ae7fd430bf0f4add41e55e711
--- /dev/null
+++ b/athena/main/web_activity.h
@@ -0,0 +1,42 @@
+// 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_MAIN_WEB_ACTIVITY_H_
+#define ATHENA_MAIN_WEB_ACTIVITY_H_
+
+#include "athena/activity/public/activity.h"
+#include "athena/activity/public/activity_view_model.h"
+#include "content/public/browser/web_contents_observer.h"
+
+namespace content {
+class WebContents;
+}
+
+class WebActivity : public athena::Activity,
+ public athena::ActivityViewModel,
+ public content::WebContentsObserver {
+ public:
+ explicit WebActivity(content::WebContents* contents);
+ virtual ~WebActivity();
+
+ protected:
+ // athena::Activity:
+ virtual athena::ActivityViewModel* GetActivityViewModel() OVERRIDE;
+
+ // athena::ActivityViewModel:
+ virtual SkColor GetRepresentativeColor() OVERRIDE;
+ virtual std::string GetTitle() OVERRIDE;
+ virtual aura::Window* GetNativeWindow() OVERRIDE;
+
+ // content::WebContentsObserver:
+ virtual void TitleWasSet(content::NavigationEntry* entry,
+ bool explicit_set) OVERRIDE;
+ virtual void DidUpdateFaviconURL(
+ const std::vector<content::FaviconURL>& candidates) OVERRIDE;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(WebActivity);
+};
+
+#endif // ATHENA_MAIN_WEB_ACTIVITY_H_
« no previous file with comments | « athena/main/sample_activity.cc ('k') | athena/main/web_activity.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698