WebKitDOMTestObj* webkit_dom_test_interface_supplemental_method2(WebKitDOMTestInterface* self, const gchar* str_arg, WebKitDOMTestObj* obj_arg, GError **error) { #if ENABLE(Condition11) || ENABLE(Condition12) g_return_val_if_fail(self, 0); WebCore::JSMainThreadNullState state; WebCore::TestInterface * item = WebKit::core(self); g_return_val_if_fail(str_arg, 0); g_return_val_if_fail(obj_arg, 0); WTF::String converted_str_arg = WTF::String::fromUTF8(str_arg); WebCore::TestObj * converted_obj_arg = NULL; if (obj_arg != NULL) { converted_obj_arg = WebKit::core(obj_arg); g_return_val_if_fail(converted_obj_arg, 0); } WebCore::ExceptionCode ec = 0; PassRefPtr<WebCore::TestObj> g_res = WTF::getPtr(WebCore::TestSupplemental::supplementalMethod2(item, converted_str_arg, converted_obj_arg, ec)); if (ec) { WebCore::ExceptionCodeDescription ecdesc(ec); g_set_error_literal(error, g_quark_from_string("WEBKIT_DOM"), ecdesc.code, ecdesc.name); } WebKitDOMTestObj* res = WebKit::kit(g_res.get()); return res; #else return NULL; #endif /* ENABLE(Condition11) || ENABLE(Condition12) */ }
gboolean webkit_dom_test_event_target_dispatch_event(WebKitDOMTestEventTarget* self, WebKitDOMEvent* evt, GError** error) { WebCore::JSMainThreadNullState state; g_return_val_if_fail(WEBKIT_DOM_IS_TEST_EVENT_TARGET(self), FALSE); g_return_val_if_fail(WEBKIT_DOM_IS_EVENT(evt), FALSE); g_return_val_if_fail(!error || !*error, FALSE); WebCore::TestEventTarget* item = WebKit::core(self); WebCore::Event* convertedEvt = WebKit::core(evt); WebCore::ExceptionCode ec = 0; gboolean result = item->dispatchEvent(convertedEvt, ec); if (ec) { WebCore::ExceptionCodeDescription ecdesc(ec); g_set_error_literal(error, g_quark_from_string("WEBKIT_DOM"), ecdesc.code, ecdesc.name); } return result; }