so that erroneous help strings are no longer found as the hash
table fills up
- updated libpng from 1.0.3 to 1.2.4
+- Added wxView::OnClosingDocument so the application can do
+ cleanup.
wxMSW:
- wxGrid cell editing veto support (Roger Gammans)
- wxListCtrl ITEM_FOCUSED event added
- support for ICO files in wxImage added (Chris Elliott)
+- improvements to wxDragImage (Chuck Messenger)
wxMSW:
wxGTK:
- fixed popup menu positioning bug
+- fixed the edit function for wxListCtrl (Chuck Messenger)
+- fixed the key-hitting events for wxListCtrl and wxTreeCtrl, so they
+ correctly return the key which was pressed (Chuck Messenger)
wxMac:
and perhaps clear the window. If {\it deleteWindow} is TRUE, delete the
frame associated with the view.
+\membersection{wxView::OnClosingDocument}\label{wxviewonclosingdocument}
+
+\func{virtual void}{OnClosingDoocument}{\void}
+
+Override this to clean up the view when the document is being
+closed.
+
\membersection{wxView::OnCreate}
\func{virtual bool}{OnCreate}{\param{wxDocument* }{doc}, \param{long}{ flags}}
wxView *GetFirstView() const;
virtual void UpdateAllViews(wxView *sender = (wxView *) NULL, wxObject *hint = (wxObject *) NULL);
+ virtual void NotifyClosing();
// Remove all views (because we're closing the document)
virtual bool DeleteAllViews();
virtual void OnDraw(wxDC *dc) = 0;
virtual void OnPrint(wxDC *dc, wxObject *info);
virtual void OnUpdate(wxView *sender, wxObject *hint = (wxObject *) NULL);
+ virtual void OnClosingDocument() {};
virtual void OnChangeFilename();
// Called by framework if created automatically by the default document
bool wxDocument::OnCloseDocument()
{
+ // Tell all views that we're about to close
+ NotifyClosing();
DeleteContents();
Modify(FALSE);
return TRUE;
}
}
+void wxDocument::NotifyClosing()
+{
+ wxNode *node = m_documentViews.First();
+ while (node)
+ {
+ wxView *view = (wxView *)node->Data();
+ view->OnClosingDocument();
+ node = node->Next();
+ }
+}
+
void wxDocument::SetFilename(const wxString& filename, bool notifyViews)
{
m_documentFile = filename;