[Qt-interest] Can a QAction be replaced at runtime ?
Stephen Collyer
scollyer at netspinner.co.uk
Tue May 12 17:28:48 CEST 2009
I have a QMenu containing a QAction which starts an activity i.e. with text
like:
"Start X"
When the activity X is started, I want to toggle the available action to
say:
"Stop X"
I've created a start action with text "Start X" and a separate stop action
with
text "Stop X". At the moment I'm toggling the actions by inserting the stop
action before
the start action, then removing the start action. This works, but feels a
little clunky.
Is it possible to directly replace a QAction in a menu ?
--
Stephen Collyer
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20090512/b5ae8895/attachment.html
More information about the Qt-interest-old
mailing list