| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef ATHENA_CONTENT_PUBLIC_WEB_ACTIVITY_H_ | 5 #ifndef ATHENA_CONTENT_PUBLIC_WEB_ACTIVITY_H_ |
| 6 #define ATHENA_CONTENT_PUBLIC_WEB_ACTIVITY_H_ | 6 #define ATHENA_CONTENT_PUBLIC_WEB_ACTIVITY_H_ |
| 7 | 7 |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "athena/activity/public/activity.h" | 10 #include "athena/activity/public/activity.h" |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 bool IsVisible() override; | 55 bool IsVisible() override; |
| 56 ActivityMediaState GetMediaState() override; | 56 ActivityMediaState GetMediaState() override; |
| 57 aura::Window* GetWindow() override; | 57 aura::Window* GetWindow() override; |
| 58 content::WebContents* GetWebContents() override; | 58 content::WebContents* GetWebContents() override; |
| 59 | 59 |
| 60 // ActivityViewModel: | 60 // ActivityViewModel: |
| 61 void Init() override; | 61 void Init() override; |
| 62 SkColor GetRepresentativeColor() const override; | 62 SkColor GetRepresentativeColor() const override; |
| 63 base::string16 GetTitle() const override; | 63 base::string16 GetTitle() const override; |
| 64 gfx::ImageSkia GetIcon() const override; | 64 gfx::ImageSkia GetIcon() const override; |
| 65 void SetActivityView(ActivityView* activity_view) override; |
| 65 bool UsesFrame() const override; | 66 bool UsesFrame() const override; |
| 66 views::View* GetContentsView() override; | 67 views::View* GetContentsView() override; |
| 67 gfx::ImageSkia GetOverviewModeImage() override; | 68 gfx::ImageSkia GetOverviewModeImage() override; |
| 68 void PrepareContentsForOverview() override; | 69 void PrepareContentsForOverview() override; |
| 69 void ResetContentsView() override; | 70 void ResetContentsView() override; |
| 70 | 71 |
| 71 // content::WebContentsObserver: | 72 // content::WebContentsObserver: |
| 72 void DidNavigateMainFrame( | 73 void DidNavigateMainFrame( |
| 73 const content::LoadCommittedDetails& details, | 74 const content::LoadCommittedDetails& details, |
| 74 const content::FrameNavigateParams& params) override; | 75 const content::FrameNavigateParams& params) override; |
| (...skipping 23 matching lines...) Expand all Loading... |
| 98 const base::string16 title_; | 99 const base::string16 title_; |
| 99 SkColor title_color_; | 100 SkColor title_color_; |
| 100 gfx::ImageSkia icon_; | 101 gfx::ImageSkia icon_; |
| 101 | 102 |
| 102 // The current state for this activity. | 103 // The current state for this activity. |
| 103 ActivityState current_state_; | 104 ActivityState current_state_; |
| 104 | 105 |
| 105 // The content proxy. | 106 // The content proxy. |
| 106 scoped_ptr<ContentProxy> content_proxy_; | 107 scoped_ptr<ContentProxy> content_proxy_; |
| 107 | 108 |
| 109 // WebActivity does not take ownership of |activity_view_|. If the view is |
| 110 // destroyed before the activity, then it must be reset using |
| 111 // SetActivityView(nullptr). |
| 112 ActivityView* activity_view_; |
| 113 |
| 108 base::WeakPtrFactory<WebActivity> weak_ptr_factory_; | 114 base::WeakPtrFactory<WebActivity> weak_ptr_factory_; |
| 109 | 115 |
| 110 DISALLOW_COPY_AND_ASSIGN(WebActivity); | 116 DISALLOW_COPY_AND_ASSIGN(WebActivity); |
| 111 }; | 117 }; |
| 112 | 118 |
| 113 } // namespace athena | 119 } // namespace athena |
| 114 | 120 |
| 115 #endif // ATHENA_CONTENT_WEB_ACTIVITY_H_ | 121 #endif // ATHENA_CONTENT_WEB_ACTIVITY_H_ |
| OLD | NEW |