예제 #1
0
        public static bool IsProgramManagerOrHiddenTrayWindow(IntPtr hWnd)
        {
            // Kind of magic...
            var titlebarInfo = new TITLEBARINFO();
            titlebarInfo.cbSize = (uint)Marshal.SizeOf(titlebarInfo);

            if (!NativeMethods.GetTitleBarInfo(hWnd, ref titlebarInfo))
            {
                throw new Win32Exception();
            }
            return (titlebarInfo.rgstate[0] & (uint)TBBStates.STATE_SYSTEM_INVISIBLE) != 0;
        }
예제 #2
0
 public static extern bool GetTitleBarInfo(IntPtr hWnd, ref TITLEBARINFO pti);