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

Unified Diff: ash/common/system/chromeos/ime_menu/ime_menu_tray.h

Issue 2474843002: Add virtual keyboard item into opt-in IME menu. (Closed)
Patch Set: Created 4 years, 1 month 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | ash/common/system/chromeos/ime_menu/ime_menu_tray.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/common/system/chromeos/ime_menu/ime_menu_tray.h
diff --git a/ash/common/system/chromeos/ime_menu/ime_menu_tray.h b/ash/common/system/chromeos/ime_menu/ime_menu_tray.h
index 81a3a5cf2c69e7f1645d69988020cf8ca1fa65ba..8e9290efeed1c8683e68a2efb9a22aecf532aebe 100644
--- a/ash/common/system/chromeos/ime_menu/ime_menu_tray.h
+++ b/ash/common/system/chromeos/ime_menu/ime_menu_tray.h
@@ -6,6 +6,7 @@
#define ASH_COMMON_SYSTEM_CHROMEOS_IME_MENU_IME_MENU_TRAY_H_
#include "ash/ash_export.h"
+#include "ash/common/system/chromeos/virtual_keyboard/virtual_keyboard_observer.h"
#include "ash/common/system/ime/ime_observer.h"
#include "ash/common/system/tray/ime_info.h"
#include "ash/common/system/tray/tray_background_view.h"
@@ -28,7 +29,8 @@ class WmWindow;
class ASH_EXPORT ImeMenuTray : public TrayBackgroundView,
public IMEObserver,
public views::TrayBubbleView::Delegate,
- public keyboard::KeyboardControllerObserver {
+ public keyboard::KeyboardControllerObserver,
+ public VirtualKeyboardObserver {
public:
explicit ImeMenuTray(WmShelf* wm_shelf);
~ImeMenuTray() override;
@@ -54,6 +56,10 @@ class ASH_EXPORT ImeMenuTray : public TrayBackgroundView,
// for non-MD UI, and a Settings button in the title row for MD.
bool ShouldShowEmojiHandwritingVoiceButtons() const;
+ // Returns whether the virtual keyboard toggle should be shown in shown in the
+ // opt-in IME menu.
+ bool ShouldShowKeyboardToggle() const;
+
// TrayBackgroundView:
void SetShelfAlignment(ShelfAlignment alignment) override;
base::string16 GetAccessibleNameForTray() override;
@@ -81,6 +87,9 @@ class ASH_EXPORT ImeMenuTray : public TrayBackgroundView,
void OnKeyboardClosed() override;
void OnKeyboardHidden() override;
+ // VirtualKeyboardObserver:
+ void OnKeyboardSuppressionChanged(bool suppressed) override;
+
private:
// To allow the test class to access |label_|.
friend class ImeMenuTrayTest;
@@ -97,6 +106,7 @@ class ASH_EXPORT ImeMenuTray : public TrayBackgroundView,
bool show_keyboard_;
bool force_show_keyboard_;
bool should_block_shelf_auto_hide_;
+ bool keyboard_suppressed_;
DISALLOW_COPY_AND_ASSIGN(ImeMenuTray);
};
« no previous file with comments | « no previous file | ash/common/system/chromeos/ime_menu/ime_menu_tray.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698