mirror of
https://github.com/bloxstraplabs/bloxstrap.git
synced 2025-04-18 16:41:36 -07:00
Fix some other things
This commit is contained in:
parent
2805263a63
commit
0d5be93616
@ -494,7 +494,7 @@ namespace Bloxstrap
|
||||
string oldStartPath = Path.Combine(Paths.WindowsStartMenu, "Bloxstrap");
|
||||
|
||||
if (File.Exists(oldDesktopPath))
|
||||
File.Move(oldDesktopPath, DesktopShortcut);
|
||||
File.Move(oldDesktopPath, DesktopShortcut, true);
|
||||
|
||||
if (Directory.Exists(oldStartPath))
|
||||
{
|
||||
|
@ -226,7 +226,7 @@ namespace Bloxstrap.Integrations
|
||||
{
|
||||
var lastActivity = History.First();
|
||||
|
||||
if (lastActivity is not null && Data.UniverseId == lastActivity.UniverseId && Data.IsTeleport)
|
||||
if (Data.UniverseId == lastActivity.UniverseId && Data.IsTeleport)
|
||||
Data.RootActivity = lastActivity.RootActivity ?? lastActivity;
|
||||
}
|
||||
}
|
||||
|
@ -28,6 +28,8 @@ namespace Bloxstrap.UI.Elements.ContextMenu
|
||||
|
||||
private ServerInformation? _serverInformationWindow;
|
||||
|
||||
private ServerHistory? _gameHistoryWindow;
|
||||
|
||||
public MenuContainer(Watcher watcher)
|
||||
{
|
||||
InitializeComponent();
|
||||
@ -51,13 +53,13 @@ namespace Bloxstrap.UI.Elements.ContextMenu
|
||||
{
|
||||
if (_serverInformationWindow is null)
|
||||
{
|
||||
_serverInformationWindow = new ServerInformation(_watcher);
|
||||
_serverInformationWindow = new(_watcher);
|
||||
_serverInformationWindow.Closed += (_, _) => _serverInformationWindow = null;
|
||||
}
|
||||
|
||||
if (!_serverInformationWindow.IsVisible)
|
||||
_serverInformationWindow.Show();
|
||||
|
||||
_serverInformationWindow.ShowDialog();
|
||||
else
|
||||
_serverInformationWindow.Activate();
|
||||
}
|
||||
|
||||
@ -135,7 +137,16 @@ namespace Bloxstrap.UI.Elements.ContextMenu
|
||||
if (_activityWatcher is null)
|
||||
throw new ArgumentNullException(nameof(_activityWatcher));
|
||||
|
||||
new ServerHistory(_activityWatcher).ShowDialog();
|
||||
if (_gameHistoryWindow is null)
|
||||
{
|
||||
_gameHistoryWindow = new(_activityWatcher);
|
||||
_gameHistoryWindow.Closed += (_, _) => _gameHistoryWindow = null;
|
||||
}
|
||||
|
||||
if (!_gameHistoryWindow.IsVisible)
|
||||
_gameHistoryWindow.ShowDialog();
|
||||
else
|
||||
_gameHistoryWindow.Activate();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user