Post Reply 
Strange error in an input form
01-20-2020, 01:48 PM
Post: #2
RE: Strange error in an input form
You wrote a message handler for message BINT15, also known as IfMsgOK, which (when handled) expects a TRUE or FALSE specifying whether the OK key press should be ignored. You gave it a menu back instead. Whoops. You're probably looking for IfMsgGetMenu, which is message BINT11.
The main piece of code looks fine otherwise, but the menu does not. It appears you copied bits out of ROMPTR2 ~IfMenuRow1 and ROMPTR2 ~IfMenuRow2 (while dropping an important 5GETLAM too, right after the TakeOver for your third menu key), which is the menu for the old input form engine (DoInputForm). You're starting the new input form engine though (FPTR2 ^IfMain); the two are incompatible.
Try decompiling the ROM at 4:5A8DC, that's the piece of code that builds the new input form engine's menu, including calling the input form's message handler with messages BINT12 (IfMsgGet3KeysMenu) and BINT11 (IfMsgGetMenu). You'll find all the default menu keys somewhere in there, so you can cobble together a menu just like you did with the old engine's keys. I'm not quite sure why you're altering the menu though, because if you only use default key definitions, you could save some effort and leave it untouched.
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
Strange error in an input form - cahlucas - 01-19-2020, 08:00 PM
RE: Strange error in an input form - 3298 - 01-20-2020 01:48 PM



User(s) browsing this thread: 1 Guest(s)