private static void HandleWindowScroll(NodeInputInfo inputInfo) { if (inputInfo.InputPos.x < 0 || inputInfo.InputPos.y < 0) { return; } NodeEditorState state = inputInfo.EdState; float Scale = 0.01f * inputInfo.InputEvent.delta.y; state.GraphZoom += Scale; if (state.GraphZoom <= 0.2f) { state.GraphZoom = 0.2f; } else if (state.GraphZoom >= 1.2f) { state.GraphZoom = 1.2f; } state.ZoomPos = state.CurGraphRect.size / 2; state.PanAdjust = EffectUtility.PanelScale(ref state.CurGraphRect, state.ZoomPos, state.GraphZoom); }