Massive code changes and cleanup to allow wxPython to be split into
multiple extension modules again. A Python CObject is used to allow the "export" of SWIG and other common helper functions from the wxc module to other modules, even if they are in separate shared libraries. Should also be usable from 3rd party code, just include wxPython/src/export.h Changed the default setup so the following are built as separate extension modules: calendar, glcanvas, grid, html, ogl, stc, and utils. Will probably add more later. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@8984 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -14,7 +14,7 @@
|
||||
%module html
|
||||
|
||||
%{
|
||||
#include "helpers.h"
|
||||
#include "export.h"
|
||||
#include <wx/html/htmlwin.h>
|
||||
#include <wx/html/htmprint.h>
|
||||
#include <wx/image.h>
|
||||
@@ -40,16 +40,6 @@
|
||||
|
||||
%extern utils.i
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
|
||||
%{
|
||||
// #ifdef __WXMSW__
|
||||
// wxString wxPyEmptyStr("");
|
||||
// wxPoint wxPyDefaultPosition(wxDefaultPosition);
|
||||
// wxSize wxPyDefaultSize(wxDefaultSize);
|
||||
// #endif
|
||||
%}
|
||||
|
||||
%pragma(python) code = "import wx"
|
||||
|
||||
|
||||
@@ -433,9 +423,9 @@ IMP_PYCALLBACK__STRING(wxPyHtmlWindow, wxHtmlWindow, OnSetTitle);
|
||||
|
||||
void wxPyHtmlWindow::OnLinkClicked(const wxHtmlLinkInfo& link) {
|
||||
bool doSave = wxPyRestoreThread();
|
||||
if (m_myInst.findCallback("OnLinkClicked")) {
|
||||
PyObject* obj = wxPyConstructObject((void*)&link, "wxHtmlLinkInfo");
|
||||
m_myInst.callCallback(Py_BuildValue("(O)", obj));
|
||||
if (wxPyCBH_findCallback(m_myInst, "OnLinkClicked")) {
|
||||
PyObject* obj = wxPyConstructObject((void*)&link, "wxHtmlLinkInfo", 0);
|
||||
wxPyCBH_callCallback(m_myInst, Py_BuildValue("(O)", obj));
|
||||
Py_DECREF(obj);
|
||||
}
|
||||
else
|
||||
@@ -452,8 +442,8 @@ void wxPyHtmlWindow::base_OnLinkClicked(const wxHtmlLinkInfo& link) {
|
||||
%name(wxHtmlWindow) class wxPyHtmlWindow : public wxScrolledWindow {
|
||||
public:
|
||||
wxPyHtmlWindow(wxWindow *parent, int id = -1,
|
||||
wxPoint& pos = wxPyDefaultPosition,
|
||||
wxSize& size = wxPyDefaultSize,
|
||||
wxPoint& pos = wxDefaultPosition,
|
||||
wxSize& size = wxDefaultSize,
|
||||
int flags=wxHW_SCROLLBAR_AUTO,
|
||||
char* name = "htmlWindow");
|
||||
|
||||
|
Reference in New Issue
Block a user