Applied latest patches from Alexander
This commit is contained in:
@@ -31,7 +31,7 @@
|
||||
|
||||
class Container {
|
||||
|
||||
virtual void prints(int, int, int, char*) = 0;
|
||||
virtual void prints(int, int, int, const char*) = 0;
|
||||
|
||||
public:
|
||||
|
||||
|
@@ -168,7 +168,7 @@ void IEclass::scrolldown(int __scol, int __srow, int __ecol, int __erow, int __l
|
||||
// ------------------------------------------------------------------
|
||||
// Zero-based
|
||||
|
||||
void IEclass::prints(int wrow, int wcol, int atr, char* str) {
|
||||
void IEclass::prints(int wrow, int wcol, int atr, const char* str) {
|
||||
|
||||
editwin.prints(wrow, wcol, atr, str);
|
||||
}
|
||||
@@ -272,7 +272,8 @@ void IEclass::dispstring(const char* __string, uint __row, int attr, Line* line)
|
||||
}
|
||||
}
|
||||
else {
|
||||
memcpy(_buf, __string, _length);
|
||||
if(_length)
|
||||
memcpy(_buf, __string, _length);
|
||||
}
|
||||
|
||||
// mark selected block
|
||||
@@ -2394,12 +2395,10 @@ void UndoStack::PushItem(uint action, Line* __line, uint __col, uint __len) {
|
||||
last_item->line = __line;
|
||||
break;
|
||||
case EDIT_UNDO_INS_TEXT:
|
||||
last_item->line = __line;
|
||||
goto save_item;
|
||||
case EDIT_UNDO_WRAP_TEXT:
|
||||
last_item->line = __line->prev;
|
||||
save_item:
|
||||
throw_new(last_item->data.text_ptr = new text_item(__col, __len));
|
||||
last_item->line = __line;
|
||||
throw_new(last_item->data.text_ptr = new(__len) text_item(__col, __len));
|
||||
memcpy(last_item->data.text_ptr->text, __line->txt.c_str() + __col, __len);
|
||||
break;
|
||||
case EDIT_UNDO_NEW_LINE:
|
||||
last_item->line = last_item->data.line_ptr = __line;
|
||||
|
@@ -307,7 +307,7 @@ protected:
|
||||
int isempty (Line* __line=NULL);
|
||||
void killkillbuf ();
|
||||
void killpastebuf ();
|
||||
void prints (int wrow, int wcol, int atr, char* str);
|
||||
void prints (int wrow, int wcol, int atr, const char* str);
|
||||
int reflowok (char* __qstr);
|
||||
void refresh (Line* __currline, uint __row);
|
||||
void savefile (int __status);
|
||||
|
@@ -1109,6 +1109,9 @@ void Initialize(int argc, char* argv[]) {
|
||||
remove(AddPath(CFG->areapath, "DBRIDGE.EMW"));
|
||||
}
|
||||
|
||||
if(CFG->loadlanguage[0])
|
||||
LoadLanguage(CFG->loadlanguage);
|
||||
|
||||
// Unlink windows
|
||||
wunlink(W_READ);
|
||||
|
||||
|
@@ -546,12 +546,12 @@ static void KludgePID(GMsg* msg, const char* ptr) {
|
||||
|
||||
static void KludgeREPLYADDR(GMsg* msg, const char* ptr) {
|
||||
|
||||
Name name;
|
||||
INam name;
|
||||
name[0] = NUL;
|
||||
char *buf=throw_strdup(ptr);
|
||||
ParseInternetAddr(buf, *msg->realby ? name : msg->realby, msg->iaddr);
|
||||
if(*name)
|
||||
strxcpy(msg->realby, name, sizeof(Name));
|
||||
strxcpy(msg->realby, name, sizeof(INam));
|
||||
throw_free(buf);
|
||||
}
|
||||
|
||||
|
@@ -647,7 +647,7 @@ void GMsgBodyView::UpdateScrollbar() {
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
||||
void GMsgBodyView::prints(int wrow, int wcol, int atr, char* str) {
|
||||
void GMsgBodyView::prints(int wrow, int wcol, int atr, const char* str) {
|
||||
|
||||
vputs(wrow, wcol, atr, str);
|
||||
}
|
||||
|
@@ -86,7 +86,7 @@ protected:
|
||||
|
||||
void PaintLine(int row, Line *line);
|
||||
void UpdateScrollbar();
|
||||
void prints(int wrow, int wcol, int atr, char* str);
|
||||
void prints(int wrow, int wcol, int atr, const char* str);
|
||||
|
||||
public:
|
||||
|
||||
|
Reference in New Issue
Block a user