OLD | NEW |
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/system/ime/tray_ime.h" | 5 #include "ash/system/ime/tray_ime.h" |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "ash/root_window_controller.h" | 9 #include "ash/root_window_controller.h" |
10 #include "ash/shell.h" | 10 #include "ash/shell.h" |
(...skipping 251 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
262 } | 262 } |
263 | 263 |
264 views::View* TrayIME::CreateTrayView(user::LoginStatus status) { | 264 views::View* TrayIME::CreateTrayView(user::LoginStatus status) { |
265 CHECK(tray_label_ == NULL); | 265 CHECK(tray_label_ == NULL); |
266 tray_label_ = new TrayItemView; | 266 tray_label_ = new TrayItemView; |
267 tray_label_->CreateLabel(); | 267 tray_label_->CreateLabel(); |
268 SetupLabelForTray(tray_label_->label()); | 268 SetupLabelForTray(tray_label_->label()); |
269 return tray_label_; | 269 return tray_label_; |
270 } | 270 } |
271 | 271 |
272 views::View* TrayIME::CreateDefaultView(user::LoginStatus status) { | 272 views::View* TrayIME::CreateDefaultView(user::LoginStatus status, |
| 273 int bubble_width) { |
273 SystemTrayDelegate* delegate = Shell::GetInstance()->tray_delegate(); | 274 SystemTrayDelegate* delegate = Shell::GetInstance()->tray_delegate(); |
274 IMEInfoList list; | 275 IMEInfoList list; |
275 IMEPropertyInfoList property_list; | 276 IMEPropertyInfoList property_list; |
276 delegate->GetAvailableIMEList(&list); | 277 delegate->GetAvailableIMEList(&list); |
277 delegate->GetCurrentIMEProperties(&property_list); | 278 delegate->GetCurrentIMEProperties(&property_list); |
278 if (list.size() <= 1 && property_list.size() <= 1) | 279 if (list.size() <= 1 && property_list.size() <= 1) |
279 return NULL; | 280 return NULL; |
280 CHECK(default_ == NULL); | 281 CHECK(default_ == NULL); |
281 default_ = new tray::IMEDefaultView(this); | 282 default_ = new tray::IMEDefaultView(this); |
282 return default_; | 283 return default_; |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
342 } else if (!Shell::GetPrimaryRootWindowController()->shelf()->IsVisible() || | 343 } else if (!Shell::GetPrimaryRootWindowController()->shelf()->IsVisible() || |
343 !message_shown_) { | 344 !message_shown_) { |
344 ShowNotificationView(); | 345 ShowNotificationView(); |
345 message_shown_ = true; | 346 message_shown_ = true; |
346 } | 347 } |
347 } | 348 } |
348 } | 349 } |
349 | 350 |
350 } // namespace internal | 351 } // namespace internal |
351 } // namespace ash | 352 } // namespace ash |
OLD | NEW |