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

Unified Diff: chrome/browser/ui/ash/launcher/chrome_mash_shelf_controller.cc

Issue 2014013002: Add SkBitmap StructTraits for skia::mojo::Bitmap. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Sync and rebase. Created 4 years, 7 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
« no previous file with comments | « chrome/browser/ui/ash/DEPS ('k') | chrome/chrome_common.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/ash/launcher/chrome_mash_shelf_controller.cc
diff --git a/chrome/browser/ui/ash/launcher/chrome_mash_shelf_controller.cc b/chrome/browser/ui/ash/launcher/chrome_mash_shelf_controller.cc
index 58e43d6c4202bc43b72eb19d10974dae6dbd32dd..58a49c6ddc66f63fed1ae0c0dd1cb29cfd181c9f 100644
--- a/chrome/browser/ui/ash/launcher/chrome_mash_shelf_controller.cc
+++ b/chrome/browser/ui/ash/launcher/chrome_mash_shelf_controller.cc
@@ -16,7 +16,6 @@
#include "extensions/grit/extensions_browser_resources.h"
#include "mojo/common/common_type_converters.h"
#include "services/shell/public/cpp/connector.h"
-#include "skia/public/type_converters.h"
#include "ui/base/resource/resource_bundle.h"
#include "ui/display/display.h"
#include "ui/display/screen.h"
@@ -125,7 +124,7 @@ void ChromeMashShelfController::PinAppsFromPrefs() {
item->app_title = mojo::String::From(helper_.GetAppTitle(profile, app));
ResourceBundle& rb = ResourceBundle::GetSharedInstance();
const gfx::Image& image = rb.GetImageNamed(IDR_APP_DEFAULT_ICON);
- item->image = skia::mojom::Bitmap::From(*image.ToSkBitmap());
+ item->image = *image.ToSkBitmap();
std::unique_ptr<ChromeShelfItemDelegate> delegate(
new ChromeShelfItemDelegate(app));
shelf_controller_->PinItem(std::move(item),
@@ -169,6 +168,5 @@ void ChromeMashShelfController::OnAutoHideBehaviorChanged(
void ChromeMashShelfController::OnAppImageUpdated(const std::string& app_id,
const gfx::ImageSkia& image) {
- shelf_controller_->SetItemImage(app_id,
- skia::mojom::Bitmap::From(*image.bitmap()));
+ shelf_controller_->SetItemImage(app_id, *image.bitmap());
}
« no previous file with comments | « chrome/browser/ui/ash/DEPS ('k') | chrome/chrome_common.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698