- 64 bit fixes to GetWindowLong and callers from Florian

- SetWindowLong now sets a ptrint

git-svn-id: trunk@7446 -
This commit is contained in:
vincents 2005-07-29 22:44:07 +00:00
parent 1db6e42935
commit d2179bb34b
12 changed files with 40 additions and 40 deletions

View File

@ -913,7 +913,7 @@ begin
Result := False; Result := False;
end; end;
function TWidgetSet.GetWindowLong(Handle : hwnd; int : Integer): Longint; function TWidgetSet.GetWindowLong(Handle : hwnd; int : Integer): PtrInt;
begin begin
Result := 0; Result := 0;
end; end;
@ -1356,7 +1356,7 @@ begin
end; end;
function TWidgetSet.SetWindowLong(Handle: HWND; function TWidgetSet.SetWindowLong(Handle: HWND;
Idx: Integer; NewLong : Longint): LongInt; Idx: Integer; NewLong : PtrInt): PtrInt;
begin begin
Result := -1; Result := -1;
end; end;

View File

@ -435,7 +435,7 @@ begin
Result := InterfaceObject.GetTextMetrics(DC, TM); Result := InterfaceObject.GetTextMetrics(DC, TM);
end; end;
function GetWindowLong(Handle : hwnd; int : Integer): Longint; function GetWindowLong(Handle : hwnd; int : Integer): PtrInt;
begin begin
Result := InterfaceObject.GetWindowLong(Handle, int); Result := InterfaceObject.GetWindowLong(Handle, int);
end; end;
@ -764,7 +764,7 @@ begin
Result := InterfaceObject.SetTextColor(DC, Color); Result := InterfaceObject.SetTextColor(DC, Color);
end; end;
function SetWindowLong(Handle: HWND; Idx: Integer; NewLong : Longint): LongInt; function SetWindowLong(Handle: HWND; Idx: Integer; NewLong : PtrInt): PtrInt;
begin begin
Result := InterfaceObject.SetWindowLong(handle, Idx, NewLong); Result := InterfaceObject.SetWindowLong(handle, Idx, NewLong);
end; end;

View File

@ -136,7 +136,7 @@ function GetTextExtentExPoint(DC: HDC; Str: PChar; Count, MaxWidth: Integer; Max
function GetTextExtentPoint(DC: HDC; Str: PChar; Count: Integer; var Size: LCLType.TSize): Boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} function GetTextExtentPoint(DC: HDC; Str: PChar; Count: Integer; var Size: LCLType.TSize): Boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
function GetTextExtentPoint32(DC: HDC; Str: PChar; Count: Integer; var Size: LCLType.TSize): Boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} function GetTextExtentPoint32(DC: HDC; Str: PChar; Count: Integer; var Size: LCLType.TSize): Boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
function GetTextMetrics(DC: HDC; var TM: TTextMetric): Boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} function GetTextMetrics(DC: HDC; var TM: TTextMetric): Boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
function GetWindowLong(Handle : hwnd; int : Integer): Longint; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} function GetWindowLong(Handle : hwnd; int : Integer): PtrInt; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
function GetWindowRect(Handle : hwnd; var Rect : TRect): Integer; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} function GetWindowRect(Handle : hwnd; var Rect : TRect): Integer; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
function GetWindowSize(Handle : hwnd; var Width, Height: integer): boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} function GetWindowSize(Handle : hwnd; var Width, Height: integer): boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
function GetWindowOrgEx(dc : hdc; P : PPoint): Integer; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} function GetWindowOrgEx(dc : hdc; P : PPoint): Integer; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
@ -215,7 +215,7 @@ function SetSysColors(cElements: Integer; const lpaElements; const lpaRgbValues)
function SetTextAlign(DC: HDC; Flags: UINT): UINT; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} function SetTextAlign(DC: HDC; Flags: UINT): UINT; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
Function SetTextCharacterExtra(_hdc : hdc; nCharExtra : Integer):Integer; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} Function SetTextCharacterExtra(_hdc : hdc; nCharExtra : Integer):Integer; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
function SetTextColor(DC: HDC; Color: TColorRef): TColorRef; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} function SetTextColor(DC: HDC; Color: TColorRef): TColorRef; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
function SetWindowLong(Handle: HWND; Idx: Integer; NewLong : Longint): Longint;{$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} function SetWindowLong(Handle: HWND; Idx: Integer; NewLong : PtrInt): PtrInt;{$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
function SetWindowOrgEx(dc : hdc; NewX, NewY : Integer; OldPoint: PPoint): Boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} function SetWindowOrgEx(dc : hdc; NewX, NewY : Integer; OldPoint: PPoint): Boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
function SetWindowPos(hWnd: HWND; hWndInsertAfter: HWND; function SetWindowPos(hWnd: HWND; hWndInsertAfter: HWND;
X, Y, cx, cy: Integer; uFlags: UINT): Boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} X, Y, cx, cy: Integer; uFlags: UINT): Boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}

