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

Side by Side Diff: ui/aura/window.h

Issue 602043006: aura: Move Window::ContainsMouse() implementation into the test API. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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 | « ui/aura/test/window_test_api.cc ('k') | ui/aura/window.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 #ifndef UI_AURA_WINDOW_H_ 5 #ifndef UI_AURA_WINDOW_H_
6 #define UI_AURA_WINDOW_H_ 6 #define UI_AURA_WINDOW_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 453 matching lines...) Expand 10 before | Expand all | Expand 10 after
464 virtual bool CanAcceptEvent(const ui::Event& event) OVERRIDE; 464 virtual bool CanAcceptEvent(const ui::Event& event) OVERRIDE;
465 virtual EventTarget* GetParentTarget() OVERRIDE; 465 virtual EventTarget* GetParentTarget() OVERRIDE;
466 virtual scoped_ptr<ui::EventTargetIterator> GetChildIterator() const OVERRIDE; 466 virtual scoped_ptr<ui::EventTargetIterator> GetChildIterator() const OVERRIDE;
467 virtual ui::EventTargeter* GetEventTargeter() OVERRIDE; 467 virtual ui::EventTargeter* GetEventTargeter() OVERRIDE;
468 virtual void ConvertEventToTarget(ui::EventTarget* target, 468 virtual void ConvertEventToTarget(ui::EventTarget* target,
469 ui::LocatedEvent* event) OVERRIDE; 469 ui::LocatedEvent* event) OVERRIDE;
470 470
471 // Updates the layer name based on the window's name and id. 471 // Updates the layer name based on the window's name and id.
472 void UpdateLayerName(); 472 void UpdateLayerName();
473 473
474 // Returns true if the mouse is currently within our bounds.
475 bool ContainsMouse();
476
477 // Returns the first ancestor (starting at |this|) with a layer. |offset| is 474 // Returns the first ancestor (starting at |this|) with a layer. |offset| is
478 // set to the offset from |this| to the first ancestor with a layer. |offset| 475 // set to the offset from |this| to the first ancestor with a layer. |offset|
479 // may be NULL. 476 // may be NULL.
480 Window* GetAncestorWithLayer(gfx::Vector2d* offset) { 477 Window* GetAncestorWithLayer(gfx::Vector2d* offset) {
481 return const_cast<Window*>( 478 return const_cast<Window*>(
482 const_cast<const Window*>(this)->GetAncestorWithLayer(offset)); 479 const_cast<const Window*>(this)->GetAncestorWithLayer(offset));
483 } 480 }
484 const Window* GetAncestorWithLayer(gfx::Vector2d* offset) const; 481 const Window* GetAncestorWithLayer(gfx::Vector2d* offset) const;
485 482
486 // Bounds of this window relative to the parent. This is cached as the bounds 483 // Bounds of this window relative to the parent. This is cached as the bounds
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
541 }; 538 };
542 539
543 std::map<const void*, Value> prop_map_; 540 std::map<const void*, Value> prop_map_;
544 541
545 DISALLOW_COPY_AND_ASSIGN(Window); 542 DISALLOW_COPY_AND_ASSIGN(Window);
546 }; 543 };
547 544
548 } // namespace aura 545 } // namespace aura
549 546
550 #endif // UI_AURA_WINDOW_H_ 547 #endif // UI_AURA_WINDOW_H_
OLDNEW
« no previous file with comments | « ui/aura/test/window_test_api.cc ('k') | ui/aura/window.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698