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

Side by Side Diff: content/common/gpu/media/gpu_video_decode_accelerator.cc

Issue 649533003: C++11 declares a type safe null pointer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed Presubmit errors Created 6 years, 2 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/common/gpu/media/gpu_video_decode_accelerator.h" 5 #include "content/common/gpu/media/gpu_video_decode_accelerator.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 public: 69 public:
70 explicit DebugAutoLock(base::Lock&) {} 70 explicit DebugAutoLock(base::Lock&) {}
71 }; 71 };
72 #endif 72 #endif
73 73
74 class GpuVideoDecodeAccelerator::MessageFilter : public IPC::MessageFilter { 74 class GpuVideoDecodeAccelerator::MessageFilter : public IPC::MessageFilter {
75 public: 75 public:
76 MessageFilter(GpuVideoDecodeAccelerator* owner, int32 host_route_id) 76 MessageFilter(GpuVideoDecodeAccelerator* owner, int32 host_route_id)
77 : owner_(owner), host_route_id_(host_route_id) {} 77 : owner_(owner), host_route_id_(host_route_id) {}
78 78
79 virtual void OnChannelError() override { sender_ = NULL; } 79 virtual void OnChannelError() override { sender_ = nullptr; }
80 80
81 virtual void OnChannelClosing() override { sender_ = NULL; } 81 virtual void OnChannelClosing() override { sender_ = nullptr; }
82 82
83 virtual void OnFilterAdded(IPC::Sender* sender) override { 83 virtual void OnFilterAdded(IPC::Sender* sender) override {
84 sender_ = sender; 84 sender_ = sender;
85 } 85 }
86 86
87 virtual void OnFilterRemoved() override { 87 virtual void OnFilterRemoved() override {
88 // This will delete |owner_| and |this|. 88 // This will delete |owner_| and |this|.
89 owner_->OnFilterRemoved(); 89 owner_->OnFilterRemoved();
90 } 90 }
91 91
(...skipping 415 matching lines...) Expand 10 before | Expand all | Expand 10 after
507 return stub_->channel()->Send(message); 507 return stub_->channel()->Send(message);
508 } 508 }
509 509
510 void GpuVideoDecodeAccelerator::SendCreateDecoderReply(IPC::Message* message, 510 void GpuVideoDecodeAccelerator::SendCreateDecoderReply(IPC::Message* message,
511 bool succeeded) { 511 bool succeeded) {
512 GpuCommandBufferMsg_CreateVideoDecoder::WriteReplyParams(message, succeeded); 512 GpuCommandBufferMsg_CreateVideoDecoder::WriteReplyParams(message, succeeded);
513 Send(message); 513 Send(message);
514 } 514 }
515 515
516 } // namespace content 516 } // namespace content
OLDNEW
« no previous file with comments | « content/common/gpu/media/exynos_v4l2_video_device.cc ('k') | content/common/gpu/media/h264_dpb.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698