| Index: chrome/browser/ui/views/apps/app_info_dialog/app_info_summary_panel.h
|
| diff --git a/chrome/browser/ui/views/apps/app_info_dialog/app_info_summary_panel.h b/chrome/browser/ui/views/apps/app_info_dialog/app_info_summary_panel.h
|
| index 95ec9d5d6ebee5e99dfb982b8be3b2cee5c35d2e..1b00d78396b76dc0b821e9d58779f46c80d0aca0 100644
|
| --- a/chrome/browser/ui/views/apps/app_info_dialog/app_info_summary_panel.h
|
| +++ b/chrome/browser/ui/views/apps/app_info_dialog/app_info_summary_panel.h
|
| @@ -10,6 +10,7 @@
|
| #include "chrome/browser/ui/views/apps/app_info_dialog/app_info_panel.h"
|
| #include "chrome/common/extensions/extension_constants.h"
|
| #include "ui/views/controls/combobox/combobox_listener.h"
|
| +#include "ui/views/controls/link_listener.h"
|
|
|
| class LaunchOptionsComboboxModel;
|
| class Profile;
|
| @@ -21,12 +22,15 @@ class Extension;
|
| namespace views {
|
| class Combobox;
|
| class Label;
|
| +class Link;
|
| +class View;
|
| }
|
|
|
| // The summary panel of the app info dialog, which provides basic information
|
| // and controls related to the app.
|
| class AppInfoSummaryPanel : public AppInfoPanel,
|
| public views::ComboboxListener,
|
| + public views::LinkListener,
|
| public base::SupportsWeakPtr<AppInfoSummaryPanel> {
|
| public:
|
| AppInfoSummaryPanel(Profile* profile, const extensions::Extension* app);
|
| @@ -35,7 +39,7 @@ class AppInfoSummaryPanel : public AppInfoPanel,
|
|
|
| private:
|
| // Internal initialisation methods.
|
| - void AddDescriptionControl(views::View* vertical_stack);
|
| + void AddDescriptionAndLinksControl(views::View* vertical_stack);
|
| void AddDetailsControl(views::View* vertical_stack);
|
| void AddLaunchOptionControl(views::View* vertical_stack);
|
| void AddSubviews();
|
| @@ -43,6 +47,9 @@ class AppInfoSummaryPanel : public AppInfoPanel,
|
| // Overridden from views::ComboboxListener:
|
| virtual void OnPerformAction(views::Combobox* combobox) override;
|
|
|
| + // Overridden from views::LinkListener:
|
| + virtual void LinkClicked(views::Link* source, int event_flags) override;
|
| +
|
| // Called asynchronously to calculate and update the size of the app displayed
|
| // in the dialog.
|
| void StartCalculatingAppSize();
|
| @@ -56,8 +63,21 @@ class AppInfoSummaryPanel : public AppInfoPanel,
|
| void SetLaunchType(extensions::LaunchType) const;
|
| bool CanSetLaunchType() const;
|
|
|
| + // Opens the app's homepage URL as specified in the manifest. Must only be
|
| + // called if CanShowAppHomePage() returns true.
|
| + void ShowAppHomePage();
|
| + bool CanShowAppHomePage() const;
|
| +
|
| + // Displays the licenses for the app. Must only be called if
|
| + // CanDisplayLicenses() returns true.
|
| + void DisplayLicenses();
|
| + bool CanDisplayLicenses() const;
|
| + const std::vector<GURL> GetLicenseUrls() const;
|
| +
|
| // UI elements on the dialog.
|
| views::Label* size_value_;
|
| + views::Link* homepage_link_;
|
| + views::Link* licenses_link_;
|
|
|
| scoped_ptr<LaunchOptionsComboboxModel> launch_options_combobox_model_;
|
| views::Combobox* launch_options_combobox_;
|
|
|