ActivateActCtx PROTO :QWORD,:QWORD
AddAtomA PROTO :QWORD
AddAtom equ <AddAtomA>
AddAtomW PROTO :QWORD
AddConsoleAliasA PROTO :QWORD,:QWORD,:QWORD
AddConsoleAlias equ <AddConsoleAliasA>
AddConsoleAliasW PROTO :QWORD,:QWORD,:QWORD
AddLocalAlternateComputerNameA PROTO :QWORD,:QWORD
AddLocalAlternateComputerName equ <AddLocalAlternateComputerNameA>
.
.
.
Add typedef proto stdcall :HBITMAP,:HBITMAP,:ptr DWORDIMHO it would be better idea to concentrate on going through WinInc and recheck everything to work properly,
ReplaceIcon typedef proto stdcall :DWORD,:HICON,:ptr DWORD
SetOverlayImage typedef proto stdcall :DWORD,:DWORD
Replace typedef proto stdcall :DWORD,:HBITMAP,:HBITMAP
AddMasked typedef proto stdcall :HBITMAP,:COLORREF,:ptr DWORD
Draw typedef proto stdcall :ptr IMAGELISTDRAWPARAMS
Remove typedef proto stdcall :DWORD
GetIcon typedef proto stdcall :DWORD,:DWORD,:ptr HICON
So, wParam, lParam and uMsg are 32 bits, hWnd is 64 bits, but you can consider use 64 bits because that fact above.
WndProc proc hWnd:HWND, uMsg:UINT, wParam:WPARAM, lParam:LPARAMYes, wParam and lParam are qwords, thanks for correct.
WndProc proc hWnd:QWORD, uMsg:DWORD, wParam:QWORD, lParam:QWORD
So, I think it's better define types exactlyYes, that is why WinInc is the best solution.
WndProc proc hWnd:HWND, uMsg:UINT, wParam:WPARAM, lParam:LPARAMWndProc proc hWnd:QWORD, uMsg:QWORD, wParam:QWORD, lParam:QWORDHow many more years I have to spend in OZ to start thinking upside down
Microsoft "mystery bag" style of header files:Code: [Select]WndProc proc hWnd:HWND, uMsg:UINT, wParam:WPARAM, lParam:LPARAM
opposite to perfectly clear what we are doing:Code: [Select]WndProc proc hWnd:QWORD, uMsg:QWORD, wParam:QWORD, lParam:QWORD
option casemap : none
option win64 : 11
option frame : auto
option stackbase : rsp
.nolist
.nocref
WINVER EQU 600h
WIN32_LEAN_AND_MEAN equ 1
_WIN64 EQU 1
include windows.inc
include string.inc
include guiddef.inc
include regexpfunc.inc
include CommCtrl.inc
include winbase.inc
include shellapi.inc
include winuser.inc
include commdlg.inc
include Richedit.inc
include OLE2.inc
include windef.inc
include AkelBuild.inc
include AkelEdit.inc
.list
.cref
includelib advapi32.lib
includelib user32.lib
includelib kernel32.lib
includelib gdi32.lib
includelib comctl32.lib
includelib Shell32.lib
includelib comdlg32.lib
includelib Ole32.lib
includelib uuid.lib
In WinInc 64-bit includes, how many different names are there that all mean, simply, QWORD? I guess it's at least 100. For assembler none of them are necessary.
but I prefer:
mov wc.style, CS_HREDRAW or CS_VREDRAW
.data
wcx WNDCLASSEX <WNDCLASSEX, MyWinStyle, WndProc, 0, 0, 1, 2, 3, COLOR_BTNFACE+1, 0, txClass, 4>
wc equ [ebx.WNDCLASSEX] ; we use an equate for better readability
.code
mov ebx, offset wcx
int 3
m2m wc.style, CS_HREDRAW or CS_VREDRAW ; 5 bytes short
mov wc.style, CS_HREDRAW or CS_VREDRAW ; 7 bytes long
mov wc.hInstance, rv(GetModuleHandle, 0)
0040107D ³? 6A 03 push 3 ; ³
0040107F ³? 8F43 04 pop dword ptr [ebx+4]
00401082 ³? C743 04 03000000 mov dword ptr [ebx+4], 3
00401089 ³? 6A 00 push 0 ; ³
0040108B ³. E8 AA050000 call <jmp.&kernel32.GetModuleHandleA> ; ³hInst = 0040163A ('MiniWin')
00401090 ³? 8943 14 mov [ebx+14], eax add wc.style, CS_HREDRAW or CS_VREDRAW