Dekel's Spacing.C patch + Garst's setOK complaint + use the right policy for FormDocument

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@981 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Allan Rae 2000-08-21 01:50:25 +00:00
parent f2c777f585
commit b88c49ebd7
5 changed files with 18 additions and 5 deletions

View File

@ -1,3 +1,15 @@
2000-08-21 Dekel Tsur <dekel@math.tau.ac.il>
* src/Spacing.C (writeEnvirBegin): Small fix when sstream not present
2000-08-21 Allan Rae <rae@lyx.org>
* src/frontends/xforms/ButtonController.h (setOK): renamed from setOk to
keep Garst happy ;-)
* src/frontends/xforms/FormPreferences.C (build): use setOK
* src/frontends/xforms/FormDocument.C (build): use setOK
(FormDocument): use the appropriate policy.
2000-08-21 Allan Rae <rae@lyx.org>
* src/frontends/xforms/ButtonController.h (class ButtonController): Allow

View File

@ -111,7 +111,7 @@ string Spacing::writeEnvirBegin() const
char tmp[512];
ostrstream ost(tmp, 512);
ost << "\\begin{spacing}{"
<< getValue() << "}";
<< getValue() << "}" << '\0';
return ost.str();
}
#endif

View File

@ -54,7 +54,7 @@ public:
/**@name Initialise Button Functions */
//@{
/// Call refresh() when finished setting the buttons.
void setOk(FL_OBJECT * obj)
void setOK(FL_OBJECT * obj)
{ okay_ = obj; }
///
void setApply(FL_OBJECT * obj)

View File

@ -65,7 +65,8 @@ FormDocument::FormDocument(LyXView * lv, Dialogs * d)
: dialog_(0), paper_(0), class_(0), language_(0), options_(0),
bullets_(0), lv_(lv), d_(d), u_(0), h_(0),
status(POPUP_UNMODIFIED) ,
bc_(new ButtonController<PreferencesPolicy>(_("Cancel"), _("Close")))
bc_(new ButtonController<NoRepeatedApplyReadOnlyPolicy>(_("Cancel"),
_("Close")))
{
// let the popup be shown
// This is a permanent connection so we won't bother
@ -89,7 +90,7 @@ void FormDocument::build()
dialog_ = build_tabbed_document();
// manage the restore, save, apply and cancel/close buttons
bc_->setOk(dialog_->button_ok);
bc_->setOK(dialog_->button_ok);
bc_->setApply(dialog_->button_apply);
bc_->setCancel(dialog_->button_cancel);
bc_->setUndoAll(dialog_->button_restore);

View File

@ -62,7 +62,7 @@ void FormPreferences::build()
dialog_ = build_preferences();
// manage the restore, save, apply and cancel/close buttons
bc_->setOk(dialog_->button_ok);
bc_->setOK(dialog_->button_ok);
bc_->setApply(dialog_->button_apply);
bc_->setCancel(dialog_->button_cancel);
bc_->setUndoAll(dialog_->button_restore);