added eventMask

This commit is contained in:
fluxgen 2003-08-26 23:45:36 +00:00
parent 1fc69d17ad
commit 9d3b8d55ff
2 changed files with 12 additions and 2 deletions

View file

@ -19,7 +19,7 @@
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
// $Id: FbWindow.cc,v 1.24 2003/08/15 13:52:06 fluxgen Exp $
// $Id: FbWindow.cc,v 1.25 2003/08/26 23:45:36 fluxgen Exp $
#include "FbWindow.hh"
@ -359,6 +359,15 @@ int FbWindow::screenNumber() const {
return m_screen_num;
}
long FbWindow::eventMask() const {
XWindowAttributes attrib;
if (XGetWindowAttributes(s_display, window(),
&attrib) == Success) {
return attrib.your_event_mask;
}
return 0;
}
void FbWindow::updateGeometry() {
if (m_window == 0)
return;

View file

@ -19,7 +19,7 @@
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
// $Id: FbWindow.hh,v 1.22 2003/08/15 13:52:06 fluxgen Exp $
// $Id: FbWindow.hh,v 1.23 2003/08/26 23:45:36 fluxgen Exp $
#ifndef FBTK_FBWINDOW_HH
#define FBTK_FBWINDOW_HH
@ -132,6 +132,7 @@ public:
unsigned int borderWidth() const { return m_border_width; }
int depth() const { return m_depth; }
int screenNumber() const;
long eventMask() const;
/// compare X window
bool operator == (Window win) const { return m_window == win; }
bool operator != (Window win) const { return m_window != win; }