PDA

View Full Version : windowinstance.minimize() fails in FGU



celestian
May 6th, 2020, 06:55
[5/6/2020 12:47:08 AM] [<color="red">ERROR</color>] Script execution error: [string "desktop/scripts/menubutton.lua"]:78: attempt to call field 'minimize' (a table value)

line 78: windowDropDown.minimize();

WindowDropDown is a windowinstance:
[5/6/2020 12:52:44 AM] s'menulist.lua' | s'onInit' | s'windowDropDown' | windowinstance = { class = menus_dropwindow, node = nil, x,y,w,h = 501,373,20,20 }

This works in FGC.

PS. if this functionality just isn't there yet in FGU please also consider adding a <minimize /> (no icon) for windows that want to hide w/o icon displaying...unless there is some other way to do that.

pindercarl
May 6th, 2020, 15:55
[5/6/2020 12:47:08 AM] [<color="red">ERROR</color>] Script execution error: [string "desktop/scripts/menubutton.lua"]:78: attempt to call field 'minimize' (a table value)

line 78: windowDropDown.minimize();

WindowDropDown is a windowinstance:
[5/6/2020 12:52:44 AM] s'menulist.lua' | s'onInit' | s'windowDropDown' | windowinstance = { class = menus_dropwindow, node = nil, x,y,w,h = 501,373,20,20 }

This works in FGC.

PS. if this functionality just isn't there yet in FGU please also consider adding a <minimize /> (no icon) for windows that want to hide w/o icon displaying...unless there is some other way to do that.

Minimize is not yet implemented and is in the list of known differences.

celestian
May 6th, 2020, 16:04
Minimize is not yet implemented and is in the list of known differences.

Understood. For now I'll write a hack to just not use this added feature in FGU until it's there.

pindercarl
May 6th, 2020, 16:15
Understood. For now I'll write a hack to just not use this added feature in FGU until it's there.

Speaking of hacks, a new update should be pushed today that includes significant changes to the text rendering. The FGU specific positioning of text in the 2E menu should no longer be necessary with this update. This should apply to anywhere that you are overriding the text positions based on FGC/FGU.

celestian
May 6th, 2020, 17:11
Speaking of hacks, a new update should be pushed today that includes significant changes to the text rendering. The FGU specific positioning of text in the 2E menu should no longer be necessary with this update. This should apply to anywhere that you are overriding the text positions based on FGC/FGU.

Thanks, I'll try and review tonight after patch and clean those tweaks up.

celestian
June 28th, 2020, 20:50
I posted a follow up to when this was added, it still has some issues.

https://www.fantasygrounds.com/forums/showthread.php?59110-Minimize-in-FGU

celestian
July 13th, 2020, 07:28
Has their been any updates related to the minimize features? I suspect the toggleWindow might be the culprit as mentioned before but that is speculation. While running the same code in FGC it works so ... that's my guess.