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

Side by Side Diff: skia/ext/bitmap_platform_device_linux.cc

Issue 2982002: test_shell: fix for newer cairos (Closed)
Patch Set: Created 10 years, 5 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 "skia/ext/bitmap_platform_device_linux.h" 5 #include "skia/ext/bitmap_platform_device_linux.h"
6 6
7 #include <cairo/cairo.h> 7 #include <cairo/cairo.h>
8 8
9 namespace skia { 9 namespace skia {
10 10
(...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after
180 const BitmapPlatformDevice& other) 180 const BitmapPlatformDevice& other)
181 : PlatformDevice(const_cast<BitmapPlatformDevice&>( 181 : PlatformDevice(const_cast<BitmapPlatformDevice&>(
182 other).accessBitmap(true)), 182 other).accessBitmap(true)),
183 data_(other.data_) { 183 data_(other.data_) {
184 } 184 }
185 185
186 BitmapPlatformDevice::~BitmapPlatformDevice() { 186 BitmapPlatformDevice::~BitmapPlatformDevice() {
187 } 187 }
188 188
189 cairo_t* BitmapPlatformDevice::beginPlatformPaint() { 189 cairo_t* BitmapPlatformDevice::beginPlatformPaint() {
190 return data_->GetContext(); 190 cairo_t* cairo = data_->GetContext();
191 // Tell Cairo that we've (probably) modified its pixel buffer without
192 // its knowledge.
193 cairo_surface_mark_dirty(cairo_get_target(cairo));
194 return cairo;
191 } 195 }
192 196
193 void BitmapPlatformDevice::setMatrixClip(const SkMatrix& transform, 197 void BitmapPlatformDevice::setMatrixClip(const SkMatrix& transform,
194 const SkRegion& region) { 198 const SkRegion& region) {
195 data_->SetMatrixClip(transform, region); 199 data_->SetMatrixClip(transform, region);
196 } 200 }
197 201
198 BitmapPlatformDevice& BitmapPlatformDevice::operator=( 202 BitmapPlatformDevice& BitmapPlatformDevice::operator=(
199 const BitmapPlatformDevice& other) { 203 const BitmapPlatformDevice& other) {
200 data_ = other.data_; 204 data_ = other.data_;
201 return *this; 205 return *this;
202 } 206 }
203 207
204 } // namespace skia 208 } // namespace skia
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698