* Licence details can be found in the file COPYING.
*
* \author Angus Leeming
- * \author Jürgen Spitzmüller
+ * \author Jürgen Spitzmüller
*
* Full author contact details are available in file CREDITS.
*/
#include "insets/InsetNote.h"
-#include <QCloseEvent>
-
-using std::string;
-
+using namespace std;
namespace lyx {
namespace frontend {
GuiNote::GuiNote(GuiView & lv)
- : GuiDialog(lv, "note")
+ : GuiDialog(lv, "note", qt_("Note Settings"))
{
setupUi(this);
- setViewTitle(_("Note Settings"));
connect(okPB, SIGNAL(clicked()), this, SLOT(slotOK()));
connect(closePB, SIGNAL(clicked()), this, SLOT(slotClose()));
connect(noteRB, SIGNAL(clicked()), this, SLOT(change_adaptor()));
connect(greyedoutRB, SIGNAL(clicked()), this, SLOT(change_adaptor()));
connect(commentRB, SIGNAL(clicked()), this, SLOT(change_adaptor()));
- connect(framedRB, SIGNAL(clicked()), this, SLOT(change_adaptor()));
- connect(shadedRB, SIGNAL(clicked()), this, SLOT(change_adaptor()));
bc().setPolicy(ButtonPolicy::NoRepeatedApplyReadOnlyPolicy);
bc().setOK(okPB);
}
-void GuiNote::closeEvent(QCloseEvent * e)
-{
- slotClose();
- e->accept();
-}
-
-
void GuiNote::change_adaptor()
{
changed();
case InsetNoteParams::Greyedout:
greyedoutRB->setChecked(true);
break;
- case InsetNoteParams::Framed:
- framedRB->setChecked(true);
- break;
- case InsetNoteParams::Shaded:
- shadedRB->setChecked(true);
- break;
}
}
params_.type = InsetNoteParams::Greyedout;
else if (commentRB->isChecked())
params_.type = InsetNoteParams::Comment;
- else if (framedRB->isChecked())
- params_.type = InsetNoteParams::Framed;
- else if (shadedRB->isChecked())
- params_.type = InsetNoteParams::Shaded;
else
params_.type = InsetNoteParams::Note;
}
bool GuiNote::initialiseParams(string const & data)
{
- InsetNoteMailer::string2params(data, params_);
+ InsetNote::string2params(data, params_);
return true;
}
void GuiNote::dispatchParams()
{
- dispatch(FuncRequest(getLfun(), InsetNoteMailer::params2string(params_)));
+ dispatch(FuncRequest(getLfun(), InsetNote::params2string(params_)));
}
} // namespace frontend
} // namespace lyx
-#include "GuiNote_moc.cpp"
+#include "moc_GuiNote.cpp"