3 * This file is part of LyX, the document processor.
4 * Licence details can be found in the file COPYING.
6 * \author Jürgen Spitzmüller
8 * Full author contact details are available in file CREDITS.
14 #include "ControlNote.h"
15 #include "insets/insetnote.h"
17 #include <qradiobutton.h>
18 #include <qpushbutton.h>
20 #include "QNoteDialog.h"
25 typedef QController<ControlNote, QView<QNoteDialog> > base_class;
28 QNote::QNote(Dialog & parent)
29 : base_class(parent, _("LyX: Note Settings"))
33 void QNote::build_dialog()
35 dialog_.reset(new QNoteDialog(this));
37 bcview().setOK(dialog_->okPB);
38 bcview().setCancel(dialog_->closePB);
42 void QNote::update_contents()
44 QRadioButton * rb = 0;
45 string type(controller().params().type);
49 else if (type == "Comment")
50 rb = dialog_->commentRB;
51 else if (type == "Greyedout")
52 rb = dialog_->greyedoutRB;
62 if (dialog_->greyedoutRB->isChecked())
64 else if (dialog_->commentRB->isChecked())
69 controller().params().type = type;