mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-23 13:31:49 +00:00
* src/frontends/qt4/GuiWorkArea.[Ch]:
- reimplement doubleClickTimeout() from the qt3 frontend in order to get triple clicking working (bug 3272). This is just an emultation of triple clicking, since qt does not have a mouseTripleClickEvent() git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17588 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
ff7dd5e06c
commit
7cce9b87f8
@ -421,10 +421,8 @@ void GuiWorkArea::keyPressEvent(QKeyEvent * e)
|
||||
}
|
||||
|
||||
|
||||
void GuiWorkArea::mouseDoubleClickEvent(QMouseEvent * e)
|
||||
void GuiWorkArea::doubleClickTimeout()
|
||||
{
|
||||
dc_event_ = double_click(e);
|
||||
|
||||
if (!dc_event_.active)
|
||||
return;
|
||||
|
||||
@ -437,6 +435,16 @@ void GuiWorkArea::mouseDoubleClickEvent(QMouseEvent * e)
|
||||
}
|
||||
|
||||
|
||||
void GuiWorkArea::mouseDoubleClickEvent(QMouseEvent * e)
|
||||
{
|
||||
dc_event_ = double_click(e);
|
||||
|
||||
// doubleClickInterval() is just too long.
|
||||
QTimer::singleShot(int(QApplication::doubleClickInterval() / 1.5),
|
||||
this, SLOT(doubleClickTimeout()));
|
||||
}
|
||||
|
||||
|
||||
void GuiWorkArea::resizeEvent(QResizeEvent * ev)
|
||||
{
|
||||
QAbstractScrollArea::resizeEvent(ev);
|
||||
|
@ -155,6 +155,8 @@ public Q_SLOTS:
|
||||
* emits an 'int' action.
|
||||
*/
|
||||
void adjustViewWithScrollBar(int action = 0);
|
||||
///
|
||||
void doubleClickTimeout();
|
||||
|
||||
private:
|
||||
/// The slot connected to SyntheticMouseEvent::timeout.
|
||||
|
Loading…
Reference in New Issue
Block a user