mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 873518 - Fix off-by-one error when moving widgets within their area, r=jaws
--HG-- extra : rebase_source : f88fdacfbdc34564d70eec022fd7201c4490c9aa
This commit is contained in:
parent
ecc9f5f892
commit
b07c1a24bc
@ -911,6 +911,11 @@ let CustomizableUIInternal = {
|
||||
}
|
||||
|
||||
placements.splice(oldPlacement.position, 1);
|
||||
// If we just removed the item from *before* where it is now added,
|
||||
// we need to compensate the position offset for that:
|
||||
if (oldPlacement.position < aPosition) {
|
||||
aPosition--;
|
||||
}
|
||||
placements.splice(aPosition, 0, aWidgetId);
|
||||
|
||||
let widget = gPalette.get(aWidgetId);
|
||||
|
Loading…
Reference in New Issue
Block a user