OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/passwords/manage_passwords_bubble_ui_controller.h" | 5 #include "chrome/browser/ui/passwords/manage_passwords_bubble_ui_controller.h" |
6 | 6 |
7 #include "chrome/browser/chrome_notification_types.h" | 7 #include "chrome/browser/chrome_notification_types.h" |
8 #include "chrome/browser/password_manager/password_store_factory.h" | 8 #include "chrome/browser/password_manager/password_store_factory.h" |
9 #include "chrome/browser/ui/browser_finder.h" | 9 #include "chrome/browser/ui/browser_finder.h" |
10 #include "chrome/browser/ui/browser_window.h" | 10 #include "chrome/browser/ui/browser_window.h" |
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
163 state = ManagePasswordsIcon::BLACKLISTED_STATE; | 163 state = ManagePasswordsIcon::BLACKLISTED_STATE; |
164 else if (password_to_be_saved_) | 164 else if (password_to_be_saved_) |
165 state = ManagePasswordsIcon::PENDING_STATE; | 165 state = ManagePasswordsIcon::PENDING_STATE; |
166 else if (manage_passwords_icon_to_be_shown_) | 166 else if (manage_passwords_icon_to_be_shown_) |
167 state = ManagePasswordsIcon::MANAGE_STATE; | 167 state = ManagePasswordsIcon::MANAGE_STATE; |
168 | 168 |
169 icon->SetState(state); | 169 icon->SetState(state); |
170 | 170 |
171 if (manage_passwords_bubble_needs_showing_) { | 171 if (manage_passwords_bubble_needs_showing_) { |
172 DCHECK(state == ManagePasswordsIcon::PENDING_STATE); | 172 DCHECK(state == ManagePasswordsIcon::PENDING_STATE); |
| 173 // TODO(mkwst): Replace this with execution of a browser command once we |
| 174 // can pipe a CommandUpdater down here. |
173 icon->ShowBubbleWithoutUserInteraction(); | 175 icon->ShowBubbleWithoutUserInteraction(); |
174 manage_passwords_bubble_needs_showing_ = false; | 176 manage_passwords_bubble_needs_showing_ = false; |
175 } | 177 } |
176 } | 178 } |
OLD | NEW |