abort max animation on unrelated geometry changes
stupid clients think it's relevant to withdraw other states when going fullscreen, this means we trigger an nmaximization animation and when that's done, the window is fullscreen... Unfortunately one of the stupid clients is QWidget and also the window could get other, *legit*, resizes during the animation, so we cancel it on occasion BUG: 336467 FIXED-IN: 5.5 REVIEW: 125989
This commit is contained in:
parent
8bea96d701
commit
c04f7919c1
1 changed files with 13 additions and 2 deletions
|
@ -35,7 +35,7 @@ var maximizeEffect = {
|
|||
oldGeometry = window.olderGeometry;
|
||||
window.olderGeometry = window.oldGeometry;
|
||||
window.oldGeometry = newGeometry;
|
||||
animate({
|
||||
window.maximizeAnimation1 = animate({
|
||||
window: window,
|
||||
duration: maximizeEffect.duration,
|
||||
animations: [{
|
||||
|
@ -61,7 +61,7 @@ var maximizeEffect = {
|
|||
}]
|
||||
});
|
||||
if (!window.resize) {
|
||||
animate({
|
||||
window.maximizeAnimation2 =animate({
|
||||
window: window,
|
||||
duration: maximizeEffect.duration,
|
||||
animations: [{
|
||||
|
@ -74,6 +74,17 @@ var maximizeEffect = {
|
|||
},
|
||||
geometryChange: function (window, oldGeometry) {
|
||||
"use strict";
|
||||
if (window.maximizeAnimation1) {
|
||||
if (window.geometry.width != window.oldGeometry.width ||
|
||||
window.geometry.height != window.oldGeometry.height) {
|
||||
cancel(window.maximizeAnimation1);
|
||||
delete window.maximizeAnimation1;
|
||||
if (window.maximizeAnimation2) {
|
||||
cancel(window.maximizeAnimation2);
|
||||
delete window.maximizeAnimation2;
|
||||
}
|
||||
}
|
||||
}
|
||||
window.oldGeometry = window.geometry;
|
||||
window.olderGeometry = oldGeometry;
|
||||
},
|
||||
|
|
Loading…
Reference in a new issue