| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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/cocoa/autofill/autofill_dialog_cocoa.h" | 5 #include "chrome/browser/ui/cocoa/autofill/autofill_dialog_cocoa.h" |
| 6 | 6 |
| 7 #include "base/mac/bundle_locations.h" | 7 #include "base/mac/bundle_locations.h" |
| 8 #include "base/mac/scoped_nsobject.h" | 8 #include "base/mac/scoped_nsobject.h" |
| 9 #include "chrome/browser/ui/autofill/autofill_dialog_controller.h" | 9 #include "chrome/browser/ui/autofill/autofill_dialog_controller.h" |
| 10 #include "chrome/browser/ui/chrome_style.h" | 10 #include "chrome/browser/ui/chrome_style.h" |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 59 new ConstrainedWindowMac(this, controller_->web_contents(), sheet)); | 59 new ConstrainedWindowMac(this, controller_->web_contents(), sheet)); |
| 60 constrained_window_->SetPreventCloseOnLoadStart(true); | 60 constrained_window_->SetPreventCloseOnLoadStart(true); |
| 61 } | 61 } |
| 62 | 62 |
| 63 void AutofillDialogCocoa::Hide() { | 63 void AutofillDialogCocoa::Hide() { |
| 64 [sheet_controller_ hide]; | 64 [sheet_controller_ hide]; |
| 65 } | 65 } |
| 66 | 66 |
| 67 // Closes the sheet and ends the modal loop. Triggers cleanup sequence. | 67 // Closes the sheet and ends the modal loop. Triggers cleanup sequence. |
| 68 void AutofillDialogCocoa::PerformClose() { | 68 void AutofillDialogCocoa::PerformClose() { |
| 69 constrained_window_->CloseWebContentsModalDialog(); | 69 if (constrained_window_) |
| 70 constrained_window_->CloseWebContentsModalDialog(); |
| 70 } | 71 } |
| 71 | 72 |
| 72 void AutofillDialogCocoa::UpdateAccountChooser() { | 73 void AutofillDialogCocoa::UpdateAccountChooser() { |
| 73 [sheet_controller_ updateAccountChooser]; | 74 [sheet_controller_ updateAccountChooser]; |
| 74 } | 75 } |
| 75 | 76 |
| 76 void AutofillDialogCocoa::UpdateButtonStrip() { | 77 void AutofillDialogCocoa::UpdateButtonStrip() { |
| 77 } | 78 } |
| 78 | 79 |
| 79 void AutofillDialogCocoa::UpdateDetailArea() { | 80 void AutofillDialogCocoa::UpdateDetailArea() { |
| (...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 377 [[signInContainer_ view] setHidden:YES]; | 378 [[signInContainer_ view] setHidden:YES]; |
| 378 [[mainContainer_ view] setHidden:NO]; | 379 [[mainContainer_ view] setHidden:NO]; |
| 379 [self performLayout]; | 380 [self performLayout]; |
| 380 } | 381 } |
| 381 | 382 |
| 382 - (void)modelChanged { | 383 - (void)modelChanged { |
| 383 [mainContainer_ modelChanged]; | 384 [mainContainer_ modelChanged]; |
| 384 } | 385 } |
| 385 | 386 |
| 386 @end | 387 @end |
| OLD | NEW |