Hi Andy, On Mon, Oct 25, 2010 at 5:11 AM, Andy Stewart <lazycat.mana...@gmail.com> wrote: > Hi Maxime, > > Maxime Henrion <mhenr...@gmail.com> writes: > >> Hello all, >> >> >> Yet another boring patch to update signal handlers to the new way of >> doing things, this time for the MenuItem and Item objects :-). There >> is, however, something of interest in this patch. > I have apply your patches, thanks! :) >> >> I was surprised to see that the "onToggle" and "afterToggle" signal >> handlers were actually bound to the signal name "toggled". Checking the >> GTK+ API documentation, it appears the correct signal name is really >> "toggle", without the final 'd' character. I suspect this code never >> worked before, but that noone was unlucky enough to actually hit it. >> Therefore, I corrected the signal name in the new signal handler as well >> as in the deprecated signal handlers. > Yes, it's a bug, thanks fix. :) >> >> Finally, another question comes to mind: why is the "activate" signal >> bound by the "activateLeaf" signal handler? Should I take advantage of >> this patch to rename it to just "activate", or "menuItemActivate" if >> there are namespace conflicts? > Yes, menuItemActivate is right signal name. > But after we change to 'menuItemActivate' it conflict with function > 'menu_item_activate' that emit 'activate' signal. > > So we change function 'menuItemActivate' (menu_item_activate) to > 'menuItemEmitActivate' avoid conflict. > > Please see detail in patches i push. :)
So, you actually qualified every signal handler with the object name; I thought we were only doing this in case of namespace conflicts, which is why I didn't do it. However, there's a problem in your patch, as far as I can see: you have prefixed the "select", "deselect" and "toggle" signals with "menuItem", while they are actually signal handlers for the Item object and not the MenuItem one. So I think they should have been named "itemSelect", "itemDeselect" and "itemToggle" respectively. Cheers, Maxime ------------------------------------------------------------------------------ Nokia and AT&T present the 2010 Calling All Innovators-North America contest Create new apps & games for the Nokia N8 for consumers in U.S. and Canada $10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store http://p.sf.net/sfu/nokia-dev2dev _______________________________________________ Gtk2hs-devel mailing list Gtk2hs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gtk2hs-devel