]> git.lyx.org Git - lyx.git/blob - src/frontends/qt4/QErrorListDialog.C
This new citation dialog follows a new design similar to lyx-1.3:
[lyx.git] / src / frontends / qt4 / QErrorListDialog.C
1 /**
2  * \file QErrorListDialog.C
3  * This file is part of LyX, the document processor.
4  * Licence details can be found in the file COPYING.
5  *
6  * \author Alfredo Braunstein
7  *
8  * Full author contact details are available in file CREDITS.
9  */
10
11 #include <config.h>
12
13 #include "QErrorListDialog.h"
14 #include "QErrorList.h"
15
16 #include <q3listbox.h>
17 #include <qpushbutton.h>
18 //Added by qt3to4:
19 #include <QCloseEvent>
20
21 namespace lyx {
22 namespace frontend {
23
24 QErrorListDialog::QErrorListDialog(QErrorList * form)
25         : form_(form)
26 {
27         setupUi(this);
28         connect(closePB, SIGNAL(clicked()),
29                 form, SLOT(slotClose()));
30         connect(errorsLB, SIGNAL(returnPressed(Q3ListBoxItem *)),
31                 form, SLOT(slotClose()));
32
33     connect( errorsLB, SIGNAL( highlighted(int) ), this, SLOT( select_adaptor(int) ) );
34 }
35
36
37 QErrorListDialog::~QErrorListDialog()
38 {}
39
40
41 void QErrorListDialog::select_adaptor(int item)
42 {
43         form_->select(item);
44 }
45
46
47 void QErrorListDialog::closeEvent(QCloseEvent * e)
48 {
49         form_->slotWMHide();
50         e->accept();
51 }
52
53 } // namespace frontend
54 } // namespace lyx