break;
}
- case Qt::MidButton:
+ case Qt::MiddleButton:
{
hide();
break;
mouseActionDesktop(m_leftButtonDesktop);
}
}
- if (me->button() == Qt::MidButton) {
+ if (me->button() == Qt::MiddleButton) {
if (hovering) {
// mouse is hovering above a window - use MouseActionsWindow
mouseActionWindow(m_middleButtonWindow);
case Qt::LeftButton:
button = Button1;
break;
- case Qt::MidButton:
+ case Qt::MiddleButton:
button = Button2;
break;
case Qt::RightButton:
if ((!m_button[MaxButton]) && isMaximizable()) {
btn = createButton(MaxButton);
if (!btn) break;
- btn->setRealizeButtons(Qt::LeftButton | Qt::MidButton | Qt::RightButton);
+ btn->setRealizeButtons(Qt::LeftButton | Qt::MiddleButton | Qt::RightButton);
const bool max = maximizeMode() == MaximizeFull;
btn->setTipText(max ? i18n("Restore") : i18n("Maximize"));
btn->setToggleButton(true);
KDecorationDefines::WindowOperation KDecorationOptions::operationMaxButtonClick(Qt::MouseButtons button) const
{
return button == Qt::RightButton ? d->opMaxButtonRightClick :
- button == Qt::MidButton ? d->opMaxButtonMiddleClick :
+ button == Qt::MiddleButton ? d->opMaxButtonMiddleClick :
d->opMaxButtonLeftClick;
}
if (button == Qt::LeftButton)
com = active ? options->commandActiveTitlebar1() : options->commandInactiveTitlebar1();
- else if (button == Qt::MidButton)
+ else if (button == Qt::MiddleButton)
com = active ? options->commandActiveTitlebar2() : options->commandInactiveTitlebar2();
else if (button == Qt::RightButton)
com = active ? options->commandActiveTitlebar3() : options->commandInactiveTitlebar3();
{
if (button == Qt::LeftButton)
return XCB_BUTTON_INDEX_1;
- else if (button == Qt::MidButton)
+ else if (button == Qt::MiddleButton)
return XCB_BUTTON_INDEX_2;
else if (button == Qt::RightButton)
return XCB_BUTTON_INDEX_3;
if (button == XCB_BUTTON_INDEX_1)
return Qt::LeftButton;
if (button == XCB_BUTTON_INDEX_2)
- return Qt::MidButton;
+ return Qt::MiddleButton;
if (button == XCB_BUTTON_INDEX_3)
return Qt::RightButton;
if (button == XCB_BUTTON_INDEX_4)
int ret = 0;
if (buttons & Qt::LeftButton)
ret |= XCB_KEY_BUT_MASK_BUTTON_1;
- if (buttons & Qt::MidButton)
+ if (buttons & Qt::MiddleButton)
ret |= XCB_KEY_BUT_MASK_BUTTON_2;
if (buttons & Qt::RightButton)
ret |= XCB_KEY_BUT_MASK_BUTTON_3;
if (state & XCB_KEY_BUT_MASK_BUTTON_1)
ret |= Qt::LeftButton;
if (state & XCB_KEY_BUT_MASK_BUTTON_2)
- ret |= Qt::MidButton;
+ ret |= Qt::MiddleButton;
if (state & XCB_KEY_BUT_MASK_BUTTON_3)
ret |= Qt::RightButton;
if (state & XCB_KEY_BUT_MASK_BUTTON_4)
}
}
- if (event->button() == Qt::MidButton) {
+ if (event->button() == Qt::MiddleButton) {
event->ignore();
}
}
{
Applet::mousePressEvent(event);
- if (event->button() == Qt::MidButton) {
+ if (event->button() == Qt::MiddleButton) {
event->accept();
}
}
{
Applet::mouseReleaseEvent(event);
- if (event->button() == Qt::MidButton) {
+ if (event->button() == Qt::MiddleButton) {
showMenu(true);
}
}
m_buttons.insert(Qt::LeftButton, I18N_NOOP("Left Button"));
m_buttons.insert(Qt::RightButton, I18N_NOOP("Right Button"));
- m_buttons.insert(Qt::MidButton, I18N_NOOP("Middle Button"));
+ m_buttons.insert(Qt::MiddleButton, I18N_NOOP("Middle Button"));
m_buttons.insert(Qt::XButton1, I18N_NOOP("First X Button"));
m_buttons.insert(Qt::XButton2, I18N_NOOP("Second X Button"));
}
qmlRegisterType<KDeclarativeWheelEvent>();
setFiltersChildEvents(true);
- setAcceptedMouseButtons(Qt::LeftButton|Qt::RightButton|Qt::MidButton|Qt::XButton1|Qt::XButton2);
+ setAcceptedMouseButtons(Qt::LeftButton|Qt::RightButton|Qt::MiddleButton|Qt::XButton1|Qt::XButton2);
}
MouseEventListener::~MouseEventListener()
QtNoButton = Qt::NoButton,
QtLeftButton = Qt::LeftButton,
QtRightButton = Qt::RightButton,
- QtMidButton = Qt::MidButton,
+ QtMidButton = Qt::MiddleButton,
QtXButton1 = Qt::XButton1,
QtXButton2 = Qt::XButton2
};
Plasma::ContainmentActionsPluginsConfig desktopPlugins;
desktopPlugins.addPlugin(Qt::NoModifier, Qt::Vertical, "switchdesktop");
- desktopPlugins.addPlugin(Qt::NoModifier, Qt::MidButton, "paste");
+ desktopPlugins.addPlugin(Qt::NoModifier, Qt::MiddleButton, "paste");
desktopPlugins.addPlugin(Qt::NoModifier, Qt::RightButton, "contextmenu");
Plasma::ContainmentActionsPluginsConfig panelPlugins;
panelPlugins.addPlugin(Qt::NoModifier, Qt::RightButton, "contextmenu");