Infobar material design refresh: layout
[chromium-blink-merge.git] / chrome / browser / ui / views / open_pdf_in_reader_bubble_view.h
blob003eb575d6ca72ca8093d34ea8b2974052bf462a
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef CHROME_BROWSER_UI_VIEWS_OPEN_PDF_IN_READER_BUBBLE_VIEW_H_
6 #define CHROME_BROWSER_UI_VIEWS_OPEN_PDF_IN_READER_BUBBLE_VIEW_H_
8 #include "ui/views/bubble/bubble_delegate.h"
9 #include "ui/views/controls/button/button.h"
10 #include "ui/views/controls/link_listener.h"
12 namespace pdf {
13 class OpenPDFInReaderPromptClient;
16 namespace views {
17 class LabelButton;
20 class OpenPDFInReaderBubbleView : public views::BubbleDelegateView,
21 public views::ButtonListener,
22 public views::LinkListener {
23 public:
24 OpenPDFInReaderBubbleView(views::View* anchor_view,
25 pdf::OpenPDFInReaderPromptClient* model);
26 ~OpenPDFInReaderBubbleView() override;
28 protected:
29 // views::BubbleDelegateView:
30 void Init() override;
32 // views::ButtonListener:
33 void ButtonPressed(views::Button* sender, const ui::Event& event) override;
35 // views::LinkListener:
36 void LinkClicked(views::Link* source, int event_flags) override;
38 private:
39 // Weak pointer; owned by the PDFWebContentsHelper of the currently active
40 // tab.
41 pdf::OpenPDFInReaderPromptClient* model_;
43 views::Link* open_in_reader_link_;
44 views::LabelButton* close_button_;
46 DISALLOW_COPY_AND_ASSIGN(OpenPDFInReaderBubbleView);
49 #endif // CHROME_BROWSER_UI_VIEWS_OPEN_PDF_IN_READER_BUBBLE_VIEW_H_