Skip to content

Commit

Permalink
Fixed inconsistency with how get_side_highlight_pango handles its arg…
Browse files Browse the repository at this point in the history
…ument
  • Loading branch information
Vultraz committed Jul 12, 2019
1 parent 5b9eb3c commit 4a41c46
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/gui/dialogs/game_stats.cpp
Expand Up @@ -115,7 +115,7 @@ void game_stats::pre_show(window& window)
}
}

leader_name = "<span color='" + team::get_side_highlight_pango(team.side() - 1) + "'>" + leader_name + "</span>";
leader_name = "<span color='" + team::get_side_highlight_pango(team.side()) + "'>" + leader_name + "</span>";
}

//
Expand Down
2 changes: 1 addition & 1 deletion src/replay.cpp
Expand Up @@ -156,7 +156,7 @@ chat_msg::chat_msg(const config &cfg)
if (side==0) {
color_ = "white";//observers
} else {
color_ = team::get_side_highlight_pango(side-1);
color_ = team::get_side_highlight_pango(side);
}
time_ = get_time(cfg);
/*
Expand Down
2 changes: 1 addition & 1 deletion src/team.cpp
Expand Up @@ -986,7 +986,7 @@ std::string team::get_side_color_id_from_config(const config& cfg)

std::string team::get_side_highlight_pango(int side)
{
return get_side_color_range(side + 1).mid().to_hex_string();
return get_side_color_range(side).mid().to_hex_string();
}

void team::log_recruitable() const
Expand Down

0 comments on commit 4a41c46

Please sign in to comment.