Re: events do NOT respond :S



Jonathon Jongsma wrote:

On 10/4/05, Bartek Kostrzewa <bartek runbox com> wrote:
HeavyJoost wrote:
For some reason events are not received by my program, while I think it
should.
I use this piece of code:
 buttonBack.set_events(Gdk::ALL_EVENTS_MASK);

buttonBack.signal_button_press_event().connect(sigc::mem_fun(*this,&MainWindow::BackClick));


Where buttonBack is a Gtk::Button. Bool
MainWindow::BackClick(GdkEventButton* event) is a simple function that
shows some message like "hello" using std::cout.
What is wrong with my code?
As in your previous posts about the same problem I don't think there's
anything wrong with your code... I suspect you should look into your
libsigc++ installation...


Are you running Debian testing/unstable?  Any chance your gtkmm and
libsigc++ installations are out of sync and have different C++ ABI
versions?  I got bit by this a while back which was causing segfaults
whenever I tried to handle a signal.

I use Gentoo Linux as my OS, libsigc++ 2.0.16 and gtkmm 2.6.4.
I recompiled these two packages but it didn't help me.
To compile I use: g++ mainwindow.cpp -o output `pkg-config gtkmm-2.4 --cflags --libs`




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