Commit ee358b1b authored by Michael Pyne's avatar Michael Pyne

systemtray: Fix crash with scroll-to-next.

And crashes involving other action invocations.  We need to guard
against KSNI::action everywhere action() is called, not just in the
ctor.  A good Junior Job might be going through and renaming the
JuK-specific ActionCollection and action() functions to something a
little less likely to conflict with KDE or Qt namespace.
parent 57be37b3
......@@ -432,13 +432,13 @@ void SystemTray::createButtonBox(QBoxLayout *parentLayout)
*/
void SystemTray::slotBack()
{
action("back")->trigger();
ActionCollection::action("back")->trigger();
m_fade = false;
}
void SystemTray::slotForward()
{
action("forward")->trigger();
ActionCollection::action("forward")->trigger();
m_fade = false;
}
......@@ -512,15 +512,15 @@ void SystemTray::scrollEvent(int delta, Qt::Orientation orientation)
switch(QApplication::keyboardModifiers()) {
case Qt::ShiftModifier:
if(delta > 0)
action("volumeUp")->trigger();
ActionCollection::action("volumeUp")->trigger();
else
action("volumeDown")->trigger();
ActionCollection::action("volumeDown")->trigger();
break;
default:
if(delta > 0)
action("forward")->trigger();
ActionCollection::action("forward")->trigger();
else
action("back")->trigger();
ActionCollection::action("back")->trigger();
break;
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment