#if wxUSE_TEXTCTRL
+#include <ctype.h>
+
#ifndef WX_PRECOMP
#include "wx/log.h"
// ----------------------------------------------------------------------------
/*
- We use custom versions of wxWindows command processor to implement undo/redo
+ We use custom versions of wxWidgets command processor to implement undo/redo
as we want to avoid storing the backpointer to wxTextCtrl in wxCommand
itself: this is a waste of memory as all commands in the given command
processor always have the same associated wxTextCtrl and so it makes sense
virtual bool CanUndo() const;
virtual bool Do(wxTextCtrl *text);
+ virtual bool Do() { return wxTextCtrlCommand::Do(); }
+ virtual bool Undo() { return wxTextCtrlCommand::Undo(); }
virtual bool Undo(wxTextCtrl *text);
private:
virtual bool CanUndo() const;
virtual bool Do(wxTextCtrl *text);
+ virtual bool Do() { return wxTextCtrlCommand::Do(); }
+ virtual bool Undo() { return wxTextCtrlCommand::Undo(); }
virtual bool Undo(wxTextCtrl *text);
private:
return m_isEditable && IsEnabled();
}
+void wxTextCtrl::MarkDirty()
+{
+ m_isModified = TRUE;
+}
+
void wxTextCtrl::DiscardEdits()
{
m_isModified = FALSE;
lines = 5;
else if ( lines > 10 )
lines = 10;
- h *= 10;
+ h *= lines;
}
wxRect rectText;