|
OpenTTD Source 20260218-master-g2123fca5ea
|
Button shown for either a company or client in the client-list. More...
Public Member Functions | |
| ButtonCommon (SpriteID sprite, StringID tooltip, Colours colour, bool disabled=false) | |
| virtual void | OnClick (struct NetworkClientListWindow *w, Point pt)=0 |
| OnClick handler for when the button is pressed. | |
Data Fields | |
| SpriteID | sprite |
| The sprite to use on the button. | |
| StringID | tooltip |
| The tooltip of the button. | |
| Colours | colour |
| The colour of the button. | |
| bool | disabled |
| Is the button disabled? | |
| uint | height |
| Calculated height of the button. | |
| uint | width |
| Calculated width of the button. | |
Button shown for either a company or client in the client-list.
These buttons are dynamic and strongly depends on which company/client what buttons are available. This class allows dynamically creating them as the current Widget system does not.
Definition at line 1319 of file network_gui.cpp.
|
inline |
Definition at line 1328 of file network_gui.cpp.
|
pure virtual |
OnClick handler for when the button is pressed.
| w | The window the click was in. |
| pt | The location the click was at. |
Implemented in Button< T >, Button< ClientID >, and Button< CompanyID >.
References Point.
Referenced by NetworkClientListWindow::OnClick().
| Colours ButtonCommon::colour |
The colour of the button.
Definition at line 1323 of file network_gui.cpp.
| bool ButtonCommon::disabled |
Is the button disabled?
Definition at line 1324 of file network_gui.cpp.
Referenced by Button< CompanyID >::OnClick(), and NetworkClientListWindow::RebuildListCompany().
| uint ButtonCommon::height |
Calculated height of the button.
Definition at line 1325 of file network_gui.cpp.
| SpriteID ButtonCommon::sprite |
The sprite to use on the button.
Definition at line 1321 of file network_gui.cpp.
| StringID ButtonCommon::tooltip |
The tooltip of the button.
Definition at line 1322 of file network_gui.cpp.
Referenced by ButtonLine::GetTooltip().
| uint ButtonCommon::width |
Calculated width of the button.
Definition at line 1326 of file network_gui.cpp.