Fix bug 5434: DEPM not executed for PgUp/PgDown

http://bugzilla.lyx.org/show_bug.cgi?id=5434

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28909 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Vincent van Ravesteijn 2009-03-25 21:00:34 +00:00
parent 06cfe568bb
commit 7ad10f7403

View File

@ -1448,12 +1448,16 @@ bool BufferView::dispatch(FuncRequest const & cmd)
p = Point(0, 0); p = Point(0, 0);
if (cmd.action == LFUN_SCREEN_DOWN && scrolled < height_) if (cmd.action == LFUN_SCREEN_DOWN && scrolled < height_)
p = Point(width_, height_); p = Point(width_, height_);
Cursor old = cur;
cur.reset(buffer_.inset()); cur.reset(buffer_.inset());
updateMetrics(); updateMetrics();
buffer_.changed(); buffer_.changed();
d->text_metrics_[&buffer_.text()].editXY(cur, p.x_, p.y_); d->text_metrics_[&buffer_.text()].editXY(cur, p.x_, p.y_);
//FIXME: what to do with cur.x_target()? //FIXME: what to do with cur.x_target()?
bool const update = cur.bv().checkDepm(cur, old);
cur.finishUndo(); cur.finishUndo();
if (update)
processUpdateFlags(Update::Force | Update::FitCursor);
break; break;
} }