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

Side by Side Diff: ash/shell.cc

Issue 11412315: Make the cursor have separate mode for disabled mouse events and invisible. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years 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 | Annotate | Revision Log
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/shell.h" 5 #include "ash/shell.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <string> 8 #include <string>
9 9
10 #include "ash/accelerators/focus_manager_factory.h" 10 #include "ash/accelerators/focus_manager_factory.h"
(...skipping 570 matching lines...) Expand 10 before | Expand all | Expand 10 after
581 // Force Layout 581 // Force Layout
582 root_window_controller->root_window_layout()->OnWindowResized(); 582 root_window_controller->root_window_layout()->OnWindowResized();
583 583
584 // It needs to be created after OnWindowResized has been called, otherwise the 584 // It needs to be created after OnWindowResized has been called, otherwise the
585 // widget will not paint when restoring after a browser crash. Also it needs 585 // widget will not paint when restoring after a browser crash. Also it needs
586 // to be created after InitSecondaryDisplays() to initialize the wallpapers in 586 // to be created after InitSecondaryDisplays() to initialize the wallpapers in
587 // the correct size. 587 // the correct size.
588 user_wallpaper_delegate_->InitializeWallpaper(); 588 user_wallpaper_delegate_->InitializeWallpaper();
589 589
590 if (initially_hide_cursor_) 590 if (initially_hide_cursor_)
591 cursor_manager_.ShowCursor(false); 591 cursor_manager_.EnableCursor(false);
592 cursor_manager_.SetCursor(ui::kCursorPointer); 592 cursor_manager_.SetCursor(ui::kCursorPointer);
593 593
594 // Cursor might have been hidden by somethign other than chrome. 594 // Cursor might have been hidden by somethign other than chrome.
595 // Let the first mouse event show the cursor. 595 // Let the first mouse event show the cursor.
596 env_filter_->set_cursor_hidden_by_filter(true); 596 env_filter_->set_cursor_hidden_by_filter(true);
597 } 597 }
598 598
599 void Shell::ShowContextMenu(const gfx::Point& location_in_screen) { 599 void Shell::ShowContextMenu(const gfx::Point& location_in_screen) {
600 // No context menus if user have not logged in. 600 // No context menus if user have not logged in.
601 if (!delegate_->IsUserLoggedIn()) 601 if (!delegate_->IsUserLoggedIn())
(...skipping 291 matching lines...) Expand 10 before | Expand all | Expand 10 after
893 893
894 bool Shell::CanAcceptEvents() { 894 bool Shell::CanAcceptEvents() {
895 return true; 895 return true;
896 } 896 }
897 897
898 ui::EventTarget* Shell::GetParentTarget() { 898 ui::EventTarget* Shell::GetParentTarget() {
899 return NULL; 899 return NULL;
900 } 900 }
901 901
902 } // namespace ash 902 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698