#include "chrome/browser/picture_in_picture/auto_pip_setting_view.h"
#include "chrome/grit/generated_resources.h"
#include "components/strings/grit/components_strings.h"
#include "components/url_formatter/url_formatter.h"
#include "ui/base/l10n/l10n_util.h"
#include "ui/base/mojom/dialog_button.mojom.h"
#include "ui/gfx/text_elider.h"
#include "ui/views/layout/flex_layout_view.h"
constexpr int kBubbleTopOffset = …;
constexpr int kControlViewButtonCornerRadius = …;
constexpr int kControlViewButtonWidth = …;
constexpr int kControlViewButtonHeight = …;
constexpr int kLayoutBetweenChildSpacing = …;
constexpr int kDescriptionViewWidth = …;
constexpr int kDescriptionViewHeight = …;
constexpr int kBubbleFixedWidth = …;
constexpr int kBubbleBorderCornerRadius = …;
constexpr int kBubbleBorderMdShadowElevation = …;
constexpr gfx::Insets kBubbleMargins = …;
constexpr gfx::Insets kBubbleTitleMargins = …;
constexpr int kBubbleOriginTextMaximumWidth = …;
constexpr gfx::Insets kControlViewMargins = …;
AutoPipSettingView::AutoPipSettingView(
ResultCb result_cb,
HideViewCb hide_view_cb,
const GURL& origin,
const gfx::Rect& browser_view_overridden_bounds,
views::View* anchor_view,
views::BubbleBorder::Arrow arrow)
: … { … }
AutoPipSettingView::~AutoPipSettingView() { … }
void AutoPipSettingView::InitBubble() { … }
raw_ptr<views::MdTextButton> AutoPipSettingView::InitControlViewButton(
views::BoxLayoutView* controls_view,
UiResult ui_result,
const std::u16string& label_text) { … }
void AutoPipSettingView::InitBubbleTitleView(const GURL& origin) { … }
void AutoPipSettingView::OnButtonPressed(UiResult result) { … }
bool AutoPipSettingView::WantsEvent(const gfx::Point& point_in_screen) { … }
gfx::Rect AutoPipSettingView::GetAnchorRect() const { … }
std::unique_ptr<views::NonClientFrameView>
AutoPipSettingView::CreateNonClientFrameView(views::Widget* widget) { … }
void AutoPipSettingView::OnWidgetInitialized() { … }
AutoPipSettingView::AnchorViewObserver::AnchorViewObserver(
views::View* anchor_view,
AutoPipSettingView* bubble)
: … { … }
AutoPipSettingView::AnchorViewObserver::~AnchorViewObserver() = default;
void AutoPipSettingView::AnchorViewObserver::OnViewRemovedFromWidget(
views::View*) { … }
void AutoPipSettingView::AnchorViewObserver::OnViewIsDeleting(views::View*) { … }
void AutoPipSettingView::AnchorViewObserver::CloseWidget() { … }