[SHELLFIND] Remove unnecessary data member for focus
authorBrock Mammen <brockmammen@gmail.com>
Fri, 23 Aug 2019 20:33:34 +0000 (15:33 -0500)
committerGiannis Adamopoulos <gadamopoulos@reactos.org>
Sun, 15 Sep 2019 16:46:36 +0000 (19:46 +0300)
dll/win32/browseui/shellfind/CSearchBar.cpp
dll/win32/browseui/shellfind/CSearchBar.h

index 8ab28b6..74dfd73 100644 (file)
@@ -33,8 +33,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(shellfind);
 
 CSearchBar::CSearchBar() :
     pSite(NULL),
-    fVisible(FALSE),
-    bFocused(FALSE)
+    fVisible(FALSE)
 {
 }
 
@@ -111,7 +110,6 @@ HRESULT CSearchBar::ExecuteCommand(CComPtr<IContextMenu>& menu, UINT nCmd)
 // *** ATL event handlers ***
 LRESULT CSearchBar::OnSetFocus(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
 {
-    bFocused = TRUE;
     IUnknown_OnFocusChangeIS(pSite, reinterpret_cast<IUnknown*>(this), TRUE);
     bHandled = FALSE;
     return TRUE;
@@ -470,7 +468,7 @@ HRESULT STDMETHODCALLTYPE CSearchBar::UIActivateIO(BOOL fActivate, LPMSG lpMsg)
 
 HRESULT STDMETHODCALLTYPE CSearchBar::HasFocusIO()
 {
-    return bFocused ? S_OK : S_FALSE;
+    return S_OK;
 }
 
 HRESULT STDMETHODCALLTYPE CSearchBar::TranslateAcceleratorIO(LPMSG lpMsg)
index a94466f..c2df78e 100644 (file)
@@ -41,7 +41,6 @@ private:
     CComPtr<IUnknown> pSite;
     CComPtr<IAddressEditBox> fAddressEditBox;
     BOOL fVisible;
-    BOOL bFocused;
 
     HRESULT GetSearchResultsFolder(IShellBrowser **ppShellBrowser, HWND *pHwnd, IShellFolder **ppShellFolder);
     BOOL GetAddressEditBoxPath(WCHAR (&szPath)[MAX_PATH]);