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

Side by Side Diff: ash/wm/workspace/multi_window_resize_controller.cc

Issue 10026013: Update use of TimeDelta in chrome/browser/*, ui/views/*, and other places. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Rebase onto master. Created 8 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 unified diff | Download patch
« no previous file with comments | « no previous file | base/process_util_linux.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "ash/wm/workspace/multi_window_resize_controller.h" 5 #include "ash/wm/workspace/multi_window_resize_controller.h"
6 6
7 #include "ash/shell.h" 7 #include "ash/shell.h"
8 #include "ash/shell_window_ids.h" 8 #include "ash/shell_window_ids.h"
9 #include "ash/wm/window_animations.h" 9 #include "ash/wm/window_animations.h"
10 #include "ash/wm/workspace/workspace_event_filter.h" 10 #include "ash/wm/workspace/workspace_event_filter.h"
(...skipping 356 matching lines...) Expand 10 before | Expand all | Expand 10 after
367 resize_widget_->GetNativeWindow(), 367 resize_widget_->GetNativeWindow(),
368 WINDOW_VISIBILITY_ANIMATION_TYPE_FADE); 368 WINDOW_VISIBILITY_ANIMATION_TYPE_FADE);
369 resize_widget_->GetNativeWindow()->SetName("MultiWindowResizeController"); 369 resize_widget_->GetNativeWindow()->SetName("MultiWindowResizeController");
370 resize_widget_->SetContentsView(view); 370 resize_widget_->SetContentsView(view);
371 show_bounds_ = CalculateResizeWidgetBounds(show_location_); 371 show_bounds_ = CalculateResizeWidgetBounds(show_location_);
372 resize_widget_->SetBounds(show_bounds_); 372 resize_widget_->SetBounds(show_bounds_);
373 resize_widget_->Show(); 373 resize_widget_->Show();
374 mouse_watcher_.reset(new views::MouseWatcher( 374 mouse_watcher_.reset(new views::MouseWatcher(
375 new ResizeMouseWatcherHost(this), 375 new ResizeMouseWatcherHost(this),
376 this)); 376 this));
377 mouse_watcher_->set_notify_on_exit_time_ms(kHideDelayMS); 377 mouse_watcher_->set_notify_on_exit_time(
378 base::TimeDelta::FromMilliseconds(kHideDelayMS));
378 mouse_watcher_->Start(); 379 mouse_watcher_->Start();
379 } 380 }
380 381
381 bool MultiWindowResizeController::IsShowing() const { 382 bool MultiWindowResizeController::IsShowing() const {
382 return resize_widget_ || show_timer_.IsRunning(); 383 return resize_widget_ || show_timer_.IsRunning();
383 } 384 }
384 385
385 void MultiWindowResizeController::StartResize( 386 void MultiWindowResizeController::StartResize(
386 const gfx::Point& screen_location) { 387 const gfx::Point& screen_location) {
387 DCHECK(!window_resizer_.get()); 388 DCHECK(!window_resizer_.get());
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
489 490
490 gfx::Point window_loc(screen_location); 491 gfx::Point window_loc(screen_location);
491 aura::Window::ConvertPointToWindow( 492 aura::Window::ConvertPointToWindow(
492 window->GetRootWindow(), window, &window_loc); 493 window->GetRootWindow(), window, &window_loc);
493 return window->HitTest(window_loc) && 494 return window->HitTest(window_loc) &&
494 window->delegate()->GetNonClientComponent(window_loc) == component; 495 window->delegate()->GetNonClientComponent(window_loc) == component;
495 } 496 }
496 497
497 } // namespace internal 498 } // namespace internal
498 } // namespace ash 499 } // namespace ash
OLDNEW
« no previous file with comments | « no previous file | base/process_util_linux.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698