Skip to content

Commit

Permalink
use shorter name of prefetchPriority; don't type-check when calling it
Browse files Browse the repository at this point in the history
  • Loading branch information
frasercl committed Feb 15, 2024
1 parent 1ea988b commit a70efb4
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/aics-image-viewer/components/App/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ import {
View3d,
Volume,
IVolumeLoader,
WorkerLoader,
PrefetchDirection,
} from "@aics/volume-viewer";

Expand Down Expand Up @@ -216,7 +215,7 @@ const App: React.FC<AppProps> = (props) => {
const playControls = useConstructor(() => new PlayControls());
const [playingAxis, setPlayingAxis] = useState<AxisName | "t" | null>(null);
playControls.onPlayingAxisChanged = (axis) => {
(loader.current as WorkerLoader)?.setPrefetchPriorityDirections?.(axis ? [axisToLoaderPriority[axis]] : []);
loader.current?.setPrefetchPriority(axis ? [axisToLoaderPriority[axis]] : []);
setPlayingAxis(axis);
};

Expand Down

0 comments on commit a70efb4

Please sign in to comment.