Hi again...
Sorry for sending two mail, but I read the patch a little closer again
so I don't forget something.
I probably won't include the simple_gui_changed(property_t prop)
function, but I want do comment it nevertheless since you might provide
more patches.
You have the two arrays "props_to_change" and "prop_menus_to_change"
and iterate over the in the second for loop.
1)
When you force the bw displays off, then the options to show or hide
them should also be removed from the gui (menu bar->view) since they
no longer have any effect.
2)
It would be cleaner to change the props directly instead of calling
update_stats_visibility(). It would save you the "prop_menus_to_change"
array and it would make the stuff more understandable. With your code
something like this should happen (if I read everything right), the
important line is marked with the "*":
- simple_gui_changed(...)
* update_stats_visibility(cm, w, !)
- gtk_check_menu_item_set_state(cm, val)
- progressbar_bws_in_visible_changed(...)
So in the end the property gets changed, but it's not obvious from the
code. Better would be this:
- simple_gui_changed(...)
* set property (using a stub, see setting_gui.c | search 'prop_set')
- progressbar_bws_in_visible_changed(...)
- update_stats_visibility(cm, w, !)
That makes it more obvious that a property is changed and lets the rest
of the gui/property code update the according gui elements as needed.
Can you see what I mean?
--
Richard Eckart <[EMAIL PROTECTED]>
-------------------------------------------------------
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills. Sign up for IBM's
Free Linux Tutorials. Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
_______________________________________________
Gtk-gnutella-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/gtk-gnutella-devel