Ack. glPaint is not expensive since plugins will not have their hooks called unless they are running animations on the window and PAINT_WINDOW_NO_CORE_INSTANCE_MASK means that no gl operations occurr
Seems a bit more weird. Primarily because the local invisible variable reflects the window invisible state, which is fine, but then it becomes "invisible or destroyed", which isn't what the variable reflects.
As an aside, this value is then negated in the if statement.
Ack. glPaint is not expensive since plugins will not have their hooks called unless they are running animations on the window and PAINT_WINDOW_ NO_CORE_ INSTANCE_ MASK means that no gl operations occurr
Sent from Samsung Mobile
Tim Penhey <email address hidden> wrote:
Review: Needs Fixing
I'm going to be pedantic here...
> bool isDock = w->type () & CompWindowTypeD ockMask;
This looks fine.
However...
> bool invisible = w->invisible ();
> invisible |= w->destroyed ();
> if (isDock && !invisible)
Seems a bit more weird. Primarily because the local invisible variable reflects the window invisible state, which is fine, but then it becomes "invisible or destroyed", which isn't what the variable reflects.
As an aside, this value is then negated in the if statement.
How about...
bool drawShadow = !w->invisible ();
if (w->destroyed ())
drawShadow = false;
if (isDock && drawShadow)
// ...
Having booleans expressed in the positive are simpler to follow.
bool drawShadow = !(w->invisible () || w-> destroyed ());
Also seems simple enough to follow.
I can't really comment on the internals of the method though. /code.launchpad .net/~compiz- team/compiz/ compiz. fix_1012956/ +merge/ 110268
How expensive is the glPaint call?
--
https:/
Your team Compiz Maintainers is subscribed to branch lp:compiz.