update putc parameters.

git-svn-id: svn://qnap.local/TwoTerm/branches/fix-gno-scrolling-region@3164 5590a31f-7b70-45f8-8c82-aa3a8e5f4507
This commit is contained in:
Kelvin Sherlock 2017-02-16 18:06:20 +00:00
parent 2f0cd34e32
commit d899cb8c0e
2 changed files with 5 additions and 4 deletions

View File

@ -67,13 +67,13 @@ iRect Screen::endUpdate()
void Screen::putc(uint8_t c, const context &ctx)
void Screen::putc(uint8_t c, iPoint cursor, uint8_t flags)
{
auto cursor = ctx.cursor;
if (!_frame.contains(cursor)) return;
if (cursor.x >= _frame.maxX() || cursor.y >= _frame.maxY()) return;
_updates.push_back(cursor);
_screen[cursor.y][cursor.x] = char_info(c, ctx.flags);
_screen[cursor.y][cursor.x] = char_info(c, flags);
}

View File

@ -92,7 +92,8 @@ public:
void putc(uint8_t c, const context &);
void putc(uint8_t c, iPoint cursor, uint8_t flags = 0);
void putc(uint8_t c, const context &ctx) { putc(c, ctx.cursor, ctx.flags); }
char_info getc(iPoint p) const;