/*
- * $Id: rb_esmart_file_dialog.c 356 2006-02-10 18:27:31Z tilman $
+ * $Id: rb_esmart_file_dialog.c 391 2006-11-11 12:14:24Z tilman $
*
* Copyright (C) 2005 Tilman Sauerbeck (tilman at code-monkey de)
*
static void on_action (void *data, Evas_Object *edje,
Esmart_File_Dialog_Op op);
+static VALUE cEdje;
+
static void c_mark (RbFileDialog *e)
{
c_evas_object_mark (&e->real);
static VALUE c_edje_get (VALUE self)
{
Evas_Object *e;
- VALUE mEdje, cEdje, s;
- ID const_get;
GET_OBJ (self, RbFileDialog, fd);
if (!NIL_P (fd->edje))
return fd->edje;
- const_get = rb_intern ("const_get");
- s = rb_str_new2 ("Edje");
-
- mEdje = rb_funcall (rb_cModule, const_get, 1, s);
- cEdje = rb_funcall (mEdje, const_get, 1, s);
-
e = esmart_file_dialog_edje_get (fd->real.real);
fd->edje = rb_funcall (cEdje, rb_intern ("new_from_pointer"), 2,
TO_EVAS (self, evas_object_evas_get (e)),
void Init_esmart_file_dialog (void)
{
- VALUE c;
+ VALUE m, c;
rb_require ("esmart");
+ rb_require ("edje");
+
+ m = rb_const_get (rb_cModule, rb_intern ("Edje"));
+ cEdje = rb_const_get (m, rb_intern ("Edje"));
c = rb_define_class_under (mEsmart, "FileDialog", cEvasObject);