Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit 224b526

Browse files
committed
fix nits
1 parent 8ff375d commit 224b526

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

shell/common/vsync_waiter.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,7 @@ class VsyncWaiter : public std::enable_shared_from_this<VsyncWaiter> {
6565
// as AwaitVSync().
6666
virtual void AwaitVSyncForSecondaryCallback() { AwaitVSync(); }
6767

68+
// FireCallback() can be safely called from any thread.
6869
void FireCallback(fml::TimePoint frame_start_time,
6970
fml::TimePoint frame_target_time,
7071
bool pause_secondary_tasks = true);

shell/platform/fuchsia/flutter/vsync_waiter.cc

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,13 +51,13 @@ fml::TimePoint VsyncWaiter::SnapToNextPhase(
5151
const fml::TimePoint last_frame_presentation_time,
5252
const fml::TimeDelta presentation_interval) {
5353
if (presentation_interval <= fml::TimeDelta::Zero()) {
54-
FML_LOG(ERROR) << "Presentation interval must be positive. The value was: "
54+
FML_LOG(WARNING) << "Presentation interval must be positive. The value was: "
5555
<< presentation_interval.ToMilliseconds() << "ms.";
5656
return now;
5757
}
5858

5959
if (last_frame_presentation_time >= now) {
60-
FML_LOG(ERROR)
60+
FML_LOG(WARNING)
6161
<< "Last frame was presented in the future. Clamping to now.";
6262
return now + presentation_interval;
6363
}
@@ -193,7 +193,6 @@ VsyncWaiter::VsyncWaiter(SessionConnection* session_connection,
193193
}
194194

195195
VsyncWaiter::~VsyncWaiter() {
196-
FML_LOG(WARNING) << "~VsyncWaiter()";
197196
fml::AutoResetWaitableEvent ui_latch;
198197
fml::TaskRunner::RunNowOrPostTask(
199198
task_runners_.GetUITaskRunner(),

shell/platform/fuchsia/flutter/vsync_waiter.h

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,22 +25,22 @@ using LatchPointVsyncPair = std::pair<fml::TimePoint, fml::TimePoint>;
2525

2626
class VsyncWaiter final : public flutter::VsyncWaiter {
2727
public:
28-
static constexpr zx_signals_t SessionPresentSignal = ZX_EVENT_SIGNALED;
29-
VsyncWaiter(SessionConnection* session_connection,
30-
flutter::TaskRunners task_runners,
31-
fml::TimeDelta vsync_offset);
32-
3328
static FrameTargetTimes GetTargetTimes(fml::TimeDelta vsync_offset,
3429
fml::TimeDelta vsync_interval,
3530
fml::TimePoint last_targetted_vsync,
3631
fml::TimePoint now,
3732
fml::TimePoint next_vsync);
3833

34+
3935
static fml::TimePoint SnapToNextPhase(
4036
const fml::TimePoint now,
4137
const fml::TimePoint last_frame_presentation_time,
4238
const fml::TimeDelta presentation_interval);
4339

40+
VsyncWaiter(SessionConnection* session_connection,
41+
flutter::TaskRunners task_runners,
42+
fml::TimeDelta vsync_offset);
43+
4444
~VsyncWaiter() override;
4545

4646
private:

0 commit comments

Comments
 (0)