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

Side by Side Diff: chrome/browser/ui/gtk/task_manager_gtk.cc

Issue 10860004: image-skia: Remove implicit conversion to SkBitmap on linux and chromeos. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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 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 "chrome/browser/ui/gtk/task_manager_gtk.h" 5 #include "chrome/browser/ui/gtk/task_manager_gtk.h"
6 6
7 #include <gdk/gdkkeysyms.h> 7 #include <gdk/gdkkeysyms.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <set> 10 #include <set>
(...skipping 714 matching lines...) Expand 10 before | Expand all | Expand 10 after
725 case IDS_TASK_MANAGER_GOATS_TELEPORTED_COLUMN: // Goats Teleported! 725 case IDS_TASK_MANAGER_GOATS_TELEPORTED_COLUMN: // Goats Teleported!
726 return UTF16ToUTF8(model_->GetResourceGoatsTeleported(row)); 726 return UTF16ToUTF8(model_->GetResourceGoatsTeleported(row));
727 727
728 default: 728 default:
729 NOTREACHED(); 729 NOTREACHED();
730 return std::string(); 730 return std::string();
731 } 731 }
732 } 732 }
733 733
734 GdkPixbuf* TaskManagerGtk::GetModelIcon(int row) { 734 GdkPixbuf* TaskManagerGtk::GetModelIcon(int row) {
735 SkBitmap icon = model_->GetResourceIcon(row); 735 SkBitmap icon = *model_->GetResourceIcon(row).bitmap();
736 if (icon.pixelRef() == 736 if (icon.pixelRef() ==
737 ui::ResourceBundle::GetSharedInstance().GetBitmapNamed( 737 ui::ResourceBundle::GetSharedInstance().GetBitmapNamed(
738 IDR_DEFAULT_FAVICON)->pixelRef()) { 738 IDR_DEFAULT_FAVICON)->pixelRef()) {
739 return static_cast<GdkPixbuf*>(g_object_ref( 739 return static_cast<GdkPixbuf*>(g_object_ref(
740 GtkThemeService::GetDefaultFavicon(true).ToGdkPixbuf())); 740 GtkThemeService::GetDefaultFavicon(true).ToGdkPixbuf()));
741 } 741 }
742 742
743 return gfx::GdkPixbufFromSkBitmap(icon); 743 return gfx::GdkPixbufFromSkBitmap(icon);
744 } 744 }
745 745
(...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after
1016 guint keyval, 1016 guint keyval,
1017 GdkModifierType modifier) { 1017 GdkModifierType modifier) {
1018 if (keyval == GDK_w && modifier == GDK_CONTROL_MASK) { 1018 if (keyval == GDK_w && modifier == GDK_CONTROL_MASK) {
1019 // The GTK_RESPONSE_DELETE_EVENT response must be sent before the widget 1019 // The GTK_RESPONSE_DELETE_EVENT response must be sent before the widget
1020 // is destroyed. The deleted object will receive gtk signals otherwise. 1020 // is destroyed. The deleted object will receive gtk signals otherwise.
1021 gtk_dialog_response(GTK_DIALOG(dialog_), GTK_RESPONSE_DELETE_EVENT); 1021 gtk_dialog_response(GTK_DIALOG(dialog_), GTK_RESPONSE_DELETE_EVENT);
1022 } 1022 }
1023 1023
1024 return TRUE; 1024 return TRUE;
1025 } 1025 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/gtk/speech_recognition_bubble_gtk.cc ('k') | content/browser/web_contents/web_contents_drag_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698