7 #include <smoke/qtwebkit_smoke.h>
13 static VALUE
getClassList(VALUE
/*self*/)
15 VALUE classList
= rb_ary_new();
16 for (int i
= 1; i
< qtwebkit_Smoke
->numClasses
; i
++) {
17 if (qtwebkit_Smoke
->classes
[i
].className
&& !qtwebkit_Smoke
->classes
[i
].external
)
18 rb_ary_push(classList
, rb_str_new2(qtwebkit_Smoke
->classes
[i
].className
));
24 resolve_classname_qtwebkit(smokeruby_object
* o
)
26 return o
->smoke
->binding
->className(o
->classId
);
29 extern TypeHandler QtWebKit_handlers
[];
33 VALUE qtwebkit_module
;
34 VALUE qtwebkit_internal_module
;
39 init_qtwebkit_Smoke();
41 qtwebkit_Smoke
->binding
= new QtRubySmokeBinding(qtwebkit_Smoke
);
43 smokeList
<< qtwebkit_Smoke
;
45 QtRubyModule module
= { "QtWebKit", resolve_classname_qtwebkit
, 0 };
46 qtruby_modules
[qtwebkit_Smoke
] = module
;
48 install_handlers(QtWebKit_handlers
);
50 qtwebkit_module
= rb_define_module("QtWebKit");
51 qtwebkit_internal_module
= rb_define_module_under(qtwebkit_module
, "Internal");
53 rb_define_singleton_method(qtwebkit_internal_module
, "getClassList", (VALUE (*) (...)) getClassList
, 0);
55 rb_require("qtwebkit/qtwebkit.rb");
56 rb_funcall(qtwebkit_internal_module
, rb_intern("init_all_classes"), 0);