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

Side by Side Diff: content/browser/media/capture/aura_window_capture_machine.cc

Issue 2553763002: Fix cursor missing in tabCapture on OSX Sierra (Closed)
Patch Set: address comments and implement mouse tracking on Mac Created 3 years, 11 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "content/browser/media/capture/aura_window_capture_machine.h" 5 #include "content/browser/media/capture/aura_window_capture_machine.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 345 matching lines...) Expand 10 before | Expand all | Expand 10 after
356 bool result) { 356 bool result) {
357 DCHECK_CURRENTLY_ON(BrowserThread::UI); 357 DCHECK_CURRENTLY_ON(BrowserThread::UI);
358 358
359 release_callback->Run(gpu::SyncToken(), false); 359 release_callback->Run(gpu::SyncToken(), false);
360 360
361 // Render the cursor and deliver the captured frame if the 361 // Render the cursor and deliver the captured frame if the
362 // AuraWindowCaptureMachine has not been stopped (i.e., the WeakPtr is 362 // AuraWindowCaptureMachine has not been stopped (i.e., the WeakPtr is
363 // still valid). 363 // still valid).
364 if (machine) { 364 if (machine) {
365 if (machine->cursor_renderer_ && result) 365 if (machine->cursor_renderer_ && result)
366 machine->cursor_renderer_->RenderOnVideoFrame(target); 366 machine->cursor_renderer_->RenderOnVideoFrame(target.get());
367 } else { 367 } else {
368 VLOG(1) << "Aborting capture: AuraWindowCaptureMachine has gone away."; 368 VLOG(1) << "Aborting capture: AuraWindowCaptureMachine has gone away.";
369 result = false; 369 result = false;
370 } 370 }
371 371
372 capture_frame_cb.Run(std::move(target), event_time, result); 372 capture_frame_cb.Run(std::move(target), event_time, result);
373 } 373 }
374 374
375 void AuraWindowCaptureMachine::OnWindowBoundsChanged( 375 void AuraWindowCaptureMachine::OnWindowBoundsChanged(
376 aura::Window* window, 376 aura::Window* window,
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
437 Capture(timestamp); 437 Capture(timestamp);
438 } 438 }
439 439
440 void AuraWindowCaptureMachine::OnCompositingShuttingDown( 440 void AuraWindowCaptureMachine::OnCompositingShuttingDown(
441 ui::Compositor* compositor) { 441 ui::Compositor* compositor) {
442 DCHECK_CURRENTLY_ON(BrowserThread::UI); 442 DCHECK_CURRENTLY_ON(BrowserThread::UI);
443 compositor->RemoveAnimationObserver(this); 443 compositor->RemoveAnimationObserver(this);
444 } 444 }
445 445
446 } // namespace content 446 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698