Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions Src/StartMenu/StartMenuDLL/StartMenuDLL.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3966,7 +3966,7 @@ if (!g_bTrimHooks)
if (msg->message==WM_MOUSEMOVE)
{
TaskbarInfo *taskBar=FindTaskBarInfoButton(msg->hwnd);
if (taskBar && !CMenuContainer::IsMenuOpened() && !WindowsMenuOpened())
if (taskBar && !taskBar->bSuppressHover && !CMenuContainer::IsMenuOpened() && !WindowsMenuOpened())
{
if (GetSettingInt(L"Hover") && !taskBar->bTimer)
{
Expand All @@ -3987,6 +3987,7 @@ if (!g_bTrimHooks)
TaskbarInfo *taskBar=FindTaskBarInfoButton(msg->hwnd);
if (taskBar)
{
taskBar->bSuppressHover=false;
taskBar->bTimer=false;
KillTimer(msg->hwnd,'CLSM');
if (taskBar->oldButton==msg->hwnd)
Expand All @@ -4013,7 +4014,9 @@ if (!g_bTrimHooks)
TaskbarInfo *taskBar=FindTaskBarInfoBar(msg->hwnd);
if (taskBar)
{
if (!CMenuContainer::IsMenuOpened() && !WindowsMenuOpened() && PointAroundStartButton(taskBar->taskbarId))
if (!PointAroundStartButton(taskBar->taskbarId))
taskBar->bSuppressHover=false;
if (!taskBar->bSuppressHover && !CMenuContainer::IsMenuOpened() && !WindowsMenuOpened() && PointAroundStartButton(taskBar->taskbarId))
{
if (!taskBar->bTimer)
{
Expand Down Expand Up @@ -4232,6 +4235,8 @@ if (!g_bTrimHooks)
// Win+X is shown asynchronously on Windows 11. Cancel any pending
// hover-open timer first, otherwise it can open the configured
// hover menu a moment later and dismiss Win+X again.
if (IsWin11())
taskBar->bSuppressHover=true;
if (taskBar->bTimer)
{
taskBar->bTimer=false;
Expand Down
3 changes: 2 additions & 1 deletion Src/StartMenu/StartMenuDLL/StartMenuDLL.h
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ void EnableStartTooltip( bool bEnable );

struct TaskbarInfo
{
TaskbarInfo( void ) { taskbarId=pointerId=0; taskBar=startButton=oldButton=rebar=taskList=chevron=news=desktop=NULL; startButtonSize.cx=startButtonSize.cy=0; oldButtonSize.cx=oldButtonSize.cy=0; bTimer=bCustomLook=bReplaceButton=bHideButton=bRecreatingButton=bThemeChanging=false; }
TaskbarInfo( void ) { taskbarId=pointerId=0; taskBar=startButton=oldButton=rebar=taskList=chevron=news=desktop=NULL; startButtonSize.cx=startButtonSize.cy=0; oldButtonSize.cx=oldButtonSize.cy=0; bTimer=bSuppressHover=bCustomLook=bReplaceButton=bHideButton=bRecreatingButton=bThemeChanging=false; }
int taskbarId;
HWND taskBar;
HWND startButton; // either own start button or the win7 start button (depending on bReplaceButton)
Expand All @@ -61,6 +61,7 @@ struct TaskbarInfo
SIZE oldButtonSize;
int pointerId;
bool bTimer;
bool bSuppressHover; // prevent hover reopening the Start menu immediately after Win+X
bool bCustomLook;
bool bReplaceButton; // replace start button with own one
bool bHideButton; // hide old start button (if we have own button)
Expand Down