There's no point in painting if it can't be seen anyway. We also make sure
to request a repaint when un-minimizing, so the window gets a chance to
repaint itself then.
Use this in Terminal to tell the window server to not bother with the alpha
channel in the backing store if we're running without transparency.
Semi-transparent terminals look neat but they slow everything down, so this
keeps things fast while making it easy to switch to the flashy mode. :^)
This widget is automatically included in GStatusBar, but can be added in
any other place, too. When clicked (with the left button), it initiates a
window resize (using a WM request.)
In this patch I also fixed up some issues with override cursors being
cleared after the WindowServer finishes a drag or resize.
Since the sockets we use are non-blocking, just slap a select before the
second call to read(). This fixes some flakiness seen under load.
This should eventually work a bit differently, we could use recv() once
it has MSG_WAITALL, and we should not let WindowServer handle all the
client connections on the main thread. But for now, this works.
Fixes#24.
The threading API's are not very mature, so this code looks a bit crufty
but it does take the load off the WindowServer main thread when changing
wallpapers. :^)
They show up as checkable GButtons in GToolBar, and with (or without) check
marks in menus.
There are a bunch of places to make use of this. This patch only takes
advantage of it in the FileManager for the view type actions.
To get truly atomic updates, add a mechanism for passing arbitrary amounts
of extra data along with WindowServer messages. This allows us to pass all
the rects in a single message.
Don't send unnecessarily large paint requests to clients. This avoids some
unnecessary work and fixes choppiness when dragging widgets outside the
visible part of a VisualBuilder form.
This patch moves to sending up to 32 rects at a time when coordinating the
painting between WindowServer and its clients. Rects are also merged into
a minimal DisjointRectSet on the server side before painting.
Interactive resize looks a lot better after this change, since we can
usually do all the repainting needed in one go.
This was pretty straightforward thanks to the work I did separating out
LibCore from LibGUI already. :^)
- WSMessageLoop now inherits from CEventLoop.
- WSMessage now inherits from CEvent.
- WSMessageReceiver goes away.
Now there is only one event loop in Serenity. Very nice!