dadisigursveinn / 400plus

Automatically exported from code.google.com/p/400plus
0 stars 0 forks source link

Named temperatures is broken #333

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Enter 400plus menu
2. Enter Named color temps.
3.

What is the expected output? What do you see instead?
I want Matches, Candles, Tungsten etc, but get only Matches.

What version of the product are you using?
1798, 1800 and a few other recent builds.

Please provide any additional information below.

I rolled back part of settings.c to r1744, then it works.

--1800:--
menu_order_t menu_order_default;

--1744:--
menu_order_t menu_order_default = {
    main        : {0, 1, 2, 3, 4, 5, 6, 7, 8, 9},
    params      : {0, 1, 2, 3, 4, 5, 6, 7, 8, 9},
    scripts     : {0, 1, 2, 3, 4, 5, 6, 7, 8, 9},
    info        : {0, 1, 2, 3, 4, 5, 6, 7, 8, 9},
    developer   : {0, 1, 2, 3, 4, 5, 6, 7, 8, 9},
    settings    : {0, 1, 2, 3, 4, 5, 6, 7, 8, 9},
    named_temps : {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15},
};

Original issue reported on code.google.com by TEEM...@gmail.com on 5 Apr 2013 at 5:37

GoogleCodeExporter commented 9 years ago
Had a closer look today. This is probably a better fix :-)
Made a quick test and it seem to work.

settings.c (r1781):

    for (i = 0; i < LENGTH(menu_order_default.settings); i++)
        menu_order_default.settings[i] = i;

+   for (i = 0; i < LENGTH(menu_order_default.named_temps); i++)
+       menu_order_default.named_temps[i] = i;

    settings_t    settings_buffer;
    menu_order_t  menu_order_buffer;
    named_temps_t named_temps_buffer;

Original comment by TEEM...@gmail.com on 6 Apr 2013 at 12:11

GoogleCodeExporter commented 9 years ago
Good catch!

Second version nails it, I applied it at revision r1803; and to fix the 
affected files that may have been created, I added a temporal correction at 
revision r1804.

Many thanks.

Original comment by eduardo....@gmail.com on 6 Apr 2013 at 10:03