Skip to content
This repository has been archived by the owner on Sep 21, 2022. It is now read-only.

For SteamVR projects, show Desktop view before opening URLs #25

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions src/UI/AccountOptionsMenu.cs
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,9 @@ public void OpenProfileInBrowser()
profileURL += "?ref=steam";
}

#if STEAM_VR
Valve.VR.OpenVR.Overlay.ShowDashboard("valve.steam.desktop");
#endif
Application.OpenURL(profileURL);
this.viewProfileButton.interactable = true;
}
Expand Down
3 changes: 3 additions & 0 deletions src/UI/Utility/UIUtilities.cs
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,9 @@ public static void OpenYouTubeVideoURL(string youTubeVideoId)
{
if(!String.IsNullOrEmpty(youTubeVideoId))
{
#if STEAM_VR
Valve.VR.OpenVR.Overlay.ShowDashboard("valve.steam.desktop");
#endif
Application.OpenURL(@"https://youtu.be/" + youTubeVideoId);
}
}
Expand Down
3 changes: 3 additions & 0 deletions src/UI/Utility/WebLinkFollower.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ public class WebLinkFollower : MonoBehaviour
{
public void OpenBrowserAt(string url)
{
#if STEAM_VR
Valve.VR.OpenVR.Overlay.ShowDashboard("valve.steam.desktop");
#endif
Application.OpenURL(url);
}
}
Expand Down