Fixed the unregistered window class error on 64-bit Windows: turns out it was a difference in Go's int vs. what Windows expected (thanks Microsoft for not using your special types here). Fixed all instances of this, even in unmigrated/. Still does not work in wine...

This commit is contained in:
Pietro Gagliardi 2014-02-21 02:27:59 -05:00
parent bd51e3e9a7
commit e39a5d928c
3 changed files with 13 additions and 12 deletions

View File

@ -75,8 +75,8 @@ func stdWndProc(s *sysData) func(hwnd _HWND, uMsg uint32, wParam _WPARAM, lParam
type _WNDCLASS struct {
style uint32
lpfnWndProc uintptr
cbClsExtra int
cbWndExtra int
cbClsExtra int32 // originally int
cbWndExtra int32 // originally int
hInstance _HANDLE
hIcon _HANDLE
hCursor _HANDLE

View File

@ -27,8 +27,9 @@ important things:
super ultra important things:
- for some reason events are now delayed on windows
- the windows build appears to be unstable:
- 64-bit doesn't work, period: it crashes in malloc in wine with heap corruption warnings aplenty during DLL loading; in windows 7 CreateWindowExW complains about an unregistered window class, yet the RegisterClassW appears to have succeeded and examining the stack in WinDbg indicates the correct class name is being sent (see below)
- 64-bit doesn't work, period: it crashes in malloc in wine with heap corruption warnings aplenty during DLL loading; in windows 7 it works fine
- 32-bit: it works now, but if I save the class name converted to UTF-16 beforehand, wine indicates that the class name is replaced with the window title, so something there is wrong...
- on 64-bit windows 7 comboboxes don't show their lists
- handle in-library panics (internal errors) by reporting them to the user
- david wendt is telling me he's getting frequent crashes on his end with the GTK+ amd64 build...
- I get soft deadlock if I mash the Click Me button repeatedly

View File

@ -30,17 +30,17 @@ type LOGFONT struct {
type NONCLIENTMETRICS struct {
cbSize uint32
iBorderWidth int
iScrollWidth int
iScrollHeight int
iCaptionWidth int
iCaptionHeight int
iBorderWidth int32 // originally int
iScrollWidth int32 // originally int
iScrollHeight int32 // originally int
iCaptionWidth int32 // originally int
iCaptionHeight int32 // originally int
lfCaptionFont LOGFONT
iSmCaptionWidth int
iSmCaptionHeight int
iSmCaptionWidth int32 // originally int
iSmCaptionHeight int32 // originally int
lfSmCaptionFont LOGFONT
iMenuWidth int
iMenuHeight int
iMenuWidth int32 // originally int
iMenuHeight int32 // originally int
lfMenuFont LOGFONT
lfStatusFont LOGFONT
lfMessageFont LOGFONT