Fix graphical vga mode scaling on loading states#1576
Conversation
|
Threading a boolean flag through a bunch of functions doesn't look like a very readable solution. Can you try to find something nicer? |
|
Would you prefer having restore first call |
|
I just filed a different bug about graphical text mode, #1579 , and if it is related to initialization somehow maybe the solution is connected to this issue also (but the patch in this PR does not fix it on its own). @chschnell any thoughts? Sorry for the double-ping but I realized you weren't addressed on this PR. |
It seems that |
|
So I did something slightly different, instead adding a method to invalidate the screen's internal state. I tried to do as you suggested first but it looked like I'd need to duplicate some logic around what exact calls needed to be made during |
|
Oh, and I'm also happy to combine these into one commit and force push a cleaner history after review but I wanted to give you a chance to review commit-by-commit first. |
7f35971 to
71336ba
Compare
|
Thanks! Squashed and merged. |
I encountered an issue similar to the one described in PR 1123. While using VGA text mode, if I made a save state during text mode and started a fullscreen game that was at a different resolution, then when I loaded the state the canvas size (notably its actual size, not its style) would still be set to a smaller value. This is because the number of rows and columns did not actually change, so the text mode display was not refreshed. I fixed this by adding a
forceparameter to the involved functions to give a way to ensure that the settings were refreshed even if it seemed locally to the screen code like a no-op.