ELinks 0.18.0
keyboard.c File Reference
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "elinks.h"
#include "js/libdom/dom.h"
#include "document/libdom/corestrings.h"
#include "document/libdom/doc.h"
#include "js/ecmascript.h"
#include "js/quickjs.h"
#include "js/quickjs/element.h"
#include "js/quickjs/keyboard.h"
#include "js/quickjs/node.h"
#include "intl/charsets.h"
#include "terminal/event.h"
Include dependency graph for keyboard.c:

Macros

#define countof(x)

Functions

static JSValue js_keyboardEvent_get_property_code (JSContext *ctx, JSValueConst this_val)
static JSValue js_keyboardEvent_get_property_key (JSContext *ctx, JSValueConst this_val)
static JSValue js_keyboardEvent_get_property_keyCode (JSContext *ctx, JSValueConst this_val)
static JSValue js_keyboardEvent_get_property_bubbles (JSContext *ctx, JSValueConst this_val)
static JSValue js_keyboardEvent_get_property_cancelable (JSContext *ctx, JSValueConst this_val)
static JSValue js_keyboardEvent_get_property_defaultPrevented (JSContext *ctx, JSValueConst this_val)
static JSValue js_keyboardEvent_get_property_target (JSContext *ctx, JSValueConst this_val)
static JSValue js_keyboardEvent_get_property_type (JSContext *ctx, JSValueConst this_val)
static JSValue js_keyboardEvent_preventDefault (JSContext *ctx, JSValueConst this_val, int argc, JSValueConst *argv)
static void js_keyboardEvent_finalizer (JSRuntime *rt, JSValue val)
JSValue get_keyboardEvent (JSContext *ctx, struct term_event *ev)
static JSValue js_keyboardEvent_constructor (JSContext *ctx, JSValueConst new_target, int argc, JSValueConst *argv)
static void JS_NewGlobalCConstructor2 (JSContext *ctx, JSValue func_obj, const char *name, JSValueConst proto)
static JSValueConst JS_NewGlobalCConstructor (JSContext *ctx, const char *name, JSCFunction *func, int length, JSValueConst proto)
int js_keyboardEvent_init (JSContext *ctx)

Variables

static JSClassID js_keyboardEvent_class_id
static JSClassDef js_keyboardEvent_class
static const JSCFunctionListEntry js_keyboardEvent_proto_funcs []

Macro Definition Documentation

◆ countof

#define countof ( x)
Value:
(sizeof(x) / sizeof((x)[0]))

Function Documentation

◆ get_keyboardEvent()

JSValue get_keyboardEvent ( JSContext * ctx,
struct term_event * ev )

◆ js_keyboardEvent_constructor()

JSValue js_keyboardEvent_constructor ( JSContext * ctx,
JSValueConst new_target,
int argc,
JSValueConst * argv )
static

◆ js_keyboardEvent_finalizer()

void js_keyboardEvent_finalizer ( JSRuntime * rt,
JSValue val )
static

◆ js_keyboardEvent_get_property_bubbles()

JSValue js_keyboardEvent_get_property_bubbles ( JSContext * ctx,
JSValueConst this_val )
static

◆ js_keyboardEvent_get_property_cancelable()

JSValue js_keyboardEvent_get_property_cancelable ( JSContext * ctx,
JSValueConst this_val )
static

◆ js_keyboardEvent_get_property_code()

JSValue js_keyboardEvent_get_property_code ( JSContext * ctx,
JSValueConst this_val )
static

◆ js_keyboardEvent_get_property_defaultPrevented()

JSValue js_keyboardEvent_get_property_defaultPrevented ( JSContext * ctx,
JSValueConst this_val )
static

◆ js_keyboardEvent_get_property_key()

JSValue js_keyboardEvent_get_property_key ( JSContext * ctx,
JSValueConst this_val )
static

◆ js_keyboardEvent_get_property_keyCode()

JSValue js_keyboardEvent_get_property_keyCode ( JSContext * ctx,
JSValueConst this_val )
static

◆ js_keyboardEvent_get_property_target()

JSValue js_keyboardEvent_get_property_target ( JSContext * ctx,
JSValueConst this_val )
static

◆ js_keyboardEvent_get_property_type()

JSValue js_keyboardEvent_get_property_type ( JSContext * ctx,
JSValueConst this_val )
static

◆ js_keyboardEvent_init()

int js_keyboardEvent_init ( JSContext * ctx)

◆ js_keyboardEvent_preventDefault()

JSValue js_keyboardEvent_preventDefault ( JSContext * ctx,
JSValueConst this_val,
int argc,
JSValueConst * argv )
static

◆ JS_NewGlobalCConstructor()

JSValueConst JS_NewGlobalCConstructor ( JSContext * ctx,
const char * name,
JSCFunction * func,
int length,
JSValueConst proto )
static

◆ JS_NewGlobalCConstructor2()

void JS_NewGlobalCConstructor2 ( JSContext * ctx,
JSValue func_obj,
const char * name,
JSValueConst proto )
static

Variable Documentation

◆ js_keyboardEvent_class

JSClassDef js_keyboardEvent_class
static
Initial value:
= {
"KeyboardEvent",
}
static void js_keyboardEvent_finalizer(JSRuntime *rt, JSValue val)
Definition keyboard.c:43

◆ js_keyboardEvent_class_id

JSClassID js_keyboardEvent_class_id
static

◆ js_keyboardEvent_proto_funcs

const JSCFunctionListEntry js_keyboardEvent_proto_funcs[]
static
Initial value:
= {
JS_CGETSET_DEF("bubbles", js_keyboardEvent_get_property_bubbles, NULL),
JS_CGETSET_DEF("cancelable", js_keyboardEvent_get_property_cancelable, NULL),
JS_CGETSET_DEF("code", js_keyboardEvent_get_property_code, NULL),
JS_CGETSET_DEF("defaultPrevented", js_keyboardEvent_get_property_defaultPrevented, NULL),
JS_CGETSET_DEF("key", js_keyboardEvent_get_property_key, NULL),
JS_CGETSET_DEF("keyCode", js_keyboardEvent_get_property_keyCode, NULL),
JS_CGETSET_DEF("target", js_keyboardEvent_get_property_target, NULL),
JS_CGETSET_DEF("type", js_keyboardEvent_get_property_type, NULL),
}
#define NULL
Definition explodename.c:35
static JSValue js_keyboardEvent_get_property_bubbles(JSContext *ctx, JSValueConst this_val)
Definition keyboard.c:73
static JSValue js_keyboardEvent_get_property_target(JSContext *ctx, JSValueConst this_val)
Definition keyboard.c:239
static JSValue js_keyboardEvent_get_property_cancelable(JSContext *ctx, JSValueConst this_val)
Definition keyboard.c:94
static JSValue js_keyboardEvent_get_property_code(JSContext *ctx, JSValueConst this_val)
Definition keyboard.c:211
static JSValue js_keyboardEvent_get_property_key(JSContext *ctx, JSValueConst this_val)
Definition keyboard.c:156
static JSValue js_keyboardEvent_get_property_type(JSContext *ctx, JSValueConst this_val)
Definition keyboard.c:270
static JSValue js_keyboardEvent_get_property_keyCode(JSContext *ctx, JSValueConst this_val)
Definition keyboard.c:183
static JSValue js_keyboardEvent_get_property_defaultPrevented(JSContext *ctx, JSValueConst this_val)
Definition keyboard.c:134