mirror of
https://github.com/Hofknecht/SystemTrayMenu.git
synced 2024-09-29 16:51:18 +13:00
f867894a1e
[Feature] Bigger buttons for Touch #113
18 lines
449 B
C#
18 lines
449 B
C#
using System.Runtime.InteropServices;
|
|
|
|
namespace SystemTrayMenu.DllImports
|
|
{
|
|
public static partial class NativeMethods
|
|
{
|
|
[DllImport("user32.dll")]
|
|
private static extern int GetSystemMetrics(int nIndex);
|
|
|
|
public static bool IsTouchEnabled()
|
|
{
|
|
const int MAXTOUCHES_INDEX = 95;
|
|
int maxTouches = GetSystemMetrics(MAXTOUCHES_INDEX);
|
|
|
|
return maxTouches > 0;
|
|
}
|
|
}
|
|
}
|