On Sat, 18 Jul 2009 21:12:26 +1000, Lex wrote:
I have commented out execute/stop button code because now that multiple executes are possible the question is, which one does the button execute/stop??
Not sure. New features, new problems, haha. Maybe it's enough to let the Run/Stop button stick to the first Run command and maybe add the second Run command to the Build button's menu.
And also the other code handling the button
menu seems to be old. You should update it or tell me to do so if you don't want to.
Done as best I can. Please check.
I found only a little thing which was missing, see attached patch.
The build toolbar button runs the compile command. This is because the build_toolbutton_build_clicked user_data is always 0. It used to be GBO_BUILD. Where is it set now?
Er, the build button callback user_data was always NULL. The NULL is set in src/toolbar.c:345. The build button should run the GBO_BUILD command unless any other build action from the menu was chosen. Then the build button runs the last chosen action. This is done in build_toolbutton_build_clicked() and there the user_data isn't taken into account. Maybe you changed the semantics in on_build_menu_item() but this can be easily changed with the attached patch (build_button_fix.diff) which explicitly call the GBO_BUILD action on on_build_menu_item().
Ok, I had just copied the way the old build_toolbutton_build_clicked worked? But I am not sure how it actually worked then?? But it works now so who cares!!!! Thanks.
Hehe. Tested the Build button + menu and it seems to work as in trunk, so it's all fine for now.
Regards, Enrico