]> git.lyx.org Git - lyx.git/blobdiff - src/frontends/qt4/GuiHyperlink.h
Use the command-alternatives sequence as defined in menus.bind
[lyx.git] / src / frontends / qt4 / GuiHyperlink.h
index 3b28c1aac3fa8a136104b0a5291723238e253a50..3f24fce848d0eab4636b2521f863762c27c07cd4 100644 (file)
 #ifndef GUIHYPERLINK_H
 #define GUIHYPERLINK_H
 
-#include "GuiDialog.h"
+#include "InsetParamsWidget.h"
 #include "ui_HyperlinkUi.h"
 
-#include "insets/InsetCommandParams.h"
-
 namespace lyx {
 namespace frontend {
 
-class GuiHyperlink : public GuiDialog, public Ui::HyperlinkUi
+class GuiHyperlink : public InsetParamsWidget, public Ui::HyperlinkUi
 {
        Q_OBJECT
 
 public:
-       /// Constructor
-       GuiHyperlink(GuiView & lv);
-
-public Q_SLOTS:
-       void changed_adaptor();
-
-private:
-       ///
-       bool isValid();
-       /// apply dialog
-       void applyView();
-       /// update dialog
-       void updateContents();
        ///
-       bool initialiseParams(std::string const & data);
-       /// clean-up on hide.
-       void clearParams() { params_.clear(); }
-       /// clean-up on hide.
-       void dispatchParams();
-       ///
-       bool isBufferDependent() const { return true; }
+       GuiHyperlink(QWidget * parent = 0);
 
 private:
-       ///
-       InsetCommandParams params_;
+       /// \name InsetParamsWidget inherited methods
+       //@{
+       InsetCode insetCode() const { return HYPERLINK_CODE; }
+       FuncCode creationCode() const { return LFUN_INSET_INSERT; }
+       QString dialogTitle() const { return qt_("Hyperlink Settings"); }
+       void paramsToDialog(Inset const *);
+       docstring dialogToParams() const;
+       bool checkWidgets(bool readonly) const;
+       bool initialiseParams(std::string const & data);
+       //@}
 };
 
 } // namespace frontend