AddBook ignores wxMac paths (still won't work)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@11040 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -38,6 +38,7 @@
|
|||||||
#include "wx/log.h"
|
#include "wx/log.h"
|
||||||
#include "wx/html/htmlpars.h"
|
#include "wx/html/htmlpars.h"
|
||||||
#include "wx/html/htmldefs.h"
|
#include "wx/html/htmldefs.h"
|
||||||
|
#include "wx/filename.h"
|
||||||
|
|
||||||
#include "wx/arrimpl.cpp"
|
#include "wx/arrimpl.cpp"
|
||||||
WX_DEFINE_OBJARRAY(wxHtmlBookRecArray)
|
WX_DEFINE_OBJARRAY(wxHtmlBookRecArray)
|
||||||
@@ -567,8 +568,15 @@ bool wxHtmlHelpData::AddBook(const wxString& book)
|
|||||||
index = wxEmptyString,
|
index = wxEmptyString,
|
||||||
charset = wxEmptyString;
|
charset = wxEmptyString;
|
||||||
|
|
||||||
|
#ifdef __WXMAC__
|
||||||
|
// wxIsAbsolutePath is broken
|
||||||
|
bookFull = wxGetCwd() + ":" + book;
|
||||||
|
wxFileName fn( bookFull );
|
||||||
|
bookFull = fn.GetFullPath( wxPATH_UNIX );
|
||||||
|
#else
|
||||||
if (wxIsAbsolutePath(book)) bookFull = book;
|
if (wxIsAbsolutePath(book)) bookFull = book;
|
||||||
else bookFull = wxGetCwd() + "/" + book;
|
else bookFull = wxGetCwd() + "/" + book;
|
||||||
|
#endif
|
||||||
|
|
||||||
fi = fsys.OpenFile(bookFull);
|
fi = fsys.OpenFile(bookFull);
|
||||||
if (fi == NULL)
|
if (fi == NULL)
|
||||||
|
Reference in New Issue
Block a user