| 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/common/system/chromeos/network/network_state_list_detailed_view.h" | 5 #include "ash/common/system/chromeos/network/network_state_list_detailed_view.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "ash/common/ash_constants.h" | 10 #include "ash/common/ash_constants.h" |
| (...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 225 bundle.GetLocalizedString(IDS_ASH_STATUS_TRAY_NETWORK_INFO)); | 225 bundle.GetLocalizedString(IDS_ASH_STATUS_TRAY_NETWORK_INFO)); |
| 226 SetPaintToLayer(); | 226 SetPaintToLayer(); |
| 227 layer()->SetFillsBoundsOpaquely(false); | 227 layer()->SetFillsBoundsOpaquely(false); |
| 228 layer()->SetOpacity(1.0); | 228 layer()->SetOpacity(1.0); |
| 229 } | 229 } |
| 230 | 230 |
| 231 ~InfoIcon() override {} | 231 ~InfoIcon() override {} |
| 232 | 232 |
| 233 // views::View | 233 // views::View |
| 234 gfx::Size GetPreferredSize() const override { | 234 gfx::Size GetPreferredSize() const override { |
| 235 int size = GetTrayConstant(TRAY_POPUP_ITEM_MIN_HEIGHT); | 235 return gfx::Size(kTrayPopupItemMinHeight, kTrayPopupItemMinHeight); |
| 236 return gfx::Size(size, size); | |
| 237 } | 236 } |
| 238 | 237 |
| 239 void SetVisible(bool visible) override { | 238 void SetVisible(bool visible) override { |
| 240 layer()->GetAnimator()->StopAnimating(); // Stop any previous animation. | 239 layer()->GetAnimator()->StopAnimating(); // Stop any previous animation. |
| 241 ui::ScopedLayerAnimationSettings animation(layer()->GetAnimator()); | 240 ui::ScopedLayerAnimationSettings animation(layer()->GetAnimator()); |
| 242 animation.SetTransitionDuration( | 241 animation.SetTransitionDuration( |
| 243 base::TimeDelta::FromMilliseconds(kFadeIconMs)); | 242 base::TimeDelta::FromMilliseconds(kFadeIconMs)); |
| 244 layer()->SetOpacity(visible ? 1.0 : 0.0); | 243 layer()->SetOpacity(visible ? 1.0 : 0.0); |
| 245 } | 244 } |
| 246 | 245 |
| (...skipping 505 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 752 UMA_STATUS_AREA_NETWORK_JOIN_OTHER_CLICKED); | 751 UMA_STATUS_AREA_NETWORK_JOIN_OTHER_CLICKED); |
| 753 WmShell::Get()->system_tray_controller()->ShowNetworkCreate(shill::kTypeWifi); | 752 WmShell::Get()->system_tray_controller()->ShowNetworkCreate(shill::kTypeWifi); |
| 754 } | 753 } |
| 755 | 754 |
| 756 void NetworkStateListDetailedView::RelayoutScrollList() { | 755 void NetworkStateListDetailedView::RelayoutScrollList() { |
| 757 scroller()->Layout(); | 756 scroller()->Layout(); |
| 758 } | 757 } |
| 759 | 758 |
| 760 } // namespace tray | 759 } // namespace tray |
| 761 } // namespace ash | 760 } // namespace ash |
| OLD | NEW |