| 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 "chrome/browser/ui/views/ash/chrome_shell_delegate.h" | 5 #include "chrome/browser/ui/views/ash/chrome_shell_delegate.h" |
| 6 | 6 |
| 7 #include "ash/launcher/launcher_types.h" | 7 #include "ash/launcher/launcher_types.h" |
| 8 #include "ash/system/tray/system_tray_delegate.h" | 8 #include "ash/system/tray/system_tray_delegate.h" |
| 9 #include "ash/wm/window_util.h" | 9 #include "ash/wm/window_util.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 343 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 354 break; | 354 break; |
| 355 case ash::UMA_ACCEL_NEXTWINDOW_F5: | 355 case ash::UMA_ACCEL_NEXTWINDOW_F5: |
| 356 content::RecordAction(content::UserMetricsAction("Accel_NextWindow_F5")); | 356 content::RecordAction(content::UserMetricsAction("Accel_NextWindow_F5")); |
| 357 break; | 357 break; |
| 358 case ash::UMA_ACCEL_NEWTAB_T: | 358 case ash::UMA_ACCEL_NEWTAB_T: |
| 359 content::RecordAction(content::UserMetricsAction("Accel_NewTab_T")); | 359 content::RecordAction(content::UserMetricsAction("Accel_NewTab_T")); |
| 360 break; | 360 break; |
| 361 case ash::UMA_ACCEL_SEARCH_LWIN: | 361 case ash::UMA_ACCEL_SEARCH_LWIN: |
| 362 content::RecordAction(content::UserMetricsAction("Accel_Search_LWin")); | 362 content::RecordAction(content::UserMetricsAction("Accel_Search_LWin")); |
| 363 break; | 363 break; |
| 364 case ash::UMA_TOUCHPAD_TAP_DOWN: |
| 365 content::RecordAction(content::UserMetricsAction("Touchpad_Down")); |
| 366 break; |
| 367 case ash::UMA_TOUCHSCREEN_TAP_DOWN: |
| 368 content::RecordAction(content::UserMetricsAction("Touchscreen_Down")); |
| 369 break; |
| 364 } | 370 } |
| 365 } | 371 } |
| 366 | 372 |
| 367 void ChromeShellDelegate::Observe(int type, | 373 void ChromeShellDelegate::Observe(int type, |
| 368 const content::NotificationSource& source, | 374 const content::NotificationSource& source, |
| 369 const content::NotificationDetails& details) { | 375 const content::NotificationDetails& details) { |
| 370 #if defined(OS_CHROMEOS) | 376 #if defined(OS_CHROMEOS) |
| 371 switch (type) { | 377 switch (type) { |
| 372 case chrome::NOTIFICATION_LOGIN_USER_PROFILE_PREPARED: | 378 case chrome::NOTIFICATION_LOGIN_USER_PROFILE_PREPARED: |
| 373 ash::Shell::GetInstance()->CreateLauncher(); | 379 ash::Shell::GetInstance()->CreateLauncher(); |
| 374 break; | 380 break; |
| 375 case chrome::NOTIFICATION_SESSION_STARTED: | 381 case chrome::NOTIFICATION_SESSION_STARTED: |
| 376 ash::Shell::GetInstance()->ShowLauncher(); | 382 ash::Shell::GetInstance()->ShowLauncher(); |
| 377 break; | 383 break; |
| 378 default: | 384 default: |
| 379 NOTREACHED() << "Unexpected notification " << type; | 385 NOTREACHED() << "Unexpected notification " << type; |
| 380 } | 386 } |
| 381 #else | 387 #else |
| 382 // MSVC++ warns about switch statements without any cases. | 388 // MSVC++ warns about switch statements without any cases. |
| 383 NOTREACHED() << "Unexpected notification " << type; | 389 NOTREACHED() << "Unexpected notification " << type; |
| 384 #endif | 390 #endif |
| 385 } | 391 } |
| OLD | NEW |