mirror of
https://github.com/n00mkrad/flowframes.git
synced 2025-12-22 19:29:24 +01:00
Case-sensitive rename operation (2/2)
This commit is contained in:
25
Code/Ui/ControlExtensions.cs
Normal file
25
Code/Ui/ControlExtensions.cs
Normal file
@@ -0,0 +1,25 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace Flowframes.Ui
|
||||
{
|
||||
public static class ControlExtensions
|
||||
{
|
||||
[System.Runtime.InteropServices.DllImport("user32.dll")]
|
||||
public static extern bool LockWindowUpdate(IntPtr hWndLock);
|
||||
|
||||
public static void Suspend(this Control control)
|
||||
{
|
||||
LockWindowUpdate(control.Handle);
|
||||
}
|
||||
|
||||
public static void Resume(this Control control)
|
||||
{
|
||||
LockWindowUpdate(IntPtr.Zero);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user