summaryrefslogtreecommitdiff
path: root/futureplans.md
diff options
context:
space:
mode:
authorPietro Gagliardi <[email protected]>2014-04-09 13:22:16 -0400
committerPietro Gagliardi <[email protected]>2014-04-09 13:22:16 -0400
commitbfb259da273e13be02cb2dc637af737e4e694a72 (patch)
treed52bc18eaf88e63f73e229dc1381fab5823fd762 /futureplans.md
parente395adb214af94c43302eb15fb4c2d1e1fed10a5 (diff)
Tried to resolve the use a single window class for each type of custom window TODO; found it was nothing but problems, so moved to future plans.
Diffstat (limited to 'futureplans.md')
-rw-r--r--futureplans.md8
1 files changed, 8 insertions, 0 deletions
diff --git a/futureplans.md b/futureplans.md
index 54d99c3..6150f69 100644
--- a/futureplans.md
+++ b/futureplans.md
@@ -76,6 +76,14 @@ big things:
- don't worry about UI state messages yet; this is before opening the UI anyway (these might be needed when we add tab stops)
- http://msdn.microsoft.com/en-us/library/windows/desktop/ms644898%28v=vs.85%29.aspx GWLP_ID
+big dumb things:
+- for our two custom window classes on Windows, we should allocate extra space in the window class's info structure and then use SetWindowLongPtrW() during WM_CREATE to store the sysData and not have to make a new window class each time; this might also fix the s != nil && s.hwnd != 0 special cases in the Area WndProc if done right
+ - references: https://github.com/glfw/glfw/blob/master/src/win32_window.c#L182, http://www.catch22.net/tuts/custom-controls
+ - this is a bit flakier as SetWindowLongPtr() can fail, and it can also succeed in such a way that the last error is unreliable
+ - and doesn't exist on 32-bit windows; we will need special code for detecting 32-bit/64-bit (see http://bugs.winehq.org/show_bug.cgi?id=30556 and GerbilSoft in irc.badnik.net/#retro)
+ - also CreateWindow() and CreateWindowEx() docs differ in indicating which messages are sent but ultimately send the same set; WM_GETMINMAXINFO is sent first so that throws a wrench in the whole point, AND we'll need a way to properly differentiate between custom classes and controls...
+ - tl;dr what started as a somewhat quick change was really way too much effort for only potential/theoretical gain; approach if someone actually DOES hit Go's syscall.NewCallback() limit
+
specifics:
WINDOWS