|
OpenTTD Source 20251116-master-g21329071df
|
The GUI for objects. More...
#include "stdafx.h"#include "command_func.h"#include "company_func.h"#include "hotkeys.h"#include "newgrf.h"#include "newgrf_badge_gui.h"#include "newgrf_object.h"#include "newgrf_text.h"#include "object.h"#include "object_base.h"#include "picker_gui.h"#include "sound_func.h"#include "strings_func.h"#include "viewport_func.h"#include "tilehighlight_func.h"#include "window_gui.h"#include "window_func.h"#include "zoom_func.h"#include "terraform_cmd.h"#include "object_cmd.h"#include "road_cmd.h"#include "widgets/object_widget.h"#include "table/strings.h"#include "safeguards.h"Go to the source code of this file.
Data Structures | |
| struct | ObjectPickerSelection |
| class | ObjectPickerCallbacks |
| class | BuildObjectWindow |
| The window used for building objects. More... | |
Functions | |
| Window * | ShowBuildObjectPicker () |
| Show our object picker. | |
| void | InitializeObjectGui () |
| Reset all data of the object GUI. | |
Variables | |
| static ObjectPickerSelection | _object_gui |
| Settings of the object picker. | |
| static constexpr std::initializer_list< NWidgetPart > | _nested_build_object_widgets |
| static WindowDesc | _build_object_desc (WDP_AUTO, "build_object", 0, 0, WC_BUILD_OBJECT, WC_BUILD_TOOLBAR, WindowDefaultFlag::Construction, _nested_build_object_widgets, &BuildObjectWindow::hotkeys) |
The GUI for objects.
Definition in file object_gui.cpp.
| void InitializeObjectGui | ( | ) |
Reset all data of the object GUI.
Definition at line 435 of file object_gui.cpp.
References _object_gui, OBJECT_CLASS_BEGIN, and ObjectPickerSelection::sel_class.
| Window * ShowBuildObjectPicker | ( | ) |
Show our object picker.
Definition at line 425 of file object_gui.cpp.
Referenced by BuildObjectWindow::BuildObjectGlobalHotkeys(), TerraformToolbarWindow::OnClick(), and ScenarioEditorLandscapeGenerationWindow::OnClick().
|
staticconstexpr |
Definition at line 388 of file object_gui.cpp.
|
static |
Settings of the object picker.
Definition at line 43 of file object_gui.cpp.
Referenced by ObjectPickerCallbacks::DrawType(), BuildObjectWindow::DrawWidget(), ObjectPickerCallbacks::GetSelectedClass(), ObjectPickerCallbacks::GetSelectedType(), BuildObjectWindow::GetWidgetString(), InitializeObjectGui(), BuildObjectWindow::OnClick(), BuildObjectWindow::OnInvalidateData(), BuildObjectWindow::OnPlaceMouseUp(), BuildObjectWindow::OnPlaceObject(), ObjectPickerCallbacks::SetSelectedClass(), ObjectPickerCallbacks::SetSelectedType(), BuildObjectWindow::UpdateButtons(), and BuildObjectWindow::UpdateWidgetSize().