Function at 0x498a90
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x4c
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
mov esi, ecx
push str.ahk_autosize
push dword [edi]
call dword [sym.imp.USER32.dll_GetPropW]
mov dword [esp + 0x18], eax
test eax, eax
je 0x498d52
push str.ahk_autosize
push dword [edi]
call dword [sym.imp.USER32.dll_RemovePropW]
mov cl, byte [edi + 7]
mov ebx, closesocket
mov edx, dword [sym.imp.USER32.dll_GetWindowRect]
xor edi, edi
mov byte [esp + 0xf], cl
mov dword [esp + 0x14], ebx
mov dword [esp + 0x10], ebx
cmp dword [esi + 0x10], edi
jbe 0x498b3c
xor ebx, ebx
nop word [eax + eax]
mov eax, dword [esi + 0x18]
cmp byte [ebx + eax + 6], cl
jne 0x498b2f
lea ecx, [esp + 0x48]
push ecx
push dword [ebx + eax]
call edx
mov ecx, dword [esp + 0x14]
cmp ecx, dword [esp + 0x50]
mov edx, dword [sym.imp.USER32.dll_GetWindowRect]
cmovl ecx, dword [esp + 0x50]
mov dword [esp + 0x14], ecx
mov ecx, dword [esp + 0x10]
cmp ecx, dword [esp + 0x54]
cmovl ecx, dword [esp + 0x54]
mov dword [esp + 0x10], ecx
mov cl, byte [esp + 0xf]
inc edi
add ebx, 0x40
cmp edi, dword [esi + 0x10]
jb 0x498af0
mov ebx, dword [esp + 0x14]
mov edi, dword [ebp + 8]
lea eax, [esp + 0x28]
push eax
push dword [edi]
call edx
mov ecx, dword [esp + 0x18]
test cl, 1
je 0x498b65
cmp ebx, 0x80000000
je 0x498b65
mov eax, dword [esi + 0x78]
add eax, 4
add eax, ebx
mov dword [esp + 0x30], eax
test cl, 2
je 0x498b82
cmp ebx, 0x80000000
je 0x498b82
mov ecx, dword [esp + 0x10]
mov eax, dword [esi + 0x7c]
add ecx, 4
add eax, ecx
mov dword [esp + 0x34], eax
push 2
lea eax, [esp + 0x2c]
push eax
push dword [esi + 4]
push 0
call dword [sym.imp.USER32.dll_MapWindowPoints]
mov eax, dword [esp + 0x30]
sub eax, dword [esp + 0x28]
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0x34]
sub eax, dword [esp + 0x2c]
push 0xfffffffffffffff0
push dword [edi]
mov dword [esp + 0x1c], eax
call dword [sym.imp.USER32.dll_GetWindowLongW]
mov ecx, eax
mov dword [esp + 0x20], eax
and ecx, 0x80
mov dword [esp + 0x24], ecx
neg ecx
sbb ecx, ecx
add ecx, 2
and ecx, dword [esp + 0x18]
mov dword [esp + 0x1c], ecx
je 0x498c0c
test al, 2
jne 0x498c0c
push 0
push 0
push 0x132c
push dword [edi]
call dword [sym.imp.USER32.dll_SendMessageW]
push 1
push dword [esp + 0x18]
mov dword [esp + 0x20], eax
push dword [esp + 0x18]
push dword [esp + 0x38]
push dword [esp + 0x38]
push dword [edi]
call dword [sym.imp.USER32.dll_MoveWindow]
jmp 0x498c39
push 1
push dword [esp + 0x18]
push dword [esp + 0x18]
push dword [esp + 0x38]
push dword [esp + 0x38]
push dword [edi]
call dword [sym.imp.USER32.dll_MoveWindow]
cmp dword [esp + 0x1c], 0
mov dword [esp + 0x18], 0
je 0x498ceb
push 0
push 0
push 0x132c
push dword [edi]
call dword [sym.imp.USER32.dll_SendMessageW]
mov dword [esp + 0x1c], eax
cmp dword [esp + 0x18], eax
je 0x498ceb
lea eax, [esp + 0x38]
push eax
push 0
push 0x130a
push dword [edi]
call dword [sym.imp.USER32.dll_SendMessageW]
mov ecx, dword [esp + 0x20]
mov edx, dword [esp + 0x1c]
and ecx, 0x100
neg ecx
sbb ecx, ecx
sub edx, dword [esp + 0x18]
and ecx, 3
cmp dword [esp + 0x24], 0
je 0x498caf
mov eax, dword [esp + 0x40]
sub eax, dword [esp + 0x38]
add eax, ecx
mov ecx, dword [esp + 0x10]
imul eax, edx
add ecx, eax
mov eax, dword [esp + 0x28]
add eax, ecx
mov dword [esp + 0x10], ecx
mov dword [esp + 0x30], eax
jmp 0x498cd4
mov eax, dword [esp + 0x44]
sub eax, dword [esp + 0x3c]
add eax, ecx
mov ecx, dword [esp + 0x14]
imul eax, edx
add ecx, eax
mov eax, dword [esp + 0x2c]
add eax, ecx
mov dword [esp + 0x14], ecx
mov ecx, dword [esp + 0x10]
mov dword [esp + 0x34], eax
push 1
push dword [esp + 0x18]
push ecx
push dword [esp + 0x38]
push dword [esp + 0x38]
push dword [edi]
call dword [sym.imp.USER32.dll_MoveWindow]
mov ecx, dword [esi + 0x10]
mov eax, dword [esi + 0x18]
mov dl, byte [esp + 0xf]
shl ecx, 6
cmp byte [ecx + eax - 0x3a], dl
je 0x498d06
cmp ebx, 0x80000000
jne 0x498d52
mov eax, dword [esp + 0x28]
mov dword [esi + 0x80], eax
mov eax, dword [esp + 0x2c]
mov dword [esi + 0x84], eax
mov eax, dword [esp + 0x10]
mov dword [esi + 0x88], eax
mov eax, dword [esp + 0x14]
mov dword [esi + 0x8c], eax
mov eax, dword [esp + 0x30]
cmp dword [esi + 0x90], eax
jge 0x498d40
mov dword [esi + 0x90], eax
mov eax, dword [esp + 0x34]
cmp dword [esi + 0x94], eax
jge 0x498d52
mov dword [esi + 0x94], eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4