X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/4fe30bceff0445f540e639d2b6d3977d56b34020..5c60e84569e7646f091a60c14ac2f4c54b100d8a:/utils/configtool/src/configtree.cpp?ds=sidebyside diff --git a/utils/configtool/src/configtree.cpp b/utils/configtool/src/configtree.cpp index 28e32bddb4..10769df40e 100644 --- a/utils/configtool/src/configtree.cpp +++ b/utils/configtool/src/configtree.cpp @@ -9,19 +9,15 @@ // Licence: ///////////////////////////////////////////////////////////////////////////// -#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) -#pragma implementation "configtree.h" -#endif - -// Includes other headers for precompiled compilation -#include "wx/wx.h" +// For compilers that support precompilation, includes "wx/wx.h". +#include "wx/wxprec.h" #ifdef __BORLANDC__ #pragma hdrstop #endif -#include "wx/imaglist.h" #include "wx/cshelp.h" +#include "wx/imaglist.h" // Include XPM icons #include "bitmaps/closedfolder.xpm" @@ -202,10 +198,11 @@ void ctConfigTreeCtrl::OnHelp(wxHelpEvent& event) wxPoint pt = ScreenToClient(event.GetPosition()); int flags = 0; wxTreeItemId id = HitTest(pt, flags); + ctTreeItemData *itemData = (ctTreeItemData*) GetItemData(id); wxHelpProvider *helpProvider = wxHelpProvider::Get(); - if ( helpProvider && id > 0) + if ( helpProvider && itemData) { - ctConfigItem* item = ((ctTreeItemData*) GetItemData(id))->GetConfigItem(); + ctConfigItem* item = itemData->GetConfigItem(); if (item) { wxString helpTopic = item->GetPropertyString(wxT("help-topic"));