Remove application::path_to_string/string_to_path
This commit is contained in:
@@ -1094,7 +1094,7 @@ void application::initialize_actions()
|
|||||||
{
|
{
|
||||||
for (auto & [path, action]: generic_trackers)
|
for (auto & [path, action]: generic_trackers)
|
||||||
{
|
{
|
||||||
if (name.starts_with(path_to_string(path)))
|
if (name.starts_with(xr_instance.path_to_string(path)))
|
||||||
action = xr_session.create_action_space(a);
|
action = xr_session.create_action_space(a);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1134,7 +1134,7 @@ void application::initialize_actions()
|
|||||||
|
|
||||||
xr_bindings.push_back(XrActionSuggestedBinding{
|
xr_bindings.push_back(XrActionSuggestedBinding{
|
||||||
.action = a,
|
.action = a,
|
||||||
.binding = string_to_path(k.input_source)});
|
.binding = xr_instance.string_to_path(k.input_source)});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1151,7 +1151,7 @@ void application::initialize_actions()
|
|||||||
|
|
||||||
for (const auto & name: profile.input_sources)
|
for (const auto & name: profile.input_sources)
|
||||||
{
|
{
|
||||||
xr_bindings.push_back({actions_by_name[name], string_to_path(name)});
|
xr_bindings.push_back({actions_by_name[name], xr_instance.string_to_path(name)});
|
||||||
}
|
}
|
||||||
|
|
||||||
try
|
try
|
||||||
|
|||||||
@@ -262,16 +262,6 @@ public:
|
|||||||
return std::make_pair(position, orientation);
|
return std::make_pair(position, orientation);
|
||||||
}
|
}
|
||||||
|
|
||||||
static XrPath string_to_path(const std::string & s)
|
|
||||||
{
|
|
||||||
return instance().xr_instance.string_to_path(s);
|
|
||||||
}
|
|
||||||
|
|
||||||
static std::string path_to_string(XrPath p)
|
|
||||||
{
|
|
||||||
return instance().xr_instance.path_to_string(p);
|
|
||||||
}
|
|
||||||
|
|
||||||
void run();
|
void run();
|
||||||
|
|
||||||
static void push_scene(std::shared_ptr<scene>);
|
static void push_scene(std::shared_ptr<scene>);
|
||||||
|
|||||||
@@ -360,7 +360,7 @@ std::shared_ptr<scenes::stream> scenes::stream::create(std::unique_ptr<wivrn_ses
|
|||||||
{
|
{
|
||||||
self->haptics_actions.emplace(id, haptics_action{
|
self->haptics_actions.emplace(id, haptics_action{
|
||||||
.action = action.first,
|
.action = action.first,
|
||||||
.path = application::string_to_path(path),
|
.path = self->instance.string_to_path(path),
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user