Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
DeskTop: Remove seemingly unneeded safety check when adjusting ports
When drawing window entries, the grafport needs to be adjusted to account for the header. This is normally done in `OffsetWindowGrafportAndSet` which updates the previously selected `window_grafport`. Notably, while callers must be sensitive to GetWinPort failing if the window is obscured, when the port is updated and SetPort is called there is no subsequent check that the port is not offscreen. MGTK seems okay with this. When update events are being processed, a different grafport is provided via `BeginUpdate`. This is clipped to just the necessary update rect, e.g. what was revealed by a window move. There was separate code to deal with updating the port to account for the header here. And notably, because of issue #369, there was logic to ensure the updated port was not offscreen. Why is it needed for updates, but not for the normal drawing? Further testing reveals that the bug no longer reproduces with this logic removed; likely it was only present in old code that didn't use the grafport provided with the `BeginUpdate`. So... remove the check? Seems okay so far.
- Loading branch information