| 148 text->value.ptr = str; |
148 text->value.ptr = str; |
| 149 text->value.free = (ui_freefunc)XtFree; |
149 text->value.free = (ui_freefunc)XtFree; |
| 150 return str; |
150 return str; |
| 151 } |
151 } |
| 152 |
152 |
| 153 void ui_textarea_insert(UiText *text, int pos, char *str) { |
153 void ui_textarea_insert(UiText *text, int pos, const char *str) { |
| 154 text->value.ptr = NULL; |
154 text->value.ptr = NULL; |
| 155 XmTextInsert(text->obj, pos, str); |
155 XmTextInsert(text->obj, pos, (char*)str); |
| 156 if(text->value.ptr) { |
156 if(text->value.ptr) { |
| 157 text->value.free(text->value.ptr); |
157 text->value.free(text->value.ptr); |
| 158 } |
158 } |
| 159 } |
159 } |
| 160 |
160 |