summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDouglas Young <rcxdude@gmail.com>2008-06-24 17:32:27 +0100
committerDouglas Young <rcxdude@gmail.com>2008-06-24 17:32:27 +0100
commitabf4d7a4f35fd10c750bb47964186cda7c60f98e (patch)
treed3844b4f8ebdc938a437bb4bfac0fb3f3d35d693
parent7782233ab074be000612df1310f5a003c7bc22bd (diff)
downloaddialog-abf4d7a4f35fd10c750bb47964186cda7c60f98e.tar.gz
dialog-abf4d7a4f35fd10c750bb47964186cda7c60f98e.tar.bz2
added matching for dialog
-rw-r--r--dialog.c5
-rw-r--r--dialog.xml.in8
2 files changed, 11 insertions, 2 deletions
diff --git a/dialog.c b/dialog.c
index daaeda5..0e495b6 100644
--- a/dialog.c
+++ b/dialog.c
@@ -190,7 +190,8 @@ dialogHandleEvent (CompDisplay *d,
int othertrans = 0;
for (www = w->screen->windows; www; www = www->next)
{
- if (www->transientFor == ww->id && w->id != www->id)
+ if (www->transientFor == ww->id && w->id != www->id &&
+ matchEval(dialogGetDialogtypes (www->screen->display),www))
othertrans++;
}
if (!othertrans)
@@ -205,7 +206,7 @@ dialogHandleEvent (CompDisplay *d,
if (event->type == MapNotify)
{
CompWindow *w = findWindowAtDisplay (d, event->xmap.window);
- if (w && w->transientFor)
+ if (w && w->transientFor && matchEval(dialogGetDialogtypes (w->screen->display),w))
{
CompWindow *ww = findWindowAtDisplay (w->screen->display, w->transientFor);
DialogWindow *dww = GET_DIALOG_WINDOW (ww, \
diff --git a/dialog.xml.in b/dialog.xml.in
index 7b0c7c2..d5ce059 100644
--- a/dialog.xml.in
+++ b/dialog.xml.in
@@ -4,8 +4,16 @@
<short>ADDialog</short>
<long>Fades windows with open dialogs</long>
<category>Extras</category>
+ <deps>
+ <requirement> regex </requirement>
+ </deps>
<display>
<group>
+ <option name="dialogtypes" type="match">
+ <_short>Dialog Match</_short>
+ <_long>Dialogs which will trigger fading</_long>
+ <default>any</default>
+ </option>
<option name="speed" type="float">
<_short>Speed</_short>
<_long>The speed of the animation</_long>