Hi Pete, I am having the exact same problem, I am creating a Linda Lua script that is a menu display for the G1000 PFD. The idea is not to use the mouse to select options in the G1000. I am creating a new window. If i use ipc.setdisplay() 25 times in P2D v2.5 it hangs. I found a work around where i create the display once and put the Title Display line at line 0 using the ipc.display("Display line \n1 \n2,,,).
How can i tell if another application created a display so i can then rectreat it again?
thanks for your help
Creating the display and then calling the text to fill it from other functions. its not complete but here is what i am talking about.
function G1000_PFD_Main_Display() -- G1000 PFD: Menu Window Open and Menu Item Toggle: Use On-Press ipc.display("") ipc.sleep(500) if G1_Window == 0 and Main_Panel == 1 then -- Call G1000 Main Window ipc.setowndisplay("G1000 PFD Main Key Select", 45, 25, 10, 10) G1000SK = 0
G1_Window = 1 G1000_Main_Keys_Menu() G1_Window = 1 elseif G1_Window == 1 and Main_Panel == 1 then -- Call G1000 Main Panel Key Selection Window G1000_Main_Keys_Menu() --elseif G1_Window == 0 and PFDL1_PANEL == 1 then -- Call PFD Key Main Window --ipc.setowndisplay("G1000 PFD PFD SoftKey Select", 45, 25, 10, 10) --PFDSK_L1 = 0 --PFDL1_SoftKey_Menu () elseif G1_Window == 1 and PFDL1_PANEL == 1 then PFDL1_SoftKey_Menu () elseif G1_Window == 1 and FDFRMT_PANEL == 1 then FD_FRMT_Menu () elseif G1_Window == 1 and Wnd_Panel == 1 then PFD_Wind_Menu () elseif G1_Window == 1 and PFDALT_Panel == 1 then PFDALT_UNIT_Menu() --elseif G1_Window == 0 and INSET_Panel == 1 then -- Call PFD Key Main Window --ipc.setowndisplay("G1000 PFD: INSET SoftKey Select", 45, 25, 10, 10) --INSETv = 0 --INSET_SoftKey_Menu () elseif G1_Window == 1 and INSET_Panel == 1 then INSET_SoftKey_Menu () end
I would need to detect a change to set G1_Window back to a 0.
thanks