View File

@ -519,7 +519,7 @@ begin
Result:=inherited GetTextMetrics(DC, TM); Result:=inherited GetTextMetrics(DC, TM);
end; end;
function TCarbonWidgetSet.GetWindowLong(Handle: hwnd; int: Integer): Longint; function TCarbonWidgetSet.GetWindowLong(Handle: hwnd; int: Integer): PtrInt;
begin begin
Result:=inherited GetWindowLong(Handle, int); Result:=inherited GetWindowLong(Handle, int);
end; end;
@ -849,7 +849,7 @@ begin
end; end;
function TCarbonWidgetSet.SetWindowLong(Handle: HWND; Idx: Integer; function TCarbonWidgetSet.SetWindowLong(Handle: HWND; Idx: Integer;
NewLong: Longint): LongInt; NewLong: PtrInt): PtrInt;
begin begin
Result:=inherited SetWindowLong(Handle, Idx, NewLong); Result:=inherited SetWindowLong(Handle, Idx, NewLong);
end; end;

View File

@ -127,7 +127,7 @@ function GetSystemMetrics(nIndex: Integer): Integer; override;
function GetTextColor(DC: HDC) : TColorRef; Override; function GetTextColor(DC: HDC) : TColorRef; Override;
function GetTextExtentPoint(DC: HDC; Str: PChar; Count: Integer; var Size: TSize): Boolean; override; function GetTextExtentPoint(DC: HDC; Str: PChar; Count: Integer; var Size: TSize): Boolean; override;
function GetTextMetrics(DC: HDC; var TM: TTextMetric): Boolean; override; function GetTextMetrics(DC: HDC; var TM: TTextMetric): Boolean; override;
function GetWindowLong(Handle : hwnd; int: Integer): Longint; override; function GetWindowLong(Handle : hwnd; int: Integer): PtrInt; override;
function GetWindowOrgEx(dc : hdc; P: PPoint): Integer; override; function GetWindowOrgEx(dc : hdc; P: PPoint): Integer; override;
function GetWindowRect(Handle : hwnd; var ARect: TRect): Integer; override; function GetWindowRect(Handle : hwnd; var ARect: TRect): Integer; override;
function GetWindowRelativePosition(Handle : hwnd; var Left, Top: integer): boolean; override; function GetWindowRelativePosition(Handle : hwnd; var Left, Top: integer): boolean; override;
@ -193,7 +193,7 @@ function SetScrollInfo(Handle : HWND; SBStyle : Integer; ScrollInfo: TScrollInfo
function SetSysColors(cElements: Integer; const lpaElements; const lpaRgbValues): Boolean; override; function SetSysColors(cElements: Integer; const lpaElements; const lpaRgbValues): Boolean; override;
function SetTextCharacterExtra(_hdc : hdc; nCharExtra : Integer):Integer; override; function SetTextCharacterExtra(_hdc : hdc; nCharExtra : Integer):Integer; override;
function SetTextColor(DC: HDC; Color: TColorRef): TColorRef; override; function SetTextColor(DC: HDC; Color: TColorRef): TColorRef; override;
function SetWindowLong(Handle: HWND; Idx: Integer; NewLong : Longint): LongInt; override; function SetWindowLong(Handle: HWND; Idx: Integer; NewLong : PtrInt): PtrInt; override;
function SetWindowOrgEx(DC : HDC; NewX, NewY : Integer; OldPoint: PPoint) : Boolean; override; function SetWindowOrgEx(DC : HDC; NewX, NewY : Integer; OldPoint: PPoint) : Boolean; override;
function SetWindowPos(hWnd: HWND; hWndInsertAfter: HWND; function SetWindowPos(hWnd: HWND; hWndInsertAfter: HWND;
X, Y, cx, cy: Integer; uFlags: UINT): Boolean; override; X, Y, cx, cy: Integer; uFlags: UINT): Boolean; override;

View File

@ -2100,7 +2100,7 @@ begin
Mess.Msg := LM_NOTIFY; Mess.Msg := LM_NOTIFY;
FillChar(NMHdr,SizeOf(NMHdr),0); FillChar(NMHdr,SizeOf(NMHdr),0);
NMHdr.code := TCN_SELCHANGE; NMHdr.code := TCN_SELCHANGE;
NMHdr.hwndfrom := longint(widget); NMHdr.hwndfrom := ptrint(widget);
NMHdr.idfrom := pagenum; //use this to set pageindex to the correct page. NMHdr.idfrom := pagenum; //use this to set pageindex to the correct page.
Mess.NMHdr := @NMHdr; Mess.NMHdr := @NMHdr;
DeliverMessage(Data, Mess); DeliverMessage(Data, Mess);

View File

@ -51,7 +51,7 @@ begin
msg.Msg := CN_NOTIFY; msg.Msg := CN_NOTIFY;
FillChar(NM, SizeOf(NM), 0); FillChar(NM, SizeOf(NM), 0);
NM.hdr.hwndfrom := longint(AList); NM.hdr.hwndfrom := PtrInt(AList);
NM.hdr.code := LVN_COLUMNCLICK; NM.hdr.code := LVN_COLUMNCLICK;
NM.iItem := -1; NM.iItem := -1;
NM.iSubItem := AColumn; NM.iSubItem := AColumn;

View File

@ -3120,7 +3120,7 @@ procedure TGtkWidgetSet.SetDesigning(AComponent: TComponent);
begin begin
// change cursor // change cursor
if AComponent is TWinControl then if AComponent is TWinControl then
gtkproc.SetCursor(TWinControl(AComponent), TCursor(cardinal(nil))); gtkproc.SetCursor(TWinControl(AComponent), TCursor(PtrUInt(nil)));
end; end;
{------------------------------------------------------------------------------ {------------------------------------------------------------------------------
@ -6876,7 +6876,7 @@ begin
i:=0; i:=0;
while i<LinesList.Count do begin while i<LinesList.Count do begin
// add LineEnd - LineStart + 1 for the #0 // add LineEnd - LineStart + 1 for the #0
LineLen:=Cardinal(LinesList[i+1])-Cardinal(LinesList[i])+1; LineLen:=PtrUInt(LinesList[i+1])-PtrUInt(LinesList[i])+1;
inc(TotalSize,LineLen); inc(TotalSize,LineLen);
inc(i,2); inc(i,2);
end; end;
@ -6891,8 +6891,8 @@ begin
// set the pointer to the start of the current line // set the pointer to the start of the current line
CurLineEntry[i shr 1]:=CurLineStart; CurLineEntry[i shr 1]:=CurLineStart;
// copy the line // copy the line
LineStart:=Integer(LinesList[i]); LineStart:=PtrInt(LinesList[i]);
LineEnd:=Integer(LinesList[i+1]); LineEnd:=PtrInt(LinesList[i+1]);
LineLen:=LineEnd-LineStart; LineLen:=LineEnd-LineStart;
if LineLen>0 then if LineLen>0 then
Move(AText[LineStart],CurLineStart^,LineLen); Move(AText[LineStart],CurLineStart^,LineLen);
@ -6903,7 +6903,7 @@ begin
// next line // next line
inc(i,2); inc(i,2);
end; end;
if Integer(Lines)+TotalSize<>Integer(CurLineStart) then if PtrInt(Lines)+TotalSize<>PtrInt(CurLineStart) then
RaiseException('TGtkWidgetSet.WordWrap Consistency Error:' RaiseException('TGtkWidgetSet.WordWrap Consistency Error:'
+' Lines+TotalSize<>CurLineStart'); +' Lines+TotalSize<>CurLineStart');
CurLineEntry[i shr 1]:=nil; CurLineEntry[i shr 1]:=nil;

View File

@ -830,7 +830,7 @@ var
GdiObject: PGdiObject; GdiObject: PGdiObject;
DefGdkWindow: PGdkWindow; DefGdkWindow: PGdkWindow;
begin begin
Assert(False, Format('Trace:> [TGtkWidgetSet.CreateBitmap] Width: %d, Height: %d, Planes: %d, BitCount: %d, BitmapBits: 0x%x', [Width, Height, Planes, BitCount, Longint(BitmapBits)])); Assert(False, Format('Trace:> [TGtkWidgetSet.CreateBitmap] Width: %d, Height: %d, Planes: %d, BitCount: %d, BitmapBits: 0x%x', [Width, Height, Planes, BitCount, PtrInt(BitmapBits)]));
if (BitCount < 1) or (Bitcount > 32) if (BitCount < 1) or (Bitcount > 32)
then begin then begin
@ -5558,7 +5558,7 @@ end;
Params: none Params: none
Returns: Nothing Returns: Nothing
------------------------------------------------------------------------------} ------------------------------------------------------------------------------}
Function TGtkWidgetSet.GetWindowLong(Handle : hwnd; int : Integer): Longint; Function TGtkWidgetSet.GetWindowLong(Handle : hwnd; int : Integer): PtrInt;
var var
//Data : Tobject; //Data : Tobject;
P : Pointer; P : Pointer;
@ -5569,23 +5569,23 @@ begin
case int of case int of
GWL_WNDPROC : GWL_WNDPROC :
begin begin
Result := Longint(gtk_object_get_data(pgtkobject(Handle),'WNDPROC')); Result := PtrInt(gtk_object_get_data(pgtkobject(Handle),'WNDPROC'));
end; end;
GWL_HINSTANCE : GWL_HINSTANCE :
begin begin
Result := Longint(gtk_object_get_data(pgtkobject(Handle),'HINSTANCE')); Result := PtrInt(gtk_object_get_data(pgtkobject(Handle),'HINSTANCE'));
end; end;
GWL_HWNDPARENT : GWL_HWNDPARENT :
begin begin
P := gtk_object_get_data(pgtkobject(Handle),'HWNDPARENT'); P := gtk_object_get_data(pgtkobject(Handle),'HWNDPARENT');
if P = nil then Result := 0 else Result := LongInt(p); if P = nil then Result := 0 else Result := PtrInt(p);
end; end;
{ GWL_WNDPROC : { GWL_WNDPROC :
begin begin
Data := GetLCLObject(Pointer(Handle)); Data := GetLCLObject(Pointer(Handle));
if Data is TControl if Data is TControl
then Result := Longint(@(TControl(Data).WindowProc)); then Result := PtrInt(@(TControl(Data).WindowProc));
// TODO fix this, a method pointer (2 pointers) cant be casted to a longint // TODO fix this, a method pointer (2 pointers) cant be casted to a longint
end; end;
} }
@ -5593,25 +5593,25 @@ begin
begin begin
Data := GetLCLObject(Pointer(Handle)); Data := GetLCLObject(Pointer(Handle));
if (Data is TWinControl) if (Data is TWinControl)
then Result := Longint(TWincontrol(Data).Handle) then Result := PtrInt(TWincontrol(Data).Handle)
else Result := 0; else Result := 0;
end; end;
} }
GWL_STYLE : GWL_STYLE :
begin begin
Result := Longint(gtk_object_get_data(pgtkobject(Handle),'Style')); Result := PtrInt(gtk_object_get_data(pgtkobject(Handle),'Style'));
end; end;
GWL_EXSTYLE : GWL_EXSTYLE :
begin begin
Result := Longint(gtk_object_get_data(pgtkobject(Handle),'ExStyle')); Result := PtrInt(gtk_object_get_data(pgtkobject(Handle),'ExStyle'));
end; end;
GWL_USERDATA : GWL_USERDATA :
begin begin
Result := Longint(gtk_object_get_data(pgtkobject(Handle),'Userdata')); Result := PtrInt(gtk_object_get_data(pgtkobject(Handle),'Userdata'));
end; end;
GWL_ID : GWL_ID :
begin begin
Result := Longint(gtk_object_get_data(pgtkobject(Handle),'ID')); Result := PtrInt(gtk_object_get_data(pgtkobject(Handle),'ID'));
end; end;
else Result := 0; else Result := 0;
end; //case end; //case
@ -6833,7 +6833,7 @@ const
begin begin
if (Item^.Data <> Pointer(hndMenu)) // exclude ourself if (Item^.Data <> Pointer(hndMenu)) // exclude ourself
and gtk_is_radio_menu_item(Item^.Data) and gtk_is_radio_menu_item(Item^.Data)
and (GroupIndex = Integer(gtk_object_get_data(Item^.Data, GROUPIDX_DATANAME))) and (GroupIndex = PtrInt(gtk_object_get_data(Item^.Data, GROUPIDX_DATANAME)))
then begin then begin
Result := gtk_radio_menu_item_group(PGtkRadioMenuItem(Item^.Data)); Result := gtk_radio_menu_item_group(PGtkRadioMenuItem(Item^.Data));
Exit; Exit;
@ -6876,7 +6876,7 @@ begin
Exit; Exit;
end; end;
CurrentGroupIndex := Integer(gtk_object_get_data(Pointer(hndMenu), GROUPIDX_DATANAME)); CurrentGroupIndex := PtrInt(gtk_object_get_data(Pointer(hndMenu), GROUPIDX_DATANAME));
// Update needed ? // Update needed ?
if GroupIndex = CurrentGroupIndex if GroupIndex = CurrentGroupIndex
@ -7798,7 +7798,7 @@ var
FocusObject: PGTKObject; FocusObject: PGTKObject;
begin begin
FocusObject := PGTKObject(GetFocus); FocusObject := PGTKObject(GetFocus);
Result:=SetCaretPosEx(LongInt(FocusObject),X,Y); Result:=SetCaretPosEx(PtrInt(FocusObject),X,Y);
end; end;
{------------------------------------------------------------------------------ {------------------------------------------------------------------------------
@ -8336,14 +8336,14 @@ end;
------------------------------------------------------------------------------} ------------------------------------------------------------------------------}
function TGtkWidgetSet.SetWindowLong(Handle: HWND; Idx: Integer; function TGtkWidgetSet.SetWindowLong(Handle: HWND; Idx: Integer;
NewLong: Longint): LongInt; NewLong: PtrInt): PtrInt;
var var
Data: Pointer; Data: Pointer;
begin begin
//TODO: Finish this; //TODO: Finish this;
Assert(False, Format('Trace:> [TGtkWidgetSet.SETWINDOWLONG] HWND: 0x%x, idx: 0x%x(%d), Value: 0x%x(%d)', [Handle, idx, idx, newlong, newlong])); Assert(False, Format('Trace:> [TGtkWidgetSet.SETWINDOWLONG] HWND: 0x%x, idx: 0x%x(%d), Value: 0x%x(%d)', [Handle, idx, idx, newlong, newlong]));
Result:=0; Result:=0;
Data := Pointer(PtrInt(NewLong)); Data := Pointer(NewLong);
case idx of case idx of
GWL_WNDPROC : GWL_WNDPROC :
@ -8866,7 +8866,7 @@ begin
FillChar(ev,SizeOf(ev),0); FillChar(ev,SizeOf(ev),0);
ev.any.window := Window; ev.any.window := Window;
Widget := gtk_get_event_widget(@ev); Widget := gtk_get_event_widget(@ev);
Result := Longint(widget); Result := PtrInt(widget);
end; end;
end; end;

