mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-17 16:59:20 +02:00
Qt5: changed LongWord -> PtrUInt for all winID functions which uses WId in Qt. issue #35156
git-svn-id: trunk@60525 -
This commit is contained in:
parent
b22e6cf5b2
commit
aabe1d2294
@ -5785,7 +5785,7 @@ function QWindow_visibility(handle: QWindowH): QWindowVisibility; cdecl; externa
|
||||
procedure QWindow_setVisibility(handle: QWindowH; v: QWindowVisibility); cdecl; external Qt5PasLib name 'QWindow_setVisibility';
|
||||
procedure QWindow_createPlatformResources(handle: QWindowH); cdecl; external Qt5PasLib name 'QWindow_createPlatformResources';
|
||||
procedure QWindow_destroyPlatformResources(handle: QWindowH); cdecl; external Qt5PasLib name 'QWindow_destroyPlatformResources';
|
||||
function QWindow_winId(handle: QWindowH): LongWord; cdecl; external Qt5PasLib name 'QWindow_winId';
|
||||
function QWindow_winId(handle: QWindowH): PtrUInt; cdecl; external Qt5PasLib name 'QWindow_winId';
|
||||
function QWindow_parent(handle: QWindowH): QWindowH; cdecl; external Qt5PasLib name 'QWindow_parent';
|
||||
procedure QWindow_setParent(handle: QWindowH; parent: QWindowH); cdecl; external Qt5PasLib name 'QWindow_setParent';
|
||||
function QWindow_isTopLevel(handle: QWindowH): boolean; cdecl; external Qt5PasLib name 'QWindow_isTopLevel';
|
||||
@ -5856,7 +5856,7 @@ procedure QWindow_cursor(handle: QWindowH; retval: QCursorH); cdecl; external Qt
|
||||
procedure QWindow_setCursor(handle: QWindowH; AnonParam1: QCursorH); cdecl; external Qt5PasLib name 'QWindow_setCursor';
|
||||
procedure QWindow_unsetCursor(handle: QWindowH); cdecl; external Qt5PasLib name 'QWindow_unsetCursor';
|
||||
function QWindow_focusObject(handle: QWindowH): QObjectH; cdecl; external Qt5PasLib name 'QWindow_focusObject';
|
||||
function QWindow_fromWinID(id: LongWord): QWindowH; cdecl; external Qt5PasLib name 'QWindow_fromWinId';
|
||||
function QWindow_fromWinID(id: PtrUInt): QWindowH; cdecl; external Qt5PasLib name 'QWindow_fromWinId';
|
||||
procedure QWindow_requestActivate(handle: QWindowH); cdecl; external Qt5PasLib name 'QWindow_requestActivate';
|
||||
procedure QWindow_setVisible(handle: QWindowH; visible: boolean); cdecl; external Qt5PasLib name 'QWindow_setVisible';
|
||||
procedure QWindow_show(handle: QWindowH); cdecl; external Qt5PasLib name 'QWindow_show';
|
||||
@ -5913,10 +5913,10 @@ const
|
||||
function QWidget_Create(parent: QWidgetH = nil; f: QtWindowFlags = 0): QWidgetH; cdecl; external Qt5PasLib name 'QWidget_Create';
|
||||
procedure QWidget_Destroy(handle: QWidgetH); cdecl; external Qt5PasLib name 'QWidget_Destroy';
|
||||
function QWidget_devType(handle: QWidgetH): Integer; cdecl; external Qt5PasLib name 'QWidget_devType';
|
||||
function QWidget_winId(handle: QWidgetH): LongWord; cdecl; external Qt5PasLib name 'QWidget_winId';
|
||||
function QWidget_winId(handle: QWidgetH): PtrUInt; cdecl; external Qt5PasLib name 'QWidget_winId';
|
||||
procedure QWidget_createWinId(handle: QWidgetH); cdecl; external Qt5PasLib name 'QWidget_createWinId';
|
||||
function QWidget_internalWinId(handle: QWidgetH): LongWord; cdecl; external Qt5PasLib name 'QWidget_internalWinId';
|
||||
function QWidget_effectiveWinId(handle: QWidgetH): LongWord; cdecl; external Qt5PasLib name 'QWidget_effectiveWinId';
|
||||
function QWidget_internalWinId(handle: QWidgetH): PtrUInt; cdecl; external Qt5PasLib name 'QWidget_internalWinId';
|
||||
function QWidget_effectiveWinId(handle: QWidgetH): PtrUInt; cdecl; external Qt5PasLib name 'QWidget_effectiveWinId';
|
||||
function QWidget_style(handle: QWidgetH): QStyleH; cdecl; external Qt5PasLib name 'QWidget_style';
|
||||
procedure QWidget_setStyle(handle: QWidgetH; AnonParam1: QStyleH); cdecl; external Qt5PasLib name 'QWidget_setStyle';
|
||||
function QWidget_isTopLevel(handle: QWidgetH): Boolean; cdecl; external Qt5PasLib name 'QWidget_isTopLevel';
|
||||
@ -6137,7 +6137,7 @@ procedure QWidget_setWindowFlags(handle: QWidgetH; _type: QtWindowFlags); cdecl;
|
||||
function QWidget_windowFlags(handle: QWidgetH): QtWindowFlags; cdecl; external Qt5PasLib name 'QWidget_windowFlags';
|
||||
procedure QWidget_overrideWindowFlags(handle: QWidgetH; _type: QtWindowFlags); cdecl; external Qt5PasLib name 'QWidget_overrideWindowFlags';
|
||||
function QWidget_windowType(handle: QWidgetH): QtWindowType; cdecl; external Qt5PasLib name 'QWidget_windowType';
|
||||
function QWidget_find(AnonParam1: LongWord): QWidgetH; cdecl; external Qt5PasLib name 'QWidget_find';
|
||||
function QWidget_find(AnonParam1: PtrUInt): QWidgetH; cdecl; external Qt5PasLib name 'QWidget_find';
|
||||
function QWidget_childAt(handle: QWidgetH; x: Integer; y: Integer): QWidgetH; cdecl; external Qt5PasLib name 'QWidget_childAt';
|
||||
function QWidget_childAt(handle: QWidgetH; p: PQtPoint): QWidgetH; cdecl; external Qt5PasLib name 'QWidget_childAt2';
|
||||
procedure QWidget_setAttribute(handle: QWidgetH; AnonParam1: QtWidgetAttribute; _on: Boolean = True); cdecl; external Qt5PasLib name 'QWidget_setAttribute';
|
||||
@ -6520,7 +6520,7 @@ procedure QScreen_transformBetween(handle: QScreenH; retval: QTransformH; a: QtS
|
||||
procedure QScreen_mapBetween(handle: QScreenH; retval: PRect; a: QtScreenOrientation; b: QtScreenOrientation; AnonParam1: PRect); cdecl; external Qt5PasLib name 'QScreen_mapBetween';
|
||||
function QScreen_isPortrait(handle: QScreenH; orientation: QtScreenOrientation): boolean; cdecl; external Qt5PasLib name 'QScreen_isPortrait';
|
||||
function QScreen_isLandscape(handle: QScreenH; orientation: QtScreenOrientation): boolean; cdecl; external Qt5PasLib name 'QScreen_isLandscape';
|
||||
procedure QScreen_grabWindow(handle: QScreenH; retval: QPixmapH; window: LongWord; x: integer = 0; y: integer = 0; w: integer = -1; h: integer = -1); cdecl; external Qt5PasLib name 'QScreen_grabWindow';
|
||||
procedure QScreen_grabWindow(handle: QScreenH; retval: QPixmapH; window: PtrUInt; x: integer = 0; y: integer = 0; w: integer = -1; h: integer = -1); cdecl; external Qt5PasLib name 'QScreen_grabWindow';
|
||||
function QScreen_refreshRate(handle: QScreenH): qreal; cdecl; external Qt5PasLib name 'QScreen_refreshRate';
|
||||
|
||||
type
|
||||
@ -8954,7 +8954,7 @@ function QPixmap_hasAlpha(handle: QPixmapH): Boolean; cdecl; external Qt5PasLib
|
||||
function QPixmap_hasAlphaChannel(handle: QPixmapH): Boolean; cdecl; external Qt5PasLib name 'QPixmap_hasAlphaChannel';
|
||||
procedure QPixmap_createHeuristicMask(handle: QPixmapH; retval: QBitmapH; clipTight: Boolean = True); cdecl; external Qt5PasLib name 'QPixmap_createHeuristicMask';
|
||||
procedure QPixmap_createMaskFromColor(handle: QPixmapH; retval: QBitmapH; maskColor: PQColor; mode: QtMaskMode = QtMaskInColor); cdecl; external Qt5PasLib name 'QPixmap_createMaskFromColor';
|
||||
procedure QPixmap_grabWindow(retval: QPixmapH; AnonParam1: LongWord; x: Integer = 0; y: Integer = 0; w: Integer = -1; h: Integer = -1); cdecl; external Qt5PasLib name 'QPixmap_grabWindow';
|
||||
procedure QPixmap_grabWindow(retval: QPixmapH; AnonParam1: PtrUInt; x: Integer = 0; y: Integer = 0; w: Integer = -1; h: Integer = -1); cdecl; external Qt5PasLib name 'QPixmap_grabWindow';
|
||||
procedure QPixmap_grabWidget(retval: QPixmapH; widget: QObjectH; rect: PRect); cdecl; external Qt5PasLib name 'QPixmap_grabWidget';
|
||||
procedure QPixmap_grabWidget(retval: QPixmapH; widget: QObjectH; x: Integer = 0; y: Integer = 0; w: Integer = -1; h: Integer = -1); cdecl; external Qt5PasLib name 'QPixmap_grabWidget2';
|
||||
procedure QPixmap_scaled(handle: QPixmapH; retval: QPixmapH; w: Integer; h: Integer; aspectMode: QtAspectRatioMode = QtIgnoreAspectRatio; mode: QtTransformationMode = QtFastTransformation); cdecl; external Qt5PasLib name 'QPixmap_scaled';
|
||||
|
@ -258,7 +258,7 @@ type
|
||||
{$IFDEF HASX11}
|
||||
function IsWayland: Boolean; {this is not X11 but wayland !}
|
||||
function IsCurrentDesktop(AWidget: QWidgetH): Boolean;
|
||||
function X11Raise(AHandle: HWND): boolean;
|
||||
function X11Raise(AHandle: PtrUInt): boolean;
|
||||
function X11GetActiveWindow: QWidgetH;
|
||||
function GetWindowManager: String;
|
||||
function SetTransientForHint(Widget: QWidgetH; ATransientWin: QWidgetH): boolean;
|
||||
@ -270,18 +270,18 @@ type
|
||||
{check KDE session version. Possible results are > 2, -1 means not running under KDE}
|
||||
function GetKdeSessionVersion: integer;
|
||||
{force mapping}
|
||||
procedure MapX11Window(AWinID: LongWord);
|
||||
procedure MapX11Window(AWinID: PtrUInt);
|
||||
{$IFDEF QtUseAccurateFrame}
|
||||
function GetX11WindowRealized(AWinID: LongWord): boolean;
|
||||
function GetX11WindowAttributes(AWinID: LongWord; out ALeft, ATop, AWidth, AHeight, ABorder: integer): boolean;
|
||||
function GetX11SupportedAtoms(AWinID: LongWord; AList: TStrings): boolean;
|
||||
function GetX11WindowRealized(AWinID: PtrUInt): boolean;
|
||||
function GetX11WindowAttributes(AWinID: PtrUInt; out ALeft, ATop, AWidth, AHeight, ABorder: integer): boolean;
|
||||
function GetX11SupportedAtoms(AWinID: PtrUInt; AList: TStrings): boolean;
|
||||
{Ask for _NET_FRAME_EXTENTS,_KDE_NET_WM_SHADOW,_GTK_NET_FRAME_EXTENTS}
|
||||
function GetX11RectForAtom(AWinID: LongWord; const AAtomName: string; out ARect: TRect): boolean;
|
||||
function GetX11WindowPos(AWinID: LongWord; out ALeft, ATop: integer): boolean;
|
||||
function SetX11WindowPos(AWinID: LongWord; const ALeft, ATop: integer): boolean;
|
||||
function GetX11WindowGeometry(AWinID: LongWord; out ARect: TRect): boolean;
|
||||
function GetX11RectForAtom(AWinID: PtrUInt; const AAtomName: string; out ARect: TRect): boolean;
|
||||
function GetX11WindowPos(AWinID: PtrUInt; out ALeft, ATop: integer): boolean;
|
||||
function SetX11WindowPos(AWinID: PtrUInt; const ALeft, ATop: integer): boolean;
|
||||
function GetX11WindowGeometry(AWinID: PtrUInt; out ARect: TRect): boolean;
|
||||
{check if wm supports request for frame extents}
|
||||
function AskX11_NET_REQUEST_FRAME_EXTENTS(AWinID: LongWord; out AMargins: TRect): boolean;
|
||||
function AskX11_NET_REQUEST_FRAME_EXTENTS(AWinID: PtrUInt; out AMargins: TRect): boolean;
|
||||
{$ENDIF}
|
||||
{$ENDIF}
|
||||
|
||||
|
@ -742,7 +742,7 @@ var
|
||||
Desc: TRawImageDescription absolute ARawImage.Description;
|
||||
|
||||
//SrcWidth, SrcHeight: Integer;
|
||||
WinID: Cardinal;
|
||||
WinID: PtrUInt;
|
||||
DCSize: TSize;
|
||||
Pixmap: TQtPixmap;
|
||||
Image: QImageH;
|
||||
|
@ -1869,7 +1869,7 @@ var
|
||||
ATempWidget: QWidgetH;
|
||||
R: TRect;
|
||||
ASize, AFrameSize: TSize;
|
||||
AID: LongWord;
|
||||
AID: PtrUInt;
|
||||
I: integer;
|
||||
B: Boolean;
|
||||
ATicks: DWORD;
|
||||
|
@ -495,7 +495,7 @@ type
|
||||
function getHeight: Integer;
|
||||
function getWidth: Integer;
|
||||
procedure grabWidget(AWidget: QWidgetH; x: Integer = 0; y: Integer = 0; w: Integer = -1; h: Integer = -1);
|
||||
procedure grabWindow(p1: Cardinal; x: Integer = 0; y: Integer = 0; w: Integer = -1; h: Integer = -1);
|
||||
procedure grabWindow(p1: PtrUInt; x: Integer = 0; y: Integer = 0; w: Integer = -1; h: Integer = -1);
|
||||
procedure toImage(retval: QImageH);
|
||||
class procedure fromImage(retval: QPixmapH; image: QImageH; flags: QtImageConversionFlags = QtAutoColor);
|
||||
end;
|
||||
@ -3705,7 +3705,7 @@ begin
|
||||
QPixmap_grabWidget(FHandle, AWidget, x, y, w, h);
|
||||
end;
|
||||
|
||||
procedure TQtPixmap.grabWindow(p1: Cardinal; x: Integer; y: Integer; w: Integer; h: Integer);
|
||||
procedure TQtPixmap.grabWindow(p1: PtrUInt; x: Integer; y: Integer; w: Integer; h: Integer);
|
||||
begin
|
||||
QPixmap_grabWindow(FHandle, p1, x, y, w, h);
|
||||
end;
|
||||
|
@ -6789,7 +6789,6 @@ begin
|
||||
with SrcQDC.getDeviceSize do
|
||||
TmpPixmap := QPixmap_create(x, y);
|
||||
QScreen_grabWindow(QGuiApplication_primaryScreen, TmpPixmap, QWidget_winId(SrcQDC.Parent), 0, 0);
|
||||
// QPixmap_grabWindow(TmpPixmap, QWidget_winId(SrcQDC.Parent), 0, 0);
|
||||
Image := QImage_create();
|
||||
QPixmap_toImage(TmpPixmap, Image);
|
||||
QPixmap_destroy(TmpPixmap);
|
||||
|
@ -112,7 +112,7 @@ begin
|
||||
end;
|
||||
end;
|
||||
|
||||
function X11Raise(AHandle: HWND): boolean;
|
||||
function X11Raise(AHandle: PtrUInt): boolean;
|
||||
var
|
||||
Display: PDisplay;
|
||||
RootWin: TWindow;
|
||||
@ -248,7 +248,7 @@ end;
|
||||
function SetTransientForHint(Widget: QWidgetH; ATransientWin: QWidgetH): boolean;
|
||||
var
|
||||
Display: PDisplay;
|
||||
AWin: LongWord;
|
||||
AWin: PtrUInt;
|
||||
begin
|
||||
Result := False;
|
||||
if Widget = nil then
|
||||
@ -380,14 +380,14 @@ begin
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure MapX11Window(AWinID: LongWord);
|
||||
procedure MapX11Window(AWinID: PtrUInt);
|
||||
begin
|
||||
XMapWindow(QX11Info_display(), TWindow(AWinID));
|
||||
end;
|
||||
|
||||
{$IFDEF QtUseAccurateFrame}
|
||||
|
||||
function GetX11WindowRealized(AWinID: LongWord): boolean;
|
||||
function GetX11WindowRealized(AWinID: PtrUInt): boolean;
|
||||
var
|
||||
d: PDisplay;
|
||||
AXWinAttr: TXWindowAttributes;
|
||||
@ -398,7 +398,7 @@ begin
|
||||
Result := (AXWinAttr.map_installed > 0) and (AXWinAttr.map_state = 2);
|
||||
end;
|
||||
|
||||
function GetX11WindowAttributes(AWinID: LongWord; out ALeft, ATop, AWidth, AHeight, ABorder: integer): boolean;
|
||||
function GetX11WindowAttributes(AWinID: PtrUInt; out ALeft, ATop, AWidth, AHeight, ABorder: integer): boolean;
|
||||
var
|
||||
d: PDisplay;
|
||||
Attr: TXWindowAttributes;
|
||||
@ -422,7 +422,7 @@ begin
|
||||
end;
|
||||
end;
|
||||
|
||||
function GetX11WindowPos(AWinID: LongWord; out ALeft, ATop: integer): boolean;
|
||||
function GetX11WindowPos(AWinID: PtrUInt; out ALeft, ATop: integer): boolean;
|
||||
var
|
||||
D: PDisplay;
|
||||
ARootWindow, AChildWin: TWindow;
|
||||
@ -442,7 +442,7 @@ begin
|
||||
Result := (AXWinAttr.map_installed > 0) and (AXWinAttr.map_state = 2);
|
||||
end;
|
||||
|
||||
function SetX11WindowPos(AWinID: LongWord; const ALeft, ATop: integer): boolean;
|
||||
function SetX11WindowPos(AWinID: PtrUInt; const ALeft, ATop: integer): boolean;
|
||||
var
|
||||
D: PDisplay;
|
||||
ARootWindow, AChildWin: TWindow;
|
||||
@ -462,10 +462,10 @@ var
|
||||
function propNotifyFrameExtents({%H-}ADisplay: PDisplay; AEvent:PXEvent;
|
||||
AData : TXPointer): TBoolResult;cdecl;
|
||||
var
|
||||
AWin: PLongWord;
|
||||
AWin: PPtrUInt;
|
||||
begin
|
||||
Result := False;
|
||||
AWin := PLongWord(AData);
|
||||
AWin := PPtrUInt(AData);
|
||||
if (AEvent^.xany.window = AWin^) then
|
||||
inc(InternalExtentsCounter);
|
||||
if (AEvent^.xany._type = PropertyNotify) and (AEvent^.xany.window = AWin^) then
|
||||
@ -480,7 +480,7 @@ begin
|
||||
end;
|
||||
end;
|
||||
|
||||
function AskX11_NET_REQUEST_FRAME_EXTENTS(AWinID: LongWord; out AMargins: TRect): boolean;
|
||||
function AskX11_NET_REQUEST_FRAME_EXTENTS(AWinID: PtrUInt; out AMargins: TRect): boolean;
|
||||
var
|
||||
AAtom: TAtom;
|
||||
AEvent: TXEvent;
|
||||
@ -545,7 +545,7 @@ begin
|
||||
end;
|
||||
end;
|
||||
|
||||
function GetX11WindowGeometry(AWinID: LongWord; out ARect: TRect): boolean;
|
||||
function GetX11WindowGeometry(AWinID: PtrUInt; out ARect: TRect): boolean;
|
||||
var
|
||||
d: PDisplay;
|
||||
ARootWin, X11Window: TWindow;
|
||||
@ -578,7 +578,7 @@ type
|
||||
PUint32 = PDWord;
|
||||
{$ENDIF}
|
||||
|
||||
function GetX11RectForAtom(AWinID: LongWord; const AAtomName: string; out ARect: TRect): boolean;
|
||||
function GetX11RectForAtom(AWinID: PtrUInt; const AAtomName: string; out ARect: TRect): boolean;
|
||||
var
|
||||
d: PDisplay;
|
||||
X11Window: TWindow;
|
||||
@ -656,7 +656,7 @@ begin
|
||||
end;
|
||||
end;
|
||||
|
||||
function GetX11SupportedAtoms(AWinID: LongWord; AList: TStrings): boolean;
|
||||
function GetX11SupportedAtoms(AWinID: PtrUInt; AList: TStrings): boolean;
|
||||
var
|
||||
d: PDisplay;
|
||||
ARoot: TWindow;
|
||||
|
Loading…
Reference in New Issue
Block a user