]> git.lyx.org Git - lyx.git/blobdiff - src/insets/InsetWrap.cpp
Require a buffer on construction of InsetGraphics and InsetExternal. Eventually,...
[lyx.git] / src / insets / InsetWrap.cpp
index 0b0ab1f388894ea933fcbfc880626c79f6477ec5..244467ac86aa6bb0542b393af62f01bbc5d994c2 100644 (file)
@@ -39,10 +39,10 @@ using namespace std;
 namespace lyx {
 
 
-InsetWrap::InsetWrap(BufferParams const & bp, string const & type)
-       : InsetCollapsable(bp), name_(from_utf8(type))
+InsetWrap::InsetWrap(Buffer const & buf, string const & type)
+       : InsetCollapsable(buf), name_(from_utf8(type))
 {
-       setLabel(_("wrap: ") + floatName(type, bp));
+       setLabel(_("wrap: ") + floatName(type, buf.params()));
        params_.type = type;
        params_.lines = 0;
        params_.placement = "o";
@@ -74,15 +74,6 @@ void InsetWrap::doDispatch(Cursor & cur, FuncRequest & cmd)
                InsetWrapMailer(*this).updateDialog(&cur.bv());
                break;
 
-       case LFUN_MOUSE_RELEASE: {
-               if (cmd.button() == mouse_button::button3 && hitButton(cmd)) {
-                       InsetWrapMailer(*this).showDialog(&cur.bv());
-                       break;
-               }
-               InsetCollapsable::doDispatch(cur, cmd);
-               break;
-       }
-
        default:
                InsetCollapsable::doDispatch(cur, cmd);
                break;
@@ -200,12 +191,6 @@ void InsetWrap::validate(LaTeXFeatures & features) const
 }
 
 
-Inset * InsetWrap::clone() const
-{
-       return new InsetWrap(*this);
-}
-
-
 docstring InsetWrap::editMessage() const
 {
        return _("Opened Wrap Inset");