qtvcp: write the var file before reloading the preview on offset changes - #4607
Open
grandixximo wants to merge 1 commit into
Open
grandixximo wants to merge 1 commit into
grandixximo wants to merge 1 commit into
Conversation
The preview reads offsets from the var file, which the interpreter only writes when it synchs. Offset actions reloaded before that happened: the CALL_MDI ones did not wait for the MDI, and the others had no mode change to trigger the write when already in MDI mode. Run them through one helper that waits, requests a plan synch, restores the previous mode and reloads.
Collaborator
|
Restoring the mode is good yes. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
After ZERO G5X, ZERO G92, zero rotation, set axis origin or lathe mirror, qtdragon can keep drawing the program at the old offsets.
The preview reads offsets from the var file, which the interpreter writes only when it synchs (on a mode change). The
CALL_MDIbased actions reloaded before the G10/G92.1 ran; the others, when already in MDI mode, had no mode change to trigger the write.All six now go through one helper: run the MDI, wait,
task_plan_synch(), restore the mode, reload.MDILinealready does this for typed G10. As a side effect, the formerCALL_MDIactions return to the calling mode instead of staying in MDI.Tested in the qtdragon_xyz sim under xvfb, from MANUAL and from MDI:
probe_routines.pyset_zero/rotate_coord_systemhave the same pattern; not changed here (untested).@cmorley, is restoring the previous mode OK for these actions?