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

Side by Side Diff: chrome/browser/ui/app_list/app_list_shower_views.cc

Issue 1608733002: Remove ui/gfx/screen_type_delegate.h (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@metro-mode-4
Patch Set: and another rebase Created 4 years, 11 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 unified diff | Download patch
OLDNEW
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 #include "chrome/browser/ui/app_list/app_list_shower_views.h" 5 #include "chrome/browser/ui/app_list/app_list_shower_views.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/location.h" 8 #include "base/location.h"
9 #include "base/profiler/scoped_tracker.h" 9 #include "base/profiler/scoped_tracker.h"
10 #include "base/single_thread_task_runner.h" 10 #include "base/single_thread_task_runner.h"
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 app_list::AppListView* view; 110 app_list::AppListView* view;
111 { 111 {
112 // TODO(tapted): Remove ScopedTracker below once crbug.com/431326 is fixed. 112 // TODO(tapted): Remove ScopedTracker below once crbug.com/431326 is fixed.
113 tracked_objects::ScopedTracker tracking_profile1( 113 tracked_objects::ScopedTracker tracking_profile1(
114 FROM_HERE_WITH_EXPLICIT_FUNCTION("431326 AppListView()")); 114 FROM_HERE_WITH_EXPLICIT_FUNCTION("431326 AppListView()"));
115 115
116 // The app list view manages its own lifetime. 116 // The app list view manages its own lifetime.
117 view = new app_list::AppListView(delegate_->GetViewDelegateForCreate()); 117 view = new app_list::AppListView(delegate_->GetViewDelegateForCreate());
118 } 118 }
119 119
120 gfx::Point cursor = gfx::Screen::GetNativeScreen()->GetCursorScreenPoint(); 120 gfx::Point cursor = gfx::Screen::GetScreen()->GetCursorScreenPoint();
121 view->InitAsBubbleAtFixedLocation(NULL, 121 view->InitAsBubbleAtFixedLocation(NULL,
122 0, 122 0,
123 cursor, 123 cursor,
124 views::BubbleBorder::FLOAT, 124 views::BubbleBorder::FLOAT,
125 false /* border_accepts_events */); 125 false /* border_accepts_events */);
126 return view; 126 return view;
127 } 127 }
128 128
129 void AppListShower::UpdateViewForNewProfile() { 129 void AppListShower::UpdateViewForNewProfile() {
130 app_list_->SetProfileByPath(profile_->GetPath()); 130 app_list_->SetProfileByPath(profile_->GetPath());
(...skipping 18 matching lines...) Expand all
149 FROM_HERE, 149 FROM_HERE,
150 base::Bind(&AppListShower::ResetKeepAlive, base::Unretained(this))); 150 base::Bind(&AppListShower::ResetKeepAlive, base::Unretained(this)));
151 return; 151 return;
152 } 152 }
153 ResetKeepAlive(); 153 ResetKeepAlive();
154 } 154 }
155 155
156 void AppListShower::ResetKeepAlive() { 156 void AppListShower::ResetKeepAlive() {
157 keep_alive_.reset(); 157 keep_alive_.reset();
158 } 158 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/app_list/app_list_service_mac.mm ('k') | chrome/browser/ui/ash/launcher/chrome_launcher_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698