| OLD | NEW | 
|---|
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 #ifndef CHROME_BROWSER_UI_JAVASCRIPT_DIALOGS_JAVASCRIPT_DIALOG_TAB_HELPER_H_ | 5 #ifndef CHROME_BROWSER_UI_JAVASCRIPT_DIALOGS_JAVASCRIPT_DIALOG_TAB_HELPER_H_ | 
| 6 #define CHROME_BROWSER_UI_JAVASCRIPT_DIALOGS_JAVASCRIPT_DIALOG_TAB_HELPER_H_ | 6 #define CHROME_BROWSER_UI_JAVASCRIPT_DIALOGS_JAVASCRIPT_DIALOG_TAB_HELPER_H_ | 
| 7 | 7 | 
| 8 #include <memory> | 8 #include <memory> | 
| 9 | 9 | 
| 10 #include "base/callback_forward.h" | 10 #include "base/callback_forward.h" | 
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 84 | 84 | 
| 85   void ClearDialogInfo(); | 85   void ClearDialogInfo(); | 
| 86 | 86 | 
| 87   // The dialog being displayed on the observed WebContents. | 87   // The dialog being displayed on the observed WebContents. | 
| 88   base::WeakPtr<JavaScriptDialog> dialog_; | 88   base::WeakPtr<JavaScriptDialog> dialog_; | 
| 89 | 89 | 
| 90   // The type of dialog being displayed. Only valid when |dialog_| is non-null. | 90   // The type of dialog being displayed. Only valid when |dialog_| is non-null. | 
| 91   content::JavaScriptDialogType dialog_type_ = | 91   content::JavaScriptDialogType dialog_type_ = | 
| 92       content::JavaScriptDialogType::JAVASCRIPT_DIALOG_TYPE_ALERT; | 92       content::JavaScriptDialogType::JAVASCRIPT_DIALOG_TYPE_ALERT; | 
| 93 | 93 | 
|  | 94   // The WebContents that was marked as showing the dialog. | 
|  | 95   content::WebContents* alerting_web_contents_ = nullptr; | 
|  | 96 | 
| 94   // The callback provided for when the dialog is closed. Usually the dialog | 97   // The callback provided for when the dialog is closed. Usually the dialog | 
| 95   // itself calls it, but in the cases where the dialog is closed not by the | 98   // itself calls it, but in the cases where the dialog is closed not by the | 
| 96   // user's input but by a call to |CloseDialog|, this class will call it. | 99   // user's input but by a call to |CloseDialog|, this class will call it. | 
| 97   content::JavaScriptDialogManager::DialogClosedCallback dialog_callback_; | 100   content::JavaScriptDialogManager::DialogClosedCallback dialog_callback_; | 
| 98 | 101 | 
| 99   base::Closure dialog_shown_; | 102   base::Closure dialog_shown_; | 
| 100 | 103 | 
| 101   DISALLOW_COPY_AND_ASSIGN(JavaScriptDialogTabHelper); | 104   DISALLOW_COPY_AND_ASSIGN(JavaScriptDialogTabHelper); | 
| 102 }; | 105 }; | 
| 103 | 106 | 
| 104 #endif  // CHROME_BROWSER_UI_JAVASCRIPT_DIALOGS_JAVASCRIPT_DIALOG_TAB_HELPER_H_ | 107 #endif  // CHROME_BROWSER_UI_JAVASCRIPT_DIALOGS_JAVASCRIPT_DIALOG_TAB_HELPER_H_ | 
| OLD | NEW | 
|---|