mirror of
https://github.com/reactos/reactos.git
synced 2026-06-20 12:22:25 +08:00
[BROWSEUI] Implement toggling the folders and search band with the toolbar and make their buttons appear pressed when they are shown.
CBaseBarSite: Ask the CBaseBar to close itself when the x button is pressed. CBaseBar: Hide the bar and inform its site that it is closing when it gets the close command. CShellBrowser: Cache the guid of the current vertical bar and use it to report correct command status to the toolbar. Also implement toggling the Folders, Favorites, History and search commands. CInternetToolbar: Query the Folders and Search command status from the site so that they can be properly be shown as pressed.
This commit is contained in:
@@ -692,17 +692,10 @@ LRESULT CBaseBarSite::OnNotify(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL &bH
|
||||
|
||||
LRESULT CBaseBarSite::OnCommand(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
|
||||
{
|
||||
HRESULT hResult;
|
||||
CComPtr<IDockingWindow> parentSite;
|
||||
|
||||
if (HIWORD(wParam) == BN_CLICKED && LOWORD(wParam) == IDM_BASEBAR_CLOSE)
|
||||
{
|
||||
hResult = fDeskBarSite->QueryInterface(IID_PPV_ARG(IDockingWindow, &parentSite));
|
||||
if (!SUCCEEDED(hResult))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
parentSite->ShowDW(FALSE);
|
||||
/* Tell the base bar to hide */
|
||||
IUnknown_Exec(fDeskBarSite, IID_IDeskBarClient, 0, 0, NULL, NULL);
|
||||
bHandled = TRUE;
|
||||
}
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user