fix: remaining issues recorded during test coverage work

- RenderManager: GPU-side members (context_, decoder_cache_,
  shader_cache_, auto_cacher_, worker_pool_, decoder_clear_timer_) were
  left uninitialized when the configured graphics backend is unknown
  (e.g. dummy); ViewerWidget then dereferenced garbage and crashed.
  Initialize them at declaration
- CurveView::SelectKeyframesOfInput ignored its reference parameter and
  selected keyframes of every connected track; select only the
  requested track's keyframes
- SeekableWidget::SeekToScenePoint dereferenced GetViewerNode()
  unconditionally; skip the playhead update when no viewer is connected
- LoadOTIOTask: unknown root schema leaked the freshly allocated
  project_ (delete + reset; OTIO is not enabled in local builds so this
  file is compile-verified by inspection only)

Locked by new tests: RenderManagerDummyBackend,
TimeRuler.SeekToScenePointWithoutViewerIsNoOp,
CurveViewTest.SelectKeyframesOfInputSelectsOnlyRequestedTrack
This commit is contained in:
2026-07-17 17:20:50 +08:00
parent 7223900b6d
commit 004e942cf9
7 changed files with 77 additions and 13 deletions
@@ -100,6 +100,20 @@ TEST(TimeRuler, SeekToScenePointWithoutTimebaseIsNoOp)
SUCCEED();
}
TEST(TimeRuler, SeekToScenePointWithoutViewerIsNoOp)
{
EnsureAppSingletons();
// Timebase set but no viewer connected: previously dereferenced a null
// GetViewerNode() and crashed.
TimeRuler ruler;
ruler.SetTimebase(rational(1, 30));
ruler.SetScale(100.0);
ruler.SeekToScenePoint(150.0);
SUCCEED();
}
class PlaybackControlsTest : public ::testing::Test {
protected:
void SetUp() override