(svn r16963) -Codechange: Added NWidgetViewport widget.

This commit is contained in:
alberth
2009-07-26 17:29:01 +00:00
parent 66bca52949
commit 84507dc358
4 changed files with 96 additions and 6 deletions

View File

@@ -193,7 +193,7 @@ enum SortButtonState {
* A viewport is either following a vehicle (its id in then in #follow_vehicle), or it aims to display a specific
* location #dest_scrollpos_x, #dest_scrollpos_y (#follow_vehicle is then #INVALID_VEHICLE).
* The actual location being shown is #scrollpos_x, #scrollpos_y.
* @see InitializeViewport(), UpdateViewportPosition().
* @see InitializeViewport(), UpdateViewportPosition(), UpdateViewportCoordinates().
*/
struct ViewportData : ViewPort {
VehicleID follow_vehicle; ///< VehicleID to follow if following a vehicle, #INVALID_VEHICLE otherwise.
@@ -644,6 +644,7 @@ public:
/**
* Called after the window got resized.
* For nested windows with a viewport, call NWidgetViewport::UpdateViewportCoordinates.
* @param delta The amount of which the window size changed.
*/
virtual void OnResize(Point delta) {}