parent
bc17ffc991
commit
4d439be211
|
@ -126,7 +126,8 @@ CoordsShow(EWin * ewin)
|
||||||
EobjMap(eo, 0);
|
EobjMap(eo, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
ITApply(eo->win, ic, NULL, STATE_NORMAL, 1, 0, ST_SOLID, tc, NULL, s, 1);
|
ITApply(EobjGetWin(eo), ic, NULL, STATE_NORMAL, 1, 0, ST_SOLID, tc, NULL, s,
|
||||||
|
1);
|
||||||
|
|
||||||
if (md) /* Assuming that shape change only happens when size changes too */
|
if (md) /* Assuming that shape change only happens when size changes too */
|
||||||
EobjShapeUpdate(eo, 0);
|
EobjShapeUpdate(eo, 0);
|
||||||
|
|
|
@ -552,15 +552,15 @@ ECompMgrMoveResizeFix(EObj * eo, int x, int y, int w, int h)
|
||||||
|
|
||||||
if (!cw || !Conf_compmgr.resize_fix_enable)
|
if (!cw || !Conf_compmgr.resize_fix_enable)
|
||||||
{
|
{
|
||||||
EMoveResizeWindow(eo->win, x, y, w, h);
|
EMoveResizeWindow(EobjGetWin(eo), x, y, w, h);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
wo = ho = 0;
|
wo = ho = 0;
|
||||||
EGetGeometry(eo->win, NULL, NULL, NULL, &wo, &ho, NULL, NULL);
|
EGetGeometry(EobjGetWin(eo), NULL, NULL, NULL, &wo, &ho, NULL, NULL);
|
||||||
if (wo <= 0 || ho <= 0 || (wo == w && ho == h))
|
if (wo <= 0 || ho <= 0 || (wo == w && ho == h))
|
||||||
{
|
{
|
||||||
EMoveResizeWindow(eo->win, x, y, w, h);
|
EMoveResizeWindow(EobjGetWin(eo), x, y, w, h);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -570,7 +570,7 @@ ECompMgrMoveResizeFix(EObj * eo, int x, int y, int w, int h)
|
||||||
wo, ho);
|
wo, ho);
|
||||||
|
|
||||||
/* Resize (+move) */
|
/* Resize (+move) */
|
||||||
EMoveResizeWindow(eo->win, x, y, w, h);
|
EMoveResizeWindow(EobjGetWin(eo), x, y, w, h);
|
||||||
|
|
||||||
/* Paste old contents back in */
|
/* Paste old contents back in */
|
||||||
if (w < wo)
|
if (w < wo)
|
||||||
|
@ -1058,7 +1058,7 @@ ECompMgrWinSetExtents(EObj * eo)
|
||||||
|
|
||||||
#if ENABLE_SHADOWS
|
#if ENABLE_SHADOWS
|
||||||
cw->has_shadow = (Mode_compmgr.shadow_mode != ECM_SHADOWS_OFF) &&
|
cw->has_shadow = (Mode_compmgr.shadow_mode != ECM_SHADOWS_OFF) &&
|
||||||
eo->shadow && (EShapeCheck(eo->win) >= 0);
|
eo->shadow && (EShapeCheck(EobjGetWin(eo)) >= 0);
|
||||||
if (!cw->has_shadow)
|
if (!cw->has_shadow)
|
||||||
goto skip_shadow;
|
goto skip_shadow;
|
||||||
|
|
||||||
|
@ -1186,7 +1186,7 @@ ECompMgrWinSetShape(EObj * eo)
|
||||||
}
|
}
|
||||||
|
|
||||||
static Pixmap
|
static Pixmap
|
||||||
EWindowGetNamePixmap(Win win)
|
EWindowGetNamePixmap(const struct _xwin *win)
|
||||||
{
|
{
|
||||||
XWindowAttributes xwa;
|
XWindowAttributes xwa;
|
||||||
|
|
||||||
|
@ -1285,7 +1285,7 @@ ECompMgrWinSetOpacity(EObj * eo, unsigned int opacity)
|
||||||
|
|
||||||
if (eo->noredir)
|
if (eo->noredir)
|
||||||
mode = WINDOW_UNREDIR;
|
mode = WINDOW_UNREDIR;
|
||||||
else if (eo->win->argb)
|
else if (EobjGetWin(eo)->argb)
|
||||||
mode = WINDOW_ARGB;
|
mode = WINDOW_ARGB;
|
||||||
else if (cw->opacity != OPAQUE)
|
else if (cw->opacity != OPAQUE)
|
||||||
mode = WINDOW_TRANS;
|
mode = WINDOW_TRANS;
|
||||||
|
@ -1516,7 +1516,7 @@ ECompMgrWinSetPicts(EObj * eo)
|
||||||
if (draw == None)
|
if (draw == None)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
pictfmt = XRenderFindVisualFormat(disp, WinGetVisual(eo->win));
|
pictfmt = XRenderFindVisualFormat(disp, WinGetVisual(EobjGetWin(eo)));
|
||||||
pa.subwindow_mode = IncludeInferiors;
|
pa.subwindow_mode = IncludeInferiors;
|
||||||
cw->picture = XRenderCreatePicture(disp, draw,
|
cw->picture = XRenderCreatePicture(disp, draw,
|
||||||
pictfmt, CPSubwindowMode, &pa);
|
pictfmt, CPSubwindowMode, &pa);
|
||||||
|
@ -1542,7 +1542,7 @@ ECompMgrWinNew(EObj * eo)
|
||||||
if (!Mode_compmgr.active) /* FIXME - Here? */
|
if (!Mode_compmgr.active) /* FIXME - Here? */
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (eo->inputonly || eo->win == VROOT)
|
if (eo->inputonly || EobjGetWin(eo) == VROOT)
|
||||||
{
|
{
|
||||||
eo->noredir = 1;
|
eo->noredir = 1;
|
||||||
return;
|
return;
|
||||||
|
@ -1593,7 +1593,7 @@ ECompMgrWinNew(EObj * eo)
|
||||||
|
|
||||||
if (eo->type == EOBJ_TYPE_DESK || eo->type == EOBJ_TYPE_ROOT_BG)
|
if (eo->type == EOBJ_TYPE_DESK || eo->type == EOBJ_TYPE_ROOT_BG)
|
||||||
{
|
{
|
||||||
ESelectInputChange(eo->win, VisibilityChangeMask, 0);
|
ESelectInputChange(EobjGetWin(eo), VisibilityChangeMask, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (eo->type != EOBJ_TYPE_EWIN)
|
if (eo->type != EOBJ_TYPE_EWIN)
|
||||||
|
@ -1602,7 +1602,7 @@ ECompMgrWinNew(EObj * eo)
|
||||||
cw->opacity = 0xdeadbeef;
|
cw->opacity = 0xdeadbeef;
|
||||||
ECompMgrWinSetOpacity(eo, eo->opacity);
|
ECompMgrWinSetOpacity(eo, eo->opacity);
|
||||||
|
|
||||||
EventCallbackRegister(eo->win, 0, ECompMgrHandleWindowEvent, eo);
|
EventCallbackRegister(EobjGetWin(eo), 0, ECompMgrHandleWindowEvent, eo);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
@ -1710,7 +1710,7 @@ ECompMgrWinConfigure(EObj * eo, XEvent * ev)
|
||||||
change_wh = EobjGetW(eo) != w || EobjGetH(eo) != h;
|
change_wh = EobjGetW(eo) != w || EobjGetH(eo) != h;
|
||||||
change_bw = EobjGetBW(eo) != bw;
|
change_bw = EobjGetBW(eo) != bw;
|
||||||
|
|
||||||
EWindowSetGeometry(eo->win, x, y, w, h, bw);
|
EWindowSetGeometry(EobjGetWin(eo), x, y, w, h, bw);
|
||||||
|
|
||||||
ECompMgrWinMoveResize(eo, change_xy, change_wh, change_bw);
|
ECompMgrWinMoveResize(eo, change_xy, change_wh, change_bw);
|
||||||
}
|
}
|
||||||
|
@ -1801,7 +1801,7 @@ ECompMgrWinDel(EObj * eo)
|
||||||
if (eo->fading)
|
if (eo->fading)
|
||||||
ECompMgrWinFadeEnd(eo, 1);
|
ECompMgrWinFadeEnd(eo, 1);
|
||||||
|
|
||||||
EventCallbackUnregister(eo->win, 0, ECompMgrHandleWindowEvent, eo);
|
EventCallbackUnregister(EobjGetWin(eo), 0, ECompMgrHandleWindowEvent, eo);
|
||||||
|
|
||||||
if (!eo->gone)
|
if (!eo->gone)
|
||||||
{
|
{
|
||||||
|
|
16
src/edge.c
16
src/edge.c
|
@ -238,14 +238,14 @@ EdgeWindowsShow(void)
|
||||||
w4 = EobjWindowCreate(EOBJ_TYPE_EVENT,
|
w4 = EobjWindowCreate(EOBJ_TYPE_EVENT,
|
||||||
0, WinGetH(VROOT) - 1, WinGetW(VROOT), 1,
|
0, WinGetH(VROOT) - 1, WinGetW(VROOT), 1,
|
||||||
0, "Edge-B");
|
0, "Edge-B");
|
||||||
ESelectInput(w1->win, EnterWindowMask | LeaveWindowMask);
|
ESelectInput(EobjGetWin(w1), EnterWindowMask | LeaveWindowMask);
|
||||||
ESelectInput(w2->win, EnterWindowMask | LeaveWindowMask);
|
ESelectInput(EobjGetWin(w2), EnterWindowMask | LeaveWindowMask);
|
||||||
ESelectInput(w3->win, EnterWindowMask | LeaveWindowMask);
|
ESelectInput(EobjGetWin(w3), EnterWindowMask | LeaveWindowMask);
|
||||||
ESelectInput(w4->win, EnterWindowMask | LeaveWindowMask);
|
ESelectInput(EobjGetWin(w4), EnterWindowMask | LeaveWindowMask);
|
||||||
EventCallbackRegister(w1->win, 0, EdgeHandleEvents, (void *)0);
|
EventCallbackRegister(EobjGetWin(w1), 0, EdgeHandleEvents, (void *)0);
|
||||||
EventCallbackRegister(w2->win, 0, EdgeHandleEvents, (void *)1);
|
EventCallbackRegister(EobjGetWin(w2), 0, EdgeHandleEvents, (void *)1);
|
||||||
EventCallbackRegister(w3->win, 0, EdgeHandleEvents, (void *)2);
|
EventCallbackRegister(EobjGetWin(w3), 0, EdgeHandleEvents, (void *)2);
|
||||||
EventCallbackRegister(w4->win, 0, EdgeHandleEvents, (void *)3);
|
EventCallbackRegister(EobjGetWin(w4), 0, EdgeHandleEvents, (void *)3);
|
||||||
}
|
}
|
||||||
DeskCurrentGetArea(&cx, &cy);
|
DeskCurrentGetArea(&cx, &cy);
|
||||||
DesksGetAreaSize(&ax, &ay);
|
DesksGetAreaSize(&ax, &ay);
|
||||||
|
|
22
src/eobj.c
22
src/eobj.c
|
@ -203,7 +203,7 @@ EobjInit(EObj * eo, int type, Win win, int x, int y, int w, int h,
|
||||||
eo->icccm.wm_name = Estrdup("-?-");
|
eo->icccm.wm_name = Estrdup("-?-");
|
||||||
|
|
||||||
if (type != EOBJ_TYPE_EWIN && type != EOBJ_TYPE_EXT)
|
if (type != EOBJ_TYPE_EWIN && type != EOBJ_TYPE_EXT)
|
||||||
HintsSetWindowName(eo->win, eo->icccm.wm_name);
|
HintsSetWindowName(EobjGetWin(eo), eo->icccm.wm_name);
|
||||||
|
|
||||||
#if USE_COMPOSITE
|
#if USE_COMPOSITE
|
||||||
switch (type)
|
switch (type)
|
||||||
|
@ -240,9 +240,9 @@ EobjFini(EObj * eo)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (eo->external)
|
if (eo->external)
|
||||||
EUnregisterWindow(eo->win);
|
EUnregisterWindow(EobjGetWin(eo));
|
||||||
else
|
else
|
||||||
EDestroyWindow(eo->win);
|
EDestroyWindow(EobjGetWin(eo));
|
||||||
|
|
||||||
Efree(eo->icccm.wm_name);
|
Efree(eo->icccm.wm_name);
|
||||||
Efree(eo->icccm.wm_res_name);
|
Efree(eo->icccm.wm_res_name);
|
||||||
|
@ -269,8 +269,8 @@ EobjWindowCreate(int type, int x, int y, int w, int h, int su, const char *name)
|
||||||
|
|
||||||
eo->floating = 1;
|
eo->floating = 1;
|
||||||
EobjSetLayer(eo, 20);
|
EobjSetLayer(eo, 20);
|
||||||
EobjInit(eo, type, eo->win, x, y, w, h, su, name);
|
EobjInit(eo, type, EobjGetWin(eo), x, y, w, h, su, name);
|
||||||
if (eo->win == None)
|
if (eo->win == NULL)
|
||||||
{
|
{
|
||||||
Efree(eo);
|
Efree(eo);
|
||||||
eo = NULL;
|
eo = NULL;
|
||||||
|
@ -365,7 +365,7 @@ EobjMap(EObj * eo, int raise)
|
||||||
if (eo->shaped < 0)
|
if (eo->shaped < 0)
|
||||||
EobjShapeUpdate(eo, 0);
|
EobjShapeUpdate(eo, 0);
|
||||||
|
|
||||||
EMapWindow(eo->win);
|
EMapWindow(EobjGetWin(eo));
|
||||||
#if USE_COMPOSITE
|
#if USE_COMPOSITE
|
||||||
ECompMgrWinMap(eo);
|
ECompMgrWinMap(eo);
|
||||||
#endif
|
#endif
|
||||||
|
@ -381,7 +381,7 @@ EobjUnmap(EObj * eo)
|
||||||
if (eo->cmhook)
|
if (eo->cmhook)
|
||||||
ECompMgrWinUnmap(eo);
|
ECompMgrWinUnmap(eo);
|
||||||
#endif
|
#endif
|
||||||
EUnmapWindow(eo->win);
|
EUnmapWindow(EobjGetWin(eo));
|
||||||
eo->shown = 0;
|
eo->shown = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -400,7 +400,7 @@ EobjMoveResize(EObj * eo, int x, int y, int w, int h)
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
{
|
{
|
||||||
EMoveResizeWindow(eo->win, x, y, w, h);
|
EMoveResizeWindow(EobjGetWin(eo), x, y, w, h);
|
||||||
}
|
}
|
||||||
#if USE_COMPOSITE
|
#if USE_COMPOSITE
|
||||||
if (eo->cmhook)
|
if (eo->cmhook)
|
||||||
|
@ -438,7 +438,7 @@ EobjReparent(EObj * eo, EObj * dst, int x, int y)
|
||||||
|
|
||||||
move = x != EobjGetX(eo) || y != EobjGetY(eo);
|
move = x != EobjGetX(eo) || y != EobjGetY(eo);
|
||||||
|
|
||||||
EReparentWindow(eo->win, dst->win, x, y);
|
EReparentWindow(EobjGetWin(eo), EobjGetWin(dst), x, y);
|
||||||
if (dst->type == EOBJ_TYPE_DESK)
|
if (dst->type == EOBJ_TYPE_DESK)
|
||||||
{
|
{
|
||||||
Desk *dsk = (Desk *) dst;
|
Desk *dsk = (Desk *) dst;
|
||||||
|
@ -520,9 +520,9 @@ EobjShapeUpdate(EObj * eo, int propagate)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (propagate)
|
if (propagate)
|
||||||
eo->shaped = EShapePropagate(eo->win) != 0;
|
eo->shaped = EShapePropagate(EobjGetWin(eo)) != 0;
|
||||||
else
|
else
|
||||||
eo->shaped = EShapeCheck(eo->win) != 0;
|
eo->shaped = EShapeCheck(EobjGetWin(eo)) != 0;
|
||||||
|
|
||||||
#if USE_COMPOSITE
|
#if USE_COMPOSITE
|
||||||
if (was_shaped <= 0 && eo->shaped <= 0)
|
if (was_shaped <= 0 && eo->shaped <= 0)
|
||||||
|
|
12
src/eobj.h
12
src/eobj.h
|
@ -73,12 +73,12 @@ struct _eobj {
|
||||||
#define EOBJ_TYPE_GLX 8
|
#define EOBJ_TYPE_GLX 8
|
||||||
|
|
||||||
#define EobjGetWin(eo) ((eo)->win)
|
#define EobjGetWin(eo) ((eo)->win)
|
||||||
#define EobjGetXwin(eo) WinGetXwin((eo)->win)
|
#define EobjGetXwin(eo) WinGetXwin(EobjGetWin(eo))
|
||||||
#define EobjGetX(eo) WinGetX((eo)->win)
|
#define EobjGetX(eo) WinGetX(EobjGetWin(eo))
|
||||||
#define EobjGetY(eo) WinGetY((eo)->win)
|
#define EobjGetY(eo) WinGetY(EobjGetWin(eo))
|
||||||
#define EobjGetW(eo) WinGetW((eo)->win)
|
#define EobjGetW(eo) WinGetW(EobjGetWin(eo))
|
||||||
#define EobjGetH(eo) WinGetH((eo)->win)
|
#define EobjGetH(eo) WinGetH(EobjGetWin(eo))
|
||||||
#define EobjGetBW(eo) WinGetBorderWidth((eo)->win)
|
#define EobjGetBW(eo) WinGetBorderWidth(EobjGetWin(eo))
|
||||||
#define EobjGetType(eo) ((eo)->type)
|
#define EobjGetType(eo) ((eo)->type)
|
||||||
#define EobjGetDesk(eo) ((eo)->desk)
|
#define EobjGetDesk(eo) ((eo)->desk)
|
||||||
#define EobjGetName(eo) ((eo)->icccm.wm_name)
|
#define EobjGetName(eo) ((eo)->icccm.wm_name)
|
||||||
|
|
|
@ -1167,8 +1167,8 @@ IPC_ObjInfo(const char *params __UNUSED__)
|
||||||
eo = lst[i];
|
eo = lst[i];
|
||||||
IpcPrintf
|
IpcPrintf
|
||||||
(" %2d %#9lx %2d %d %d %2d/%2d %3d %d %d %3d %5d,%5d %4dx%4d %d %d %s\n",
|
(" %2d %#9lx %2d %d %d %2d/%2d %3d %d %d %3d %5d,%5d %4dx%4d %d %d %s\n",
|
||||||
i, EobjGetXwin(eo), WinGetDepth(eo->win), eo->type, eo->shown,
|
i, EobjGetXwin(eo), WinGetDepth(EobjGetWin(eo)), eo->type,
|
||||||
eo->shaped, EShapeCheck(eo->win), eo->desk->num,
|
eo->shown, eo->shaped, EShapeCheck(EobjGetWin(eo)), eo->desk->num,
|
||||||
eo->sticky, eo->floating, eo->ilayer,
|
eo->sticky, eo->floating, eo->ilayer,
|
||||||
EobjGetX(eo), EobjGetY(eo), EobjGetW(eo), EobjGetH(eo),
|
EobjGetX(eo), EobjGetY(eo), EobjGetW(eo), EobjGetH(eo),
|
||||||
#if USE_COMPOSITE
|
#if USE_COMPOSITE
|
||||||
|
|
|
@ -1033,9 +1033,9 @@ MenuShowMasker(Menu * m __UNUSED__)
|
||||||
|
|
||||||
EobjReparent(eo, EoObj(DesksGetCurrent()), 0, 0);
|
EobjReparent(eo, EoObj(DesksGetCurrent()), 0, 0);
|
||||||
EobjSetLayer(eo, 11);
|
EobjSetLayer(eo, 11);
|
||||||
ESelectInput(eo->win, ButtonPressMask | ButtonReleaseMask |
|
ESelectInput(EobjGetWin(eo), ButtonPressMask | ButtonReleaseMask |
|
||||||
EnterWindowMask | LeaveWindowMask);
|
EnterWindowMask | LeaveWindowMask);
|
||||||
EventCallbackRegister(eo->win, 0, MenuMaskerHandleEvents, NULL);
|
EventCallbackRegister(EobjGetWin(eo), 0, MenuMaskerHandleEvents, NULL);
|
||||||
|
|
||||||
Mode_menus.cover_win = eo;
|
Mode_menus.cover_win = eo;
|
||||||
}
|
}
|
||||||
|
@ -1051,7 +1051,7 @@ MenuHideMasker(void)
|
||||||
if (!eo)
|
if (!eo)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
EventCallbackUnregister(eo->win, 0, MenuMaskerHandleEvents, NULL);
|
EventCallbackUnregister(EobjGetWin(eo), 0, MenuMaskerHandleEvents, NULL);
|
||||||
EobjWindowDestroy(eo);
|
EobjWindowDestroy(eo);
|
||||||
Mode_menus.cover_win = NULL;
|
Mode_menus.cover_win = NULL;
|
||||||
}
|
}
|
||||||
|
|
|
@ -151,12 +151,12 @@ ProgressbarSet(Progressbar * p, int progress)
|
||||||
Esnprintf(s, sizeof(s), "%i%%", p->value);
|
Esnprintf(s, sizeof(s), "%i%%", p->value);
|
||||||
|
|
||||||
EobjResize(p->p_win, w, p->h);
|
EobjResize(p->p_win, w, p->h);
|
||||||
ImageclassApply(p->ic, p->p_win->win, 1, 0, STATE_NORMAL, ST_SOLID);
|
ImageclassApply(p->ic, EobjGetWin(p->p_win), 1, 0, STATE_NORMAL, ST_SOLID);
|
||||||
EobjShapeUpdate(p->p_win, 0);
|
EobjShapeUpdate(p->p_win, 0);
|
||||||
|
|
||||||
pad = ImageclassGetPadding(p->ic);
|
pad = ImageclassGetPadding(p->ic);
|
||||||
EClearWindow(p->n_win->win);
|
EClearWindow(EobjGetWin(p->n_win));
|
||||||
TextDraw(p->tnc, p->n_win->win, None, 0, 0, STATE_CLICKED, s,
|
TextDraw(p->tnc, EobjGetWin(p->n_win), None, 0, 0, STATE_CLICKED, s,
|
||||||
pad->left, pad->top, p->h * 5 - (pad->left + pad->right),
|
pad->left, pad->top, p->h * 5 - (pad->left + pad->right),
|
||||||
p->h - (pad->top + pad->bottom), p->h - (pad->top + pad->bottom),
|
p->h - (pad->top + pad->bottom), p->h - (pad->top + pad->bottom),
|
||||||
TextclassGetJustification(p->tnc));
|
TextclassGetJustification(p->tnc));
|
||||||
|
@ -171,17 +171,18 @@ ProgressbarShow(Progressbar * p)
|
||||||
{
|
{
|
||||||
EImageBorder *pad;
|
EImageBorder *pad;
|
||||||
|
|
||||||
ImageclassApply(p->ic, p->win->win, 0, 0, STATE_NORMAL, ST_SOLID);
|
ImageclassApply(p->ic, EobjGetWin(p->win), 0, 0, STATE_NORMAL, ST_SOLID);
|
||||||
ImageclassApply(p->ic, p->n_win->win, 0, 0, STATE_CLICKED, ST_SOLID);
|
ImageclassApply(p->ic, EobjGetWin(p->n_win), 0, 0, STATE_CLICKED, ST_SOLID);
|
||||||
ImageclassApply(p->ic, p->p_win->win, 1, 0, STATE_NORMAL, ST_SOLID);
|
ImageclassApply(p->ic, EobjGetWin(p->p_win), 1, 0, STATE_NORMAL, ST_SOLID);
|
||||||
|
|
||||||
EobjMap(p->win, 0);
|
EobjMap(p->win, 0);
|
||||||
EobjMap(p->n_win, 0);
|
EobjMap(p->n_win, 0);
|
||||||
EobjMap(p->p_win, 0);
|
EobjMap(p->p_win, 0);
|
||||||
|
|
||||||
pad = ImageclassGetPadding(p->ic);
|
pad = ImageclassGetPadding(p->ic);
|
||||||
TextDraw(p->tc, p->win->win, None, 0, 0, STATE_NORMAL, EobjGetName(p->win),
|
TextDraw(p->tc, EobjGetWin(p->win), None, 0, 0, STATE_NORMAL,
|
||||||
pad->left, pad->top, p->w - (p->h * 5) - (pad->left + pad->right),
|
EobjGetName(p->win), pad->left, pad->top,
|
||||||
|
p->w - (p->h * 5) - (pad->left + pad->right),
|
||||||
p->h - (pad->top + pad->bottom), p->h - (pad->top + pad->bottom),
|
p->h - (pad->top + pad->bottom), p->h - (pad->top + pad->bottom),
|
||||||
TextclassGetJustification(p->tnc));
|
TextclassGetJustification(p->tnc));
|
||||||
|
|
||||||
|
|
|
@ -76,7 +76,7 @@ StartupWindowsCreate(void)
|
||||||
if (!eo)
|
if (!eo)
|
||||||
return;
|
return;
|
||||||
init_win1 = eo;
|
init_win1 = eo;
|
||||||
w1 = eo->win;
|
w1 = EobjGetWin(eo);
|
||||||
win1 = ECreateWindow(w1, x, y, WinGetW(VROOT), WinGetH(VROOT), 0);
|
win1 = ECreateWindow(w1, x, y, WinGetW(VROOT), WinGetH(VROOT), 0);
|
||||||
|
|
||||||
eo = EobjWindowCreate(EOBJ_TYPE_MISC,
|
eo = EobjWindowCreate(EOBJ_TYPE_MISC,
|
||||||
|
@ -84,7 +84,7 @@ StartupWindowsCreate(void)
|
||||||
if (!eo)
|
if (!eo)
|
||||||
return;
|
return;
|
||||||
init_win2 = eo;
|
init_win2 = eo;
|
||||||
w2 = eo->win;
|
w2 = EobjGetWin(eo);
|
||||||
win2 = ECreateWindow(w2, -x, -y, WinGetW(VROOT), WinGetH(VROOT), 0);
|
win2 = ECreateWindow(w2, -x, -y, WinGetW(VROOT), WinGetH(VROOT), 0);
|
||||||
|
|
||||||
EMapWindow(win1);
|
EMapWindow(win1);
|
||||||
|
|
|
@ -83,7 +83,7 @@ TooltipRealize(ToolTip * tt)
|
||||||
EobjChangeOpacity(eo, OpacityFromPercent(Conf.opacity.tooltips));
|
EobjChangeOpacity(eo, OpacityFromPercent(Conf.opacity.tooltips));
|
||||||
tt->win[i] = eo;
|
tt->win[i] = eo;
|
||||||
}
|
}
|
||||||
tt->iwin = ECreateWindow(tt->TTWIN->win, 0, 0, 1, 1, 0);
|
tt->iwin = ECreateWindow(EobjGetWin(tt->TTWIN), 0, 0, 1, 1, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
static ToolTip *
|
static ToolTip *
|
||||||
|
@ -248,7 +248,8 @@ TooltipIclassPaste(ToolTip * tt, const char *ic_name, int x, int y, int *px)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
EImageGetSize(im, &w, &h);
|
EImageGetSize(im, &w, &h);
|
||||||
EImageRenderOnDrawable(im, tt->TTWIN->win, None, EIMAGE_BLEND, x, y, w, h);
|
EImageRenderOnDrawable(im, EobjGetWin(tt->TTWIN), None, EIMAGE_BLEND, x, y,
|
||||||
|
w, h);
|
||||||
|
|
||||||
*px = x + w;
|
*px = x + w;
|
||||||
}
|
}
|
||||||
|
@ -569,7 +570,8 @@ TooltipShow(ToolTip * tt, const char *text, ActionClass * ac, int x, int y)
|
||||||
eo = tt->win[i];
|
eo = tt->win[i];
|
||||||
if (!eo)
|
if (!eo)
|
||||||
continue;
|
continue;
|
||||||
ImageclassApply(tt->iclass[i], eo->win, 0, 0, STATE_NORMAL, ST_TOOLTIP);
|
ImageclassApply(tt->iclass[i], EobjGetWin(eo), 0, 0, STATE_NORMAL,
|
||||||
|
ST_TOOLTIP);
|
||||||
EobjShapeUpdate(eo, 0);
|
EobjShapeUpdate(eo, 0);
|
||||||
EobjMap(eo, 0);
|
EobjMap(eo, 0);
|
||||||
}
|
}
|
||||||
|
@ -577,8 +579,8 @@ TooltipShow(ToolTip * tt, const char *text, ActionClass * ac, int x, int y)
|
||||||
xx = pad->left + iw;
|
xx = pad->left + iw;
|
||||||
|
|
||||||
/* draw the ordinary tooltip text */
|
/* draw the ordinary tooltip text */
|
||||||
TextDraw(tt->tclass, tt->TTWIN->win, None, 0, 0, STATE_NORMAL, text, xx,
|
TextDraw(tt->tclass, EobjGetWin(tt->TTWIN), None, 0, 0, STATE_NORMAL, text,
|
||||||
pad->top, headline_w, headline_h, 17, 512);
|
xx, pad->top, headline_w, headline_h, 17, 512);
|
||||||
|
|
||||||
/* draw the icons and labels, if any */
|
/* draw the icons and labels, if any */
|
||||||
if (ac)
|
if (ac)
|
||||||
|
@ -602,9 +604,9 @@ TooltipShow(ToolTip * tt, const char *text, ActionClass * ac, int x, int y)
|
||||||
|
|
||||||
if (ActionGetEvent(aa) == EVENT_DOUBLE_DOWN)
|
if (ActionGetEvent(aa) == EVENT_DOUBLE_DOWN)
|
||||||
{
|
{
|
||||||
TextDraw(tt->tclass, tt->TTWIN->win, None, 0, 0, STATE_NORMAL,
|
TextDraw(tt->tclass, EobjGetWin(tt->TTWIN), None, 0, 0,
|
||||||
"2x", xx + iw - double_w, y, double_w, heights[i],
|
STATE_NORMAL, "2x", xx + iw - double_w, y, double_w,
|
||||||
17, 0);
|
heights[i], 17, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (ActionGetAnybutton(aa))
|
if (ActionGetAnybutton(aa))
|
||||||
|
@ -654,8 +656,8 @@ TooltipShow(ToolTip * tt, const char *text, ActionClass * ac, int x, int y)
|
||||||
TooltipIclassPaste(tt, "TOOLTIP_KEY_MOD5", x, y, &x);
|
TooltipIclassPaste(tt, "TOOLTIP_KEY_MOD5", x, y, &x);
|
||||||
}
|
}
|
||||||
|
|
||||||
TextDraw(tt->tclass, tt->TTWIN->win, None, 0, 0, STATE_NORMAL, tts,
|
TextDraw(tt->tclass, EobjGetWin(tt->TTWIN), None, 0, 0,
|
||||||
pad->left + icons_width + iw, y,
|
STATE_NORMAL, tts, pad->left + icons_width + iw, y,
|
||||||
labels_width, heights[i], 17, 0);
|
labels_width, heights[i], 17, 0);
|
||||||
y += heights[i];
|
y += heights[i];
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue