Sophie

Sophie

distrib > Fedora > 15 > i386 > by-pkgid > 4442dd9bdde98a1d9ca2177557e87d7d > files > 556

libqxt-devel-0.6.1-3.fc15.i686.rpm

<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html
    PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<!-- /builddir/build/BUILD/libqxt/doc/src/qxtnativeeventfilter.qdoc -->
<head>
  <title>QxtNativeEventFilter Class Reference</title>
  <link href="stylesheet.css" rel="stylesheet" type="text/css" />
</head>
<body>
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td align="left" valign="top" width="32"><a href="http://libqxt.org"><img src="images/qxt-logo.png" width="50" height="40" align="left" border="0" /></a></td>
<td width="1">&nbsp;&nbsp;</td><td class="postheader" valign="center"><a href="index.html"><font color="#004faf">Home</font></a>&nbsp;&middot; <a href="modules.html"><font color="#004faf">Modules</font></a>&nbsp;&middot; <a href="classes.html"><font color="#004faf">Classes</font></a>&nbsp;&middot; <a href="namespaces.html"><font color="#004faf">Namespaces</font></a>&nbsp;&middot; <a href="functions.html"><font color="#004faf">Functions</font></a></td>
<td align="right" valign="top" width="230"></td></tr></table><h1 class="title">QxtNativeEventFilter Class Reference<br /><span class="small-subtitle">[<a href="qxtgui.html">QxtGui</a> module]</span>
</h1>
<p>The QxtNativeEventFilter class provides a native event filter to access platform specific events. <a href="#details">More...</a></p>
<pre>    #include &lt;QxtNativeEventFilter&gt;</pre><ul>
<li><a href="qxtnativeeventfilter-members.html">List of all members, including inherited members</a></li>
</ul>
<a name="public-functions"></a>
<h3>Public Functions</h3>
<ul>
<li><div class="fn"></div>virtual <b><a href="qxtnativeeventfilter.html#dtor.QxtNativeEventFilter">~QxtNativeEventFilter</a></b> ()</li>
<li><div class="fn"></div>virtual bool <b><a href="qxtnativeeventfilter.html#macEventFilter">macEventFilter</a></b> ( EventHandlerCallRef <i>caller</i>, EventRef <i>event</i> )</li>
<li><div class="fn"></div>virtual bool <b><a href="qxtnativeeventfilter.html#winEventFilter">winEventFilter</a></b> ( MSG * <i>msg</i>, long * <i>result</i> )</li>
<li><div class="fn"></div>virtual bool <b><a href="qxtnativeeventfilter.html#x11EventFilter">x11EventFilter</a></b> ( XEvent * <i>event</i> )</li>
</ul>
<a name="details"></a>
<hr />
<h2>Detailed Description</h2>
<p>The QxtNativeEventFilter class provides a native event filter to access platform specific events.</p>
<p>QxtNativeEventFilter provides access to platform specific native events without the need of subclassing <a href="http://doc.qtsoftware.com/4.5/qapplication.html">QApplication</a>.</p>
<p><b>Note:</b> QxtNativeEventFilter requires <a href="qxtapplication.html">QxtApplication</a>.</p>
<p>Example usage:</p>
<pre>    qxtApp-&gt;installNativeEventFilter(myObject);

    class MyObject : public QxtNativeEventFilter {
        public:
            ...

            bool x11EventFilter(XEvent* event) {
                if (event-&gt;type == ...) {
                    ...
                }
                return false;
            }

            bool winEventFilter(MSG* msg, long* result) {
                if (msg-&gt;message == ...) {
                    ...
                }
                return false;
            }

            bool macEventFilter(EventHandlerCallRef caller, EventRef event) {
                if (GetEventClass(event) == ...) {
                    ...
                }
                return false;
            }
    };</pre>
<p>See also <a href="qxtapplication.html#installNativeEventFilter">QxtApplication::installNativeEventFilter</a>().</p>
<hr />
<h2>Member Function Documentation</h2>
<h3 class="fn"><a name="dtor.QxtNativeEventFilter"></a>QxtNativeEventFilter::~QxtNativeEventFilter ()&nbsp;&nbsp;<tt> [virtual]</tt></h3>
<p>Destructs the native event filter. The native event filter is automatically removed from the application.</p>
<p>See also <a href="qxtapplication.html#removeNativeEventFilter">QxtApplication::removeNativeEventFilter</a>().</p>
<h3 class="fn"><a name="macEventFilter"></a>bool QxtNativeEventFilter::macEventFilter ( EventHandlerCallRef <i>caller</i>, EventRef <i>event</i> )&nbsp;&nbsp;<tt> [virtual]</tt></h3>
<p>Filters Mac events if this object has been installed as a native event filter. The events are passed in the <i>event</i> parameter with the <i>caller</i> parameter.</p>
<p>In your reimplementation of this function, if you want to filter the event out, i.e&#x2e; stop it being handled further, return <tt>true</tt>; otherwise return <tt>false</tt>.</p>
<p>See also <a href="qxtapplication.html#installNativeEventFilter">QxtApplication::installNativeEventFilter</a>().</p>
<h3 class="fn"><a name="winEventFilter"></a>bool QxtNativeEventFilter::winEventFilter ( MSG * <i>msg</i>, long * <i>result</i> )&nbsp;&nbsp;<tt> [virtual]</tt></h3>
<p>Filters Windows events if this object has been installed as a native event filter. The window messages are passed in the <i>msg</i> parameter and the return value of the window procedure can be set to the <i>result</i> parameter.</p>
<p>In your reimplementation of this function, if you want to filter the event out, i.e&#x2e; stop it being handled further, return <tt>true</tt>; otherwise return <tt>false</tt>.</p>
<p>See also <a href="qxtapplication.html#installNativeEventFilter">QxtApplication::installNativeEventFilter</a>().</p>
<h3 class="fn"><a name="x11EventFilter"></a>bool QxtNativeEventFilter::x11EventFilter ( XEvent * <i>event</i> )&nbsp;&nbsp;<tt> [virtual]</tt></h3>
<p>Filters X11 events if this object has been installed as a native event filter. The events are passed in the <i>event</i> parameter.</p>
<p>In your reimplementation of this function, if you want to filter the event out, i.e&#x2e; stop it being handled further, return <tt>true</tt>; otherwise return <tt>false</tt>.</p>
<p>See also <a href="qxtapplication.html#installNativeEventFilter">QxtApplication::installNativeEventFilter</a>().</p>
<p /><address><hr /><div align="center">
<table width="100%" cellspacing="0" border="0"><tr class="address">
<td align="left">Copyright &copy; 2007-2010
<a href="mailto:foundation@libqxt.org">Qxt Foundation</a></td>
<td align="right"><div align="right">
<a href="http://libqxt.org">Qxt</a> 0.6.1</div></td>
</tr></table></div></address></body>
</html>