* Fix keyboard navigation on vertical popup menus. Navigating through the menubar does not work yet.
CORE-7586

svn path=/branches/shell-experiments/; revision=62753
This commit is contained in:
David Quintana 2014-04-15 15:53:17 +00:00
parent ba203171e1
commit 5e4427d973
2 changed files with 6 additions and 4 deletions

View file

@ -809,16 +809,16 @@ HRESULT CMenuBand::_KeyboardItemChange(DWORD change)
return hr;
// Select the second toolbar based on the first
if (tb == m_SFToolbar)
if (tb == m_SFToolbar && m_staticToolbar)
tb = m_staticToolbar;
else
else if (m_SFToolbar)
tb = m_SFToolbar;
if (!tb)
return hr;
// Ask the second toolbar to change
return tb->KeyboardItemChange(change == VK_DOWN ? VK_END : VK_HOME);
return tb->KeyboardItemChange(change == VK_DOWN ? VK_HOME : VK_END);
}
HRESULT CMenuBand::_MenuItemHotTrack(DWORD changeType)

View file

@ -913,7 +913,7 @@ HRESULT CMenuToolbarBase::KeyboardItemChange(DWORD dwSelectType)
if (prev != btn.idCommand)
{
TRACE("Setting Hot item to %d\n", index);
m_menuBand->_ChangeHotItem(this, index, 0);
m_menuBand->_ChangeHotItem(this, btn.idCommand, 0);
}
return S_OK;
}
@ -927,6 +927,8 @@ HRESULT CMenuToolbarBase::KeyboardItemChange(DWORD dwSelectType)
index++;
}
}
return S_FALSE;
}
if (prev != -1)