1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #import <Cocoa/Cocoa.h>
7 #include "content/browser/compositor/software_output_device_mac.h"
9 #include "content/browser/compositor/browser_compositor_view_mac.h"
10 #include "ui/compositor/compositor.h"
14 SoftwareOutputDeviceMac::SoftwareOutputDeviceMac(ui::Compositor* compositor)
15 : compositor_(compositor) {
18 SoftwareOutputDeviceMac::~SoftwareOutputDeviceMac() {
21 void SoftwareOutputDeviceMac::EndPaint(cc::SoftwareFrameData* frame_data) {
22 SoftwareOutputDevice::EndPaint(frame_data);
24 NSView* view = compositor_->widget();
25 [view gotSoftwareFrame:frame_data
26 withScaleFactor:scale_factor_
27 withCanvas:canvas_.get()];
30 } // namespace content