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

Unified Diff: ui/base/cursor/image_cursors.cc

Issue 2916823002: Move Mus into chrome's process when running with --mus.
Patch Set: Undo Screen TLS change, don't use Screen::GetScreen() in Mus. Created 3 years, 6 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: ui/base/cursor/image_cursors.cc
diff --git a/ui/base/cursor/image_cursors.cc b/ui/base/cursor/image_cursors.cc
index 93c25a9ae3d32f7c4b4a82167d5067b5486e5792..28d1e93b7ddc190d31f5c0f041928d66626afd5a 100644
--- a/ui/base/cursor/image_cursors.cc
+++ b/ui/base/cursor/image_cursors.cc
@@ -60,7 +60,8 @@ const CursorType kAnimatedCursorIds[] = {CursorType::kWait,
} // namespace
-ImageCursors::ImageCursors() : cursor_size_(CursorSize::kNormal) {}
+ImageCursors::ImageCursors()
+ : cursor_size_(CursorSize::kNormal), weak_ptr_factory_(this) {}
ImageCursors::~ImageCursors() {
}
@@ -142,4 +143,8 @@ void ImageCursors::SetPlatformCursor(gfx::NativeCursor* cursor) {
cursor_loader_->SetPlatformCursor(cursor);
}
+base::WeakPtr<ImageCursors> ImageCursors::GetWeakPtr() {
+ return weak_ptr_factory_.GetWeakPtr();
+}
+
} // namespace ui

Powered by Google App Engine
This is Rietveld 408576698