54 |
{ |
{ |
55 |
Window wnd; |
Window wnd; |
56 |
unsigned long id; |
unsigned long id; |
57 |
|
unsigned long parent; |
58 |
XWMHints *hints; |
XWMHints *hints; |
59 |
int xoffset, yoffset; |
int xoffset, yoffset; |
60 |
int width, height; |
int width, height; |
3087 |
XFree(sizehints); |
XFree(sizehints); |
3088 |
} |
} |
3089 |
|
|
|
/* Handle popups without parents through some ewm hints */ |
|
|
if (parent == 0xFFFFFFFF) |
|
|
ewmh_set_window_popup(wnd); |
|
3090 |
/* Set WM_TRANSIENT_FOR, if necessary */ |
/* Set WM_TRANSIENT_FOR, if necessary */ |
3091 |
else if (parent != 0x00000000) |
if ((parent != 0x00000000) && (parent != 0xFFFFFFFF)) |
3092 |
{ |
{ |
3093 |
sw_parent = seamless_get_window_by_id(parent); |
sw_parent = seamless_get_window_by_id(parent); |
3094 |
if (sw_parent) |
if (sw_parent) |
3113 |
sw = malloc(sizeof(seamless_window)); |
sw = malloc(sizeof(seamless_window)); |
3114 |
sw->wnd = wnd; |
sw->wnd = wnd; |
3115 |
sw->id = id; |
sw->id = id; |
3116 |
|
sw->parent = parent; |
3117 |
sw->hints = XAllocWMHints(); |
sw->hints = XAllocWMHints(); |
3118 |
sw->hints->flags = 0; |
sw->hints->flags = 0; |
3119 |
sw->xoffset = 0; |
sw->xoffset = 0; |
3243 |
break; |
break; |
3244 |
} |
} |
3245 |
|
|
3246 |
|
/* Handle popups without parents through some ewm hints */ |
3247 |
|
if ((sw->state == SEAMLESSRDP_NOTYETMAPPED) && (sw->parent == 0xFFFFFFFF)) |
3248 |
|
ewmh_set_window_popup(sw->wnd); |
3249 |
|
|
3250 |
sw->state = state; |
sw->state = state; |
3251 |
} |
} |
3252 |
|
|