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

Side by Side Diff: ash/common/system/chromeos/bluetooth/tray_bluetooth.cc

Issue 2330403002: Do not activate system tray bubble by default (Closed)
Patch Set: Do not activate system tray bubble by default Created 4 years, 2 months 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
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/chromeos/bluetooth/tray_bluetooth.h" 5 #include "ash/common/system/chromeos/bluetooth/tray_bluetooth.h"
6 6
7 #include "ash/common/material_design/material_design_controller.h" 7 #include "ash/common/material_design/material_design_controller.h"
8 #include "ash/common/session/session_state_delegate.h" 8 #include "ash/common/session/session_state_delegate.h"
9 #include "ash/common/system/tray/fixed_sized_scroll_view.h" 9 #include "ash/common/system/tray/fixed_sized_scroll_view.h"
10 #include "ash/common/system/tray/hover_highlight_view.h" 10 #include "ash/common/system/tray/hover_highlight_view.h"
(...skipping 340 matching lines...) Expand 10 before | Expand all | Expand 10 after
351 scroll_content()->SizeToPreferredSize(); 351 scroll_content()->SizeToPreferredSize();
352 static_cast<views::View*>(scroller())->Layout(); 352 static_cast<views::View*>(scroller())->Layout();
353 } 353 }
354 } 354 }
355 355
356 // TrayDetailsView: 356 // TrayDetailsView:
357 void HandleViewClicked(views::View* view) override { 357 void HandleViewClicked(views::View* view) override {
358 SystemTrayDelegate* delegate = WmShell::Get()->system_tray_delegate(); 358 SystemTrayDelegate* delegate = WmShell::Get()->system_tray_delegate();
359 if (view == manage_devices_) { 359 if (view == manage_devices_) {
360 delegate->ManageBluetoothDevices(); 360 delegate->ManageBluetoothDevices();
361 owner()->system_tray()->CloseSystemBubble();
361 return; 362 return;
362 } 363 }
363 364
364 if (view == enable_bluetooth_) { 365 if (view == enable_bluetooth_) {
365 WmShell::Get()->RecordUserMetricsAction( 366 WmShell::Get()->RecordUserMetricsAction(
366 delegate->GetBluetoothEnabled() ? UMA_STATUS_AREA_BLUETOOTH_DISABLED 367 delegate->GetBluetoothEnabled() ? UMA_STATUS_AREA_BLUETOOTH_DISABLED
367 : UMA_STATUS_AREA_BLUETOOTH_ENABLED); 368 : UMA_STATUS_AREA_BLUETOOTH_ENABLED);
368 delegate->ToggleBluetooth(); 369 delegate->ToggleBluetooth();
369 return; 370 return;
370 } 371 }
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
510 detailed_->Update(); 511 detailed_->Update();
511 } 512 }
512 513
513 void TrayBluetooth::OnBluetoothDiscoveringChanged() { 514 void TrayBluetooth::OnBluetoothDiscoveringChanged() {
514 if (!detailed_) 515 if (!detailed_)
515 return; 516 return;
516 detailed_->Update(); 517 detailed_->Update();
517 } 518 }
518 519
519 } // namespace ash 520 } // namespace ash
OLDNEW
« no previous file with comments | « ash/common/system/audio/volume_view.cc ('k') | ash/common/system/chromeos/ime_menu/ime_list_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698