]> git.lyx.org Git - lyx.git/blob - src/frontends/qt2/FormSplash.C
implement getLabelList
[lyx.git] / src / frontends / qt2 / FormSplash.C
1 /**
2  * \file FormSplash.C
3  * Copyright 2001 the LyX Team
4  * Read the file COPYING
5  *
6  * \author Edwin Leuven
7  */
8
9 #include <config.h>
10
11 #include <qframe.h>
12
13 #include "FormSplashImpl.h"
14 #include "FormSplash.h"
15 #include "Dialogs.h"
16 #include "version.h"
17 #include "support/filetools.h"
18 #include "lyxrc.h"
19
20 FormSplash::FormSplash(LyXView *, Dialogs * d)
21         : dialog_(0), d_(d)
22 {
23    c_ = d->showSplash.connect(SigC::slot(this, &FormSplash::show));
24 }
25
26
27 FormSplash::~FormSplash()
28 {
29    c_.disconnect();
30    delete dialog_;
31 }
32
33 void FormSplash::hide()
34 {
35    dialog_->hide();
36 }
37
38 void FormSplash::show()
39 {
40    if (!lyxrc.show_banner)
41      return;
42
43    if (!dialog_)
44      dialog_ = new FormSplashBase( 0, "LyX");
45
46    // show banner
47    dialog_->show();
48 }