fixed 'url' field extraction to be done for wxHtmlWindow only (bug #1741900)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_8_BRANCH@46934 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Václav Slavík
2007-06-25 12:16:51 +00:00
parent b4e7990f52
commit 5f8566b2a3

View File

@@ -437,10 +437,6 @@ static bool NodeContainsFilename(wxXmlNode *node)
if ( name == _T("icon") ) if ( name == _T("icon") )
return true; return true;
// URLs in wxHtmlWindow:
if ( name == _T("url") )
return true;
// wxBitmapButton: // wxBitmapButton:
wxXmlNode *parent = node->GetParent(); wxXmlNode *parent = node->GetParent();
if (parent != NULL && if (parent != NULL &&
@@ -458,6 +454,15 @@ static bool NodeContainsFilename(wxXmlNode *node)
return true; return true;
} }
// URLs in wxHtmlWindow:
if ( name == _T("url") &&
parent != NULL &&
parent->GetPropVal(_T("class"), _T("")) == _T("wxHtmlWindow") )
{
// FIXME: this is wrong for e.g. http:// URLs
return true;
}
return false; return false;
} }