#include "chrome/browser/ui/views/javascript_tab_modal_dialog_view_views.h"
#include "base/functional/callback.h"
#include "chrome/browser/ui/javascript_dialogs/javascript_tab_modal_dialog_manager_delegate_desktop.h"
#include "chrome/browser/ui/views/title_origin_label.h"
#include "components/constrained_window/constrained_window_views.h"
#include "content/public/browser/javascript_dialog_manager.h"
#include "ui/base/l10n/l10n_util.h"
#include "ui/base/metadata/metadata_impl_macros.h"
#include "ui/base/mojom/dialog_button.mojom.h"
#include "ui/base/mojom/ui_base_types.mojom-shared.h"
#include "ui/strings/grit/ui_strings.h"
#include "ui/views/accessibility/view_accessibility.h"
#include "ui/views/bubble/bubble_frame_view.h"
#include "ui/views/controls/label.h"
#include "ui/views/controls/message_box_view.h"
#include "ui/views/controls/textfield/textfield.h"
#include "ui/views/layout/fill_layout.h"
JavaScriptTabModalDialogViewViews::~JavaScriptTabModalDialogViewViews() =
default;
void JavaScriptTabModalDialogViewViews::CloseDialogWithoutCallback() { … }
std::u16string JavaScriptTabModalDialogViewViews::GetUserInput() { … }
std::u16string JavaScriptTabModalDialogViewViews::GetWindowTitle() const { … }
bool JavaScriptTabModalDialogViewViews::ShouldShowCloseButton() const { … }
views::View* JavaScriptTabModalDialogViewViews::GetInitiallyFocusedView() { … }
void JavaScriptTabModalDialogViewViews::AddedToWidget() { … }
JavaScriptTabModalDialogViewViews::JavaScriptTabModalDialogViewViews(
content::WebContents* parent_web_contents,
content::WebContents* alerting_web_contents,
const std::u16string& title,
content::JavaScriptDialogType dialog_type,
const std::u16string& message_text,
const std::u16string& default_prompt_text,
content::JavaScriptDialogManager::DialogClosedCallback dialog_callback,
base::OnceClosure dialog_force_closed_callback)
: … { … }
JavaScriptTabModalDialogViewViews*
JavaScriptTabModalDialogViewViews::CreateAlertDialogForTesting(
Browser* browser,
std::u16string title,
std::u16string message) { … }
BEGIN_METADATA(…)
base::WeakPtr<javascript_dialogs::TabModalDialogView>
JavaScriptTabModalDialogManagerDelegateDesktop::CreateNewDialog(
content::WebContents* alerting_web_contents,
const std::u16string& title,
content::JavaScriptDialogType dialog_type,
const std::u16string& message_text,
const std::u16string& default_prompt_text,
content::JavaScriptDialogManager::DialogClosedCallback dialog_callback,
base::OnceClosure dialog_force_closed_callback) { … }