[!if RIBBON_TOOLBAR] // This MFC Samples source code demonstrates using MFC Microsoft Office Fluent User Interface // (the "Fluent UI") and is provided only as referential material to supplement the // Microsoft Foundation Classes Reference and related electronic documentation // included with the MFC C++ library software. // License terms to copy, use or distribute the Fluent UI are available separately. // To learn more about our Fluent UI licensing program, please visit // https://go.microsoft.com/fwlink/?LinkId=238214. // // Copyright (C) Microsoft Corporation // All rights reserved. [!endif] #include "pch.h" #include "framework.h" #include "ViewTree.h" #ifdef _DEBUG #define new DEBUG_NEW #undef THIS_FILE static char THIS_FILE[] = __FILE__; #endif ///////////////////////////////////////////////////////////////////////////// // CViewTree CViewTree::CViewTree() noexcept { } CViewTree::~CViewTree() { } BEGIN_MESSAGE_MAP(CViewTree, CTreeCtrl) END_MESSAGE_MAP() ///////////////////////////////////////////////////////////////////////////// // CViewTree message handlers BOOL CViewTree::OnNotify(WPARAM wParam, LPARAM lParam, LRESULT* pResult) { BOOL bRes = CTreeCtrl::OnNotify(wParam, lParam, pResult); NMHDR* pNMHDR = (NMHDR*)lParam; ASSERT(pNMHDR != nullptr); #pragma warning(suppress : 26454) if (pNMHDR && pNMHDR->code == TTN_SHOW && GetToolTips() != nullptr) { GetToolTips()->SetWindowPos(&wndTop, -1, -1, -1, -1, SWP_NOMOVE | SWP_NOACTIVATE | SWP_NOSIZE); } return bRes; }