]> git.saurik.com Git - wxWidgets.git/commit
Refactor wxStyledTextCtrl to share common file save/load code.
authorVadim Zeitlin <vadim@wxwidgets.org>
Sat, 26 Sep 2009 13:26:16 +0000 (13:26 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Sat, 26 Sep 2009 13:26:16 +0000 (13:26 +0000)
commit3396739da180ef3f8d006f11f8a13a9e0df7d88d
tree5cfad2888c73e8e7d67e3bdbb3b4a095b64a1416
parent65702d2fe95b8ca16a9b74f53832780bf1c81970
Refactor wxStyledTextCtrl to share common file save/load code.

Keep the code for saving and loading text contents from files in a single
place instead of doing it differently in wxTextCtrl and wxStyledTextCtrl.

This required adding Set/GetValue() methods to wxTextAreaBase just so that its
DoLoad/SaveFile() could use them, even if they are the same as wxTextEntryBase
methods and are overridden in wxTextCtrlBase to be implemented in terms of the
latter.

Notice that wxRichTextCtrl might need to be refactored to use this code too in
the future.

Also notice that this reverts the change of r62081 which replaced SetValue()
with ChangeValue() in DoLoadFile() as wxTextAreaBase only has SetValue() and
it's not worth adding ChangeValue() to it too just to preserve this recent
change in behaviour.

Closes #10715.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@62139 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
include/wx/stc/stc.h
include/wx/textctrl.h
src/common/textcmn.cpp
src/stc/stc.cpp
src/stc/stc.cpp.in
src/stc/stc.h.in