use of com.helospark.tactview.ui.javafx.inputmode.strategy.DrawRequestParameter in project tactview by helospark.
the class InputModeRepository method updateCanvasWithStrategy.
private void updateCanvasWithStrategy(GraphicsContext graphics, MouseEvent e) {
if (inputModeInput != null) {
DrawRequestParameter request = DrawRequestParameter.builder().withCanvas(graphics).withWidth(uiProjectRepository.getPreviewWidth()).withHeight(uiProjectRepository.getPreviewHeight()).withMouseInCanvas(e != null).withMouseEvent(Optional.ofNullable(e)).withCanvasTranslateX(canvasStateHolder.getTranslateX()).withCanvasTranslateY(canvasStateHolder.getTranslateY()).build();
inputModeInput.currentStrategy.draw(request);
}
}
Aggregations