| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 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 "cc/test/begin_frame_args_test.h" | 5 #include "cc/test/begin_frame_args_test.h" |
| 6 | 6 |
| 7 #include <stdint.h> | 7 #include <stdint.h> |
| 8 | 8 |
| 9 #include "base/time/time.h" | 9 #include "base/time/time.h" |
| 10 #include "cc/output/begin_frame_args.h" | 10 #include "cc/output/begin_frame_args.h" |
| (...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 91 << args.frame_time.ToInternalValue() << ", " | 91 << args.frame_time.ToInternalValue() << ", " |
| 92 << args.deadline.ToInternalValue() << ", " | 92 << args.deadline.ToInternalValue() << ", " |
| 93 << args.interval.InMicroseconds() << "us)"; | 93 << args.interval.InMicroseconds() << "us)"; |
| 94 } | 94 } |
| 95 | 95 |
| 96 bool operator==(const BeginFrameAck& lhs, const BeginFrameAck& rhs) { | 96 bool operator==(const BeginFrameAck& lhs, const BeginFrameAck& rhs) { |
| 97 return (lhs.source_id == rhs.source_id) && | 97 return (lhs.source_id == rhs.source_id) && |
| 98 (lhs.sequence_number == rhs.sequence_number) && | 98 (lhs.sequence_number == rhs.sequence_number) && |
| 99 (lhs.latest_confirmed_sequence_number == | 99 (lhs.latest_confirmed_sequence_number == |
| 100 rhs.latest_confirmed_sequence_number) && | 100 rhs.latest_confirmed_sequence_number) && |
| 101 (lhs.remaining_frames == rhs.remaining_frames) && | |
| 102 (lhs.has_damage == rhs.has_damage); | 101 (lhs.has_damage == rhs.has_damage); |
| 103 } | 102 } |
| 104 | 103 |
| 105 ::std::ostream& operator<<(::std::ostream& os, const BeginFrameAck& args) { | 104 ::std::ostream& operator<<(::std::ostream& os, const BeginFrameAck& args) { |
| 106 PrintTo(args, &os); | 105 PrintTo(args, &os); |
| 107 return os; | 106 return os; |
| 108 } | 107 } |
| 109 | 108 |
| 110 void PrintTo(const BeginFrameAck& ack, ::std::ostream* os) { | 109 void PrintTo(const BeginFrameAck& ack, ::std::ostream* os) { |
| 111 *os << "BeginFrameAck(" << ack.source_id << ", " << ack.sequence_number | 110 *os << "BeginFrameAck(" << ack.source_id << ", " << ack.sequence_number |
| 112 << ", " << ack.latest_confirmed_sequence_number << ", " | 111 << ", " << ack.latest_confirmed_sequence_number << ", " << ack.has_damage |
| 113 << ack.remaining_frames << ", " << ack.has_damage << ")"; | 112 << ")"; |
| 114 } | 113 } |
| 115 | 114 |
| 116 } // namespace cc | 115 } // namespace cc |
| OLD | NEW |