mirror of
https://github.com/rkd77/elinks.git
synced 2024-12-04 14:46:47 -05:00
SEE: Renamed ELinks functions with the "SEE" prefix to distinguish them
from SEE functions.
[ Backported from commit c5b102ba08
on
the witekfl branch. --KON ]
This commit is contained in:
parent
444df743cc
commit
e741932d58
@ -104,7 +104,7 @@ see_eval(struct ecmascript_interpreter *interpreter,
|
|||||||
|
|
||||||
struct SEE_interpreter *interp = interpreter->backend_data;
|
struct SEE_interpreter *interp = interpreter->backend_data;
|
||||||
struct global_object *g = (struct global_object *)interp;
|
struct global_object *g = (struct global_object *)interp;
|
||||||
struct SEE_input *input = SEE_input_elinks(interp, code->source);
|
struct SEE_input *input = see_input_elinks(interp, code->source);
|
||||||
SEE_try_context_t try_ctxt;
|
SEE_try_context_t try_ctxt;
|
||||||
struct SEE_value result;
|
struct SEE_value result;
|
||||||
|
|
||||||
@ -125,7 +125,7 @@ see_eval_stringback(struct ecmascript_interpreter *interpreter,
|
|||||||
{
|
{
|
||||||
struct SEE_interpreter *interp = interpreter->backend_data;
|
struct SEE_interpreter *interp = interpreter->backend_data;
|
||||||
struct global_object *g = (struct global_object *)interp;
|
struct global_object *g = (struct global_object *)interp;
|
||||||
struct SEE_input *input = SEE_input_elinks(interp, code->source);
|
struct SEE_input *input = see_input_elinks(interp, code->source);
|
||||||
SEE_try_context_t try_ctxt;
|
SEE_try_context_t try_ctxt;
|
||||||
struct SEE_value result;
|
struct SEE_value result;
|
||||||
/* 'volatile' qualifier prevents register allocation which fixes:
|
/* 'volatile' qualifier prevents register allocation which fixes:
|
||||||
@ -138,7 +138,7 @@ see_eval_stringback(struct ecmascript_interpreter *interpreter,
|
|||||||
SEE_TRY(interp, try_ctxt) {
|
SEE_TRY(interp, try_ctxt) {
|
||||||
SEE_Global_eval(interp, input, &result);
|
SEE_Global_eval(interp, input, &result);
|
||||||
if (SEE_VALUE_GET_TYPE(&result) == SEE_STRING)
|
if (SEE_VALUE_GET_TYPE(&result) == SEE_STRING)
|
||||||
string = SEE_value_to_unsigned_char(interp, &result);
|
string = see_value_to_unsigned_char(interp, &result);
|
||||||
|
|
||||||
}
|
}
|
||||||
SEE_INPUT_CLOSE(input);
|
SEE_INPUT_CLOSE(input);
|
||||||
@ -154,7 +154,7 @@ see_eval_boolback(struct ecmascript_interpreter *interpreter,
|
|||||||
{
|
{
|
||||||
struct SEE_interpreter *interp = interpreter->backend_data;
|
struct SEE_interpreter *interp = interpreter->backend_data;
|
||||||
struct global_object *g = (struct global_object *)interp;
|
struct global_object *g = (struct global_object *)interp;
|
||||||
struct SEE_input *input = SEE_input_elinks(interp, code->source);
|
struct SEE_input *input = see_input_elinks(interp, code->source);
|
||||||
SEE_try_context_t try_ctxt;
|
SEE_try_context_t try_ctxt;
|
||||||
struct SEE_value result;
|
struct SEE_value result;
|
||||||
/* 'volatile' qualifier prevents register allocation which fixes:
|
/* 'volatile' qualifier prevents register allocation which fixes:
|
||||||
|
@ -145,7 +145,7 @@ document_get(struct SEE_interpreter *interp, struct SEE_object *o,
|
|||||||
SEE_SET_OBJECT(res, doc->writeln);
|
SEE_SET_OBJECT(res, doc->writeln);
|
||||||
} else {
|
} else {
|
||||||
struct form *form;
|
struct form *form;
|
||||||
unsigned char *string = SEE_string_to_unsigned_char(p);
|
unsigned char *string = see_string_to_unsigned_char(p);
|
||||||
struct form_view *form_view;
|
struct form_view *form_view;
|
||||||
struct js_form *form_object;
|
struct js_form *form_object;
|
||||||
|
|
||||||
@ -179,7 +179,7 @@ document_put(struct SEE_interpreter *interp, struct SEE_object *o,
|
|||||||
SEE_ToObject(interp, val, &res);
|
SEE_ToObject(interp, val, &res);
|
||||||
doc->forms = res.u.object;
|
doc->forms = res.u.object;
|
||||||
} else if (p == s_title) {
|
} else if (p == s_title) {
|
||||||
string = SEE_value_to_unsigned_char(interp, val);
|
string = see_value_to_unsigned_char(interp, val);
|
||||||
mem_free_set(&document->title, string);
|
mem_free_set(&document->title, string);
|
||||||
print_screen_status(doc_view->session);
|
print_screen_status(doc_view->session);
|
||||||
} else if (p == s_location || p == s_url) {
|
} else if (p == s_location || p == s_url) {
|
||||||
@ -187,12 +187,12 @@ document_put(struct SEE_interpreter *interp, struct SEE_object *o,
|
|||||||
* broken sites still assign to it (i.e.
|
* broken sites still assign to it (i.e.
|
||||||
* http://www.e-handelsfonden.dk/validering.asp?URL=www.polyteknisk.dk).
|
* http://www.e-handelsfonden.dk/validering.asp?URL=www.polyteknisk.dk).
|
||||||
* So emulate window.location. */
|
* So emulate window.location. */
|
||||||
string = SEE_value_to_unsigned_char(interp, val);
|
string = see_value_to_unsigned_char(interp, val);
|
||||||
location_goto(doc_view, string);
|
location_goto(doc_view, string);
|
||||||
mem_free_if(string);
|
mem_free_if(string);
|
||||||
} else if (p == s_cookie) {
|
} else if (p == s_cookie) {
|
||||||
#ifdef CONFIG_COOKIES
|
#ifdef CONFIG_COOKIES
|
||||||
string = SEE_value_to_unsigned_char(interp, val);
|
string = see_value_to_unsigned_char(interp, val);
|
||||||
set_cookie(vs->uri, string);
|
set_cookie(vs->uri, string);
|
||||||
mem_free_if(string);
|
mem_free_if(string);
|
||||||
#endif
|
#endif
|
||||||
@ -218,7 +218,7 @@ js_document_write_do(struct SEE_interpreter *interp, struct SEE_object *self,
|
|||||||
for (; i < argc; ++i) {
|
for (; i < argc; ++i) {
|
||||||
unsigned char *code;
|
unsigned char *code;
|
||||||
|
|
||||||
code = SEE_value_to_unsigned_char(interp, argv[i]);
|
code = see_value_to_unsigned_char(interp, argv[i]);
|
||||||
|
|
||||||
if (code) {
|
if (code) {
|
||||||
add_to_string(ret, code);
|
add_to_string(ret, code);
|
||||||
|
@ -299,14 +299,14 @@ input_put(struct SEE_interpreter *interp, struct SEE_object *o,
|
|||||||
|
|
||||||
SEE_ToString(interp, val, &conv);
|
SEE_ToString(interp, val, &conv);
|
||||||
if (conv.u.string->length)
|
if (conv.u.string->length)
|
||||||
accesskey = SEE_string_to_unicode(interp, conv.u.string);
|
accesskey = see_string_to_unicode(interp, conv.u.string);
|
||||||
else
|
else
|
||||||
accesskey = 0;
|
accesskey = 0;
|
||||||
|
|
||||||
if (link)
|
if (link)
|
||||||
link->accesskey = accesskey;
|
link->accesskey = accesskey;
|
||||||
} else if (p == s_alt) {
|
} else if (p == s_alt) {
|
||||||
string = SEE_value_to_unsigned_char(interp, val);
|
string = see_value_to_unsigned_char(interp, val);
|
||||||
mem_free_set(&fc->alt, string);
|
mem_free_set(&fc->alt, string);
|
||||||
} else if (p == s_checked) {
|
} else if (p == s_checked) {
|
||||||
if (fc->type != FC_CHECKBOX && fc->type != FC_RADIO)
|
if (fc->type != FC_CHECKBOX && fc->type != FC_RADIO)
|
||||||
@ -319,13 +319,13 @@ input_put(struct SEE_interpreter *interp, struct SEE_object *o,
|
|||||||
: (fc->mode == FORM_MODE_READONLY ? FORM_MODE_READONLY
|
: (fc->mode == FORM_MODE_READONLY ? FORM_MODE_READONLY
|
||||||
: FORM_MODE_NORMAL));
|
: FORM_MODE_NORMAL));
|
||||||
} else if (p == s_maxLength) {
|
} else if (p == s_maxLength) {
|
||||||
string = SEE_value_to_unsigned_char(interp, val);
|
string = see_value_to_unsigned_char(interp, val);
|
||||||
if (!string)
|
if (!string)
|
||||||
return;
|
return;
|
||||||
fc->maxlength = atol(string);
|
fc->maxlength = atol(string);
|
||||||
mem_free(string);
|
mem_free(string);
|
||||||
} else if (p == s_name) {
|
} else if (p == s_name) {
|
||||||
string = SEE_value_to_unsigned_char(interp, val);
|
string = see_value_to_unsigned_char(interp, val);
|
||||||
mem_free_set(&fc->name, string);
|
mem_free_set(&fc->name, string);
|
||||||
} else if (p == s_readonly) {
|
} else if (p == s_readonly) {
|
||||||
SEE_uint32_t boo = SEE_ToUint32(interp, val);
|
SEE_uint32_t boo = SEE_ToUint32(interp, val);
|
||||||
@ -334,13 +334,13 @@ input_put(struct SEE_interpreter *interp, struct SEE_object *o,
|
|||||||
: FORM_MODE_NORMAL);
|
: FORM_MODE_NORMAL);
|
||||||
} else if (p == s_src) {
|
} else if (p == s_src) {
|
||||||
if (link) {
|
if (link) {
|
||||||
string = SEE_value_to_unsigned_char(interp, val);
|
string = see_value_to_unsigned_char(interp, val);
|
||||||
mem_free_set(&link->where_img, string);
|
mem_free_set(&link->where_img, string);
|
||||||
}
|
}
|
||||||
} else if (p == s_value) {
|
} else if (p == s_value) {
|
||||||
if (fc->type == FC_FILE)
|
if (fc->type == FC_FILE)
|
||||||
return;
|
return;
|
||||||
string = SEE_value_to_unsigned_char(interp, val);
|
string = see_value_to_unsigned_char(interp, val);
|
||||||
mem_free_set(&fs->value, string);
|
mem_free_set(&fs->value, string);
|
||||||
if (fc->type == FC_TEXT || fc->type == FC_PASSWORD)
|
if (fc->type == FC_TEXT || fc->type == FC_PASSWORD)
|
||||||
fs->state = strlen(fs->value);
|
fs->state = strlen(fs->value);
|
||||||
@ -541,7 +541,7 @@ js_form_elems_item(struct SEE_interpreter *interp, struct SEE_object *self,
|
|||||||
SEE_SET_UNDEFINED(res);
|
SEE_SET_UNDEFINED(res);
|
||||||
if (argc < 1)
|
if (argc < 1)
|
||||||
return;
|
return;
|
||||||
string = SEE_value_to_unsigned_char(interp, argv[0]);
|
string = see_value_to_unsigned_char(interp, argv[0]);
|
||||||
if (!string)
|
if (!string)
|
||||||
return;
|
return;
|
||||||
index = atol(string);
|
index = atol(string);
|
||||||
@ -585,7 +585,7 @@ js_form_elems_namedItem(struct SEE_interpreter *interp, struct SEE_object *self,
|
|||||||
SEE_SET_UNDEFINED(res);
|
SEE_SET_UNDEFINED(res);
|
||||||
if (argc < 1)
|
if (argc < 1)
|
||||||
return;
|
return;
|
||||||
string = SEE_value_to_unsigned_char(interp, argv[0]);
|
string = see_value_to_unsigned_char(interp, argv[0]);
|
||||||
if (!string)
|
if (!string)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
@ -626,7 +626,7 @@ form_elems_get(struct SEE_interpreter *interp, struct SEE_object *o,
|
|||||||
} else if (p == s_namedItem) {
|
} else if (p == s_namedItem) {
|
||||||
SEE_SET_OBJECT(res, jsfe->namedItem);
|
SEE_SET_OBJECT(res, jsfe->namedItem);
|
||||||
} else {
|
} else {
|
||||||
unsigned char *string = SEE_string_to_unsigned_char(p);
|
unsigned char *string = see_string_to_unsigned_char(p);
|
||||||
struct SEE_value arg0;
|
struct SEE_value arg0;
|
||||||
struct SEE_value *argv[1] = { &arg0 };
|
struct SEE_value *argv[1] = { &arg0 };
|
||||||
|
|
||||||
@ -675,7 +675,7 @@ js_forms_item(struct SEE_interpreter *interp, struct SEE_object *self,
|
|||||||
if (argc < 1)
|
if (argc < 1)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
string = SEE_value_to_unsigned_char(interp, argv[0]);
|
string = see_value_to_unsigned_char(interp, argv[0]);
|
||||||
if (!string)
|
if (!string)
|
||||||
return;
|
return;
|
||||||
index = atol(string);
|
index = atol(string);
|
||||||
@ -712,7 +712,7 @@ js_forms_namedItem(struct SEE_interpreter *interp, struct SEE_object *self,
|
|||||||
if (argc < 1)
|
if (argc < 1)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
string = SEE_value_to_unsigned_char(interp, argv[0]);
|
string = see_value_to_unsigned_char(interp, argv[0]);
|
||||||
if (!string)
|
if (!string)
|
||||||
return;
|
return;
|
||||||
foreach (form, document->forms) {
|
foreach (form, document->forms) {
|
||||||
@ -747,7 +747,7 @@ forms_get(struct SEE_interpreter *interp, struct SEE_object *o,
|
|||||||
} else if (p == s_namedItem) {
|
} else if (p == s_namedItem) {
|
||||||
SEE_SET_OBJECT(res, fo->namedItem);
|
SEE_SET_OBJECT(res, fo->namedItem);
|
||||||
} else {
|
} else {
|
||||||
unsigned char *string = SEE_string_to_unsigned_char(p);
|
unsigned char *string = see_string_to_unsigned_char(p);
|
||||||
struct SEE_value arg0;
|
struct SEE_value arg0;
|
||||||
struct SEE_value *argv[1] = { &arg0 };
|
struct SEE_value *argv[1] = { &arg0 };
|
||||||
|
|
||||||
@ -843,7 +843,7 @@ form_get(struct SEE_interpreter *interp, struct SEE_object *o,
|
|||||||
} else if (p == s_reset) {
|
} else if (p == s_reset) {
|
||||||
SEE_SET_OBJECT(res, js_form->reset);
|
SEE_SET_OBJECT(res, js_form->reset);
|
||||||
} else {
|
} else {
|
||||||
unsigned char *string = SEE_string_to_unsigned_char(p);
|
unsigned char *string = see_string_to_unsigned_char(p);
|
||||||
struct form_control *fc;
|
struct form_control *fc;
|
||||||
|
|
||||||
if (!string)
|
if (!string)
|
||||||
@ -878,7 +878,7 @@ form_put(struct SEE_interpreter *interp, struct SEE_object *o,
|
|||||||
struct js_form *js_form = (struct js_form *)o;
|
struct js_form *js_form = (struct js_form *)o;
|
||||||
struct form_view *fv = js_form->fv;
|
struct form_view *fv = js_form->fv;
|
||||||
struct form *form = find_form_by_form_view(doc_view->document, fv);
|
struct form *form = find_form_by_form_view(doc_view->document, fv);
|
||||||
unsigned char *string = SEE_value_to_unsigned_char(interp, val);
|
unsigned char *string = see_value_to_unsigned_char(interp, val);
|
||||||
|
|
||||||
if (!string)
|
if (!string)
|
||||||
return;
|
return;
|
||||||
|
@ -49,7 +49,7 @@ input_elinks_close(struct SEE_input *inp)
|
|||||||
}
|
}
|
||||||
|
|
||||||
struct SEE_input *
|
struct SEE_input *
|
||||||
SEE_input_elinks(struct SEE_interpreter *interp, unsigned char *s)
|
see_input_elinks(struct SEE_interpreter *interp, unsigned char *s)
|
||||||
{
|
{
|
||||||
struct input_elinks *input;
|
struct input_elinks *input;
|
||||||
|
|
||||||
@ -64,7 +64,7 @@ SEE_input_elinks(struct SEE_interpreter *interp, unsigned char *s)
|
|||||||
}
|
}
|
||||||
|
|
||||||
unsigned char *
|
unsigned char *
|
||||||
SEE_string_to_unsigned_char(struct SEE_string *S)
|
see_string_to_unsigned_char(struct SEE_string *S)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
unsigned char *str = mem_alloc(S->length + 1);
|
unsigned char *str = mem_alloc(S->length + 1);
|
||||||
@ -79,12 +79,12 @@ SEE_string_to_unsigned_char(struct SEE_string *S)
|
|||||||
}
|
}
|
||||||
|
|
||||||
unsigned char *
|
unsigned char *
|
||||||
SEE_value_to_unsigned_char(struct SEE_interpreter *interp, struct SEE_value *val)
|
see_value_to_unsigned_char(struct SEE_interpreter *interp, struct SEE_value *val)
|
||||||
{
|
{
|
||||||
struct SEE_value result;
|
struct SEE_value result;
|
||||||
|
|
||||||
SEE_ToString(interp, val, &result);
|
SEE_ToString(interp, val, &result);
|
||||||
return SEE_string_to_unsigned_char(result.u.string);
|
return see_string_to_unsigned_char(result.u.string);
|
||||||
}
|
}
|
||||||
|
|
||||||
struct SEE_string *
|
struct SEE_string *
|
||||||
@ -127,7 +127,7 @@ append_unicode_to_SEE_string(struct SEE_interpreter *interp,
|
|||||||
}
|
}
|
||||||
|
|
||||||
unicode_val_T
|
unicode_val_T
|
||||||
SEE_string_to_unicode(struct SEE_interpreter *interp, struct SEE_string *S)
|
see_string_to_unicode(struct SEE_interpreter *interp, struct SEE_string *S)
|
||||||
{
|
{
|
||||||
/* This implementation ignores extra characters in the string. */
|
/* This implementation ignores extra characters in the string. */
|
||||||
if (S->length < 1) {
|
if (S->length < 1) {
|
||||||
|
@ -7,12 +7,12 @@ struct SEE_interpreter;
|
|||||||
struct SEE_string;
|
struct SEE_string;
|
||||||
struct SEE_value;
|
struct SEE_value;
|
||||||
|
|
||||||
struct SEE_input *SEE_input_elinks(struct SEE_interpreter *, unsigned char *);
|
struct SEE_input *see_input_elinks(struct SEE_interpreter *, unsigned char *);
|
||||||
unsigned char *SEE_string_to_unsigned_char(struct SEE_string *);
|
unsigned char *see_string_to_unsigned_char(struct SEE_string *);
|
||||||
unsigned char *SEE_value_to_unsigned_char(struct SEE_interpreter *, struct SEE_value *);
|
unsigned char *see_value_to_unsigned_char(struct SEE_interpreter *, struct SEE_value *);
|
||||||
struct SEE_string *string_to_SEE_string(struct SEE_interpreter *, unsigned char *);
|
struct SEE_string *string_to_SEE_string(struct SEE_interpreter *, unsigned char *);
|
||||||
void append_unicode_to_SEE_string(struct SEE_interpreter *, struct SEE_string *,
|
void append_unicode_to_SEE_string(struct SEE_interpreter *, struct SEE_string *,
|
||||||
unicode_val_T);
|
unicode_val_T);
|
||||||
unicode_val_T SEE_string_to_unicode(struct SEE_interpreter *, struct SEE_string *);
|
unicode_val_T see_string_to_unicode(struct SEE_interpreter *, struct SEE_string *);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -232,7 +232,7 @@ js_history_go(struct SEE_interpreter *interp, struct SEE_object *self,
|
|||||||
if (argc < 1)
|
if (argc < 1)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
str = SEE_value_to_unsigned_char(interp, argv[0]);
|
str = see_value_to_unsigned_char(interp, argv[0]);
|
||||||
if (!str)
|
if (!str)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
@ -297,7 +297,7 @@ location_put(struct SEE_interpreter *interp, struct SEE_object *o,
|
|||||||
struct global_object *g = (struct global_object *)interp;
|
struct global_object *g = (struct global_object *)interp;
|
||||||
struct view_state *vs = g->win->vs;
|
struct view_state *vs = g->win->vs;
|
||||||
struct document_view *doc_view = vs->doc_view;
|
struct document_view *doc_view = vs->doc_view;
|
||||||
unsigned char *url = SEE_value_to_unsigned_char(interp, val);
|
unsigned char *url = see_value_to_unsigned_char(interp, val);
|
||||||
|
|
||||||
location_goto(doc_view, url);
|
location_goto(doc_view, url);
|
||||||
mem_free(url);
|
mem_free(url);
|
||||||
|
@ -143,7 +143,7 @@ window_get(struct SEE_interpreter *interp, struct SEE_object *o,
|
|||||||
} else if (p == s_navigator) {
|
} else if (p == s_navigator) {
|
||||||
SEE_OBJECT_GET(interp, interp->Global, s_navigator, res);
|
SEE_OBJECT_GET(interp, interp->Global, s_navigator, res);
|
||||||
} else {
|
} else {
|
||||||
unsigned char *frame = SEE_string_to_unsigned_char(p);
|
unsigned char *frame = see_string_to_unsigned_char(p);
|
||||||
struct document_view *doc_view = vs->doc_view;
|
struct document_view *doc_view = vs->doc_view;
|
||||||
struct js_window_object *obj;
|
struct js_window_object *obj;
|
||||||
|
|
||||||
@ -164,7 +164,7 @@ window_put(struct SEE_interpreter *interp, struct SEE_object *o,
|
|||||||
struct js_window_object *win = (struct js_window_object *)o;
|
struct js_window_object *win = (struct js_window_object *)o;
|
||||||
struct view_state *vs = win->vs;
|
struct view_state *vs = win->vs;
|
||||||
struct document_view *doc_view = vs->doc_view;
|
struct document_view *doc_view = vs->doc_view;
|
||||||
unsigned char *str = SEE_value_to_unsigned_char(interp, val);
|
unsigned char *str = see_value_to_unsigned_char(interp, val);
|
||||||
|
|
||||||
if (str) {
|
if (str) {
|
||||||
location_goto(doc_view, str);
|
location_goto(doc_view, str);
|
||||||
@ -176,7 +176,7 @@ window_put(struct SEE_interpreter *interp, struct SEE_object *o,
|
|||||||
struct view_state *vs = win->vs;
|
struct view_state *vs = win->vs;
|
||||||
struct document_view *doc_view = vs->doc_view;
|
struct document_view *doc_view = vs->doc_view;
|
||||||
struct session *ses = doc_view->session;
|
struct session *ses = doc_view->session;
|
||||||
unsigned char *stat = SEE_value_to_unsigned_char(interp, val);
|
unsigned char *stat = see_value_to_unsigned_char(interp, val);
|
||||||
|
|
||||||
mem_free_set(&ses->status.window_status, stat);
|
mem_free_set(&ses->status.window_status, stat);
|
||||||
print_screen_status(ses);
|
print_screen_status(ses);
|
||||||
@ -217,7 +217,7 @@ js_window_alert(struct SEE_interpreter *interp, struct SEE_object *self,
|
|||||||
if (argc < 1)
|
if (argc < 1)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
string = SEE_value_to_unsigned_char(interp, argv[0]);
|
string = see_value_to_unsigned_char(interp, argv[0]);
|
||||||
if (!string || !*string) {
|
if (!string || !*string) {
|
||||||
mem_free_if(string);
|
mem_free_if(string);
|
||||||
return;
|
return;
|
||||||
@ -274,14 +274,14 @@ js_window_open(struct SEE_interpreter *interp, struct SEE_object *self,
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
SEE_ToString(interp, argv[0], &url_value);
|
SEE_ToString(interp, argv[0], &url_value);
|
||||||
url = SEE_string_to_unsigned_char(url_value.u.string);
|
url = see_string_to_unsigned_char(url_value.u.string);
|
||||||
if (!url) return;
|
if (!url) return;
|
||||||
trim_chars(url, ' ', 0);
|
trim_chars(url, ' ', 0);
|
||||||
if (argc > 1) {
|
if (argc > 1) {
|
||||||
struct SEE_value target_value;
|
struct SEE_value target_value;
|
||||||
|
|
||||||
SEE_ToString(interp, argv[1], &target_value);
|
SEE_ToString(interp, argv[1], &target_value);
|
||||||
frame = SEE_string_to_unsigned_char(target_value.u.string);
|
frame = see_string_to_unsigned_char(target_value.u.string);
|
||||||
if (!frame) {
|
if (!frame) {
|
||||||
mem_free(url);
|
mem_free(url);
|
||||||
return;
|
return;
|
||||||
@ -345,7 +345,7 @@ js_setTimeout(struct SEE_interpreter *interp, struct SEE_object *self,
|
|||||||
|
|
||||||
if (argc != 2) return;
|
if (argc != 2) return;
|
||||||
ei = ((struct global_object *)interp)->interpreter;
|
ei = ((struct global_object *)interp)->interpreter;
|
||||||
code = SEE_value_to_unsigned_char(interp, argv[0]);
|
code = see_value_to_unsigned_char(interp, argv[0]);
|
||||||
timeout = SEE_ToInt32(interp, argv[1]);
|
timeout = SEE_ToInt32(interp, argv[1]);
|
||||||
ecmascript_set_timeout(ei, code, timeout);
|
ecmascript_set_timeout(ei, code, timeout);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user