OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "content/shell/browser/shell.h" | 5 #include "content/shell/browser/shell.h" |
6 | 6 |
7 #include <windows.h> | 7 #include <windows.h> |
8 #include <commctrl.h> | 8 #include <commctrl.h> |
9 #include <fcntl.h> | 9 #include <fcntl.h> |
10 #include <io.h> | 10 #include <io.h> |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
69 id = IDC_NAV_STOP; | 69 id = IDC_NAV_STOP; |
70 break; | 70 break; |
71 default: | 71 default: |
72 NOTREACHED() << "Unknown UI control"; | 72 NOTREACHED() << "Unknown UI control"; |
73 return; | 73 return; |
74 } | 74 } |
75 EnableWindow(GetDlgItem(window_, id), is_enabled); | 75 EnableWindow(GetDlgItem(window_, id), is_enabled); |
76 } | 76 } |
77 | 77 |
78 void Shell::PlatformSetAddressBarURL(const GURL& url) { | 78 void Shell::PlatformSetAddressBarURL(const GURL& url) { |
79 std::wstring url_string = UTF8ToWide(url.spec()); | 79 std::wstring url_string = base::UTF8ToWide(url.spec()); |
80 SendMessage(url_edit_view_, WM_SETTEXT, 0, | 80 SendMessage(url_edit_view_, WM_SETTEXT, 0, |
81 reinterpret_cast<LPARAM>(url_string.c_str())); | 81 reinterpret_cast<LPARAM>(url_string.c_str())); |
82 } | 82 } |
83 | 83 |
84 void Shell::PlatformSetIsLoading(bool loading) { | 84 void Shell::PlatformSetIsLoading(bool loading) { |
85 } | 85 } |
86 | 86 |
87 void Shell::PlatformCreateWindow(int width, int height) { | 87 void Shell::PlatformCreateWindow(int width, int height) { |
88 window_ = CreateWindow(kWindowClass, kWindowTitle, | 88 window_ = CreateWindow(kWindowClass, kWindowTitle, |
89 WS_OVERLAPPEDWINDOW | WS_CLIPCHILDREN, | 89 WS_OVERLAPPEDWINDOW | WS_CLIPCHILDREN, |
(...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
276 | 276 |
277 return CallWindowProc(shell->default_edit_wnd_proc_, hwnd, message, wParam, | 277 return CallWindowProc(shell->default_edit_wnd_proc_, hwnd, message, wParam, |
278 lParam); | 278 lParam); |
279 } | 279 } |
280 | 280 |
281 void Shell::PlatformSetTitle(const base::string16& text) { | 281 void Shell::PlatformSetTitle(const base::string16& text) { |
282 ::SetWindowText(window_, text.c_str()); | 282 ::SetWindowText(window_, text.c_str()); |
283 } | 283 } |
284 | 284 |
285 } // namespace content | 285 } // namespace content |
OLD | NEW |