Mercurial > hg > svapp
comparison framework/MainWindowBase.cpp @ 389:8cfc71c8ec4b
Some temporary action debug output
author | Chris Cannam |
---|---|
date | Wed, 13 Aug 2014 09:09:16 +0100 |
parents | 479f60cf85d8 |
children | 3e5c8a03bcb7 |
comparison
equal
deleted
inserted
replaced
388:479f60cf85d8 | 389:8cfc71c8ec4b |
---|---|
340 if (hasButton) continue; | 340 if (hasButton) continue; |
341 QKeySequence sc = a->shortcut(); | 341 QKeySequence sc = a->shortcut(); |
342 if (sc.count() == 1 && !(sc[0] & Qt::KeyboardModifierMask)) { | 342 if (sc.count() == 1 && !(sc[0] & Qt::KeyboardModifierMask)) { |
343 QShortcut *newSc = new QShortcut(sc, a->parentWidget()); | 343 QShortcut *newSc = new QShortcut(sc, a->parentWidget()); |
344 QObject::connect(newSc, SIGNAL(activated()), mapper, SLOT(map())); | 344 QObject::connect(newSc, SIGNAL(activated()), mapper, SLOT(map())); |
345 cerr << "setting mapping for action " << a << ", name " << a->text() << endl; | |
345 mapper->setMapping(newSc, a); | 346 mapper->setMapping(newSc, a); |
346 } | 347 } |
347 } | 348 } |
348 #endif | 349 #endif |
349 } | 350 } |
351 void | 352 void |
352 MainWindowBase::menuActionMapperInvoked(QObject *o) | 353 MainWindowBase::menuActionMapperInvoked(QObject *o) |
353 { | 354 { |
354 QAction *a = qobject_cast<QAction *>(o); | 355 QAction *a = qobject_cast<QAction *>(o); |
355 if (a && a->isEnabled()) { | 356 if (a && a->isEnabled()) { |
357 cerr << "about to call trigger on action " << a << ", name " << a->text() << endl; | |
356 a->trigger(); | 358 a->trigger(); |
357 } | 359 } |
358 } | 360 } |
359 | 361 |
360 void | 362 void |