mirror of
https://github.com/rkd77/elinks.git
synced 2024-12-04 14:46:47 -05:00
SMJS: elinks.alert: drop the extra 'error' text
Use info_box directly instead of via report_scripting_error by way of alert_smjs_error, thereby avoiding the addition of extra text saying that an error has occurred.
This commit is contained in:
parent
d5fe12b5f4
commit
3bd14d8392
@ -6,8 +6,10 @@
|
||||
|
||||
#include "elinks.h"
|
||||
|
||||
#include "bfu/msgbox.h"
|
||||
#include "config/home.h"
|
||||
#include "ecmascript/spidermonkey/util.h"
|
||||
#include "intl/gettext/libintl.h"
|
||||
#include "protocol/uri.h"
|
||||
#include "scripting/scripting.h"
|
||||
#include "scripting/smjs/bookmarks.h"
|
||||
@ -75,7 +77,8 @@ elinks_alert(JSContext *ctx, JSObject *obj, uintN argc, jsval *argv, jsval *rval
|
||||
if (!*string)
|
||||
return JS_TRUE;
|
||||
|
||||
alert_smjs_error(string);
|
||||
info_box(smjs_ses->tab->term, MSGBOX_NO_TEXT_INTL,
|
||||
N_("User script alert"), ALIGN_LEFT, string);
|
||||
|
||||
undef_to_jsval(ctx, rval);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user