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

Side by Side Diff: ash/common/system/ime/tray_ime_chromeos.cc

Issue 2518963004: Fix button-pressed handling in ImeDetailedView (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 unified diff | Download patch
« no previous file with comments | « ash/common/system/chromeos/ime_menu/ime_list_view.cc ('k') | no next file » | 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 #include "ash/common/system/ime/tray_ime_chromeos.h" 5 #include "ash/common/system/ime/tray_ime_chromeos.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "ash/common/material_design/material_design_controller.h" 9 #include "ash/common/material_design/material_design_controller.h"
10 #include "ash/common/session/session_state_delegate.h" 10 #include "ash/common/session/session_state_delegate.h"
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after
146 private: 146 private:
147 // ImeListView: 147 // ImeListView:
148 void HandleViewClicked(views::View* view) override { 148 void HandleViewClicked(views::View* view) override {
149 ImeListView::HandleViewClicked(view); 149 ImeListView::HandleViewClicked(view);
150 if (view == settings_) 150 if (view == settings_)
151 ShowSettings(); 151 ShowSettings();
152 } 152 }
153 153
154 void HandleButtonPressed(views::Button* sender, 154 void HandleButtonPressed(views::Button* sender,
155 const ui::Event& event) override { 155 const ui::Event& event) override {
156 ImeListView::HandleButtonPressed(sender, event);
156 if (sender == settings_button_) 157 if (sender == settings_button_)
157 ShowSettings(); 158 ShowSettings();
158 } 159 }
159 160
160 void CreateExtraTitleRowButtons() override { 161 void CreateExtraTitleRowButtons() override {
161 if (MaterialDesignController::IsSystemTrayMenuMaterial()) { 162 if (MaterialDesignController::IsSystemTrayMenuMaterial()) {
162 // It is possible that the settings button has already been created 163 // It is possible that the settings button has already been created
163 // through a previous call to Update(). 164 // through a previous call to Update().
164 if (settings_button_) 165 if (settings_button_)
165 return; 166 return;
(...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after
342 else 343 else
343 Update(); 344 Update();
344 } 345 }
345 346
346 bool TrayIME::ShouldDefaultViewBeVisible() { 347 bool TrayIME::ShouldDefaultViewBeVisible() {
347 return is_visible_ && (ime_list_.size() > 1 || property_list_.size() > 1 || 348 return is_visible_ && (ime_list_.size() > 1 || property_list_.size() > 1 ||
348 ShouldShowKeyboardToggle()); 349 ShouldShowKeyboardToggle());
349 } 350 }
350 351
351 } // namespace ash 352 } // namespace ash
OLDNEW
« no previous file with comments | « ash/common/system/chromeos/ime_menu/ime_list_view.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698