QtPlatformSupport is a static library. Platform plugins are meant to
link against this library to pull in dependencies such as fontengines
and convenience functions for finding the right GL configs. The linker
will only pull in the symbols used, so the size of the library doesn't
really matter
To enable having a single GL context used for multiple drawables we need
to de-couple the context class a bit more from the window class in the
plugin API. Now contexts are created stand-alone based on a GL format
and a share context, and when calling makeCurrent() a desired surface
is specified. This maps well to GLX, EGL, Cocoa, AGL, and WGL, which all
support this use case.
QWindowContext is renamed to QGuiGLContext, and QWindowFormat is renamed
to QGuiGLFormat. We have the ability to introduce a pbuffer or similar
other offscreen GL drawable abstraction in the future.
There seems to be no easy equivalent in the XCB world and the
fallback we currently have is really incomplete. Hence we will
call XLookupString with a fake XKeyEvent if XCB_USE_XLIB is
enabled.
Reviewed-by: Samuel Rødal
Instead we'll let the platform plugins construct
an QEventDispatcherQPA subclass. This API will be
added later on.
This temporarily breaks cocoa, uikit and opencode.
There is a #define DrawText DrawTextW in winuser.h which is included
in windows.h so that the enum value in line 1981 is seen as DrawTextW
and thus is not a valid enum value on Windows.
Reviewed-by: Samuel
Reviewed-by: Lars Knoll
We should not call requestActivateWindow() in
reaction to WM_TAKE_FOCUS. Looks like it should
only be done if the focus should in fact go
to a modal child of the widget.
Do not set the event mask of the window
we drop onto to NO_EVENT. Always use the
clipboards requestor window to convert
selections.
Reviewed-by: Samuel
Ported most of the code to support dragging
from qdnd_x11.cpp to xcb. Some features are still
not working 100% correct, but it's becoming
usable.
Reviewed-by: Samuel
Initial code for DnD on X11. Only Xdnd based,
Motif DnD is being ignored.
The code is currently limited to dropping
stuff onto the application. Starting drags
is not yet implemented.
Reviewed-by: Samuel
I'm not sure what "local" and "global" means for
QWindowSystemInterface::handleMouseEvent. Sending
the mouse position in window coordinates for both
works.
This requires adding a couple of window system interface events, namely
Map, Unmap, and Expose. When a widget is minimized on X11 it is
unmapped, and thus update requests should not be delivered. Instead the
event will delivered when the widget is mapped, which causes an Expose
event to be sent. The Unmap and Expose event thus need to be handled in
QWidgetWindow, and Map is also added for the purpose of API symmetry
(and for future needs).
When an auto-test calls processEvents() indirectly via QTest::qWait(),
QAbstractEventDispatcher::aboutToBlock() doesn't get emitted since
the processEvents() implementation gets called without
the QEventLoop::WaitForMoreEvents flag set. Since the auto-tests depend
on all events getting delivered, we need to process the XCB events on
awake() as well.