PDA

View Full Version : Accessing fields no longer available in onFirstLayout



GKEnialb
May 25th, 2025, 21:20
I took over Misc Annotations (https://forge.fantasygrounds.com/shop/items/567/view) and all was going well until the update last month, where some of the character sheet fields changed type (like the Misc box on the skills page of the 3.5 character sheet changed from basicnumber to number_listitem_right), with the end result being they don't get onInit() or onFirstLayout() being called anymore. The annotation was added in onFirstLayout() by checking the name of the field, which was handy. Basically, I check if the name is Misc (or some other fields that users requested), then associates a new DB node with it that fancy stuff can be done to. Any advice on if there's a similar hook to onFirstLayout() for a number_listitem_right?

Moon Wizard
May 25th, 2025, 23:17
They all have the same event calls. However, when you merge over an existing window class, you must use the exact same template. So, you’ll need to update the templates in the extension to match the ruleset.

Regards,
JPG

GKEnialb
May 26th, 2025, 00:08
Ah, excellent. Thanks for the speedy response!