diff options
Diffstat (limited to 'chrome/browser/views')
-rw-r--r-- | chrome/browser/views/browser_dialogs.h | 11 | ||||
-rw-r--r-- | chrome/browser/views/frame/browser_view.cc | 1 | ||||
-rw-r--r-- | chrome/browser/views/page_info_window_view.cc | 27 |
3 files changed, 24 insertions, 15 deletions
diff --git a/chrome/browser/views/browser_dialogs.h b/chrome/browser/views/browser_dialogs.h index c2b13f3..8806976 100644 --- a/chrome/browser/views/browser_dialogs.h +++ b/chrome/browser/views/browser_dialogs.h @@ -6,6 +6,7 @@ #define CHROME_BROWSER_VIEWS_BROWSER_DIALOGS_H_ #include "base/gfx/native_widget_types.h" +#include "chrome/browser/tab_contents/navigation_entry.h" // This file contains functions for running a variety of browser dialogs and // popups. The dialogs here are the ones that the caller does not need to @@ -97,6 +98,16 @@ void EditSearchEngine(gfx::NativeWindow parent, EditSearchEngineControllerDelegate* delegate, Profile* profile); +// Shows the page info using the specified information. +// |url| is the url of the page/frame the info applies to, |ssl| is the SSL +// information for that page/frame. If |show_history| is true, a section +// showing how many times that URL has been visited is added to the page info. +void ShowPageInfo(gfx::NativeWindow parent, + Profile* profile, + const GURL& url, + const NavigationEntry::SSLStatus& ssl, + bool show_history); + } // namespace browser #endif // CHROME_BROWSER_VIEWS_BROWSER_DIALOGS_H_ diff --git a/chrome/browser/views/frame/browser_view.cc b/chrome/browser/views/frame/browser_view.cc index d4fc97e..1de6e48 100644 --- a/chrome/browser/views/frame/browser_view.cc +++ b/chrome/browser/views/frame/browser_view.cc @@ -30,7 +30,6 @@ #if defined(OS_WIN) #include "chrome/browser/jumplist.h" #endif -#include "chrome/browser/page_info_window.h" #include "chrome/browser/profile.h" #include "chrome/browser/view_ids.h" #include "chrome/browser/views/bookmark_bar_view.h" diff --git a/chrome/browser/views/page_info_window_view.cc b/chrome/browser/views/page_info_window_view.cc index df95004..4e3b020 100644 --- a/chrome/browser/views/page_info_window_view.cc +++ b/chrome/browser/views/page_info_window_view.cc @@ -15,7 +15,6 @@ #include "base/compiler_specific.h" #include "chrome/browser/cert_store.h" #include "chrome/browser/page_info_model.h" -#include "chrome/browser/page_info_window.h" #include "chrome/common/pref_names.h" #include "grit/locale_settings.h" #include "grit/generated_resources.h" @@ -75,8 +74,8 @@ class PageInfoWindowView : public views::View, // views::DialogDelegate methods: virtual int GetDialogButtons() const; - virtual string16 GetWindowTitle() const; - virtual string16 GetWindowName() const; + virtual std::wstring GetWindowTitle() const; + virtual std::wstring GetWindowName() const; virtual views::View* GetContentsView(); virtual views::View* GetExtraView(); virtual bool CanResize() const { return true; } @@ -110,10 +109,10 @@ class PageInfoWindowView : public views::View, // optional head-line (in bold) and a description. class Section : public views::View { public: - Section(const string16& title, + Section(const std::wstring& title, bool state, - const string16& head_line, - const string16& description); + const std::wstring& head_line, + const std::wstring& description); virtual ~Section(); virtual int GetHeightForWidth(int w); @@ -121,16 +120,16 @@ class Section : public views::View { private: // The text placed on top of the section (on the left of the separator bar). - string16 title_; + std::wstring title_; // Whether to show the good/bad icon. bool state_; // The first line of the description, show in bold. - string16 head_line_; + std::wstring head_line_; // The description, displayed below the head line. - string16 description_; + std::wstring description_; static SkBitmap* good_state_icon_; static SkBitmap* bad_state_icon_; @@ -238,11 +237,11 @@ int PageInfoWindowView::GetDialogButtons() const { return MessageBoxFlags::DIALOGBUTTON_CANCEL; } -string16 PageInfoWindowView::GetWindowTitle() const { +std::wstring PageInfoWindowView::GetWindowTitle() const { return l10n_util::GetString(IDS_PAGEINFO_WINDOW_TITLE); } -string16 PageInfoWindowView::GetWindowName() const { +std::wstring PageInfoWindowView::GetWindowName() const { return prefs::kPageInfoWindowPlacement; } @@ -362,10 +361,10 @@ void PageInfoWindowView::ShowCertDialog(int cert_id) { //////////////////////////////////////////////////////////////////////////////// // Section -Section::Section(const string16& title, +Section::Section(const std::wstring& title, bool state, - const string16& head_line, - const string16& description) + const std::wstring& head_line, + const std::wstring& description) : title_(title), state_(state), head_line_(head_line), |