]> git.lyx.org Git - lyx.git/blobdiff - src/frontends/xforms/FormUrl.C
Introduce LFUN_PRINT.
[lyx.git] / src / frontends / xforms / FormUrl.C
index 276965721708acc310ef2b43e0c74594d0292b05..9d52023ac98915d318de207cadb3eda311e673c2 100644 (file)
@@ -1,33 +1,35 @@
 /**
- * \file xforms/FormUrl.C
- * Copyright 2000-2001 The LyX Team.
- * See the file COPYING.
+ * \file FormUrl.C
+ * This file is part of LyX, the document processor.
+ * Licence details can be found in the file COPYING.
  *
- * \author Angus Leeming, a.leeming@ic.ac.uk
+ * \author Angus Leeming
+ *
+ * Full author contact details are available in file CREDITS.
  */
 
 
 #include <config.h>
 
-#ifdef __GNUG__
-#pragma implementation
-#endif
+#include "FormUrl.h"
+#include "ControlCommand.h"
+#include "forms/form_url.h"
 
 #include "xformsBC.h"
-#include "ControlUrl.h"
-#include "FormUrl.h"
-#include "form_url.h"
 
-typedef FormCB<ControlUrl, FormDB<FD_form_url> > base_class;
+#include "lyx_forms.h"
+
+
+typedef  FormController<ControlCommand, FormView<FD_url> > base_class;
 
-FormUrl::FormUrl(ControlUrl & c)
-       : base_class(c, _("Url"))
+FormUrl::FormUrl(Dialog & parent)
+       : base_class(parent, _("URL"))
 {}
 
 
 void FormUrl::build()
 {
-       dialog_.reset(build_url());
+       dialog_.reset(build_url(this));
 
        fl_set_input_return(dialog_->input_name, FL_RETURN_CHANGED);
        fl_set_input_return(dialog_->input_url,  FL_RETURN_CHANGED);
@@ -36,14 +38,14 @@ void FormUrl::build()
        setPrehandler(dialog_->input_url);
 
        // Manage the ok, apply, restore and cancel/close buttons
-       bc().setOK(dialog_->button_ok);
-       bc().setApply(dialog_->button_apply);
-       bc().setCancel(dialog_->button_close);
-       bc().setRestore(dialog_->button_restore);
-
-       bc().addReadOnly(dialog_->input_name);
-       bc().addReadOnly(dialog_->input_url);
-       bc().addReadOnly(dialog_->check_html);
+       bcview().setOK(dialog_->button_ok);
+       bcview().setApply(dialog_->button_apply);
+       bcview().setCancel(dialog_->button_close);
+       bcview().setRestore(dialog_->button_restore);
+
+       bcview().addReadOnly(dialog_->input_name);
+       bcview().addReadOnly(dialog_->input_url);
+       bcview().addReadOnly(dialog_->check_html);
 }