]> git.lyx.org Git - features.git/commitdiff
fix warning.
authorAbdelrazak Younes <younes@lyx.org>
Wed, 5 Sep 2007 13:29:31 +0000 (13:29 +0000)
committerAbdelrazak Younes <younes@lyx.org>
Wed, 5 Sep 2007 13:29:31 +0000 (13:29 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20067 a592a061-630c-0410-9148-cb99ea01b6c8

src/BufferView.cpp

index 7ce16c4c0505b096f598ab41547523841718be73..a032e4f1129aa3bcd696f398f5bb26d554bd70b5 100644 (file)
@@ -1531,9 +1531,6 @@ void BufferView::menuInsertLyXFile(string const & filenm)
 
 void BufferView::draw(frontend::Painter & pain)
 {
-       Text & text = buffer_.text();
-       bool const select = cursor_.selection();
-
        PainterInfo pi(this, pain);
        // Should the whole screen, including insets, be refreshed?
        // FIXME: We should also distinguish DecorationUpdate to avoid text
@@ -1548,6 +1545,7 @@ void BufferView::draw(frontend::Painter & pain)
                        buffer_.inset().backgroundColor());
 
        LYXERR(Debug::PAINTING) << "\t\t*** START DRAWING ***" << endl;
+       Text & text = buffer_.text();
        TextMetrics const & tm = text_metrics_[&text];
        if (!pi.full_repaint)
                tm.drawParagraph(pi, metrics_info_.p1, 0,