]> git.lyx.org Git - lyx.git/blob - src/frontends/xforms/FormCopyright.C
Angus's FormBase patch with tiny cleanup
[lyx.git] / src / frontends / xforms / FormCopyright.C
1 /* FormCopyright.C
2  * FormCopyright Interface Class Implementation
3  */
4
5 #include <config.h>
6
7 #include FORMS_H_LOCATION
8
9 #ifdef __GNUG__
10 #pragma implementation
11 #endif
12
13 #include "Dialogs.h"
14 #include "LyXView.h"
15 #include "gettext.h"
16 #include "form_copyright.h"
17 #include "FormCopyright.h"
18
19 FormCopyright::FormCopyright( LyXView * lv, Dialogs * d )
20         : FormBase( lv, d, BUFFER_INDEPENDENT, _("Copyright and Warranty") ),
21           dialog_(0)
22 {
23         // let the dialog be shown
24         // This is a permanent connection so we won't bother
25         // storing a copy because we won't be disconnecting.
26         d->showCopyright.connect(slot(this, &FormCopyright::show));
27 }
28
29
30 FormCopyright::~FormCopyright()
31 {
32         delete dialog_;
33 }
34
35
36 void FormCopyright::build()
37 {
38         dialog_ = build_copyright();
39 }
40
41
42 FL_FORM * const FormCopyright::form() const
43 {
44         if( dialog_ ) // no need to test for dialog_->form
45                 return dialog_->form;
46         else
47                 return 0;
48 }