2 * \file QIncludeDialog.C
3 * This file is part of LyX, the document processor.
4 * Licence details can be found in the file COPYING.
8 * Full author contact details are available in file CREDITS.
13 #include "QIncludeDialog.h"
16 #include <QCloseEvent>
17 #include "validators.h"
19 #include <qpushbutton.h>
20 #include <qcheckbox.h>
21 #include <qlineedit.h>
27 QIncludeDialog::QIncludeDialog(QInclude * form)
31 connect(okPB, SIGNAL(clicked()),
32 form, SLOT(slotOK()));
33 connect(closePB, SIGNAL(clicked()),
34 form, SLOT(slotClose()));
36 connect( visiblespaceCB, SIGNAL( clicked() ), this, SLOT( change_adaptor() ) );
37 connect( filenameED, SIGNAL( textChanged(const QString&) ), this, SLOT( change_adaptor() ) );
38 connect( loadPB, SIGNAL( clicked() ), this, SLOT( loadClicked() ) );
39 connect( browsePB, SIGNAL( clicked() ), this, SLOT( browseClicked() ) );
40 connect( typeCO, SIGNAL( activated(int) ), this, SLOT( change_adaptor() ) );
41 connect( typeCO, SIGNAL( activated(int) ), this, SLOT( typeChanged(int) ) );
42 connect( previewCB, SIGNAL( clicked() ), this, SLOT( change_adaptor() ) );
44 filenameED->setValidator(new PathValidator(true, filenameED));
45 setFocusProxy(filenameED);
49 void QIncludeDialog::show()
55 void QIncludeDialog::change_adaptor()
61 void QIncludeDialog::closeEvent(QCloseEvent * e)
68 void QIncludeDialog::typeChanged(int v)
73 visiblespaceCB->setEnabled(false);
74 visiblespaceCB->setChecked(false);
75 previewCB->setEnabled(false);
76 previewCB->setChecked(false);
80 visiblespaceCB->setEnabled(false);
81 visiblespaceCB->setChecked(false);
82 previewCB->setEnabled(true);
86 visiblespaceCB->setEnabled(true);
87 previewCB->setEnabled(false);
88 previewCB->setChecked(false);
94 void QIncludeDialog::loadClicked()
100 void QIncludeDialog::browseClicked()
105 } // namespace frontend
108 #include "QIncludeDialog_moc.cpp"