diff --git a/docs/release/1.0.12/RELEASE_NOTES.md b/docs/release/1.0.12/RELEASE_NOTES.md index c887981..1dd83b8 100644 --- a/docs/release/1.0.12/RELEASE_NOTES.md +++ b/docs/release/1.0.12/RELEASE_NOTES.md @@ -45,6 +45,10 @@ already did). Now pressed while held: a player chosen in the squad list: yes takes him off the list, no leads on to the offers. +- **No status text in the footer.** The transfer market replaced the club name in the + bottom row with status texts (rejections, hints). The original has no such line; the + club name now always stays there. + ## Internal - The drawing of the wide push button, of the calculator window (panel and keys) and diff --git a/src/ui/transfer_market.cpp b/src/ui/transfer_market.cpp index e29cbca..2803c66 100644 --- a/src/ui/transfer_market.cpp +++ b/src/ui/transfer_market.cpp @@ -590,8 +590,9 @@ std::string TransferMarketScreen::original_money(int32_t value) const { if(result.size()<9)result.insert(0,9-result.size(),'%'); return result+exe_.cstring(::bmh::layout::CurrencySuffixText); } -// Renders the complete 320x240 screen: frame (or plain bars), title, club name, the overview and a -// feedback line that replaces the club name line when set (shortened to fit 310 pixels). +// Renders the complete 320x240 screen: frame (or plain bars), title, club name and the overview. The original has +// no status line: the bottom row always shows the club name. feedback_ stays available in state_json() for hosts +// and tests but is never drawn. Image TransferMarketScreen::render() const { Image out=state_.decorated_background?frame_:Image(320,240); if(!state_.decorated_background){rect(out,0,4,320,13,0x44);rect(out,1,5,318,11,0x39);rect(out,0,228,320,10,0x44);rect(out,1,229,318,8,0x39);} @@ -600,16 +601,6 @@ Image TransferMarketScreen::render() const { sprite_font_.draw(out,5,235,original_to_utf8(state_.club_name)); draw_market_overview(out); if (search_open_) draw_search(out); - if (!feedback_.empty()) { - rect(out, 1, 227, 318, 12, 0x39); - auto line = feedback_; - while (!line.empty() && sprite_font_.text_width(line) > 310) { - size_t at = line.size() - 1; - while (at > 0 && (uint8_t(line[at]) & 0xc0) == 0x80) --at; - line.resize(at); - } - sprite_font_.draw(out, 5, 235, line); - } return out; } diff --git a/src/ui/transfer_market_tests.cpp b/src/ui/transfer_market_tests.cpp index 5eced04..09353ab 100644 --- a/src/ui/transfer_market_tests.cpp +++ b/src/ui/transfer_market_tests.cpp @@ -74,7 +74,9 @@ int main(int argc,char** argv){ const auto rejected_frame = screen.render(); screen.key("V"); screen.reject_action("Anderer sichtbarer Hinweis"); - check(screen.render().pixels != rejected_frame.pixels, "host rejection is actually rendered in the footer"); + // the original has no status line: the footer keeps showing the club name, the text stays in state_json() + check(screen.render().pixels == rejected_frame.pixels, "host rejection does not replace the club name in the footer"); + check(screen.state_json().find("Anderer sichtbarer Hinweis")!=std::string::npos,"host rejection stays in the state"); TransferMarketScreen selected(argv[1],s); auto marked_market=selected.click(210,28);selected.acknowledge_preview(s,quote(marked_market));