Missing Fonts dialog: Use JSDialog instead of Vex, allow dismiss

Before this commit it, it was impossible to:
- Dismiss the dialog by clicking anywhere else
- Dismiss when using mobile (it blocked both editing and reading)

Signed-off-by: Gülşah Köse <gulsah.kose@collabora.com>
Change-Id: I3caeef327e653a054994fb01e8e53c5023c20055
This commit is contained in:
Gülşah Köse 2023-01-03 17:11:20 +01:00 committed by pedropintosilva
parent 4c2c8833c5
commit 1fb15d4179

View file

@ -1077,14 +1077,13 @@ app.definitions.Socket = L.Class.extend({
}
else if (textMsg.startsWith('fontsmissing:')) {
var fontsMissingObj = JSON.parse(textMsg.substring(textMsg.indexOf('{')));
var msg = _('Missing fonts:');
msg += ' ';
var msg = ' ';
for (var i = 0; i < fontsMissingObj.fontsmissing.length; ++i) {
if (i > 0)
msg += ', ';
msg += fontsMissingObj.fontsmissing[i];
}
this._map.fire('infobar', { msg: msg });
this._map.uiManager.showInfoModal('fontsmissing', _('Missing Fonts'), msg, null, _('Close'));
}
else if (textMsg.startsWith('info:') && command.errorCmd === 'socket') {
if (command.errorKind === 'limitreached' && !this.WasShownLimitDialog) {