MCPcopy Create free account
hub / github.com/OpenTTD/OpenTTD / OnPlaceObjectAbort

Method OnPlaceObjectAbort

src/misc_gui.cpp:998–1009  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

996 }
997
998 void OnPlaceObjectAbort() override
999 {
1000 if (Station::IsExpected(Station::Get(this->parent->window_number))) {
1001 /* this is a station */
1002 SetViewportStationRect(Station::Get(this->parent->window_number), false);
1003 } else {
1004 /* this is a waypoint */
1005 SetViewportWaypointRect(Waypoint::Get(this->parent->window_number), false);
1006 }
1007
1008 this->RaiseButtons();
1009 }
1010
1011 void Close([[maybe_unused]] int data = 0) override
1012 {

Callers

nothing calls this directly

Calls 3

SetViewportStationRectFunction · 0.85
SetViewportWaypointRectFunction · 0.85
RaiseButtonsMethod · 0.80

Tested by

no test coverage detected