Skip to content

Commit

Permalink
remove item_color option
Browse files Browse the repository at this point in the history
  • Loading branch information
iav-BjRo committed Dec 2, 2024
1 parent f3e8378 commit ffd4741
Show file tree
Hide file tree
Showing 5 changed files with 2 additions and 22 deletions.
1 change: 0 additions & 1 deletion doc/Configuration/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,5 @@ These parameters will be described in the following.
| | "disp_cm_track_color" | "#001a54" | str | Hex color code, that defines the color of the track. |
| | "disp_cm_track_border_color" | "#001a54" | str | Hex color code, that defines the color of the track borders. |
| | "disp_cm_start_line_color" | "#dc46f3" | str | Hex color code, that defines the color of the start- and finish-line. |
| | "disp_cm_item_color" | "#96e7ff" | str | Hex color code, that defines the color of the items that appear on the track. |
| | "disp_cm_default_settings" | | dict | Dict of display_settings configuration paramters from above, storing the default values. |

10 changes: 0 additions & 10 deletions src/UserInterface/templates/car_map.html
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,6 @@ <h1>The map isn't currently available</h1>
const item_image_cache = new Map();

const item_size = 30;
const item_color = disp_settings.disp_cm_item_color;

addEventListener("resize", (event) => {
resizeCanvas();
Expand Down Expand Up @@ -276,15 +275,6 @@ <h1>The map isn't currently available</h1>
x *= scale;
y *= scale;
ctx.save();
/**
* ctx.beginPath();
* ctx.fillStyle = item_color;
* ctx.strokeStyle = item_color;
* ctx.arc(x, y, item_size * scale, 0, 2 * Math.PI);
* ctx.fill();
* ctx.stroke();
* ctx.restore();
*/

let img = getItemImage("item_blue.svg");
ctx.drawImage(img, x - item_size * scale / 2, y - item_size * scale / 2, item_size * scale, item_size * scale);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,6 @@ <h3>Colors:</h3>
<label for="disp_cm_start_line_color">Start line:</label>
<input type="color" id="disp_cm_start_line_color" name="disp_cm_start_line_color">
</div>
<div class="menu_item">
<label for="disp_cm_item_color">Items:</label>
<input type="color" id="disp_cm_item_color" name="disp_cm_item_color">
</div>
</div>
<div id="driver_ui_disp_settings">

Expand Down Expand Up @@ -122,7 +118,6 @@ <h3>Colors:</h3>
document.getElementById('disp_cm_track_color').value = disp_settings.disp_cm_track_color;
document.getElementById('disp_cm_track_border_color').value = disp_settings.disp_cm_track_border_color;
document.getElementById('disp_cm_start_line_color').value = disp_settings.disp_cm_start_line_color;
document.getElementById('disp_cm_item_color').value = disp_settings.disp_cm_item_color;
document.getElementById('disp_cm_qr_background_color').value = disp_settings.disp_cm_qr_background_color;
document.getElementById('disp_cm_qr_codes_color').value = disp_settings.disp_cm_qr_codes_color;
};
Expand Down
4 changes: 1 addition & 3 deletions src/config_file.json
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,6 @@
"disp_cm_track_color": "#001a54",
"disp_cm_track_border_color": "#001a54",
"disp_cm_start_line_color": "#5500b4",
"disp_cm_item_color": "#96e7ff",
"disp_cm_default_settings": {
"disp_cm_slogan_enabled": true,
"disp_cm_slogan_text": "Can it be Safe without Security? - Find out while racing with us!",
Expand All @@ -70,8 +69,7 @@
"disp_cm_background_color": "#5500b4",
"disp_cm_track_color": "#001a54",
"disp_cm_track_border_color": "#001a54",
"disp_cm_start_line_color": "#5500b4",
"disp_cm_item_color": "#96e7ff"
"disp_cm_start_line_color": "#5500b4"
}
}
}
4 changes: 1 addition & 3 deletions test/dev_config_file.json
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,6 @@
"disp_cm_track_color": "#001a54",
"disp_cm_track_border_color": "#001a54",
"disp_cm_start_line_color": "#5500b4",
"disp_cm_item_color": "#96e7ff",
"disp_cm_default_settings": {
"disp_cm_slogan_enabled": true,
"disp_cm_slogan_text": "Can it be Safe without Security? - Find out while racing with us!",
Expand All @@ -70,8 +69,7 @@
"disp_cm_background_color": "#5500b4",
"disp_cm_track_color": "#001a54",
"disp_cm_track_border_color": "#001a54",
"disp_cm_start_line_color": "#5500b4",
"disp_cm_item_color": "#96e7ff"
"disp_cm_start_line_color": "#5500b4"
},
"track": [
{
Expand Down

0 comments on commit ffd4741

Please sign in to comment.