signal_damage_event and connect.



What seems to be wrong with this?
signal_damage_event().connect(sigc::mem_fun(&Dock::dibujarDock));
Entire code:
Dock::Dock() : Gtk::Window()
{
set_decorated(false);
set_default_size(200,200);
set_app_paintable(true);
contenedor = Gtk::manage(new Gtk::Box(Gtk::ORIENTATION_HORIZONTAL,0));
add(*contenedor);
botonPrueba = Gtk::manage(new Gtk::Button("Gran boton"));
contenedor->pack_start(*botonPrueba,Gtk::PACK_SHRINK);
contenedor->show_all();
signal_damage_event().connect(sigc::mem_fun(*this,&Dock::dibujarDock));

}
void Dock::dibujarDock()
{
contextoVentana = get_window()->create_cairo_context();
contextoVentana->set_source_rgba(1.0,1.0,1.0,0.0);
contextoVentana->set_operator(Cairo::OPERATOR_SOURCE);
contextoVentana->paint();
//contextoVentana->destroy();
}


It won't build even though it should be correct right?


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]