feat: modules moved and engine moved to submodule
This commit is contained in:
parent
dfb5e645cd
commit
c33d2130cc
5136 changed files with 225275 additions and 64485 deletions
|
|
@ -31,6 +31,7 @@
|
|||
#include "openxr_action_editor.h"
|
||||
|
||||
#include "editor/editor_string_names.h"
|
||||
#include "editor/themes/editor_scale.h"
|
||||
|
||||
void OpenXRActionEditor::_bind_methods() {
|
||||
ClassDB::bind_method(D_METHOD("_do_set_name", "name"), &OpenXRActionEditor::_do_set_name);
|
||||
|
|
@ -133,25 +134,31 @@ OpenXRActionEditor::OpenXRActionEditor(Ref<OpenXRAction> p_action) {
|
|||
|
||||
action_name = memnew(LineEdit);
|
||||
action_name->set_text(action->get_name());
|
||||
action_name->set_custom_minimum_size(Size2(150.0, 0.0));
|
||||
action_name->set_tooltip_text(TTR("Internal name of the action. Some XR runtimes don't allow spaces or special characters."));
|
||||
action_name->set_custom_minimum_size(Size2(150.0 * EDSCALE, 0.0));
|
||||
action_name->connect(SceneStringName(text_changed), callable_mp(this, &OpenXRActionEditor::_on_action_name_changed));
|
||||
action_name->set_accessibility_name(TTRC("Action Name"));
|
||||
add_child(action_name);
|
||||
|
||||
action_localized_name = memnew(LineEdit);
|
||||
action_localized_name->set_text(action->get_localized_name());
|
||||
action_localized_name->set_custom_minimum_size(Size2(150.0, 0.0));
|
||||
action_localized_name->set_tooltip_text(TTR("Human-readable name of the action. This can be displayed to end users."));
|
||||
action_localized_name->set_custom_minimum_size(Size2(150.0 * EDSCALE, 0.0));
|
||||
action_localized_name->set_h_size_flags(Control::SIZE_EXPAND_FILL);
|
||||
action_localized_name->connect(SceneStringName(text_changed), callable_mp(this, &OpenXRActionEditor::_on_action_localized_name_changed));
|
||||
action_localized_name->set_accessibility_name(TTRC("Action Localized Name"));
|
||||
add_child(action_localized_name);
|
||||
|
||||
action_type_button = memnew(OptionButton);
|
||||
action_type_button->set_tooltip_text(TTR("Type of the action"));
|
||||
action_type_button->add_item("Bool", OpenXRAction::OPENXR_ACTION_BOOL);
|
||||
action_type_button->add_item("Float", OpenXRAction::OPENXR_ACTION_FLOAT);
|
||||
action_type_button->add_item("Vector2", OpenXRAction::OPENXR_ACTION_VECTOR2);
|
||||
action_type_button->add_item("Pose", OpenXRAction::OPENXR_ACTION_POSE);
|
||||
action_type_button->add_item("Haptic", OpenXRAction::OPENXR_ACTION_HAPTIC);
|
||||
action_type_button->set_accessibility_name(TTRC("Action Type"));
|
||||
action_type_button->select(int(action->get_action_type()));
|
||||
action_type_button->set_custom_minimum_size(Size2(100.0, 0.0));
|
||||
action_type_button->set_custom_minimum_size(Size2(100.0 * EDSCALE, 0.0));
|
||||
action_type_button->connect(SceneStringName(item_selected), callable_mp(this, &OpenXRActionEditor::_on_item_selected));
|
||||
add_child(action_type_button);
|
||||
|
||||
|
|
@ -159,6 +166,7 @@ OpenXRActionEditor::OpenXRActionEditor(Ref<OpenXRAction> p_action) {
|
|||
|
||||
rem_action = memnew(Button);
|
||||
rem_action->set_tooltip_text(TTR("Remove action"));
|
||||
rem_action->set_accessibility_name(TTRC("Remove action"));
|
||||
rem_action->connect(SceneStringName(pressed), callable_mp(this, &OpenXRActionEditor::_on_remove_action));
|
||||
rem_action->set_flat(true);
|
||||
add_child(rem_action);
|
||||
|
|
|
|||
|
|
@ -28,8 +28,7 @@
|
|||
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
|
||||
/**************************************************************************/
|
||||
|
||||
#ifndef OPENXR_ACTION_EDITOR_H
|
||||
#define OPENXR_ACTION_EDITOR_H
|
||||
#pragma once
|
||||
|
||||
#include "../action_map/openxr_action.h"
|
||||
|
||||
|
|
@ -71,5 +70,3 @@ public:
|
|||
Ref<OpenXRAction> get_action() { return action; }
|
||||
OpenXRActionEditor(Ref<OpenXRAction> p_action);
|
||||
};
|
||||
|
||||
#endif // OPENXR_ACTION_EDITOR_H
|
||||
|
|
|
|||
|
|
@ -34,6 +34,7 @@
|
|||
#include "editor/editor_node.h"
|
||||
#include "editor/gui/editor_bottom_panel.h"
|
||||
#include "editor/gui/editor_file_dialog.h"
|
||||
#include "editor/themes/editor_scale.h"
|
||||
|
||||
HashMap<String, String> OpenXRActionMapEditor::interaction_profile_editors;
|
||||
HashMap<String, String> OpenXRActionMapEditor::binding_modifier_editors;
|
||||
|
|
@ -431,7 +432,7 @@ String OpenXRActionMapEditor::get_binding_modifier_editor_class(const String &p_
|
|||
|
||||
OpenXRActionMapEditor::OpenXRActionMapEditor() {
|
||||
undo_redo = EditorUndoRedoManager::get_singleton();
|
||||
set_custom_minimum_size(Size2(0.0, 300.0));
|
||||
set_custom_minimum_size(Size2(0.0, 300.0 * EDSCALE));
|
||||
|
||||
top_hb = memnew(HBoxContainer);
|
||||
add_child(top_hb);
|
||||
|
|
@ -496,6 +497,3 @@ OpenXRActionMapEditor::OpenXRActionMapEditor() {
|
|||
// So load our action map and if it doesn't exist, create it right away.
|
||||
_load_action_map(GLOBAL_GET("xr/openxr/default_action_map"), true);
|
||||
}
|
||||
|
||||
OpenXRActionMapEditor::~OpenXRActionMapEditor() {
|
||||
}
|
||||
|
|
|
|||
|
|
@ -28,8 +28,7 @@
|
|||
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
|
||||
/**************************************************************************/
|
||||
|
||||
#ifndef OPENXR_ACTION_MAP_EDITOR_H
|
||||
#define OPENXR_ACTION_MAP_EDITOR_H
|
||||
#pragma once
|
||||
|
||||
#include "../action_map/openxr_action_map.h"
|
||||
#include "openxr_action_set_editor.h"
|
||||
|
|
@ -111,7 +110,4 @@ public:
|
|||
void open_action_map(String p_path);
|
||||
|
||||
OpenXRActionMapEditor();
|
||||
~OpenXRActionMapEditor();
|
||||
};
|
||||
|
||||
#endif // OPENXR_ACTION_MAP_EDITOR_H
|
||||
|
|
|
|||
|
|
@ -31,6 +31,7 @@
|
|||
#include "openxr_action_set_editor.h"
|
||||
|
||||
#include "editor/editor_string_names.h"
|
||||
#include "editor/themes/editor_scale.h"
|
||||
#include "openxr_action_editor.h"
|
||||
|
||||
void OpenXRActionSetEditor::_bind_methods() {
|
||||
|
|
@ -230,6 +231,7 @@ OpenXRActionSetEditor::OpenXRActionSetEditor(Ref<OpenXRActionMap> p_action_map,
|
|||
fold_btn = memnew(Button);
|
||||
fold_btn->set_v_size_flags(Control::SIZE_SHRINK_BEGIN);
|
||||
fold_btn->connect(SceneStringName(pressed), callable_mp(this, &OpenXRActionSetEditor::_on_toggle_expand));
|
||||
fold_btn->set_accessibility_name(TTRC("Fold"));
|
||||
fold_btn->set_flat(true);
|
||||
panel_hb->add_child(fold_btn);
|
||||
|
||||
|
|
@ -243,32 +245,40 @@ OpenXRActionSetEditor::OpenXRActionSetEditor(Ref<OpenXRActionMap> p_action_map,
|
|||
|
||||
action_set_name = memnew(LineEdit);
|
||||
action_set_name->set_text(action_set->get_name());
|
||||
action_set_name->set_custom_minimum_size(Size2(150.0, 0.0));
|
||||
action_set_name->set_tooltip_text(TTR("Internal name of the action. Some XR runtimes don't allow spaces or special characters."));
|
||||
action_set_name->set_custom_minimum_size(Size2(150.0 * EDSCALE, 0.0));
|
||||
action_set_name->connect(SceneStringName(text_changed), callable_mp(this, &OpenXRActionSetEditor::_on_action_set_name_changed));
|
||||
action_set_name->set_accessibility_name(TTRC("Action Set Name"));
|
||||
action_set_hb->add_child(action_set_name);
|
||||
|
||||
action_set_localized_name = memnew(LineEdit);
|
||||
action_set_localized_name->set_text(action_set->get_localized_name());
|
||||
action_set_localized_name->set_custom_minimum_size(Size2(150.0, 0.0));
|
||||
action_set_localized_name->set_tooltip_text(TTR("Human-readable name of the action set. This can be displayed to end users."));
|
||||
action_set_localized_name->set_custom_minimum_size(Size2(150.0 * EDSCALE, 0.0));
|
||||
action_set_localized_name->set_h_size_flags(Control::SIZE_EXPAND_FILL);
|
||||
action_set_localized_name->connect(SceneStringName(text_changed), callable_mp(this, &OpenXRActionSetEditor::_on_action_set_localized_name_changed));
|
||||
action_set_localized_name->set_accessibility_name(TTRC("Action Set Localized Name"));
|
||||
action_set_hb->add_child(action_set_localized_name);
|
||||
|
||||
action_set_priority = memnew(TextEdit);
|
||||
action_set_priority->set_text(itos(action_set->get_priority()));
|
||||
action_set_priority->set_custom_minimum_size(Size2(50.0, 0.0));
|
||||
action_set_priority->set_tooltip_text(TTR("Priority of the action set. If multiple action sets bind to the same input, the action set with the highest priority will be updated."));
|
||||
action_set_priority->set_custom_minimum_size(Size2(50.0 * EDSCALE, 0.0));
|
||||
action_set_priority->connect(SceneStringName(text_changed), callable_mp(this, &OpenXRActionSetEditor::_on_action_set_priority_changed));
|
||||
action_set_priority->set_accessibility_name(TTRC("Action Set Priority"));
|
||||
action_set_hb->add_child(action_set_priority);
|
||||
|
||||
add_action = memnew(Button);
|
||||
add_action->set_tooltip_text(TTR("Add action."));
|
||||
add_action->connect(SceneStringName(pressed), callable_mp(this, &OpenXRActionSetEditor::_on_add_action));
|
||||
add_action->set_accessibility_name(TTRC("Add"));
|
||||
add_action->set_flat(true);
|
||||
action_set_hb->add_child(add_action);
|
||||
|
||||
rem_action_set = memnew(Button);
|
||||
rem_action_set->set_tooltip_text(TTR("Remove action set."));
|
||||
rem_action_set->connect(SceneStringName(pressed), callable_mp(this, &OpenXRActionSetEditor::_on_remove_action_set));
|
||||
rem_action_set->set_accessibility_name(TTRC("Remove"));
|
||||
rem_action_set->set_flat(true);
|
||||
action_set_hb->add_child(rem_action_set);
|
||||
|
||||
|
|
|
|||
|
|
@ -28,8 +28,7 @@
|
|||
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
|
||||
/**************************************************************************/
|
||||
|
||||
#ifndef OPENXR_ACTION_SET_EDITOR_H
|
||||
#define OPENXR_ACTION_SET_EDITOR_H
|
||||
#pragma once
|
||||
|
||||
#include "../action_map/openxr_action_map.h"
|
||||
#include "../action_map/openxr_action_set.h"
|
||||
|
|
@ -94,5 +93,3 @@ public:
|
|||
|
||||
OpenXRActionSetEditor(Ref<OpenXRActionMap> p_action_map, Ref<OpenXRActionSet> p_action_set);
|
||||
};
|
||||
|
||||
#endif // OPENXR_ACTION_SET_EDITOR_H
|
||||
|
|
|
|||
|
|
@ -261,8 +261,9 @@ OpenXRBindingModifierEditor::OpenXRBindingModifierEditor() {
|
|||
header_hb->add_child(binding_modifier_title);
|
||||
|
||||
rem_binding_modifier_btn = memnew(Button);
|
||||
rem_binding_modifier_btn->set_tooltip_text(TTR("Remove binding modifier."));
|
||||
rem_binding_modifier_btn->set_tooltip_text(TTR("Remove this binding modifier."));
|
||||
rem_binding_modifier_btn->connect(SceneStringName(pressed), callable_mp(this, &OpenXRBindingModifierEditor::_on_remove_binding_modifier));
|
||||
rem_binding_modifier_btn->set_accessibility_name(TTRC("Remove"));
|
||||
rem_binding_modifier_btn->set_flat(true);
|
||||
header_hb->add_child(rem_binding_modifier_btn);
|
||||
|
||||
|
|
|
|||
|
|
@ -28,8 +28,7 @@
|
|||
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
|
||||
/**************************************************************************/
|
||||
|
||||
#ifndef OPENXR_BINDING_MODIFIER_EDITOR_H
|
||||
#define OPENXR_BINDING_MODIFIER_EDITOR_H
|
||||
#pragma once
|
||||
|
||||
#include "../action_map/openxr_action_map.h"
|
||||
#include "../action_map/openxr_action_set.h"
|
||||
|
|
@ -109,5 +108,3 @@ public:
|
|||
|
||||
OpenXRBindingModifierEditor();
|
||||
};
|
||||
|
||||
#endif // OPENXR_BINDING_MODIFIER_EDITOR_H
|
||||
|
|
|
|||
|
|
@ -32,6 +32,8 @@
|
|||
#include "../action_map/openxr_interaction_profile_metadata.h"
|
||||
#include "openxr_action_map_editor.h"
|
||||
|
||||
#include "editor/themes/editor_scale.h"
|
||||
|
||||
void OpenXRBindingModifiersDialog::_bind_methods() {
|
||||
ClassDB::bind_method(D_METHOD("_do_add_binding_modifier_editor", "binding_modifier_editor"), &OpenXRBindingModifiersDialog::_do_add_binding_modifier_editor);
|
||||
ClassDB::bind_method(D_METHOD("_do_remove_binding_modifier_editor", "binding_modifier_editor"), &OpenXRBindingModifiersDialog::_do_remove_binding_modifier_editor);
|
||||
|
|
@ -191,7 +193,7 @@ OpenXRBindingModifiersDialog::OpenXRBindingModifiersDialog() {
|
|||
set_transient(true);
|
||||
|
||||
binding_modifier_sc = memnew(ScrollContainer);
|
||||
binding_modifier_sc->set_custom_minimum_size(Size2(350.0, 0.0));
|
||||
binding_modifier_sc->set_custom_minimum_size(Size2(350.0 * EDSCALE, 0.0));
|
||||
binding_modifier_sc->set_h_size_flags(Control::SIZE_EXPAND_FILL);
|
||||
binding_modifier_sc->set_v_size_flags(Control::SIZE_EXPAND_FILL);
|
||||
binding_modifier_sc->set_horizontal_scroll_mode(ScrollContainer::SCROLL_MODE_DISABLED);
|
||||
|
|
|
|||
|
|
@ -28,8 +28,7 @@
|
|||
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
|
||||
/**************************************************************************/
|
||||
|
||||
#ifndef OPENXR_BINDING_MODIFIERS_DIALOG_H
|
||||
#define OPENXR_BINDING_MODIFIERS_DIALOG_H
|
||||
#pragma once
|
||||
|
||||
#include "../action_map/openxr_action_map.h"
|
||||
#include "../action_map/openxr_interaction_profile.h"
|
||||
|
|
@ -77,5 +76,3 @@ public:
|
|||
|
||||
void setup(Ref<OpenXRActionMap> p_action_map, Ref<OpenXRInteractionProfile> p_interaction_profile, Ref<OpenXRIPBinding> p_ip_binding = Ref<OpenXRIPBinding>());
|
||||
};
|
||||
|
||||
#endif // OPENXR_BINDING_MODIFIERS_DIALOG_H
|
||||
|
|
|
|||
|
|
@ -64,6 +64,3 @@ OpenXREditorPlugin::OpenXREditorPlugin() {
|
|||
add_control_to_container(CONTAINER_TOOLBAR, select_runtime);
|
||||
#endif
|
||||
}
|
||||
|
||||
OpenXREditorPlugin::~OpenXREditorPlugin() {
|
||||
}
|
||||
|
|
|
|||
|
|
@ -28,8 +28,7 @@
|
|||
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
|
||||
/**************************************************************************/
|
||||
|
||||
#ifndef OPENXR_EDITOR_PLUGIN_H
|
||||
#define OPENXR_EDITOR_PLUGIN_H
|
||||
#pragma once
|
||||
|
||||
#include "openxr_action_map_editor.h"
|
||||
#include "openxr_binding_modifier_editor.h"
|
||||
|
|
@ -54,7 +53,4 @@ public:
|
|||
virtual void make_visible(bool p_visible) override;
|
||||
|
||||
OpenXREditorPlugin();
|
||||
~OpenXREditorPlugin();
|
||||
};
|
||||
|
||||
#endif // OPENXR_EDITOR_PLUGIN_H
|
||||
|
|
|
|||
|
|
@ -181,6 +181,7 @@ OpenXRInteractionProfileEditorBase::OpenXRInteractionProfileEditorBase() {
|
|||
binding_modifiers_btn = memnew(Button);
|
||||
binding_modifiers_btn->set_tooltip_text(TTR("Edit binding modifiers"));
|
||||
binding_modifiers_btn->connect("pressed", callable_mp(this, &OpenXRInteractionProfileEditorBase::_on_open_binding_modifiers));
|
||||
binding_modifiers_btn->set_accessibility_name(TTRC("Edit"));
|
||||
// TODO show visual difference if there are binding modifiers for this interaction profile
|
||||
toolbar_vb->add_child(binding_modifiers_btn);
|
||||
}
|
||||
|
|
@ -308,6 +309,7 @@ void OpenXRInteractionProfileEditor::_add_io_path(VBoxContainer *p_container, co
|
|||
action_binding_modifiers_btn->set_flat(true);
|
||||
action_binding_modifiers_btn->set_button_icon(get_theme_icon(SNAME("Modifiers"), EditorStringName(EditorIcons)));
|
||||
action_binding_modifiers_btn->connect(SceneStringName(pressed), callable_mp((Window *)action_binding_modifiers_dialog, &Window::popup_centered).bind(Size2i(500, 400)));
|
||||
action_binding_modifiers_btn->set_accessibility_name(TTRC("Modifiers"));
|
||||
// TODO change style of button if there are binding modifiers
|
||||
action_hb->add_child(action_binding_modifiers_btn);
|
||||
|
||||
|
|
@ -315,6 +317,7 @@ void OpenXRInteractionProfileEditor::_add_io_path(VBoxContainer *p_container, co
|
|||
action_rem->set_flat(true);
|
||||
action_rem->set_button_icon(get_theme_icon(SNAME("Remove"), EditorStringName(EditorIcons)));
|
||||
action_rem->connect(SceneStringName(pressed), callable_mp((OpenXRInteractionProfileEditor *)this, &OpenXRInteractionProfileEditor::_on_remove_pressed).bind(action->get_name_with_set(), String(p_io_path->openxr_path)));
|
||||
action_rem->set_accessibility_name(TTRC("Remove"));
|
||||
action_hb->add_child(action_rem);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -28,8 +28,7 @@
|
|||
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
|
||||
/**************************************************************************/
|
||||
|
||||
#ifndef OPENXR_INTERACTION_PROFILE_EDITOR_H
|
||||
#define OPENXR_INTERACTION_PROFILE_EDITOR_H
|
||||
#pragma once
|
||||
|
||||
#include "../action_map/openxr_action_map.h"
|
||||
#include "../action_map/openxr_interaction_profile.h"
|
||||
|
|
@ -106,5 +105,3 @@ public:
|
|||
|
||||
OpenXRInteractionProfileEditor();
|
||||
};
|
||||
|
||||
#endif // OPENXR_INTERACTION_PROFILE_EDITOR_H
|
||||
|
|
|
|||
|
|
@ -30,6 +30,8 @@
|
|||
|
||||
#include "openxr_select_action_dialog.h"
|
||||
|
||||
#include "editor/themes/editor_scale.h"
|
||||
|
||||
void OpenXRSelectActionDialog::_bind_methods() {
|
||||
ADD_SIGNAL(MethodInfo("action_selected", PropertyInfo(Variant::STRING, "action")));
|
||||
}
|
||||
|
|
@ -124,7 +126,7 @@ OpenXRSelectActionDialog::OpenXRSelectActionDialog(Ref<OpenXRActionMap> p_action
|
|||
set_title(TTR("Select an action"));
|
||||
|
||||
scroll = memnew(ScrollContainer);
|
||||
scroll->set_custom_minimum_size(Size2(600.0, 400.0));
|
||||
scroll->set_custom_minimum_size(Size2(600.0 * EDSCALE, 400.0 * EDSCALE));
|
||||
add_child(scroll);
|
||||
|
||||
main_vb = memnew(VBoxContainer);
|
||||
|
|
|
|||
|
|
@ -28,8 +28,7 @@
|
|||
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
|
||||
/**************************************************************************/
|
||||
|
||||
#ifndef OPENXR_SELECT_ACTION_DIALOG_H
|
||||
#define OPENXR_SELECT_ACTION_DIALOG_H
|
||||
#pragma once
|
||||
|
||||
#include "../action_map/openxr_action_map.h"
|
||||
|
||||
|
|
@ -64,5 +63,3 @@ public:
|
|||
|
||||
OpenXRSelectActionDialog(Ref<OpenXRActionMap> p_action_map);
|
||||
};
|
||||
|
||||
#endif // OPENXR_SELECT_ACTION_DIALOG_H
|
||||
|
|
|
|||
|
|
@ -33,6 +33,8 @@
|
|||
#include "../action_map/openxr_interaction_profile_metadata.h"
|
||||
#include "../openxr_api.h"
|
||||
|
||||
#include "editor/themes/editor_scale.h"
|
||||
|
||||
void OpenXRSelectInteractionProfileDialog::_bind_methods() {
|
||||
ADD_SIGNAL(MethodInfo("interaction_profile_selected", PropertyInfo(Variant::STRING, "interaction_profile")));
|
||||
}
|
||||
|
|
@ -116,7 +118,7 @@ OpenXRSelectInteractionProfileDialog::OpenXRSelectInteractionProfileDialog() {
|
|||
set_title(TTR("Select an interaction profile"));
|
||||
|
||||
scroll = memnew(ScrollContainer);
|
||||
scroll->set_custom_minimum_size(Size2(600.0, 400.0));
|
||||
scroll->set_custom_minimum_size(Size2(600.0 * EDSCALE, 400.0 * EDSCALE));
|
||||
add_child(scroll);
|
||||
|
||||
main_vb = memnew(VBoxContainer);
|
||||
|
|
|
|||
|
|
@ -28,8 +28,7 @@
|
|||
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
|
||||
/**************************************************************************/
|
||||
|
||||
#ifndef OPENXR_SELECT_INTERACTION_PROFILE_DIALOG_H
|
||||
#define OPENXR_SELECT_INTERACTION_PROFILE_DIALOG_H
|
||||
#pragma once
|
||||
|
||||
#include "scene/gui/box_container.h"
|
||||
#include "scene/gui/dialogs.h"
|
||||
|
|
@ -58,5 +57,3 @@ public:
|
|||
|
||||
OpenXRSelectInteractionProfileDialog();
|
||||
};
|
||||
|
||||
#endif // OPENXR_SELECT_INTERACTION_PROFILE_DIALOG_H
|
||||
|
|
|
|||
|
|
@ -54,10 +54,9 @@ void OpenXRSelectRuntime::_update_items() {
|
|||
set_item_metadata(index, "");
|
||||
index++;
|
||||
|
||||
Array keys = runtimes.keys();
|
||||
for (int i = 0; i < keys.size(); i++) {
|
||||
String key = keys[i];
|
||||
String path = runtimes[key];
|
||||
for (const KeyValue<Variant, Variant> &kv : runtimes) {
|
||||
const String &key = kv.key;
|
||||
const String &path = kv.value;
|
||||
String adj_path = path.replace("~", home_folder);
|
||||
|
||||
if (da->file_exists(adj_path)) {
|
||||
|
|
|
|||
|
|
@ -28,8 +28,7 @@
|
|||
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
|
||||
/**************************************************************************/
|
||||
|
||||
#ifndef OPENXR_SELECT_RUNTIME_H
|
||||
#define OPENXR_SELECT_RUNTIME_H
|
||||
#pragma once
|
||||
|
||||
#include "scene/gui/option_button.h"
|
||||
|
||||
|
|
@ -46,5 +45,3 @@ private:
|
|||
void _update_items();
|
||||
void _on_item_selected(int p_which);
|
||||
};
|
||||
|
||||
#endif // OPENXR_SELECT_RUNTIME_H
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue