Index: ash/common/system/tray/tray_details_view.cc |
diff --git a/ash/common/system/tray/tray_details_view.cc b/ash/common/system/tray/tray_details_view.cc |
index 35d58cdf2c722d78da1fa4631f843384c0fdb30c..9dd3f0ce0050caff1fa977c54778cda48c3d8d86 100644 |
--- a/ash/common/system/tray/tray_details_view.cc |
+++ b/ash/common/system/tray/tray_details_view.cc |
@@ -168,8 +168,15 @@ void TrayDetailsView::TransitionToDefaultView() { |
// Cache pointer to owner in this function scope. TrayDetailsView will be |
// deleted after called ShowDefaultView. |
SystemTrayItem* owner = owner_; |
- if (title_row_ && title_row_->content() && title_row_->content()->HasFocus()) |
- owner->set_restore_focus(true); |
+ if (MaterialDesignController::IsSystemTrayMenuMaterial()) { |
varkha
2016/10/20 15:34:38
Did you not merge this with the else if condition
|
+ if (back_button_ && back_button_->HasFocus()) |
+ owner->set_restore_focus(true); |
+ } else { |
+ if (title_row_ && title_row_->content() && |
+ title_row_->content()->HasFocus()) { |
+ owner->set_restore_focus(true); |
+ } |
+ } |
owner->system_tray()->ShowDefaultView(BUBBLE_USE_EXISTING); |
owner->set_restore_focus(false); |
} |