From 8681af34d4eec396696931745684a663134bc700 Mon Sep 17 00:00:00 2001 From: Nathan Moinvaziri Date: Tue, 24 Dec 2024 13:21:23 -0800 Subject: [PATCH] Remove unused JSCore4GTK functions. --- execute_jscore4.c | 28 +--------------------------- 1 file changed, 1 insertion(+), 27 deletions(-) diff --git a/execute_jscore4.c b/execute_jscore4.c index 367c941..c4f254b 100644 --- a/execute_jscore4.c +++ b/execute_jscore4.c @@ -21,16 +21,11 @@ #include "util.h" typedef struct g_proxy_execute_jscore4_s { - // Jscore4GTK module + // JSCore4GTK module void *module; - // Class functions - JSClassRef (*JSClassCreate)(const JSClassDefinition *class_def); // Object functions - JSObjectRef (*JSObjectMake)(JSContextRef ctx, JSClassRef cls, void *Data); JSObjectRef (*JSObjectMakeFunctionWithCallback)(JSContextRef ctx, JSStringRef name, JSObjectCallAsFunctionCallback callback); - void *(*JSObjectGetPrivate)(JSObjectRef object); - bool (*JSObjectSetPrivate)(JSObjectRef object, void *data); void (*JSObjectSetProperty)(JSContextRef context, JSObjectRef object, JSStringRef name, JSValueRef value, JSPropertyAttributes attribs, JSValueRef *exception); JSValueRef (*JSObjectGetProperty)(JSContextRef ctx, JSObjectRef object, JSStringRef name, JSValueRef *exception); @@ -42,8 +37,6 @@ typedef struct g_proxy_execute_jscore4_s { JSObjectRef (*JSValueToObject)(JSContextRef ctx, JSValueRef value, JSValueRef *exception); JSStringRef (*JSValueToStringCopy)(JSContextRef ctx, JSValueRef value, JSValueRef *exception); double (*JSValueToNumber)(JSContextRef ctx, JSValueRef value, JSValueRef *exception); - JSValueRef (*JSValueMakeNull)(JSContextRef ctx); - JSValueRef (*JSValueMakeBoolean)(JSContextRef ctx, bool value); JSValueRef (*JSValueMakeString)(JSContextRef ctx, JSStringRef str); // String functions JSStringRef (*JSStringCreateWithUTF8CString)(const char *str); @@ -391,14 +384,7 @@ void proxy_execute_jscore4_delayed_init(void) { if (!g_proxy_execute_jscore4.module) return; - // Class functions - g_proxy_execute_jscore4.JSClassCreate = dlsym(g_proxy_execute_jscore4.module, "JSClassCreate"); - if (!g_proxy_execute_jscore4.JSClassCreate) - goto jscore4_init_error; // Object functions - g_proxy_execute_jscore4.JSObjectMake = dlsym(g_proxy_execute_jscore4.module, "JSObjectMake"); - if (!g_proxy_execute_jscore4.JSObjectMake) - goto jscore4_init_error; g_proxy_execute_jscore4.JSObjectMakeFunctionWithCallback = dlsym(g_proxy_execute_jscore4.module, "JSObjectMakeFunctionWithCallback"); if (!g_proxy_execute_jscore4.JSObjectMakeFunctionWithCallback) @@ -409,12 +395,6 @@ void proxy_execute_jscore4_delayed_init(void) { g_proxy_execute_jscore4.JSObjectSetProperty = dlsym(g_proxy_execute_jscore4.module, "JSObjectSetProperty"); if (!g_proxy_execute_jscore4.JSObjectSetProperty) goto jscore4_init_error; - g_proxy_execute_jscore4.JSObjectGetPrivate = dlsym(g_proxy_execute_jscore4.module, "JSObjectGetPrivate"); - if (!g_proxy_execute_jscore4.JSObjectGetPrivate) - goto jscore4_init_error; - g_proxy_execute_jscore4.JSObjectSetPrivate = dlsym(g_proxy_execute_jscore4.module, "JSObjectSetPrivate"); - if (!g_proxy_execute_jscore4.JSObjectSetPrivate) - goto jscore4_init_error; // Context functions g_proxy_execute_jscore4.JSContextGetGlobalObject = dlsym(g_proxy_execute_jscore4.module, "JSContextGetGlobalObject"); @@ -436,12 +416,6 @@ void proxy_execute_jscore4_delayed_init(void) { g_proxy_execute_jscore4.JSValueToNumber = dlsym(g_proxy_execute_jscore4.module, "JSValueToNumber"); if (!g_proxy_execute_jscore4.JSValueToNumber) goto jscore4_init_error; - g_proxy_execute_jscore4.JSValueMakeNull = dlsym(g_proxy_execute_jscore4.module, "JSValueMakeNull"); - if (!g_proxy_execute_jscore4.JSValueMakeNull) - goto jscore4_init_error; - g_proxy_execute_jscore4.JSValueMakeBoolean = dlsym(g_proxy_execute_jscore4.module, "JSValueMakeBoolean"); - if (!g_proxy_execute_jscore4.JSValueMakeBoolean) - goto jscore4_init_error; g_proxy_execute_jscore4.JSValueMakeString = dlsym(g_proxy_execute_jscore4.module, "JSValueMakeString"); if (!g_proxy_execute_jscore4.JSValueMakeString) goto jscore4_init_error;