refactor: remove unreachable internal code paths
Co-authored-by: chengyongru <61816729+chengyongru@users.noreply.github.com>
This commit is contained in:
1 parent
4212ad726d
commit
9257383bec
21 files changed
+86
-285
No files matched your search
@@ -110,7 +110,6 @@ interface ThreadMotionTurn {
|
||||
interface ThreadMotionSnapshot {
|
||||
mode: ThreadMotionMode;
|
||||
turnId: string | null;
|
||||
promptId: string | null;
|
||||
promptPositioned: boolean;
|
||||
measurementPending: boolean;
|
||||
}
|
||||
@@ -191,7 +190,6 @@ export class ThreadMotionCoordinator {
|
||||
return {
|
||||
mode: this.mode,
|
||||
turnId: this.turn.id,
|
||||
promptId: this.turn.promptId,
|
||||
promptPositioned: this.promptPositioned,
|
||||
measurementPending: this.measurementFrameId !== null,
|
||||
};
|
||||
@@ -315,17 +313,13 @@ export class ThreadMotionCoordinator {
|
||||
return result;
|
||||
}
|
||||
|
||||
navigateHistoryTo(top: number): ThreadCameraFollowResult | null {
|
||||
return this.beginHistoryNavigation(top, null);
|
||||
}
|
||||
|
||||
navigateHistoryToPrompt(promptId: string): ThreadCameraFollowResult | null {
|
||||
const geometry = this.measure(promptId);
|
||||
if (!geometry || geometry.promptTop === null) return null;
|
||||
return this.beginHistoryNavigation(geometry.promptTop, promptId);
|
||||
}
|
||||
|
||||
private beginHistoryNavigation(top: number, promptId: string | null): ThreadCameraFollowResult | null {
|
||||
private beginHistoryNavigation(top: number, promptId: string): ThreadCameraFollowResult | null {
|
||||
if (this.mode !== "navigating-history") this.camera.cancel();
|
||||
this.transition("navigate-history");
|
||||
this.historyNavigationPromptId = promptId;
|
||||
|
||||
Reference in new issue
Block a user