Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 308297
Collapse All | Expand All

(-)a/src/xcommon.c (-3 / +17 lines)
Lines 25-30 Link Here
25
#include <stdio.h>
25
#include <stdio.h>
26
#include <stdlib.h>
26
#include <stdlib.h>
27
#include <string.h>
27
#include <string.h>
28
#include <unistd.h>
28
29
29
#if defined(__FreeBSD__)
30
#if defined(__FreeBSD__)
30
#include <machine/param.h>
31
#include <machine/param.h>
Lines 106-111 Link Here
106
static Atom wm_delete_window;
107
static Atom wm_delete_window;
107
static Atom xawtv_station;
108
static Atom xawtv_station;
108
static Atom xawtv_remote;
109
static Atom xawtv_remote;
110
static Atom net_wm_pid;
109
111
110
#ifdef HAVE_XTESTEXTENSION
112
#ifdef HAVE_XTESTEXTENSION
111
static KeyCode kc_shift_l; /* Fake key to send. */
113
static KeyCode kc_shift_l; /* Fake key to send. */
Lines 150-160 Link Here
150
        "WM_PROTOCOLS",
152
        "WM_PROTOCOLS",
151
        "WM_DELETE_WINDOW",
153
        "WM_DELETE_WINDOW",
152
        "_XAWTV_STATION",
154
        "_XAWTV_STATION",
153
        "_XAWTV_REMOTE"
155
        "_XAWTV_REMOTE",
156
        "_NET_WM_PID"
154
    };
157
    };
155
    Atom atoms_return[ 17 ];
158
    Atom atoms_return[ 18 ];
156
159
157
    XInternAtoms( display, atom_names, 17, False, atoms_return );
160
    XInternAtoms( display, atom_names, 18, False, atoms_return );
158
    net_supporting_wm_check = atoms_return[ 0 ];
161
    net_supporting_wm_check = atoms_return[ 0 ];
159
    net_supported = atoms_return[ 1 ];
162
    net_supported = atoms_return[ 1 ];
160
    net_wm_name = atoms_return[ 2 ];
163
    net_wm_name = atoms_return[ 2 ];
Lines 172-177 Link Here
172
    wm_delete_window = atoms_return[ 14 ];
175
    wm_delete_window = atoms_return[ 14 ];
173
    xawtv_station = atoms_return[ 15 ];
176
    xawtv_station = atoms_return[ 15 ];
174
    xawtv_remote = atoms_return[ 16 ];
177
    xawtv_remote = atoms_return[ 16 ];
178
    net_wm_pid = atoms_return[ 17 ];
175
}
179
}
176
180
177
static uint32_t icon_colours[256];
181
static uint32_t icon_colours[256];
Lines 1017-1022 Link Here
1017
            free( data );
1021
            free( data );
1018
        }
1022
        }
1019
    }
1023
    }
1024
    
1025
    /* Set _NET_WM_PID */
1026
    {
1027
        if( xcommon_verbose ) {
1028
            fprintf( stderr, "xcommon: try to set _NET_WM_PID" );
1029
        }
1030
        pid_t mypid = getpid();
1031
        XChangeProperty(display, wm_window, net_wm_pid, cardinal, 32,
1032
                        PropModeReplace, (const unsigned char*) &mypid, 1);
1033
    }
1020
1034
1021
    if( check_for_EWMH_wm( display, &wmname ) ) {
1035
    if( check_for_EWMH_wm( display, &wmname ) ) {
1022
        if( xcommon_verbose ) {
1036
        if( xcommon_verbose ) {

Return to bug 308297