Author: mir3x Date: Sat Nov 7 23:32:43 2015 New Revision: 30474 URL: http://svn.gna.org/viewcvs/freeciv?rev=30474&view=rev Log: Sometimes after starting game, first chat message could be the last one from pregame chat or broken one. Fixed.
See bug #24028 Modified: branches/S2_6/client/gui-qt/chatline.cpp branches/S2_6/client/gui-qt/mapview.cpp Modified: branches/S2_6/client/gui-qt/chatline.cpp URL: http://svn.gna.org/viewcvs/freeciv/branches/S2_6/client/gui-qt/chatline.cpp?rev=30474&r1=30473&r2=30474&view=diff ============================================================================== --- branches/S2_6/client/gui-qt/chatline.cpp (original) +++ branches/S2_6/client/gui-qt/chatline.cpp Sat Nov 7 23:32:43 2015 @@ -181,7 +181,8 @@ ***************************************************************************/ void chatwdg::send() { - const char *theinput; + char *theinput; + char buf[MAX_LEN_MSG]; theinput = chat_line->text().toUtf8().data(); gui()->chat_history.prepend(chat_line->text()); @@ -189,12 +190,11 @@ if (client_state() == C_S_RUNNING && gui_options.gui_qt_allied_chat_only && is_plain_public_message(theinput)) { - char buf[MAX_LEN_MSG]; - fc_snprintf(buf, sizeof(buf), ". %s", theinput); send_chat(buf); } else { - send_chat(theinput); + fc_snprintf(buf, sizeof(buf), "%s", theinput); + send_chat(buf); } } chat_line->clear(); Modified: branches/S2_6/client/gui-qt/mapview.cpp URL: http://svn.gna.org/viewcvs/freeciv/branches/S2_6/client/gui-qt/mapview.cpp?rev=30474&r1=30473&r2=30474&view=diff ============================================================================== --- branches/S2_6/client/gui-qt/mapview.cpp (original) +++ branches/S2_6/client/gui-qt/mapview.cpp Sat Nov 7 23:32:43 2015 @@ -1087,6 +1087,8 @@ { const struct sprite *sprite; int d; + QSize delta; + if (client_is_global_observer()) { return; } @@ -1113,6 +1115,9 @@ tax_indicators[d]->setToolTip(_("Shows your current luxury/science/tax " "rates. Use mouse wheel to change them")); } + + delta = gui()->mapview_wdg->size() - gui()->end_turn_rect->sizeHint(); + move(delta.width(), delta.height()); } /**************************************************************************** _______________________________________________ Freeciv-commits mailing list Freeciv-commits@gna.org https://mail.gna.org/listinfo/freeciv-commits