diff options
author | fluxgen <fluxgen> | 2003-08-24 15:37:12 (GMT) |
---|---|---|
committer | fluxgen <fluxgen> | 2003-08-24 15:37:12 (GMT) |
commit | 710ef5d3c94e82e0ec99ff95a8c09d7308f81a6e (patch) | |
tree | 152ee32ca97eb45f742d57704270e7bd067db3da /src | |
parent | d1b14ad0840b7a8976f43b66f2257a13b0c70618 (diff) | |
download | fluxbox-710ef5d3c94e82e0ec99ff95a8c09d7308f81a6e.zip fluxbox-710ef5d3c94e82e0ec99ff95a8c09d7308f81a6e.tar.bz2 |
fixed isShaped and setShapeNotify
Diffstat (limited to 'src')
-rw-r--r-- | src/Shape.cc | 28 |
1 files changed, 27 insertions, 1 deletions
diff --git a/src/Shape.cc b/src/Shape.cc index 8954f3f..efc47fd 100644 --- a/src/Shape.cc +++ b/src/Shape.cc | |||
@@ -19,7 +19,7 @@ | |||
19 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER | 19 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER |
20 | // DEALINGS IN THE SOFTWARE. | 20 | // DEALINGS IN THE SOFTWARE. |
21 | 21 | ||
22 | // $Id: Shape.cc,v 1.3 2003/08/13 22:52:35 fluxgen Exp $ | 22 | // $Id: Shape.cc,v 1.4 2003/08/24 15:37:12 fluxgen Exp $ |
23 | 23 | ||
24 | #include "Shape.hh" | 24 | #include "Shape.hh" |
25 | #include "FbWindow.hh" | 25 | #include "FbWindow.hh" |
@@ -193,3 +193,29 @@ void Shape::setWindow(FbTk::FbWindow &win) { | |||
193 | m_win = &win; | 193 | m_win = &win; |
194 | update(); | 194 | update(); |
195 | } | 195 | } |
196 | |||
197 | void Shape::setShapeNotify(const FbTk::FbWindow &win) { | ||
198 | #ifdef SHAPE | ||
199 | XShapeSelectInput(FbTk::App::instance()->display(), | ||
200 | win.window(), ShapeNotifyMask); | ||
201 | #endif // SHAPE | ||
202 | } | ||
203 | |||
204 | bool Shape::isShaped(const FbTk::FbWindow &win) { | ||
205 | int shaped = 0; | ||
206 | |||
207 | #ifdef SHAPE | ||
208 | int not_used; | ||
209 | unsigned int not_used2; | ||
210 | XShapeQueryExtents(FbTk::App::instance()->display(), | ||
211 | win.window(), | ||
212 | &shaped, /// bShaped | ||
213 | ¬_used, ¬_used, // xbs, ybs | ||
214 | ¬_used2, ¬_used2, // wbs, hbs | ||
215 | ¬_used, // cShaped | ||
216 | ¬_used, ¬_used, // xcs, ycs | ||
217 | ¬_used2, ¬_used2); // wcs, hcs | ||
218 | #endif // SHAPE | ||
219 | |||
220 | return (shaped != 0 ? true : false); | ||
221 | } | ||