[gtkmm] Signals...


I'm starting with gtkmm, rigth now I'm making to TreeView, the problem is that I can catch the selection in one of them and add some text to that TreeView, but I can't catch the selection of one TreeView and add some text in the other I have 7 files, 2 of them with the .h and .cc of the TreeView1, two more with the .h and .cc of the TreeView2 and the other with the main.cc, window.h and window.cc  if I set a signal handler in the treeview1.cc I can only access the methods of that class, and I have no idea of how to access the methods of the TreeView2 class (in order to change the data of that TreeView), I read that there's a way to call the SigC with an object (rather than *this), I tried that too:

MyTreeView2Class instance;
refTreeSelection->signal_changed().connect(SigC::slot(instance, &MyTreeView2Class::on_selection_changed));

it compiles ok, but in runtime nothing happends... I'm thinking in putting all in one large .h file, but I'm not sure if that's ok (actually I don't think so), the problem is that I'm not a C++ expert, so I don't know how to deal with that type of situations...

Any help or suggestions will be appreciated.. thanx

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