Beispiel #1
0
static void
cleanup(LV2UI_Handle handle)
{
	MF2UI* ui = (MF2UI*)handle;

	ui_disable(ui);

	pango_font_description_free(ui->font[0]);
	pango_font_description_free(ui->font[1]);

	cairo_surface_destroy(ui->sf_nfo);
	cairo_surface_destroy(ui->sf_ann);
	cairo_surface_destroy(ui->sf_dat);
	cairo_surface_destroy(ui->sf_gain);
	cairo_surface_destroy(ui->sf_dial);
	cairo_surface_destroy(ui->sf_pc[0]);
	cairo_surface_destroy(ui->sf_pc[1]);

	robtk_select_destroy(ui->sel_fft);
	robtk_lbl_destroy(ui->lbl_fft);
	robtk_lbl_destroy(ui->lbl_screen);
	robtk_sep_destroy(ui->sep0);
	robtk_sep_destroy(ui->sep1);
	robtk_sep_destroy(ui->sep2);
	robtk_sep_destroy(ui->sep3);
	robtk_sep_destroy(ui->sep4);
	robtk_dial_destroy(ui->gain);
	robtk_dial_destroy(ui->screen);
	robtk_cbtn_destroy(ui->btn_oct);
	robtk_cbtn_destroy(ui->btn_norm);

	robwidget_destroy(ui->m0);
	robwidget_destroy(ui->m1);
	robwidget_destroy(ui->m2);

	rob_box_destroy(ui->hbox1);
	rob_box_destroy(ui->hbox2);
	rob_box_destroy(ui->hbox3);
	rob_box_destroy(ui->rw);

	fftx_free(ui->fa);
	fftx_free(ui->fb);
	free(ui->freq_band);

	pthread_mutex_destroy(&ui->fft_lock);

	free(ui);
}
Beispiel #2
0
static void gui_cleanup (BITui* ui) {
	if (ui->fontcache) {
		for (int i=0; i < FONT_LAST; ++i) {
			pango_font_description_free (ui->font[i]);
		}
	}

	if (ui->m0_faceplate) {
		cairo_surface_destroy (ui->m0_faceplate);
	}

	for (int i = 0; i < 6; ++i) {
		robtk_lbl_destroy (ui->lbl_desc[i]);
		robtk_lbl_destroy (ui->lbl_data[i]);
	}

	robtk_cbtn_destroy (ui->btn_freeze);
	robtk_cbtn_destroy (ui->btn_avg);
	robtk_pbtn_destroy (ui->btn_reset);

	robwidget_destroy (ui->m0);
	rob_table_destroy (ui->tbl_nfo);
	rob_box_destroy (ui->box_btn);
	rob_box_destroy (ui->vbox);

}