| OLD | NEW |
| (Empty) |
| 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 | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef MASH_BROWSER_DEBUG_VIEW_H_ | |
| 6 #define MASH_BROWSER_DEBUG_VIEW_H_ | |
| 7 | |
| 8 #include "services/navigation/public/cpp/view.h" | |
| 9 #include "ui/views/controls/button/button.h" | |
| 10 #include "ui/views/view.h" | |
| 11 | |
| 12 namespace views { | |
| 13 class Label; | |
| 14 class LabelButton; | |
| 15 class Textfield; | |
| 16 } // namespace views | |
| 17 | |
| 18 namespace mash { | |
| 19 namespace browser { | |
| 20 | |
| 21 // A panel that shows some controls for compelling the content area of the | |
| 22 // browser to do specific things. | |
| 23 class DebugView : public views::View, | |
| 24 public views::ButtonListener { | |
| 25 public: | |
| 26 DebugView(); | |
| 27 ~DebugView() override; | |
| 28 DebugView(const DebugView&) = delete; | |
| 29 void operator=(const DebugView&) = delete; | |
| 30 | |
| 31 void set_view(navigation::View* view) { view_ = view; } | |
| 32 | |
| 33 gfx::Size GetPreferredSize() const override; | |
| 34 | |
| 35 private: | |
| 36 void OnPaint(gfx::Canvas* canvas) override; | |
| 37 void ButtonPressed(views::Button* sender, const ui::Event& event) override; | |
| 38 | |
| 39 navigation::View* view_ = nullptr; | |
| 40 | |
| 41 views::View* interstitial_container_; | |
| 42 views::Label* interstitial_label_; | |
| 43 views::LabelButton* interstitial_show_; | |
| 44 views::LabelButton* interstitial_hide_; | |
| 45 views::Textfield* interstitial_content_; | |
| 46 }; | |
| 47 | |
| 48 } // namespace browser | |
| 49 } // namespace mash | |
| 50 | |
| 51 #endif // MASH_BROWSER_DEBUG_VIEW_H_ | |
| OLD | NEW |