View File

@ -123,7 +123,7 @@ function GetSystemMetrics(nIndex: Integer): Integer; override;
function GetTextColor(DC: HDC) : TColorRef; Override; function GetTextColor(DC: HDC) : TColorRef; Override;
function GetTextExtentPoint(DC: HDC; Str: PChar; Count: Integer; var Size: TSize): Boolean; override; function GetTextExtentPoint(DC: HDC; Str: PChar; Count: Integer; var Size: TSize): Boolean; override;
function GetTextMetrics(DC: HDC; var TM: TTextMetric): Boolean; override; function GetTextMetrics(DC: HDC; var TM: TTextMetric): Boolean; override;
Function GetWindowLong(Handle : hwnd; int: Integer): Longint; override; Function GetWindowLong(Handle : hwnd; int: Integer): PtrInt; override;
Function GetWindowOrgEx(dc : hdc; P: PPoint): Integer; override; Function GetWindowOrgEx(dc : hdc; P: PPoint): Integer; override;
Function GetWindowRect(Handle : hwnd; var ARect: TRect): Integer; override; Function GetWindowRect(Handle : hwnd; var ARect: TRect): Integer; override;
function GetWindowRelativePosition(Handle : hwnd; var Left, Top: integer): boolean; override; function GetWindowRelativePosition(Handle : hwnd; var Left, Top: integer): boolean; override;
@ -193,7 +193,7 @@ function SetScrollInfo(Handle : HWND; SBStyle : Integer; ScrollInfo: TScrollInfo
function SetSysColors(cElements: Integer; const lpaElements; const lpaRgbValues): Boolean; override; function SetSysColors(cElements: Integer; const lpaElements; const lpaRgbValues): Boolean; override;
Function SetTextCharacterExtra(_hdc : hdc; nCharExtra : Integer):Integer; override; Function SetTextCharacterExtra(_hdc : hdc; nCharExtra : Integer):Integer; override;
function SetTextColor(DC: HDC; Color: TColorRef): TColorRef; override; function SetTextColor(DC: HDC; Color: TColorRef): TColorRef; override;
function SetWindowLong(Handle: HWND; Idx: Integer; NewLong : Longint): LongInt; override; function SetWindowLong(Handle: HWND; Idx: Integer; PtrInt : Longint): PtrInt; override;
function SetWindowOrgEx(dc : hdc; NewX, NewY : Integer; OldPoint: PPoint) : Boolean; override; function SetWindowOrgEx(dc : hdc; NewX, NewY : Integer; OldPoint: PPoint) : Boolean; override;
function SetWindowPos(hWnd: HWND; hWndInsertAfter: HWND; function SetWindowPos(hWnd: HWND; hWndInsertAfter: HWND;
X, Y, cx, cy: Integer; uFlags: UINT): Boolean; override; X, Y, cx, cy: Integer; uFlags: UINT): Boolean; override;

View File

@ -1973,7 +1973,7 @@ End;
Retrieves information about the specified window. Retrieves information about the specified window.
------------------------------------------------------------------------------} ------------------------------------------------------------------------------}
Function TWin32WidgetSet.GetWindowLong(Handle: HWND; Int: Integer): LongInt; Function TWin32WidgetSet.GetWindowLong(Handle: HWND; Int: Integer): PtrInt;
Begin Begin
//TODO:Started but not finished //TODO:Started but not finished
Assert(False, Format('Trace:> [TWin32WidgetSet.GETWINDOWLONG] HWND: 0x%x, int: 0x%x (%d)', [Handle, int, int])); Assert(False, Format('Trace:> [TWin32WidgetSet.GETWINDOWLONG] HWND: 0x%x, int: 0x%x (%d)', [Handle, int, int]));
@ -2889,7 +2889,7 @@ End;
Changes an attribute of the specified window. Changes an attribute of the specified window.
------------------------------------------------------------------------------} ------------------------------------------------------------------------------}
Function TWin32WidgetSet.SetWindowLong(Handle: HWND; Idx: Integer; NewLong: LongInt): LongInt; Function TWin32WidgetSet.SetWindowLong(Handle: HWND; Idx: Integer; NewLong: PtrInt): PtrInt;
Begin Begin
//TODO: Finish this; //TODO: Finish this;
Assert(False, Format('Trace:> [TWin32WidgetSet.SETWINDOWLONG] HWND: 0x%x, Idx: 0x%x(%d), Value: 0x%x(%d)', [Handle, Idx, Idx, NewLong, NewLong])); Assert(False, Format('Trace:> [TWin32WidgetSet.SETWINDOWLONG] HWND: 0x%x, Idx: 0x%x(%d), Value: 0x%x(%d)', [Handle, Idx, Idx, NewLong, NewLong]));

