]> Dogcows Code - chaz/openbox/commitdiff
check if a client will respond to pings
authorDana Jansens <danakj@orodu.net>
Wed, 16 Jan 2008 01:48:28 +0000 (20:48 -0500)
committerDana Jansens <danakj@orodu.net>
Wed, 16 Jan 2008 01:48:28 +0000 (20:48 -0500)
openbox/client.c
openbox/client.h
openbox/prop.c
openbox/prop.h

index 5e4e52e748ca8b73f53c9d53af4dea710cebf155..7019f690086e16f881a3a2efd0a3c24aaed31a47 100644 (file)
@@ -1507,6 +1507,10 @@ void client_update_protocols(ObClient *self)
                 /* if this protocol is requested, then the window will be
                    notified whenever we want it to receive focus */
                 self->focus_notify = TRUE;
+            else if (proto[i] == prop_atoms.net_wm_ping)
+                /* if this protocol is requested, then the window will allow
+                   pings to determine if it is still alive */
+                self->ping = TRUE;
 #ifdef SYNC
             else if (proto[i] == prop_atoms.net_wm_sync_request)
                 /* if this protocol is requested, then resizing the
index e83a6b7a24c07d0cfdf36e31880e7d0c5b4a2851..49ff72bcdc204599963c1d76a7cf66047c43e0bd 100644 (file)
@@ -220,6 +220,9 @@ struct _ObClient
     /*! Notify the window when it receives focus? */
     gboolean focus_notify;
 
+    /*! Will the client respond to pings? */
+    gboolean ping;
+
 #ifdef SYNC
     /*! The client wants to sync during resizes */
     gboolean sync_request;
index 44abdfe646bf0a5de2859380fa87d59b75dfd600..1e343e1695507f06e556f0017436ce9a20302b40 100644 (file)
@@ -98,7 +98,7 @@ void prop_startup(void)
     CREATE(kde_net_wm_frame_strut, "_KDE_NET_WM_FRAME_STRUT");
     CREATE(net_frame_extents, "_NET_FRAME_EXTENTS");
 
-/*   CREATE(net_wm_ping, "_NET_WM_PING"); */
+    CREATE(net_wm_ping, "_NET_WM_PING");
 #ifdef SYNC
     CREATE(net_wm_sync_request, "_NET_WM_SYNC_REQUEST");
     CREATE(net_wm_sync_request_counter, "_NET_WM_SYNC_REQUEST_COUNTER");
index f0c4f5e98e1ddeff67179a0a10f22049bf408848..fd12f98a94d7c138a05f37a6abd95470ed9ddcee 100644 (file)
@@ -136,7 +136,7 @@ typedef struct Atoms {
     Atom net_frame_extents;
 
     /* application protocols */
-/*  Atom net_wm_ping; */
+    Atom net_wm_ping;
 #ifdef SYNC
     Atom net_wm_sync_request;
     Atom net_wm_sync_request_counter;
This page took 0.026487 seconds and 4 git commands to generate.