diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2020-10-21 17:41:53 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2020-10-22 08:06:15 +0200 |
commit | 5d422c0348efd1df6b3d44dd6efcf5c5490fc321 (patch) | |
tree | 5e52ab80f83161e8dc4bb3960dc63aa94bc99883 /fpicker | |
parent | 2976590ed9f727c24064c97d80a51e9891253119 (diff) |
Revert "sal_uIntPtr->unsigned long in SystemEnvData"
This reverts commit c0f1d211eff5f89f5c9298743f6e7d91d187b799, which states that
it changed the type of UNX-only SystemEnvData::aWindow from sal_uIntPtr to
unsigned long "to match the type used by X11". (And while resource IDs used for
windows etc. are apparently 32-bit in the X11 protocol, see e.g.
<https://www.x.org/releases/X11R7.7/doc/xproto/x11protocol.html>, Xlib and the
underlying /usr/include/X11/Xdefs.h indeed appear to be somewhat confused
whether the typedef for XID should be unsigned long (presumably stemming from
times when long was universally 32-bit) or CARD32, see e.g.
<https://gitlab.freedesktop.org/xorg/proto/xorgproto/-/blob/master/include/X11/
Xdefs.h>.)
But at least for GTK3/Wayland, the sal_uIntPtr values returned by
GtkSalFrame::GetNativeWindowHandle (in vcl/unx/gtk3/gtk3gtkframe.cxx, and which
are stored in SystemEnvData::aWindow in GtkSalFrame::InitCommon,
vcl/unx/gtk3/gtk3gtkframe.cxx, and GtkSalObjectBase::Init,
vcl/unx/gtk3/gtk3gtkobject.cxx) as
> return reinterpret_cast<sal_uIntPtr>(gdk_wayland_window_get_wl_surface(pWindow));
are struct wl_surface* values, so sal_uIntPtr looks like the overall more
appropriate type after all.
(The part of c0f1d211eff5f89f5c9298743f6e7d91d187b799 that dropped the somewhat
needless C-style-cast converting aWindow from sal_uIntPtr to sal_IntPtr in
SystemChildWindow::GetParentWindowHandle, vcl/source/window/syschild.cxx, has
not been reverted, though.)
Change-Id: I8fea062126eacd2d6dc44dab14d5240c4b9946e9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104639
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'fpicker')
0 files changed, 0 insertions, 0 deletions