16
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-07-19 15:49:19 +02:00

reformat: use auto on certain types

This commit is contained in:
jerrrrycho
2026-07-04 05:22:52 +02:00
parent f61068ff89
commit 20e7a99516
118 changed files with 2118 additions and 2063 deletions

View File

@@ -91,7 +91,7 @@ void trainingcard_panel::render_contents()
if (ImGui::BeginPopupModal("Zapisywanie danych"))
{
ImGui::SetWindowSize(ImVec2(-1, -1));
int s = state.load();
const int s = state.load();
if (s == 1)
{
@@ -121,8 +121,8 @@ void trainingcard_panel::render_contents()
if (start_time_wall)
{
std::tm *tm = std::localtime(&(*start_time_wall));
std::string rep = "Czas rozpoczęcia: " + std::to_string(tm->tm_year + 1900) + "-" + std::to_string(tm->tm_mon + 1) + "-" + std::to_string(tm->tm_mday) + " " + std::to_string(tm->tm_hour) +
const std::tm *tm = std::localtime(&(*start_time_wall));
const std::string rep = "Czas rozpoczęcia: " + std::to_string(tm->tm_year + 1900) + "-" + std::to_string(tm->tm_mon + 1) + "-" + std::to_string(tm->tm_mday) + " " + std::to_string(tm->tm_hour) +
":" + std::to_string(tm->tm_min);
ImGui::TextUnformatted(rep.c_str());
}
@@ -159,11 +159,11 @@ void trainingcard_panel::render_contents()
if (ImGui::Button("Rozpocznij szkolenie"))
{
start_time_wall = std::time(nullptr);
std::tm *tm = std::localtime(&(*start_time_wall));
const std::tm *tm = std::localtime(&(*start_time_wall));
recording_timestamp = std::to_string(tm->tm_year + 1900) + std::to_string(tm->tm_mon + 1) + std::to_string(tm->tm_mday) + std::to_string(tm->tm_hour) + std::to_string(tm->tm_min) + "_" +
std::string(trainee_name.c_str()) + "_" + std::string(instructor_name.c_str());
int ret = StartRecording();
const int ret = StartRecording();
if (ret != 1)
{
state.store(ret);