1
0
mirror of https://github.com/OpenTTD/OpenTTD.git synced 2025-08-24 06:59:10 +00:00

(svn r6727) -Fix r6619: don't disable inexistant widget

This commit is contained in:
glx
2006-10-10 17:19:21 +00:00
parent 8d5033ee25
commit 5b0183ce70

View File

@@ -155,7 +155,10 @@ static void PlayerFinancesWndProc(Window *w, WindowEvent *e)
PlayerID player = w->window_number;
const Player *p = GetPlayer(player);
SetWindowWidgetDisabledState(w, 7, p->current_loan == 0);
if (player == _local_player) {
/* borrow/repay buttons only exist for local player */
SetWindowWidgetDisabledState(w, 7, p->current_loan == 0);
}
SetDParam(0, p->name_1);
SetDParam(1, p->name_2);