diff options
| author | nyamatongwe <unknown> | 2009-07-21 09:05:43 +0000 | 
|---|---|---|
| committer | nyamatongwe <unknown> | 2009-07-21 09:05:43 +0000 | 
| commit | 7b7af48a7681ab335ba2c53ffa48ab053ddf4c86 (patch) | |
| tree | 6039e12ca6c8f447ca34fbe3c3b0195d4c3a2372 /src/ScintillaBase.cxx | |
| parent | f20e894bd45438901560b6838cea7d4639f1e5c6 (diff) | |
| download | scintilla-mirror-7b7af48a7681ab335ba2c53ffa48ab053ddf4c86.tar.gz | |
Using a much simpler property set implementation.
Accessor objects use the PropertyGet interface to access just the property
set methods they need.
Removed SString.
Diffstat (limited to 'src/ScintillaBase.cxx')
| -rw-r--r-- | src/ScintillaBase.cxx | 16 | 
1 files changed, 8 insertions, 8 deletions
diff --git a/src/ScintillaBase.cxx b/src/ScintillaBase.cxx index 5e2d9114b..3aba5fb7b 100644 --- a/src/ScintillaBase.cxx +++ b/src/ScintillaBase.cxx @@ -16,6 +16,7 @@  #include "Scintilla.h"  #include "PropSet.h" +#include "PropSetSimple.h"  #ifdef SCI_LEXER  #include "SciLexer.h"  #include "Accessor.h" @@ -706,24 +707,23 @@ sptr_t ScintillaBase::WndProc(unsigned int iMessage, uptr_t wParam, sptr_t lPara  		break;  	case SCI_GETPROPERTY: { -			SString val = props.Get(reinterpret_cast<const char *>(wParam)); -			const int n = val.length(); +			const char *val = props.Get(reinterpret_cast<const char *>(wParam)); +			const int n = strlen(val);  			if (lParam != 0) {  				char *ptr = reinterpret_cast<char *>(lParam); -				memcpy(ptr, val.c_str(), n); -				ptr[n] = '\0';	// terminate +				strcpy(ptr, val);  			}  			return n;	// Not including NUL  		}  	case SCI_GETPROPERTYEXPANDED: { -			SString val = props.GetExpanded(reinterpret_cast<const char *>(wParam)); -			const int n = val.length(); +			char *val = props.Expanded(reinterpret_cast<const char *>(wParam)); +			const int n = strlen(val);  			if (lParam != 0) {  				char *ptr = reinterpret_cast<char *>(lParam); -				memcpy(ptr, val.c_str(), n); -				ptr[n] = '\0';	// terminate +				strcpy(ptr, val);  			} +			delete []val;  			return n;	// Not including NUL  		}  | 
