Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1463)

Unified Diff: chrome/browser/ui/views/extensions/extension_installed_bubble_view.h

Issue 1807793003: Convert ExtensionInstalledBubble to BubbleDialogDelegateView (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/views/extensions/extension_installed_bubble_view.h
diff --git a/chrome/browser/ui/views/extensions/extension_installed_bubble_view.h b/chrome/browser/ui/views/extensions/extension_installed_bubble_view.h
deleted file mode 100644
index 8eec05bd6383d8be66fa7a269defaea4fa81a83b..0000000000000000000000000000000000000000
--- a/chrome/browser/ui/views/extensions/extension_installed_bubble_view.h
+++ /dev/null
@@ -1,85 +0,0 @@
-// Copyright 2013 The Chromium Authors. All rights reserved.
-// 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_EXTENSIONS_EXTENSION_INSTALLED_BUBBLE_VIEW_H_
-#define CHROME_BROWSER_UI_VIEWS_EXTENSIONS_EXTENSION_INSTALLED_BUBBLE_VIEW_H_
-
-#include "base/macros.h"
-#include "chrome/browser/ui/extensions/extension_installed_bubble.h"
-#include "chrome/browser/ui/sync/bubble_sync_promo_delegate.h"
-#include "components/bubble/bubble_reference.h"
-#include "ui/views/bubble/bubble_delegate.h"
-#include "ui/views/controls/button/button.h"
-#include "ui/views/controls/link_listener.h"
-
-class Browser;
-class BubbleSyncPromoView;
-
-namespace extensions {
-class Extension;
-}
-
-namespace views {
-class LabelButton;
-class Link;
-}
-
-// Provides feedback to the user upon successful installation of an
-// extension. Depending on the type of extension, the Bubble will
-// point to:
-// OMNIBOX_KEYWORD-> The omnibox.
-// BROWSER_ACTION -> The browserAction icon in the toolbar.
-// PAGE_ACTION -> A preview of the pageAction icon in the location
-// bar which is shown while the Bubble is shown.
-// GENERIC -> The app menu. This case includes pageActions that don't
-// specify a default icon.
-class ExtensionInstalledBubbleView : public BubbleSyncPromoDelegate,
- public views::BubbleDelegateView,
- public views::ButtonListener,
- public views::LinkListener {
- public:
- ExtensionInstalledBubbleView(ExtensionInstalledBubble* bubble,
- BubbleReference bubble_reference);
- ~ExtensionInstalledBubbleView() override;
-
- // Recalculate the anchor position for this bubble.
- void UpdateAnchorView();
-
- void InitLayout();
-
- private:
- // views::BubbleDelegateView:
- View* CreateFootnoteView() override;
- void WindowClosing() override;
- gfx::Rect GetAnchorRect() const override;
- void OnWidgetClosing(views::Widget* widget) override;
- void OnWidgetActivationChanged(views::Widget* widget, bool active) override;
- bool AcceleratorPressed(const ui::Accelerator& accelerator) override;
-
- // BubbleSyncPromoDelegate:
- void OnSignInLinkClicked() override;
-
- // views::LinkListener:
- void LinkClicked(views::Link* source, int event_flags) override;
-
- // views::ButtonListener:
- void ButtonPressed(views::Button* sender, const ui::Event& event) override;
-
- const ExtensionInstalledBubble* bubble_;
- BubbleReference bubble_reference_;
- const extensions::Extension* extension_;
- Browser* browser_;
- ExtensionInstalledBubble::BubbleType type_;
- ExtensionInstalledBubble::AnchorPosition anchor_position_;
-
- // The button to close the bubble.
- views::LabelButton* close_;
-
- // The shortcut to open the manage shortcuts page.
- views::Link* manage_shortcut_;
-
- DISALLOW_COPY_AND_ASSIGN(ExtensionInstalledBubbleView);
-};
-
-#endif // CHROME_BROWSER_UI_VIEWS_EXTENSIONS_EXTENSION_INSTALLED_BUBBLE_VIEW_H_

Powered by Google App Engine
This is Rietveld 408576698