Backported wxHTML fixes
Applied patch [ 654023 ] Enables HtmlHelp (native) Also fixed the bad event table in helpfrm.cpp. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_4_BRANCH@18253 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -292,7 +292,7 @@ dragimag.cpp MSW
|
|||||||
dropsrc.cpp MSW OLE
|
dropsrc.cpp MSW OLE
|
||||||
droptgt.cpp MSW OLE
|
droptgt.cpp MSW OLE
|
||||||
enhmeta.cpp MSW Win32Only
|
enhmeta.cpp MSW Win32Only
|
||||||
helpbest.cpp MSW Win32Only
|
helpbest.cpp MSW Win32Only,LowLevel
|
||||||
evtloop.cpp MSW LowLevel
|
evtloop.cpp MSW LowLevel
|
||||||
fdrepdlg.cpp MSW Win32Only
|
fdrepdlg.cpp MSW Win32Only
|
||||||
# FIXME: the generic implementation doesn't work under MSW, so we must
|
# FIXME: the generic implementation doesn't work under MSW, so we must
|
||||||
@@ -308,8 +308,8 @@ gaugemsw.cpp MSW NotWin32
|
|||||||
gdiimage.cpp MSW LowLevel
|
gdiimage.cpp MSW LowLevel
|
||||||
gdiobj.cpp MSW LowLevel
|
gdiobj.cpp MSW LowLevel
|
||||||
glcanvas.cpp MSW
|
glcanvas.cpp MSW
|
||||||
helpchm.cpp MSW Win32Only
|
helpchm.cpp MSW Win32Only,LowLevel
|
||||||
helpwin.cpp MSW
|
helpwin.cpp MSW LowLevel
|
||||||
icon.cpp MSW LowLevel
|
icon.cpp MSW LowLevel
|
||||||
imaglist.cpp MSW Win32Only
|
imaglist.cpp MSW Win32Only
|
||||||
iniconf.cpp MSW
|
iniconf.cpp MSW
|
||||||
|
@@ -888,7 +888,7 @@
|
|||||||
#define wxUSE_MS_HTML_HELP 1
|
#define wxUSE_MS_HTML_HELP 1
|
||||||
|
|
||||||
// Use wxHTML-based help controller?
|
// Use wxHTML-based help controller?
|
||||||
#define wxUSE_WXHTML_HELP 0 //? error 'type cast' cannot convert from ...
|
#define wxUSE_WXHTML_HELP 1
|
||||||
|
|
||||||
// Use resources
|
// Use resources
|
||||||
#define wxUSE_RESOURCES 1
|
#define wxUSE_RESOURCES 1
|
||||||
|
@@ -888,7 +888,7 @@
|
|||||||
#define wxUSE_MS_HTML_HELP 1
|
#define wxUSE_MS_HTML_HELP 1
|
||||||
|
|
||||||
// Use wxHTML-based help controller?
|
// Use wxHTML-based help controller?
|
||||||
#define wxUSE_WXHTML_HELP 0 //? error 'type cast' cannot convert from ...
|
#define wxUSE_WXHTML_HELP 1
|
||||||
|
|
||||||
// Use resources
|
// Use resources
|
||||||
#define wxUSE_RESOURCES 1
|
#define wxUSE_RESOURCES 1
|
||||||
|
@@ -84,6 +84,11 @@ void wxHtmlHelpController::SetTitleFormat(const wxString& title)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
bool wxHtmlHelpController::AddBook(const wxFileName& book_file, bool show_wait_msg)
|
||||||
|
{
|
||||||
|
return AddBook(wxFileSystem::FileNameToURL(book_file), show_wait_msg);
|
||||||
|
}
|
||||||
|
|
||||||
bool wxHtmlHelpController::AddBook(const wxString& book, bool show_wait_msg)
|
bool wxHtmlHelpController::AddBook(const wxString& book, bool show_wait_msg)
|
||||||
{
|
{
|
||||||
wxBusyCursor cur;
|
wxBusyCursor cur;
|
||||||
@@ -186,7 +191,7 @@ bool wxHtmlHelpController::Initialize(const wxString& file)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return AddBook(actualFilename);
|
return AddBook(wxFileName(actualFilename));
|
||||||
}
|
}
|
||||||
|
|
||||||
bool wxHtmlHelpController::LoadFile(const wxString& WXUNUSED(file))
|
bool wxHtmlHelpController::LoadFile(const wxString& WXUNUSED(file))
|
||||||
|
@@ -570,7 +570,6 @@ bool wxHtmlHelpData::AddBook(const wxString& book)
|
|||||||
{
|
{
|
||||||
wxFSFile *fi;
|
wxFSFile *fi;
|
||||||
wxFileSystem fsys;
|
wxFileSystem fsys;
|
||||||
wxString bookFull;
|
|
||||||
|
|
||||||
wxString title = _("noname"),
|
wxString title = _("noname"),
|
||||||
safetitle,
|
safetitle,
|
||||||
@@ -579,23 +578,13 @@ bool wxHtmlHelpData::AddBook(const wxString& book)
|
|||||||
index = wxEmptyString,
|
index = wxEmptyString,
|
||||||
charset = wxEmptyString;
|
charset = wxEmptyString;
|
||||||
|
|
||||||
#if defined(__WXMAC__) && !defined(__DARWIN__)
|
fi = fsys.OpenFile(book);
|
||||||
if (wxIsAbsolutePath(book)) bookFull = book;
|
|
||||||
else bookFull = wxGetCwd() + book; // no slash or dot
|
|
||||||
wxFileName fn( bookFull );
|
|
||||||
bookFull = fn.GetFullPath( wxPATH_UNIX );
|
|
||||||
#else
|
|
||||||
if (wxIsAbsolutePath(book)) bookFull = book;
|
|
||||||
else bookFull = wxGetCwd() + wxT("/") + book;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
fi = fsys.OpenFile(bookFull);
|
|
||||||
if (fi == NULL)
|
if (fi == NULL)
|
||||||
{
|
{
|
||||||
wxLogError(_("Cannot open HTML help book: %s"), bookFull.c_str());
|
wxLogError(_("Cannot open HTML help book: %s"), book.c_str());
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
fsys.ChangePathTo(bookFull);
|
fsys.ChangePathTo(book);
|
||||||
|
|
||||||
const wxChar *lineptr;
|
const wxChar *lineptr;
|
||||||
wxChar linebuf[300];
|
wxChar linebuf[300];
|
||||||
|
@@ -1020,13 +1020,17 @@ Normal face<br>(and <u>underlined</u>. <i>Italic face.</i> \
|
|||||||
{
|
{
|
||||||
UpdateTestWin();
|
UpdateTestWin();
|
||||||
}
|
}
|
||||||
|
void OnUpdateSpin(wxSpinEvent& WXUNUSED(event))
|
||||||
|
{
|
||||||
|
UpdateTestWin();
|
||||||
|
}
|
||||||
|
|
||||||
DECLARE_EVENT_TABLE()
|
DECLARE_EVENT_TABLE()
|
||||||
};
|
};
|
||||||
|
|
||||||
BEGIN_EVENT_TABLE(wxHtmlHelpFrameOptionsDialog, wxDialog)
|
BEGIN_EVENT_TABLE(wxHtmlHelpFrameOptionsDialog, wxDialog)
|
||||||
EVT_COMBOBOX(-1, wxHtmlHelpFrameOptionsDialog::OnUpdate)
|
EVT_COMBOBOX(-1, wxHtmlHelpFrameOptionsDialog::OnUpdate)
|
||||||
EVT_SPINCTRL(-1, wxHtmlHelpFrameOptionsDialog::OnUpdate)
|
EVT_SPINCTRL(-1, wxHtmlHelpFrameOptionsDialog::OnUpdateSpin)
|
||||||
END_EVENT_TABLE()
|
END_EVENT_TABLE()
|
||||||
|
|
||||||
|
|
||||||
|
113
src/wxUniv.dsp
113
src/wxUniv.dsp
@@ -49,7 +49,7 @@ BSC32=bscmake.exe
|
|||||||
# ADD BSC32 /nologo
|
# ADD BSC32 /nologo
|
||||||
LIB32=link.exe -lib
|
LIB32=link.exe -lib
|
||||||
# ADD BASE LIB32 /nologo
|
# ADD BASE LIB32 /nologo
|
||||||
# ADD LIB32 /nologo /out:"..\lib\wxuniv.lib"
|
# ADD LIB32 /nologo
|
||||||
|
|
||||||
!ELSEIF "$(CFG)" == "wxUniv - Win32 Debug"
|
!ELSEIF "$(CFG)" == "wxUniv - Win32 Debug"
|
||||||
|
|
||||||
@@ -221,6 +221,11 @@ SOURCE=.\common\event.cpp
|
|||||||
# End Source File
|
# End Source File
|
||||||
# Begin Source File
|
# Begin Source File
|
||||||
|
|
||||||
|
SOURCE=.\common\extended.c
|
||||||
|
# SUBTRACT CPP /YX /Yc /Yu
|
||||||
|
# End Source File
|
||||||
|
# Begin Source File
|
||||||
|
|
||||||
SOURCE=.\common\fddlgcmn.cpp
|
SOURCE=.\common\fddlgcmn.cpp
|
||||||
# End Source File
|
# End Source File
|
||||||
# Begin Source File
|
# Begin Source File
|
||||||
@@ -549,6 +554,11 @@ SOURCE=.\common\txtstrm.cpp
|
|||||||
# End Source File
|
# End Source File
|
||||||
# Begin Source File
|
# Begin Source File
|
||||||
|
|
||||||
|
SOURCE=.\common\unzip.c
|
||||||
|
# SUBTRACT CPP /YX /Yc /Yu
|
||||||
|
# End Source File
|
||||||
|
# Begin Source File
|
||||||
|
|
||||||
SOURCE=.\common\url.cpp
|
SOURCE=.\common\url.cpp
|
||||||
# End Source File
|
# End Source File
|
||||||
# Begin Source File
|
# Begin Source File
|
||||||
@@ -599,18 +609,6 @@ SOURCE=.\common\zipstrm.cpp
|
|||||||
|
|
||||||
SOURCE=.\common\zstream.cpp
|
SOURCE=.\common\zstream.cpp
|
||||||
# End Source File
|
# End Source File
|
||||||
|
|
||||||
# Begin Source File
|
|
||||||
|
|
||||||
SOURCE=.\common\extended.c
|
|
||||||
# SUBTRACT CPP /YX /Yc /Yu
|
|
||||||
# End Source File
|
|
||||||
# Begin Source File
|
|
||||||
|
|
||||||
SOURCE=.\common\unzip.c
|
|
||||||
# SUBTRACT CPP /YX /Yc /Yu
|
|
||||||
# End Source File
|
|
||||||
|
|
||||||
# End Group
|
# End Group
|
||||||
# Begin Group "Generic Files"
|
# Begin Group "Generic Files"
|
||||||
|
|
||||||
@@ -791,7 +789,6 @@ SOURCE=.\generic\treelay.cpp
|
|||||||
|
|
||||||
SOURCE=.\generic\wizard.cpp
|
SOURCE=.\generic\wizard.cpp
|
||||||
# End Source File
|
# End Source File
|
||||||
|
|
||||||
# End Group
|
# End Group
|
||||||
# Begin Group "wxHTML Files"
|
# Begin Group "wxHTML Files"
|
||||||
|
|
||||||
@@ -876,18 +873,12 @@ SOURCE=.\html\m_tables.cpp
|
|||||||
|
|
||||||
SOURCE=.\html\winpars.cpp
|
SOURCE=.\html\winpars.cpp
|
||||||
# End Source File
|
# End Source File
|
||||||
|
|
||||||
# End Group
|
# End Group
|
||||||
# Begin Group "MSW Files"
|
# Begin Group "MSW Files"
|
||||||
|
|
||||||
# PROP Default_Filter ""
|
# PROP Default_Filter ""
|
||||||
# Begin Source File
|
# Begin Source File
|
||||||
|
|
||||||
SOURCE=.\msw\dummy.cpp
|
|
||||||
# ADD CPP /Yc"wx/wxprec.h"
|
|
||||||
# End Source File
|
|
||||||
# Begin Source File
|
|
||||||
|
|
||||||
SOURCE=.\msw\app.cpp
|
SOURCE=.\msw\app.cpp
|
||||||
# End Source File
|
# End Source File
|
||||||
# Begin Source File
|
# Begin Source File
|
||||||
@@ -952,6 +943,11 @@ SOURCE=.\msw\dir.cpp
|
|||||||
# End Source File
|
# End Source File
|
||||||
# Begin Source File
|
# Begin Source File
|
||||||
|
|
||||||
|
SOURCE=.\msw\dummy.cpp
|
||||||
|
# ADD CPP /Yc"wx/wxprec.h"
|
||||||
|
# End Source File
|
||||||
|
# Begin Source File
|
||||||
|
|
||||||
SOURCE=.\msw\evtloop.cpp
|
SOURCE=.\msw\evtloop.cpp
|
||||||
# End Source File
|
# End Source File
|
||||||
# Begin Source File
|
# Begin Source File
|
||||||
@@ -980,6 +976,28 @@ SOURCE=.\msw\gdiobj.cpp
|
|||||||
# End Source File
|
# End Source File
|
||||||
# Begin Source File
|
# Begin Source File
|
||||||
|
|
||||||
|
SOURCE=.\msw\gsocket.c
|
||||||
|
# SUBTRACT CPP /YX /Yc /Yu
|
||||||
|
# End Source File
|
||||||
|
# Begin Source File
|
||||||
|
|
||||||
|
SOURCE=.\msw\gsockmsw.c
|
||||||
|
# SUBTRACT CPP /YX /Yc /Yu
|
||||||
|
# End Source File
|
||||||
|
# Begin Source File
|
||||||
|
|
||||||
|
SOURCE=.\msw\helpbest.cpp
|
||||||
|
# End Source File
|
||||||
|
# Begin Source File
|
||||||
|
|
||||||
|
SOURCE=.\msw\helpchm.cpp
|
||||||
|
# End Source File
|
||||||
|
# Begin Source File
|
||||||
|
|
||||||
|
SOURCE=.\msw\helpwin.cpp
|
||||||
|
# End Source File
|
||||||
|
# Begin Source File
|
||||||
|
|
||||||
SOURCE=.\msw\icon.cpp
|
SOURCE=.\msw\icon.cpp
|
||||||
# End Source File
|
# End Source File
|
||||||
# Begin Source File
|
# Begin Source File
|
||||||
@@ -1050,22 +1068,26 @@ SOURCE=.\msw\volume.cpp
|
|||||||
|
|
||||||
SOURCE=.\msw\window.cpp
|
SOURCE=.\msw\window.cpp
|
||||||
# End Source File
|
# End Source File
|
||||||
|
|
||||||
# Begin Source File
|
|
||||||
|
|
||||||
SOURCE=.\msw\gsocket.c
|
|
||||||
# SUBTRACT CPP /YX /Yc /Yu
|
|
||||||
# End Source File
|
|
||||||
# Begin Source File
|
|
||||||
|
|
||||||
SOURCE=.\msw\gsockmsw.c
|
|
||||||
# SUBTRACT CPP /YX /Yc /Yu
|
|
||||||
# End Source File
|
|
||||||
|
|
||||||
# End Group
|
# End Group
|
||||||
# Begin Group "Universal Files"
|
# Begin Group "Universal Files"
|
||||||
|
|
||||||
# PROP Default_Filter ""
|
# PROP Default_Filter ""
|
||||||
|
# Begin Group "Theme Files"
|
||||||
|
|
||||||
|
# PROP Default_Filter ""
|
||||||
|
# Begin Source File
|
||||||
|
|
||||||
|
SOURCE=.\univ\themes\gtk.cpp
|
||||||
|
# End Source File
|
||||||
|
# Begin Source File
|
||||||
|
|
||||||
|
SOURCE=.\univ\themes\metal.cpp
|
||||||
|
# End Source File
|
||||||
|
# Begin Source File
|
||||||
|
|
||||||
|
SOURCE=.\univ\themes\win32.cpp
|
||||||
|
# End Source File
|
||||||
|
# End Group
|
||||||
# Begin Source File
|
# Begin Source File
|
||||||
|
|
||||||
SOURCE=.\univ\bmpbuttn.cpp
|
SOURCE=.\univ\bmpbuttn.cpp
|
||||||
@@ -1202,24 +1224,6 @@ SOURCE=.\univ\topluniv.cpp
|
|||||||
|
|
||||||
SOURCE=.\univ\winuniv.cpp
|
SOURCE=.\univ\winuniv.cpp
|
||||||
# End Source File
|
# End Source File
|
||||||
|
|
||||||
# Begin Group "Theme Files"
|
|
||||||
|
|
||||||
# PROP Default_Filter ""
|
|
||||||
# Begin Source File
|
|
||||||
|
|
||||||
SOURCE=.\univ\themes\gtk.cpp
|
|
||||||
# End Source File
|
|
||||||
# Begin Source File
|
|
||||||
|
|
||||||
SOURCE=.\univ\themes\metal.cpp
|
|
||||||
# End Source File
|
|
||||||
# Begin Source File
|
|
||||||
|
|
||||||
SOURCE=.\univ\themes\win32.cpp
|
|
||||||
# End Source File
|
|
||||||
|
|
||||||
# End Group
|
|
||||||
# End Group
|
# End Group
|
||||||
# Begin Group "Headers"
|
# Begin Group "Headers"
|
||||||
|
|
||||||
@@ -1230,7 +1234,9 @@ SOURCE=.\univ\themes\win32.cpp
|
|||||||
# Begin Source File
|
# Begin Source File
|
||||||
|
|
||||||
SOURCE=..\include\wx\univ\setup.h
|
SOURCE=..\include\wx\univ\setup.h
|
||||||
|
|
||||||
!IF "$(CFG)" == "wxUniv - Win32 Release"
|
!IF "$(CFG)" == "wxUniv - Win32 Release"
|
||||||
|
|
||||||
# Begin Custom Build - Creating lib\univ\wx\setup.h from $(InputPath)
|
# Begin Custom Build - Creating lib\univ\wx\setup.h from $(InputPath)
|
||||||
InputPath=..\include\wx\univ\setup.h
|
InputPath=..\include\wx\univ\setup.h
|
||||||
|
|
||||||
@@ -1238,7 +1244,9 @@ InputPath=..\include\wx\univ\setup.h
|
|||||||
copy "$(InputPath)" ..\lib\univ\wx\setup.h
|
copy "$(InputPath)" ..\lib\univ\wx\setup.h
|
||||||
|
|
||||||
# End Custom Build
|
# End Custom Build
|
||||||
|
|
||||||
!ELSEIF "$(CFG)" == "wxUniv - Win32 Debug"
|
!ELSEIF "$(CFG)" == "wxUniv - Win32 Debug"
|
||||||
|
|
||||||
# Begin Custom Build - Creating lib\univd\wx\setup.h from $(InputPath)
|
# Begin Custom Build - Creating lib\univd\wx\setup.h from $(InputPath)
|
||||||
InputPath=..\include\wx\univ\setup.h
|
InputPath=..\include\wx\univ\setup.h
|
||||||
|
|
||||||
@@ -1246,7 +1254,9 @@ InputPath=..\include\wx\univ\setup.h
|
|||||||
copy "$(InputPath)" ..\lib\univd\wx\setup.h
|
copy "$(InputPath)" ..\lib\univd\wx\setup.h
|
||||||
|
|
||||||
# End Custom Build
|
# End Custom Build
|
||||||
|
|
||||||
!ENDIF
|
!ENDIF
|
||||||
|
|
||||||
# End Source File
|
# End Source File
|
||||||
# End Group
|
# End Group
|
||||||
# Begin Group "Common"
|
# Begin Group "Common"
|
||||||
@@ -2200,7 +2210,6 @@ SOURCE=..\include\wx\zipstrm.h
|
|||||||
|
|
||||||
SOURCE=..\include\wx\zstream.h
|
SOURCE=..\include\wx\zstream.h
|
||||||
# End Source File
|
# End Source File
|
||||||
|
|
||||||
# End Group
|
# End Group
|
||||||
# Begin Group "MSW"
|
# Begin Group "MSW"
|
||||||
|
|
||||||
@@ -2369,7 +2378,6 @@ SOURCE=..\include\wx\generic\treectlg.h
|
|||||||
|
|
||||||
SOURCE=..\include\wx\generic\wizard.h
|
SOURCE=..\include\wx\generic\wizard.h
|
||||||
# End Source File
|
# End Source File
|
||||||
|
|
||||||
# End Group
|
# End Group
|
||||||
# Begin Group "HTML"
|
# Begin Group "HTML"
|
||||||
|
|
||||||
@@ -2426,7 +2434,6 @@ SOURCE=..\include\wx\html\m_templ.h
|
|||||||
|
|
||||||
SOURCE=..\include\wx\html\winpars.h
|
SOURCE=..\include\wx\html\winpars.h
|
||||||
# End Source File
|
# End Source File
|
||||||
|
|
||||||
# End Group
|
# End Group
|
||||||
# Begin Group "Universal"
|
# Begin Group "Universal"
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user