Merge branch 'master' into jgrpp
# Conflicts: # src/core/strong_typedef_type.hpp # src/gfx.cpp # src/group_cmd.cpp # src/industry_cmd.cpp # src/map_func.h # src/newgrf_debug_gui.cpp # src/order_cmd.cpp # src/pathfinder/follow_track.hpp # src/rail_cmd.cpp # src/road_cmd.cpp # src/road_gui.cpp # src/saveload/saveload.cpp # src/screenshot.cpp # src/smallmap_gui.cpp # src/station_cmd.cpp # src/strings.cpp # src/tile_type.h # src/timetable_gui.cpp # src/town_cmd.cpp # src/train_cmd.cpp # src/viewport.cpp
This commit is contained in:
@@ -8,6 +8,7 @@
|
||||
/** @file statusbar_gui.cpp The GUI for the bottom status bar. */
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "core/backup_type.hpp"
|
||||
#include "date_func.h"
|
||||
#include "gfx_func.h"
|
||||
#include "news_func.h"
|
||||
@@ -68,10 +69,8 @@ static bool DrawScrollingStatusText(const NewsItem *ni, int scroll_pos, int left
|
||||
int width = GetStringBoundingBox(buffer).width;
|
||||
int pos = (_current_text_dir == TD_RTL) ? (scroll_pos - width) : (right - scroll_pos - left);
|
||||
|
||||
DrawPixelInfo *old_dpi = _cur_dpi;
|
||||
_cur_dpi = &tmp_dpi;
|
||||
AutoRestoreBackup dpi_backup(_cur_dpi, &tmp_dpi);
|
||||
DrawString(pos, INT16_MAX, 0, buffer, TC_LIGHT_BLUE, SA_LEFT | SA_FORCE);
|
||||
_cur_dpi = old_dpi;
|
||||
|
||||
return (_current_text_dir == TD_RTL) ? (pos < right - left) : (pos + width > 0);
|
||||
}
|
||||
|
Reference in New Issue
Block a user