diff options
author | rubidium <rubidium@openttd.org> | 2009-11-02 16:07:09 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2009-11-02 16:07:09 +0000 |
commit | 56611d13db7f69bb482b7fd625511a311e97e251 (patch) | |
tree | 4b65382b280fc0e7ffc9a1d8be5f19f823c484a0 | |
parent | 8382b4142001d8857abbca986a21b7763cc0e316 (diff) | |
download | openttd-56611d13db7f69bb482b7fd625511a311e97e251.tar.xz |
(svn r17955) -Codechange: s/SPR_PLAYER_ICON/SPR_COMPANY_ICON/
-rw-r--r-- | src/company_cmd.cpp | 2 | ||||
-rw-r--r-- | src/graph_gui.cpp | 4 | ||||
-rw-r--r-- | src/network/network_gui.cpp | 2 | ||||
-rw-r--r-- | src/signs_gui.cpp | 4 | ||||
-rw-r--r-- | src/table/sprites.h | 2 |
5 files changed, 7 insertions, 7 deletions
diff --git a/src/company_cmd.cpp b/src/company_cmd.cpp index 37e857a3f..710cfe63a 100644 --- a/src/company_cmd.cpp +++ b/src/company_cmd.cpp @@ -111,7 +111,7 @@ uint16 GetDrawStringCompanyColour(CompanyID company) void DrawCompanyIcon(CompanyID c, int x, int y) { - DrawSprite(SPR_PLAYER_ICON, COMPANY_SPRITE_COLOUR(c), x, y); + DrawSprite(SPR_COMPANY_ICON, COMPANY_SPRITE_COLOUR(c), x, y); } /** diff --git a/src/graph_gui.cpp b/src/graph_gui.cpp index 93335e804..cd6351e61 100644 --- a/src/graph_gui.cpp +++ b/src/graph_gui.cpp @@ -1056,7 +1056,7 @@ struct PerformanceRatingDetailWindow : Window { if (this->IsWidgetDisabled(widget)) return; CompanyID cid = (CompanyID)(widget - PRW_COMPANY_FIRST); int offset = (cid == this->company) ? 1 : 0; - Dimension sprite_size = GetSpriteSize(SPR_PLAYER_ICON); + Dimension sprite_size = GetSpriteSize(SPR_COMPANY_ICON); DrawCompanyIcon(cid, (r.left + r.right - sprite_size.width) / 2 + offset, (r.top + r.bottom - sprite_size.height) / 2 + offset); return; } @@ -1222,7 +1222,7 @@ static NWidgetBase *MakeCompanyButtonRows(int *biggest_index) NWidgetHorizontal *hor = NULL; // Storage for buttons in one row. int hor_length = 0; - Dimension sprite_size = GetSpriteSize(SPR_PLAYER_ICON); + Dimension sprite_size = GetSpriteSize(SPR_COMPANY_ICON); sprite_size.width += WD_MATRIX_LEFT + WD_MATRIX_RIGHT; sprite_size.height += WD_MATRIX_TOP + WD_MATRIX_BOTTOM + 1; // 1 for the 'offset' of being pressed diff --git a/src/network/network_gui.cpp b/src/network/network_gui.cpp index cdfc6f505..f03280a9d 100644 --- a/src/network/network_gui.cpp +++ b/src/network/network_gui.cpp @@ -2038,7 +2038,7 @@ struct NetworkClientListWindow : Window { if (widget != CLW_PANEL) return; this->server_client_width = max(GetStringBoundingBox(STR_NETWORK_SERVER).width, GetStringBoundingBox(STR_NETWORK_CLIENT).width) + WD_FRAMERECT_RIGHT; - this->company_icon_width = GetSpriteSize(SPR_PLAYER_ICON).width + WD_FRAMERECT_LEFT; + this->company_icon_width = GetSpriteSize(SPR_COMPANY_ICON).width + WD_FRAMERECT_LEFT; uint width = 200; // Default width const NetworkClientInfo *ci; diff --git a/src/signs_gui.cpp b/src/signs_gui.cpp index 71dec9c40..e6fc427c0 100644 --- a/src/signs_gui.cpp +++ b/src/signs_gui.cpp @@ -163,9 +163,9 @@ struct SignListWindow : Window, SignList { virtual void UpdateWidgetSize(int widget, Dimension *size, const Dimension &padding, Dimension *resize) { if (widget == SLW_LIST) { - Dimension spr_dim = GetSpriteSize(SPR_PLAYER_ICON); + Dimension spr_dim = GetSpriteSize(SPR_COMPANY_ICON); this->text_offset = WD_FRAMETEXT_LEFT + spr_dim.width + 2; // 2 pixels space between icon and the sign text. - resize->height = max<uint>(FONT_HEIGHT_NORMAL, GetSpriteSize(SPR_PLAYER_ICON).height); + resize->height = max<uint>(FONT_HEIGHT_NORMAL, GetSpriteSize(SPR_COMPANY_ICON).height); Dimension d = {this->text_offset + MAX_LENGTH_SIGN_NAME_PIXELS + WD_FRAMETEXT_RIGHT, WD_FRAMERECT_TOP + 5 * resize->height + WD_FRAMERECT_BOTTOM}; *size = maxdim(*size, d); } diff --git a/src/table/sprites.h b/src/table/sprites.h index 4a1a67876..e522ec71f 100644 --- a/src/table/sprites.h +++ b/src/table/sprites.h @@ -254,7 +254,7 @@ enum Sprites { SPR_GRADIENT = 874, // background gradient behind manager face /* Icon showing company colour. */ - SPR_PLAYER_ICON = 747, + SPR_COMPANY_ICON = 747, /* is itself no foundation sprite, because tileh 0 has no foundation */ SPR_FOUNDATION_BASE = 989, |