OLD | NEW |
(Empty) | |
| 1 // Copyright 2013 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. |
| 4 |
| 5 package org.chromium.chrome.browser.appmenu; |
| 6 |
| 7 import com.google.common.annotations.VisibleForTesting; |
| 8 |
| 9 /** |
| 10 * Allows monitoring of application menu actions. |
| 11 */ |
| 12 public interface AppMenuObserver { |
| 13 /** |
| 14 * Informs when the App Menu visibility changes. |
| 15 * @param newState Whether the menu is now visible. |
| 16 * @param focusedPosition The position that is currently in focus. |
| 17 */ |
| 18 public void onMenuVisibilityChanged(boolean newState, int focusedPosition); |
| 19 |
| 20 /** |
| 21 * Notifies that the keyboard focus has changed within the App Menu. |
| 22 * @param focusedPosition The position that is currently in focus. |
| 23 */ |
| 24 @VisibleForTesting |
| 25 public void onKeyboardFocusChanged(int focusedPosition); |
| 26 |
| 27 /** |
| 28 * Notifies that the keyboard has activated an item in the App Menu. |
| 29 * @param focusedPosition The position of the item that was activated. |
| 30 */ |
| 31 @VisibleForTesting |
| 32 public void onKeyboardActivatedItem(int focusedPosition); |
| 33 } |
OLD | NEW |