]> git.lyx.org Git - lyx.git/blobdiff - src/frontends/xforms/FormWrap.C
Change glob() API to accept a dir parameter.
[lyx.git] / src / frontends / xforms / FormWrap.C
index 815e609940b380fb97c3948b69594c9e74c4b2b7..37788f02026d9c819649869f947be8d485c44de9 100644 (file)
@@ -5,7 +5,7 @@
  *
  * \author Dekel Tsur
  *
- * Full author contact details are available in file CREDITS
+ * Full author contact details are available in file CREDITS.
  */
 
 #include <config.h>
 
 #include "insets/insetwrap.h"
 #include "support/lstrings.h"
-#include FORMS_H_LOCATION
+#include "lyx_forms.h"
+#include "support/tostr.h"
+
+using std::string;
+
+namespace lyx {
+
+using support::getStringFromVector;
+using support::subst;
+
+namespace frontend {
 
 typedef FormController<ControlWrap, FormView<FD_wrap> > base_class;
 
 FormWrap::FormWrap(Dialog & parent)
-       : base_class(parent, _("Wrap Options"))
+       : base_class(parent, _("Text Wrap Settings"))
 {}
 
 
@@ -36,17 +46,17 @@ void FormWrap::build()
        dialog_.reset(build_wrap(this));
 
        // Manage the ok, apply and cancel/close buttons
-       bc().setOK(dialog_->button_ok);
-       bc().setApply(dialog_->button_apply);
-       bc().setCancel(dialog_->button_close);
-       bc().setRestore(dialog_->button_restore);
+       bcview().setOK(dialog_->button_ok);
+       bcview().setApply(dialog_->button_apply);
+       bcview().setCancel(dialog_->button_close);
+       bcview().setRestore(dialog_->button_restore);
 
        // disable for read-only documents
-       bc().addReadOnly(dialog_->input_width);
-       bc().addReadOnly(dialog_->choice_width_units);
+       bcview().addReadOnly(dialog_->input_width);
+       bcview().addReadOnly(dialog_->choice_width_units);
 
        // check validity of "length + unit" input
-       addCheckedGlueLength(bc(), dialog_->input_width);
+       addCheckedGlueLength(bcview(), dialog_->input_width);
 
        // trigger an input event for cut&paste with middle mouse button.
        setPrehandler(dialog_->input_width);
@@ -106,3 +116,6 @@ void FormWrap::update()
        else
                placement_.set(params.placement.c_str()[0]);
 }
+
+} // namespace frontend
+} // namespace lyx