fix scroll-to call when the end of a selection is to the left (in terms of locations) of the start
svn: r11444
This commit is contained in:
parent
3ca429fbce
commit
27c9c2a22f
|
@ -998,6 +998,12 @@ Bool wxMediaEdit::ScrollToPosition(long start, Bool ateol, Bool refresh,
|
|||
PositionLocation(start, &topx, &topy, TRUE, ateol, TRUE);
|
||||
PositionLocation(end, &botx, &boty, FALSE, ateol, TRUE);
|
||||
|
||||
if (botx < topx) {
|
||||
/* when the end position is to the left of the start position */
|
||||
topx = 0;
|
||||
botx = totalWidth;
|
||||
}
|
||||
|
||||
w = botx - topx;
|
||||
h = boty - topy;
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user