blob: 0937b9bf4dd6f1253dc41d558cfdab57344471a6 [file] [log] [blame]
// Copyright 2021 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CHROME_BROWSER_UI_VIEWS_AUTOFILL_ADDRESS_BUBBLES_ICON_VIEW_H_
#define CHROME_BROWSER_UI_VIEWS_AUTOFILL_ADDRESS_BUBBLES_ICON_VIEW_H_
#include "chrome/browser/ui/views/page_action/page_action_icon_view.h"
#include "ui/base/metadata/metadata_header_macros.h"
class CommandUpdater;
namespace autofill {
class AddressBubblesIconController;
// The location bar icon to show the Save Address Profile bubble.
class AddressBubblesIconView : public PageActionIconView {
METADATA_HEADER(AddressBubblesIconView, PageActionIconView)
public:
AddressBubblesIconView(
CommandUpdater* command_updater,
IconLabelBubbleView::Delegate* icon_label_bubble_delegate,
PageActionIconView::Delegate* page_action_icon_delegate);
AddressBubblesIconView(const AddressBubblesIconView&) =
delete;
AddressBubblesIconView& operator=(
const AddressBubblesIconView&) = delete;
~AddressBubblesIconView() override;
// PageActionIconView:
views::BubbleDialogDelegate* GetBubble() const override;
void UpdateImpl() override;
std::u16string GetTextForTooltipAndAccessibleName() const override;
protected:
// PageActionIconView:
void OnExecuting(PageActionIconView::ExecuteSource execute_source) override;
const gfx::VectorIcon& GetVectorIcon() const override;
private:
AddressBubblesIconController* GetController() const;
};
} // namespace autofill
#endif // CHROME_BROWSER_UI_VIEWS_AUTOFILL_ADDRESS_BUBBLES_ICON_VIEW_H_