forked from Blendman974/faceclaw
Fix missing rerender when EvenHub apps finish downloading
This commit is contained in:
1 parent
d6ce2f4194
commit
a6291cf937
1 file changed
+4
-2
@@ -53,8 +53,6 @@ export async function installStoreApp(
|
|||||||
const needsPrompt = (manifest.permissions.length > 0 || privacyPolicyUrl)
|
const needsPrompt = (manifest.permissions.length > 0 || privacyPolicyUrl)
|
||||||
&& !alreadyGranted(app.packageId, manifest);
|
&& !alreadyGranted(app.packageId, manifest);
|
||||||
if (needsPrompt) {
|
if (needsPrompt) {
|
||||||
options.onStatus("");
|
|
||||||
ctx.actions.requestRender();
|
|
||||||
const accepted = await new Promise<boolean>((resolve) => {
|
const accepted = await new Promise<boolean>((resolve) => {
|
||||||
ctx.stack.push(
|
ctx.stack.push(
|
||||||
new EvenHubPermissionDialogLayer(
|
new EvenHubPermissionDialogLayer(
|
||||||
@@ -65,6 +63,10 @@ export async function installStoreApp(
|
|||||||
() => resolve(false),
|
() => resolve(false),
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
|
// Only once the dialog is stacked: an in-process window's requestRender
|
||||||
|
// paints synchronously, and nothing else repaints after a download.
|
||||||
|
options.onStatus("");
|
||||||
|
ctx.actions.requestRender();
|
||||||
});
|
});
|
||||||
if (!accepted) return null;
|
if (!accepted) return null;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user