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

Unified Diff: chrome/browser/ui/cocoa/html_dialog_window_controller.mm

Issue 7461136: Convert HtmlDialogUIDelegate::GetDialogTitle() to string16. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: more fixes Created 9 years, 4 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/cocoa/html_dialog_window_controller.mm
diff --git a/chrome/browser/ui/cocoa/html_dialog_window_controller.mm b/chrome/browser/ui/cocoa/html_dialog_window_controller.mm
index 67c9537ddd95e8652f9a59d307ed2f5be7464ac4..865430604a032a5a5ea4b791e034640972356dc9 100644
--- a/chrome/browser/ui/cocoa/html_dialog_window_controller.mm
+++ b/chrome/browser/ui/cocoa/html_dialog_window_controller.mm
@@ -35,16 +35,17 @@ public:
void WindowControllerClosed();
// HtmlDialogUIDelegate declarations.
- virtual bool IsDialogModal() const;
- virtual std::wstring GetDialogTitle() const;
- virtual GURL GetDialogContentURL() const;
+ virtual bool IsDialogModal() const OVERRIDE;
+ virtual string16 GetDialogTitle() const OVERRIDE;
+ virtual GURL GetDialogContentURL() const OVERRIDE;
virtual void GetWebUIMessageHandlers(
- std::vector<WebUIMessageHandler*>* handlers) const;
- virtual void GetDialogSize(gfx::Size* size) const;
- virtual std::string GetDialogArgs() const;
- virtual void OnDialogClosed(const std::string& json_retval);
- virtual void OnCloseContents(TabContents* source, bool* out_close_dialog) { }
- virtual bool ShouldShowDialogTitle() const { return true; }
+ std::vector<WebUIMessageHandler*>* handlers) const OVERRIDE;
+ virtual void GetDialogSize(gfx::Size* size) const OVERRIDE;
+ virtual std::string GetDialogArgs() const OVERRIDE;
+ virtual void OnDialogClosed(const std::string& json_retval) OVERRIDE;
+ virtual void OnCloseContents(TabContents* source, bool* out_close_dialog)
+ OVERRIDE { }
+ virtual bool ShouldShowDialogTitle() const OVERRIDE { return true; }
// HtmlDialogTabContentsDelegate declarations.
virtual void MoveContents(TabContents* source, const gfx::Rect& pos);
@@ -123,8 +124,8 @@ bool HtmlDialogWindowDelegateBridge::IsDialogModal() const {
return false;
}
-std::wstring HtmlDialogWindowDelegateBridge::GetDialogTitle() const {
- return delegate_ ? delegate_->GetDialogTitle() : L"";
+string16 HtmlDialogWindowDelegateBridge::GetDialogTitle() const {
+ return delegate_ ? delegate_->GetDialogTitle() : string16();
}
GURL HtmlDialogWindowDelegateBridge::GetDialogContentURL() const {
@@ -254,7 +255,7 @@ void HtmlDialogWindowDelegateBridge::HandleKeyboardEvent(
}
[window setWindowController:self];
[window setDelegate:self];
- [window setTitle:base::SysWideToNSString(delegate->GetDialogTitle())];
+ [window setTitle:base::SysUTF16ToNSString(delegate->GetDialogTitle())];
[window center];
delegate_.reset(new HtmlDialogWindowDelegateBridge(self, profile, delegate));
return self;

Powered by Google App Engine
This is Rietveld 408576698