98 } |
98 } |
99 |
99 |
100 |
100 |
101 |
101 |
102 |
102 |
103 UiEventWrapper::UiEventWrapper(ui_callback f, void* userdata) { |
103 UiEventWrapper::UiEventWrapper(UiObject *obj, ui_callback f, void* userdata) { |
|
104 this->obj = obj; |
104 this->callback = f; |
105 this->callback = f; |
105 this->userdata = userdata; |
106 this->userdata = userdata; |
106 } |
107 } |
107 |
108 |
108 void UiEventWrapper::slot() { |
109 void UiEventWrapper::slot() { |
109 printf("event\n"); |
110 UiEvent e; |
110 |
111 e.obj = obj; |
|
112 e.window = obj->window; |
|
113 e.document = obj->ctx->document; |
|
114 e.eventdata = NULL; |
|
115 e.intval = 0; |
|
116 callback(&e, userdata); |
111 } |
117 } |