Changeset - r11473:a263b133d479
[Not reviewed]
master
0 1 0
rubidium - 15 years ago 2009-03-24 22:18:40
rubidium@openttd.org
(svn r15839) -Fix: high score text was (partly) off-screen when using RTL and the window was wider than 640 pixels
1 file changed with 3 insertions and 5 deletions:
0 comments (0 inline, 0 general)
src/highscore_gui.cpp
Show inline comments
 
@@ -140,8 +140,6 @@ struct HighScoreWindow : EndGameHighScor
 

	
 
		this->SetupHighScoreEndWindow(&x, &y);
 

	
 
		const int right = this->left + this->width - 1;
 

	
 
		SetDParam(0, ORIGINAL_END_YEAR);
 
		SetDParam(1, this->window_number + STR_6801_EASY);
 
		DrawStringMultiLine(x + 70, x + 570, y, y + 140, !_networking ? STR_0211_TOP_COMPANIES_WHO_REACHED : STR_TOP_COMPANIES_NETWORK_GAME, SA_CENTER);
 
@@ -149,15 +147,15 @@ struct HighScoreWindow : EndGameHighScor
 
		/* Draw Highscore peepz */
 
		for (uint8 i = 0; i < lengthof(_highscore_table[0]); i++) {
 
			SetDParam(0, i + 1);
 
			DrawString(x + 40, right, y + 140 + (i * 55), STR_0212, TC_BLACK);
 
			DrawString(x + 40, x + 600, y + 140 + (i * 55), STR_0212, TC_BLACK);
 

	
 
			if (hs[i].company[0] != '\0') {
 
				TextColour colour = (this->rank == i) ? TC_RED : TC_BLACK; // draw new highscore in red
 

	
 
				DrawString(x + 71, right, y + 140 + (i * 55), hs[i].company, colour);
 
				DrawString(x + 71, x + 569, y + 140 + (i * 55), hs[i].company, colour);
 
				SetDParam(0, hs[i].title);
 
				SetDParam(1, hs[i].score);
 
				DrawString(x + 71, right, y + 160 + (i * 55), STR_HIGHSCORE_STATS, colour);
 
				DrawString(x + 71, x + 569, y + 160 + (i * 55), STR_HIGHSCORE_STATS, colour);
 
			}
 
		}
 
	}
0 comments (0 inline, 0 general)