mirror of
https://github.com/WerWolv/ImHex.git
synced 2026-03-28 07:47:03 -05:00
Currently, if you start a selection in the middle of a largish file and without letting go of the left mouse key you place the mouse at the top line of the hex editor view then the selection will expand upwards and at some point the start of the selection will go out of view. If then you move the cursor (without letting go of the left mouse button) to the last line of the hex editor view you would expect that the end of the selection would start to increase in value, but it does nothing instead. A similar issue occurs at the other end. The problem is that the code only allows the upward scrolling when moving the smaller address end to the first line, but it should also allow it when the bigger address end to the first line. This means that it doesn't matter which of the two ends is larger and this code removes the conditions on the relative sizes of the two ends allowing for selection growth to reverse direction.