Sunday, July 20th 2008, 2:39am UTC+1

You are not logged in.

  • Login
  • Register

1

Wednesday, May 7th 2008, 2:56pm

Extending QTimer to pass parameters

i'm very new to Qt and C++, however i find myself using both at the moment.

essentially i want to use QTimer to execute a method with a parameter int. i understand that natively you cannot execute methods with parameters. however, i was wondering if this is possible if i extended QTimer. if so does anyone had an example of the proper way to set this up.

thank you
  • Go to the top of the page

2

Wednesday, May 7th 2008, 7:07pm

RE: Extending QTimer to pass parameters

virtual void timerEvent ( QTimerEvent * event ). You can use the event param. Create an event. pass that event in then process the event. You can extend the Qtimer class but not necessary.
  • Go to the top of the page

Rate this thread