Page 2 of 2
Re: Intuition/GadTools image menus (IM_ITEM/IM_SUB)
Posted: Fri May 17, 2013 12:46 am
by chris
salass00 wrote:This bug is already assigned. FWIW I tried running your test case using the latest SVN version of popupmenu.class on my beta system and I couldn't get it to crash here. After allocating signal 17 the popup menu stopped opening but it didn't crash or cause the OS to freeze.
OK, sounds like some progress has been made on it, that's all I wanted to hear.
Re: Intuition/GadTools image menus (IM_ITEM/IM_SUB)
Posted: Fri Jun 07, 2013 11:20 am
by chris
salass00 wrote:This bug should be fixed in gadtools.library 53.5.
Unfortunately it isn't completely. Normal menu and sub-items work fine within some test code (I'm having problems elsewhere, but that's a different story), however, items with sub-items attached to them cause label.image to crash.
You can see this for yourself by modifying my original test code so the IM_ITEM is the one with sub-items, rather than the ARexx menu.
Re: Intuition/GadTools image menus (IM_ITEM/IM_SUB)
Posted: Fri Jun 07, 2013 12:39 pm
by salass00
chris wrote:
Unfortunately it isn't completely. Normal menu and sub-items work fine within some test code (I'm having problems elsewhere, but that's a different story), however, items with sub-items attached to them cause label.image to crash.
You can see this for yourself by modifying my original test code so the IM_ITEM is the one with sub-items, rather than the ARexx menu.
I will look into this next week.
Unfortunately my PC which I use for much of my development just stopped working yesterday evening

. I think it may be just the PSU that's died though.
At the moment when I connect the power and turn on the switch on the back it just makes a strange whining sound and the power light flickers.
Re: Intuition/GadTools image menus (IM_ITEM/IM_SUB)
Posted: Sat Jun 08, 2013 5:37 pm
by chris
salass00 wrote:chris wrote:
Unfortunately it isn't completely. Normal menu and sub-items work fine within some test code (I'm having problems elsewhere, but that's a different story), however, items with sub-items attached to them cause label.image to crash.
You can see this for yourself by modifying my original test code so the IM_ITEM is the one with sub-items, rather than the ARexx menu.
I will look into this next week.
Unfortunately my PC which I use for much of my development just stopped working yesterday evening

. I think it may be just the PSU that's died though.
At the moment when I connect the power and turn on the switch on the back it just makes a strange whining sound and the power light flickers.
Sounds like the PSU. Hopefully you can get it back up and running soon.
wrt image menus, do you know what would cause an entire menu (or sub-menu) to not render? I'm playing around with IM_ITEM and all I'm getting is the menu not appearing - even if I only update one item as IM_ITEM with a basic label.image LABEL_Text only.
The only difference (that I can see) between my code and the earlier test code is that mine AllocVec()s the NewMenu structure and then pokes everything in. It works for normal NM_ITEM entries though. Any ideas?
Re: Intuition/GadTools image menus (IM_ITEM/IM_SUB)
Posted: Thu Jun 13, 2013 11:30 am
by salass00
chris wrote:
Sounds like the PSU. Hopefully you can get it back up and running soon.
I have it running again now with a new CoolerMaster 600W PSU.
wrt image menus, do you know what would cause an entire menu (or sub-menu) to not render? I'm playing around with IM_ITEM and all I'm getting is the menu not appearing - even if I only update one item as IM_ITEM with a basic label.image LABEL_Text only.
The only difference (that I can see) between my code and the earlier test code is that mine AllocVec()s the NewMenu structure and then pokes everything in. It works for normal NM_ITEM entries though. Any ideas?
Could you post a small test code that reproduces this? I tried modifying your previous code to add a sub to the image item and turning the image item into an image sub but it didn't cause any problems here.
Re: Intuition/GadTools image menus (IM_ITEM/IM_SUB)
Posted: Thu Jun 13, 2013 7:58 pm
by chris
salass00 wrote:Could you post a small test code that reproduces this? I tried modifying your previous code to add a sub to the image item and turning the image item into an image sub but it didn't cause any problems here.
http://homepage.ntlworld.com/cdyoung/tmp/im_menu.lha
I can't get it to crash now, but the above gives an empty (invisible) "Prefs" menu - you can tell it's invisible because hovering over where the "sub-item" menu
should be makes it show the sub-menu!
This is exactly what I'm seeing elsewhere.
Re: Intuition/GadTools image menus (IM_ITEM/IM_SUB)
Posted: Sun Jun 16, 2013 12:05 am
by salass00
chris wrote:
http://homepage.ntlworld.com/cdyoung/tmp/im_menu.lha
I can't get it to crash now, but the above gives an empty (invisible) "Prefs" menu - you can tell it's invisible because hovering over where the "sub-item" menu
should be makes it show the sub-menu!
This is exactly what I'm seeing elsewhere.
That's a bit strange. When I try on my update 6 install it works as you describe (the submenu when it shows is as wide as the screen though) but when I try using my beta install I can't get it to display the submenu at all. I guess I will have to debug the layout code in gadtools to find out why this is happening...
Re: Intuition/GadTools image menus (IM_ITEM/IM_SUB)
Posted: Mon Jun 17, 2013 12:26 pm
by salass00
It took me long enough but I've finally found and managed to fix what was causing the problem. The reason was the layout function was storing the original leftedge of the image at one offset and then later trying to read it back at a different one (this was in turn caused by different packing being used on an internal structure making the error not immediately obvious).
Re: Intuition/GadTools image menus (IM_ITEM/IM_SUB)
Posted: Mon Jun 17, 2013 1:04 pm
by chris
Fredrik, you are my favourite OS4 developer. Thank you for fixing these issues!
Re: Intuition/GadTools image menus (IM_ITEM/IM_SUB)
Posted: Mon Jun 17, 2013 1:36 pm
by trixie
+1
