mirror of
https://github.com/stuff-by-3-random-dudes/UWUVCI-AIO-WPF
synced 2024-11-22 19:13:11 +00:00
fixed more shit
This commit is contained in:
parent
9ec440c7bb
commit
7c95435696
2 changed files with 33 additions and 6 deletions
|
@ -23,10 +23,10 @@ namespace UWUVCI_AIO_WPF
|
|||
Process[] pname = Process.GetProcessesByName("UWUVCI AIO");
|
||||
if (pname.Length > 1)
|
||||
{
|
||||
|
||||
t.Elapsed += KillProg;
|
||||
t.Start();
|
||||
Custom_Message cm = new Custom_Message("Another Instance Running", "You already got another instance of UWUVCI AIO running.\nThis instance of UWUVCI will terminate in 5 seconds.");
|
||||
Custom_Message cm = new Custom_Message("Another Instance Running", "You already got another instance of UWUVCI AIO running.\nThis instance will terminate in 5 seconds.");
|
||||
|
||||
cm.ShowDialog();
|
||||
KillProg(null, null);
|
||||
}
|
||||
|
@ -37,7 +37,8 @@ namespace UWUVCI_AIO_WPF
|
|||
if (witdh < 1150 || height < 700)
|
||||
{
|
||||
t.Elapsed += KillProg;
|
||||
t.Start(); Custom_Message cm = new Custom_Message("Resolution not supported", "Your screen resolution is not supported, please use a resolution of atleast 1152x864\nUWUVCI will terminate in 5 seconds.");
|
||||
t.Start();
|
||||
Custom_Message cm = new Custom_Message("Resolution not supported", "Your screen resolution is not supported, please use a resolution of atleast 1152x864\nThis instance will terminate in 5 seconds.");
|
||||
cm.ShowDialog();
|
||||
KillProg(null, null);
|
||||
}
|
||||
|
|
|
@ -74,7 +74,15 @@ namespace UWUVCI_AIO_WPF.UI.Windows
|
|||
{
|
||||
dont.Visibility = Visibility.Visible;
|
||||
}
|
||||
|
||||
if (title.ToLower().Contains("instance"))
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public void CloseProgram(object sender, RoutedEventArgs e)
|
||||
{
|
||||
Environment.Exit(1);
|
||||
}
|
||||
public Custom_Message(string title, string message, string Path)
|
||||
{
|
||||
|
@ -225,12 +233,30 @@ namespace UWUVCI_AIO_WPF.UI.Windows
|
|||
|
||||
private void wind_Closing(object sender, System.ComponentModel.CancelEventArgs e)
|
||||
{
|
||||
(FindResource("mvm") as MainViewModel).mw.Topmost = true;
|
||||
|
||||
try
|
||||
{
|
||||
if((FindResource("mvm") as MainViewModel).mw != null)
|
||||
(FindResource("mvm") as MainViewModel).mw.Topmost = true;
|
||||
}
|
||||
catch (Exception s)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
private void wind_Closed(object sender, EventArgs e)
|
||||
{
|
||||
(FindResource("mvm") as MainViewModel).mw.Topmost = false;
|
||||
try
|
||||
{
|
||||
if ((FindResource("mvm") as MainViewModel).mw != null)
|
||||
(FindResource("mvm") as MainViewModel).mw.Topmost = false;
|
||||
}
|
||||
catch (Exception s)
|
||||
{
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue