Differences From Artifact [ae64ef2f3f]:
- File config.c — part of check-in [5f0e743092] at 2008-06-15 07:39:09 on branch trunk — Exorcise beeps from the Colours pane in Gtk. The colour list box beeped at the user whenever it found that something other than exactly one colour was selected. This seems to happen implicitly in Gtk when the pane is changed. In Gtk1, this gave you a beep whenever you left the Colours dialog after having selected a colour from the list; in Gtk2, you additionally got a beep _every_ time you subsequently re-entered the Colours dialog (for reasons I haven't investigated). Windows was unaffected. Also, in Gtk (unlike Windows), it's possible for the user to go back to the state where no items in the list box are selected at all. For these reasons, stop beeping at the user, and instead blank the RGB edit boxes as a hint that edits to them would be futile. (Really we should be disabling them entirely, but the cross-platform edit controls aren't up to that yet.) (user: jacob size: 74661)
To Artifact [d902464666]:
- File config.c — part of check-in [dc3f5d00d0] at 2008-07-17 12:01:27 on branch trunk — At least one version of gcc won't figure out that "clear" is never read uninitialised (because the only circumstance under which it isn't initialised is when "update" is FALSE, in which case it isn't read either). Placate it. (user: simon size: 74669)
| ︙ | ︙ | |||
619 620 621 622 623 624 625 |
static void colour_handler(union control *ctrl, void *dlg,
void *data, int event)
{
Config *cfg = (Config *)data;
struct colour_data *cd =
(struct colour_data *)ctrl->generic.context.p;
| | | 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 |
static void colour_handler(union control *ctrl, void *dlg,
void *data, int event)
{
Config *cfg = (Config *)data;
struct colour_data *cd =
(struct colour_data *)ctrl->generic.context.p;
int update = FALSE, clear = FALSE, r, g, b;
if (event == EVENT_REFRESH) {
if (ctrl == cd->listbox) {
int i;
dlg_update_start(ctrl, dlg);
dlg_listbox_clear(ctrl, dlg);
for (i = 0; i < lenof(colours); i++)
|
| ︙ | ︙ |