const char *ssd_widget_get_value (const SsdWidget widget, const char *name) { SsdWidget w = widget; if (name) w = ssd_widget_get (w, name); if (!w) return ""; if (w->get_value) return w->get_value (w); return w->value; }
static int edit_callback (SsdWidget widget, const char *new_value) { const char *value; SsdEntryContext* ctx; /* Get the entry widget */ widget = widget->parent; ctx = ( SsdEntryContext* ) widget->context; value = widget->get_value (widget); #if ((defined(__SYMBIAN32__) && !defined(TOUCH_SCREEN)) || defined(IPHONE) || defined( ANDROID )) { SsdWidget text = ssd_widget_get(widget->children, "Text"); if ( text && (text->flags & SSD_TEXT_PASSWORD) ) { if (!ctx->editbox_title) ShowEditbox( ctx->kb_title, value, on_kb_closed, widget, EEditBoxPassword ); else ShowEditbox( ctx->editbox_title, value, on_kb_closed, widget, EEditBoxPassword ); } else { if (!ctx->editbox_title) ShowEditbox( ctx->kb_title, value, on_kb_closed, widget, EEditBoxStandard ); else ShowEditbox( ctx->editbox_title, value, on_kb_closed, widget, EEditBoxStandard ); } } #else ssd_show_keyboard_dialog_ext( ctx->editbox_title ? ctx->editbox_title : ctx->kb_title, value, ctx->kb_label, ctx->kb_note, on_kb_closed, widget, ctx->kb_flags ); #endif return 1; }