mirror of
https://github.com/MrUnknownDE/VRCX.git
synced 2026-04-19 23:03:51 +02:00
Remove wine support for Cef
This commit is contained in:
@@ -223,10 +223,5 @@ namespace VRCX
|
||||
using var client = MainForm.Instance.Browser.GetDevToolsClient();
|
||||
_ = client.Network.SetUserAgentOverrideAsync(Program.Version);
|
||||
}
|
||||
|
||||
public override bool IsRunningUnderWine()
|
||||
{
|
||||
return Wine.GetIfWine();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -65,21 +65,16 @@ namespace VRCX
|
||||
{
|
||||
return CultureInfo.CurrentCulture.ToString();
|
||||
}
|
||||
|
||||
|
||||
public override string CustomVrScript()
|
||||
{
|
||||
var filePath = Path.Join(Program.AppDataDirectory, "customvr.js");
|
||||
if (File.Exists(filePath))
|
||||
return File.ReadAllText(filePath);
|
||||
|
||||
|
||||
return string.Empty;
|
||||
}
|
||||
|
||||
public override bool IsRunningUnderWine()
|
||||
{
|
||||
return Wine.GetIfWine();
|
||||
}
|
||||
|
||||
public override List<KeyValuePair<string, string>> GetExecuteVrFeedFunctionQueue()
|
||||
{
|
||||
throw new NotImplementedException("GetExecuteVrFeedFunctionQueue is not implemented in AppApiVrCef.");
|
||||
|
||||
@@ -24,21 +24,10 @@ namespace VRCX
|
||||
var isGameRunning = false;
|
||||
var isSteamVRRunning = false;
|
||||
var isHmdAfk = false;
|
||||
|
||||
|
||||
if (ProcessMonitor.Instance.IsProcessRunning("VRChat"))
|
||||
isGameRunning = true;
|
||||
|
||||
if (Wine.GetIfWine())
|
||||
{
|
||||
var wineTmpPath = Path.Join(Program.AppDataDirectory, "wine.tmp");
|
||||
if (File.Exists(wineTmpPath))
|
||||
{
|
||||
var wineTmp = File.ReadAllText(wineTmpPath);
|
||||
if (wineTmp.Contains("isGameRunning=true"))
|
||||
isGameRunning = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (ProcessMonitor.Instance.IsProcessRunning("vrserver"))
|
||||
isSteamVRRunning = true;
|
||||
|
||||
@@ -49,7 +38,7 @@ namespace VRCX
|
||||
if (MainForm.Instance?.Browser != null && !MainForm.Instance.Browser.IsLoading && MainForm.Instance.Browser.CanExecuteJavascriptInMainFrame)
|
||||
MainForm.Instance.Browser.ExecuteScriptAsync("$app.store.game.updateIsGameRunning", isGameRunning, isSteamVRRunning, isHmdAfk);
|
||||
}
|
||||
|
||||
|
||||
public override bool IsGameRunning()
|
||||
{
|
||||
// unused
|
||||
@@ -61,7 +50,7 @@ namespace VRCX
|
||||
// unused
|
||||
return ProcessMonitor.Instance.IsProcessRunning("vrserver");
|
||||
}
|
||||
|
||||
|
||||
public override int QuitGame()
|
||||
{
|
||||
var processes = Process.GetProcessesByName("vrchat");
|
||||
|
||||
@@ -14,7 +14,7 @@ namespace VRCX
|
||||
public abstract void SetZoom(double zoomLevel);
|
||||
public abstract Task<double> GetZoom();
|
||||
public abstract void DesktopNotification(string BoldText, string Text = "", string Image = "");
|
||||
|
||||
|
||||
public abstract void RestartApplication(bool isUpgrade);
|
||||
public abstract bool CheckForUpdateExe();
|
||||
public abstract void ExecuteAppFunction(string function, string json);
|
||||
@@ -28,7 +28,6 @@ namespace VRCX
|
||||
public abstract void CopyImageToClipboard(string path);
|
||||
public abstract void FlashWindow();
|
||||
public abstract void SetUserAgent();
|
||||
public abstract bool IsRunningUnderWine();
|
||||
|
||||
// Folders
|
||||
public abstract string GetVRChatAppDataLocation();
|
||||
@@ -48,7 +47,7 @@ namespace VRCX
|
||||
|
||||
public abstract Task<string> OpenFileSelectorDialog(string defaultPath = "", string defaultExt = "",
|
||||
string defaultFilter = "All files (*.*)|*.*");
|
||||
|
||||
|
||||
// GameHandler
|
||||
public abstract void OnProcessStateChanged(MonitoredProcess monitoredProcess);
|
||||
public abstract void CheckGameRunning();
|
||||
@@ -57,7 +56,7 @@ namespace VRCX
|
||||
public abstract int QuitGame();
|
||||
public abstract bool StartGame(string arguments);
|
||||
public abstract bool StartGameFromPath(string path, string arguments);
|
||||
|
||||
|
||||
// RegistryPlayerPrefs
|
||||
public abstract object GetVRChatRegistryKey(string key);
|
||||
public abstract string GetVRChatRegistryKeyString(string key);
|
||||
@@ -68,7 +67,7 @@ namespace VRCX
|
||||
public abstract bool HasVRChatRegistryFolder();
|
||||
public abstract void DeleteVRChatRegistryFolder();
|
||||
public abstract string ReadVrcRegJsonFile(string filepath);
|
||||
|
||||
|
||||
// Screenshot
|
||||
public abstract string AddScreenshotMetadata(string path, string metadataString, string worldId, bool changeFilename = false);
|
||||
}
|
||||
|
||||
@@ -13,7 +13,6 @@ public abstract partial class AppApiVr
|
||||
public abstract double GetUptime();
|
||||
public abstract string CurrentCulture();
|
||||
public abstract string CustomVrScript();
|
||||
public abstract bool IsRunningUnderWine();
|
||||
public abstract List<KeyValuePair<string, string>> GetExecuteVrFeedFunctionQueue();
|
||||
public abstract List<KeyValuePair<string, string>> GetExecuteVrOverlayFunctionQueue();
|
||||
}
|
||||
@@ -147,12 +147,5 @@ namespace VRCX
|
||||
public override void SetUserAgent()
|
||||
{
|
||||
}
|
||||
|
||||
public override bool IsRunningUnderWine()
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
@@ -93,10 +93,5 @@ namespace VRCX
|
||||
|
||||
return string.Empty;
|
||||
}
|
||||
|
||||
public override bool IsRunningUnderWine()
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user