From 14e1a0997d5166cf93f92fd173594cb7bd68d4f9 Mon Sep 17 00:00:00 2001 From: "kevers@chromium.org" Date: Mon, 29 Oct 2012 20:29:13 +0000 Subject: Add checkmark for conencted bluetooth devices. BUG=146425, 157868 Review URL: https://chromiumcodereview.appspot.com/11313010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@164729 0039d316-1c4b-4281-b951-d872f2087c98 --- ash/system/bluetooth/tray_bluetooth.cc | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'ash/system/bluetooth/tray_bluetooth.cc') diff --git a/ash/system/bluetooth/tray_bluetooth.cc b/ash/system/bluetooth/tray_bluetooth.cc index 9f46fa3..50df5aa 100644 --- a/ash/system/bluetooth/tray_bluetooth.cc +++ b/ash/system/bluetooth/tray_bluetooth.cc @@ -117,7 +117,8 @@ class BluetoothDetailedView : public TrayDetailsView, for (size_t i = 0; i < list.size(); i++) { HoverHighlightView* container = AddScrollListItem(list[i].display_name, - list[i].connected ? gfx::Font::BOLD : gfx::Font::NORMAL); + list[i].connected ? gfx::Font::BOLD : gfx::Font::NORMAL, + list[i].connected); device_map_[container] = list[i].address; } @@ -134,16 +135,17 @@ class BluetoothDetailedView : public TrayDetailsView, else message_id = IDS_ASH_STATUS_TRAY_BLUETOOTH_NO_DEVICE; AddScrollListItem(l10n_util::GetStringUTF16(message_id), - gfx::Font::NORMAL); + gfx::Font::NORMAL, false); } } } HoverHighlightView* AddScrollListItem(const string16& text, - gfx::Font::FontStyle style) { + gfx::Font::FontStyle style, + bool checked) { HoverHighlightView* container = new HoverHighlightView(this); container->set_fixed_height(kTrayPopupItemHeight); - container->AddLabel(text, style); + container->AddCheckableLabel(text, style, checked); scroll_content()->AddChildView(container); return container; } -- cgit v1.1