int ef_vi_set_filter_string_add(ef_vi_set* vi_set, ef_driver_handle dh, const char* filter_str) { struct sc_stream stream; int rc; char *stream_def, *stream_str; /* TODO: we are installing a list of filters so should allow for * returning a list of cookies. */ ef_filter_cookie cookie; if( (stream_str = strdup(filter_str)) == NULL ) { fprintf(stderr, "%s: ERROR: strdup() failed\n", __func__); return -errno; } while( stream_str ) { sc_stream_reset(&stream); stream_def = strsep(&stream_str, ";"); if( (rc = set_general(&stream, stream_def)) < 0 ) goto out; if( (rc = sc_stream_add(&stream, vi_set, dh, &cookie)) < 0 ) goto out; } out: free(stream_str); return rc; }
//*********************************************** Options::Options( QWidget *parent, const char *name) : Q3TabDialog( parent, name) { setCaption("Settings"); set_general(); set_directories(); set_logedit(); set_interpreter(); connect( this, SIGNAL( applyButtonPressed() ), SLOT( apply() ) ); setDefaultButton(); connect( this, SIGNAL( defaultButtonPressed() ), SLOT( defaults() ) ); setCancelButton(); set_settings(); }