View File

@ -115,7 +115,7 @@ function GetSystemMetrics(NIndex: Integer): Integer; Override;
function GetTextColor(DC: HDC): TColorRef; Override; function GetTextColor(DC: HDC): TColorRef; Override;
function GetTextExtentPoint(DC: HDC; Str: PChar; Count: Integer; Var Size: TSize): Boolean; Override; function GetTextExtentPoint(DC: HDC; Str: PChar; Count: Integer; Var Size: TSize): Boolean; Override;
function GetTextMetrics(DC: HDC; Var TM: TTextMetric): Boolean; Override; function GetTextMetrics(DC: HDC; Var TM: TTextMetric): Boolean; Override;
function GetWindowLong(Handle: HWND; Int: Integer): LongInt; Override; function GetWindowLong(Handle: HWND; Int: Integer): PtrInt; Override;
function GetWindowOrgEx(DC: HDC; P: PPoint): Integer; Override; function GetWindowOrgEx(DC: HDC; P: PPoint): Integer; Override;
function GetWindowRect(Handle: HWND; Var Rect: TRect): Integer; Override; function GetWindowRect(Handle: HWND; Var Rect: TRect): Integer; Override;
function GetWindowRelativePosition(Handle : HWND; var Left, Top:integer): boolean; Override; function GetWindowRelativePosition(Handle : HWND; var Left, Top:integer): boolean; Override;
@ -175,7 +175,7 @@ function SetScrollInfo(Handle: HWND; SBStyle: Integer; ScrollInfo: TScrollInfo;
function SetSysColors(CElements: Integer; Const LPAElements; Const LPARgbValues): Boolean; Override; function SetSysColors(CElements: Integer; Const LPAElements; Const LPARgbValues): Boolean; Override;
function SetTextCharacterExtra(_HDC: HDC; NCharExtra: Integer): Integer; Override; function SetTextCharacterExtra(_HDC: HDC; NCharExtra: Integer): Integer; Override;
function SetTextColor(DC: HDC; Color: TColorRef): TColorRef; Override; function SetTextColor(DC: HDC; Color: TColorRef): TColorRef; Override;
function SetWindowLong(Handle: HWND; Idx: Integer; NewLong: LongInt): LongInt; Override; function SetWindowLong(Handle: HWND; Idx: Integer; NewLong: PtrInt): PtrInt; Override;
function SetWindowOrgEx(DC: HDC; NewX, NewY: Integer; OldPoint: PPoint): Boolean; Override; function SetWindowOrgEx(DC: HDC; NewX, NewY: Integer; OldPoint: PPoint): Boolean; Override;
function SetWindowPos(HWnd: HWND; HWndInsertAfter: HWND; X, Y, CX, CY: Integer; UFlags: UINT): Boolean; Override; function SetWindowPos(HWnd: HWND; HWndInsertAfter: HWND; X, Y, CX, CY: Integer; UFlags: UINT): Boolean; Override;
function ShowCaret(HWnd: HWND): Boolean; Override; function ShowCaret(HWnd: HWND): Boolean; Override;