stop/start the blinking cursor when the WorkArea get a focusInEvent or focusOutEvent.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15586 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Abdelrazak Younes 2006-10-27 23:26:52 +00:00
parent 1372f311d3
commit 9b89f1d4ad
2 changed files with 16 additions and 0 deletions

View File

@ -285,6 +285,18 @@ void GuiWorkArea::dropEvent(QDropEvent* event)
}
void GuiWorkArea::focusInEvent(QFocusEvent * /*event*/)
{
startBlinkingCursor();
}
void GuiWorkArea::focusOutEvent(QFocusEvent * /*event*/)
{
stopBlinkingCursor();
}
void GuiWorkArea::mousePressEvent(QMouseEvent * e)
{
if (dc_event_.active && dc_event_ == *e) {

View File

@ -118,6 +118,10 @@ private:
void dragEnterEvent(QDragEnterEvent * ev);
///
void dropEvent(QDropEvent * ev);
///
void focusInEvent(QFocusEvent *);
///
void focusOutEvent(QFocusEvent *);
/// repaint part of the widget
void paintEvent(QPaintEvent * ev);
/// widget has been resized