Results 1 to 3 of 3

Thread: Qtoolbutton-ignoring mouse events

  1. #1
    Join Date
    Dec 2006
    Posts
    2
    Platforms
    Windows

    Default Qtoolbutton-ignoring mouse events

    Hello everyone
    I have a QToolbutton, which when pressed starts an algorithm. I call setEnabled(false) to disable this button receiving key and mouse events. When the processing is happening, if the user keeps clicking on the button, it queues it somewhere and starts immediately processing when i set the setEnabled to true. How do i go about fixing this?

    Thanks
    Raghavan

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    5,372
    Thanks
    28
    Thanked 976 Times in 912 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Qtoolbutton-ignoring mouse events

    Try calling QCoreApplication::processEvents() before enabling that button.

  3. #3
    Join Date
    Dec 2006
    Posts
    2
    Platforms
    Windows

    Default Re: Qtoolbutton-ignoring mouse events

    thank, man. it works.

Similar Threads

  1. Re-implement mouse events of QTextEdit
    By Ankitha Varsha in forum Qt Programming
    Replies: 2
    Last Post: 14th October 2006, 16:55
  2. mouse moving don't produce mouse events
    By coralbird in forum Qt Programming
    Replies: 1
    Last Post: 13th September 2006, 06:13
  3. how to corss compile for windows in Linux
    By safknw in forum Qt Programming
    Replies: 24
    Last Post: 13th May 2006, 05:23
  4. QStackerWidget and mouse events
    By high_flyer in forum Qt Programming
    Replies: 3
    Last Post: 25th April 2006, 19:25
  5. Forwarding mouse events to another widget.
    By yogeshm02 in forum Qt Programming
    Replies: 8
    Last Post: 28th February 2006, 13:25

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.