Prevents double-clicks on a tab close button from aslo maximizing the browser
[chromium-blink-merge.git] / ash / wm / ash_focus_rules.h
blobb5774a2082fcc6d422cb52fbd359c7da3df0db83
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
3 // found in the LICENSE file.
5 #ifndef ASH_WM_ASH_FOCUS_RULES_H_
6 #define ASH_WM_ASH_FOCUS_RULES_H_
8 #include "ash/ash_export.h"
9 #include "base/basictypes.h"
10 #include "base/compiler_specific.h"
11 #include "ui/wm/core/base_focus_rules.h"
13 namespace ash {
14 namespace wm {
16 class ASH_EXPORT AshFocusRules : public ::wm::BaseFocusRules {
17 public:
18 AshFocusRules();
19 virtual ~AshFocusRules();
21 private:
22 // Overridden from ::wm::BaseFocusRules:
23 virtual bool SupportsChildActivation(aura::Window* window) const OVERRIDE;
24 virtual bool IsWindowConsideredVisibleForActivation(
25 aura::Window* window) const OVERRIDE;
26 virtual bool CanActivateWindow(aura::Window* window) const OVERRIDE;
27 virtual aura::Window* GetNextActivatableWindow(
28 aura::Window* ignore) const OVERRIDE;
30 aura::Window* GetTopmostWindowToActivateForContainerIndex(
31 int index,
32 aura::Window* ignore) const;
33 aura::Window* GetTopmostWindowToActivateInContainer(
34 aura::Window* container,
35 aura::Window* ignore) const;
37 DISALLOW_COPY_AND_ASSIGN(AshFocusRules);
40 } // namespace wm
41 } // namespace ash
43 #endif // ASH_WM_ASH_FOCUS_RULES_H_