[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: kdeartwork/kwin-styles/icewm
From: Aaron J. Seigo <aseigo () olympusproject ! org>
Date: 2003-07-15 18:18:57
[Download RAW message or body]
CVS commit by aseigo:
close on button release, not press
M +12 -4 icewm.cpp 1.28
M +11 -9 icewm.h 1.11
--- kdeartwork/kwin-styles/icewm/icewm.cpp #1.27:1.28
@@ -705,5 +705,6 @@ void IceWMButton::mouseReleaseEvent( QMo
IceWMClient::IceWMClient( Workspace *ws, WId w, QWidget *parent, const char *name )
- : Client( ws, w, parent, name, WResizeNoErase | WStaticContents | WRepaintNoErase )
+ : Client( ws, w, parent, name, WResizeNoErase | WStaticContents | WRepaintNoErase ),
+ m_closing(false)
{
// Set button pointers to null so we can track things
@@ -811,4 +812,6 @@ void IceWMClient::addClientButtons( cons
connect( button[BtnSysMenu], SIGNAL(pressed()),
this, SLOT(menuButtonPressed()));
+ connect( button[BtnSysMenu], SIGNAL(released()),
+ this, SLOT(menuButtonReleased()));
hb->addWidget( button[BtnSysMenu] );
}
@@ -1353,5 +1356,4 @@ Client::MousePosition IceWMClient::mouse
-// Make sure the menu button follows double click conventions set in kcontrol
void IceWMClient::menuButtonPressed()
{
@@ -1364,5 +1366,5 @@ void IceWMClient::menuButtonPressed()
if (dbl)
{
- closeWindow();
+ m_closing = true;
return;
}
@@ -1374,4 +1376,10 @@ void IceWMClient::menuButtonPressed()
workspace()->showWindowMenu( button[BtnSysMenu]->mapToGlobal(menuPoint), this );
button[BtnSysMenu]->setDown(false);
+}
+
+void IceWMClient::menuButtonReleased()
+{
+ if (m_closing)
+ closeWindow();
}
--- kdeartwork/kwin-styles/icewm/icewm.h #1.10:1.11
@@ -143,4 +143,5 @@ class IceWMClient : public Client
void slotMaximize();
void menuButtonPressed();
+ void menuButtonReleased();
private:
@@ -169,4 +170,5 @@ class IceWMClient : public Client
QBoxLayout* hb;
QGridLayout* grid;
+ bool m_closing;
};
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic