fix(ags popup): add timeout to onClose and fix setChild
This commit is contained in:
parent
98d5ff9389
commit
17e96320fc
1 changed files with 5 additions and 1 deletions
|
@ -1,6 +1,7 @@
|
||||||
import App from 'resource:///com/github/Aylur/ags/app.js';
|
import App from 'resource:///com/github/Aylur/ags/app.js';
|
||||||
|
|
||||||
import { Revealer, Box, Window } from 'resource:///com/github/Aylur/ags/widget.js';
|
import { Revealer, Box, Window } from 'resource:///com/github/Aylur/ags/widget.js';
|
||||||
|
import { timeout } from 'resource:///com/github/Aylur/ags/utils.js';
|
||||||
|
|
||||||
|
|
||||||
export default ({
|
export default ({
|
||||||
|
@ -57,7 +58,9 @@ export default ({
|
||||||
onOpen(child);
|
onOpen(child);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
onClose(child);
|
timeout(transitionDuration, () => {
|
||||||
|
onClose(child);
|
||||||
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}]],
|
}]],
|
||||||
|
@ -72,6 +75,7 @@ export default ({
|
||||||
window.getChild = () => window.child.children[0].child;
|
window.getChild = () => window.child.children[0].child;
|
||||||
window.setChild = (newChild) => {
|
window.setChild = (newChild) => {
|
||||||
window.child.children[0].child = newChild;
|
window.child.children[0].child = newChild;
|
||||||
|
window.child.children[0].show_all();
|
||||||
};
|
};
|
||||||
|
|
||||||
// This is for my custom pointers.js
|
// This is for my custom pointers.js
|
||||||
|
|
Loading…
Reference in a new issue