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

Side by Side Diff: content/shell/shell_gtk.cc

Issue 14081010: Cleanup: Remove unnecessary ".get()" from scoped_ptrs<>. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix some gtk issues Created 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/shell.h" 5 #include "content/shell/shell.h"
6 6
7 #include <gdk/gdkkeysyms.h> 7 #include <gdk/gdkkeysyms.h>
8 #include <gtk/gtk.h> 8 #include <gtk/gtk.h>
9 9
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 191 matching lines...) Expand 10 before | Expand all | Expand 10 after
202 if (headless_) 202 if (headless_)
203 return; 203 return;
204 204
205 WebContentsView* content_view = web_contents_->GetView(); 205 WebContentsView* content_view = web_contents_->GetView();
206 gtk_container_add(GTK_CONTAINER(vbox_), content_view->GetNativeView()); 206 gtk_container_add(GTK_CONTAINER(vbox_), content_view->GetNativeView());
207 } 207 }
208 208
209 void Shell::SizeTo(int width, int height) { 209 void Shell::SizeTo(int width, int height) {
210 content_width_ = width; 210 content_width_ = width;
211 content_height_ = height; 211 content_height_ = height;
212 if (web_contents_.get()) { 212 if (web_contents_) {
213 gtk_widget_set_size_request(web_contents_->GetView()->GetNativeView(), 213 gtk_widget_set_size_request(web_contents_->GetView()->GetNativeView(),
214 width, height); 214 width, height);
215 } 215 }
216 } 216 }
217 217
218 void Shell::PlatformResizeSubViews() { 218 void Shell::PlatformResizeSubViews() {
219 SizeTo(content_width_, content_height_); 219 SizeTo(content_width_, content_height_);
220 } 220 }
221 221
222 void Shell::Close() { 222 void Shell::Close() {
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
290 290
291 void Shell::PlatformSetTitle(const string16& title) { 291 void Shell::PlatformSetTitle(const string16& title) {
292 if (headless_) 292 if (headless_)
293 return; 293 return;
294 294
295 std::string title_utf8 = UTF16ToUTF8(title); 295 std::string title_utf8 = UTF16ToUTF8(title);
296 gtk_window_set_title(GTK_WINDOW(window_), title_utf8.c_str()); 296 gtk_window_set_title(GTK_WINDOW(window_), title_utf8.c_str());
297 } 297 }
298 298
299 } // namespace content 299 } // namespace content
OLDNEW
« no previous file with comments | « content/shell/shell_browser_context.cc ('k') | content/shell/shell_javascript_dialog_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698