mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-15 11:03:00 +01:00
Allow assigning a keyboard shortcut for opening the tile inspector (#7994)
* Allow assigning a keyboard shortcut for opening the tile inspector. * Only open when debug tools are enabled. * Add changelog entry
This commit is contained in:
committed by
Michał Janiszewski
parent
3e97b20025
commit
47eea292b5
@@ -3727,6 +3727,7 @@ STR_6263 :{SMALLFONT}{BLACK}Toggle all sound on/off
|
||||
STR_6264 :Always use system file browser
|
||||
STR_6265 :{SMALLFONT}{BLACK}When enabled, your operating system's file browser will be used instead of OpenRCT2's.
|
||||
STR_6266 :Open custom content folder
|
||||
STR_6267 :Open tile inspector
|
||||
|
||||
#############
|
||||
# Scenarios #
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
- Improved: [#7730] Draw extreme vertical and lateral Gs red in the ride window's graph tab.
|
||||
- Improved: [#7930] Automatically create folders for custom content.
|
||||
- Improved: [#7980] Show the full path of the scenario in the scenario select window.
|
||||
- Improved: [#7993] Allow assigning a keyboard shortcut for opening the tile inspector.
|
||||
- Removed: [#7929] Support for scenario text objects.
|
||||
|
||||
0.2.1 (2018-08-26)
|
||||
|
||||
@@ -749,6 +749,14 @@ static void shortcut_highlight_path_issues_toggle()
|
||||
toggle_view_flag(VIEWPORT_FLAG_HIGHLIGHT_PATH_ISSUES);
|
||||
}
|
||||
|
||||
static void shortcut_open_tile_inspector()
|
||||
{
|
||||
if (gScreenFlags & SCREEN_FLAGS_TITLE_DEMO || !gConfigGeneral.debugging_tools)
|
||||
return;
|
||||
|
||||
context_open_window(WC_TILE_INSPECTOR);
|
||||
}
|
||||
|
||||
namespace
|
||||
{
|
||||
const shortcut_action shortcut_table[SHORTCUT_COUNT] = {
|
||||
@@ -821,6 +829,7 @@ namespace
|
||||
shortcut_gridlines_toggle,
|
||||
shortcut_view_clipping,
|
||||
shortcut_highlight_path_issues_toggle,
|
||||
shortcut_open_tile_inspector,
|
||||
};
|
||||
} // anonymous namespace
|
||||
|
||||
|
||||
@@ -316,4 +316,5 @@ const uint16_t KeyboardShortcuts::DefaultKeys[SHORTCUT_COUNT] = {
|
||||
SDL_SCANCODE_7, // SHORTCUT_GRIDLINES_DISPLAY_TOGGLE
|
||||
SHORTCUT_UNDEFINED, // SHORTCUT_VIEW_CLIPPING
|
||||
SDL_SCANCODE_I, // SHORTCUT_HIGHLIGHT_PATH_ISSUES_TOGGLE
|
||||
SHORTCUT_UNDEFINED, // SHORTCUT_TILE_INSPECTOR
|
||||
};
|
||||
|
||||
@@ -93,6 +93,7 @@ enum
|
||||
SHORTCUT_GRIDLINES_DISPLAY_TOGGLE,
|
||||
SHORTCUT_VIEW_CLIPPING,
|
||||
SHORTCUT_HIGHLIGHT_PATH_ISSUES_TOGGLE,
|
||||
SHORTCUT_TILE_INSPECTOR,
|
||||
|
||||
SHORTCUT_COUNT,
|
||||
|
||||
|
||||
@@ -148,6 +148,7 @@ const rct_string_id ShortcutStringIds[SHORTCUT_COUNT] = {
|
||||
STR_SHORTCUT_GRIDLINES_DISPLAY_TOGGLE,
|
||||
STR_SHORTCUT_VIEW_CLIPPING,
|
||||
STR_SHORTCUT_HIGHLIGHT_PATH_ISSUES_TOGGLE,
|
||||
STR_SHORTCUT_OPEN_TILE_INSPECTOR,
|
||||
};
|
||||
// clang-format on
|
||||
|
||||
|
||||
@@ -3893,6 +3893,8 @@ enum
|
||||
|
||||
STR_OPEN_USER_CONTENT_FOLDER = 6266,
|
||||
|
||||
STR_SHORTCUT_OPEN_TILE_INSPECTOR = 6267,
|
||||
|
||||
// Have to include resource strings (from scenarios and objects) for the time being now that language is partially working
|
||||
STR_COUNT = 32768
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user