]> git.lyx.org Git - lyx.git/blobdiff - src/insets/insetbibtex.C
add warning make controllers compile and remove some alomost unused functions, commen...
[lyx.git] / src / insets / insetbibtex.C
index 370faeaf2b66ebdf30630b50d0d94c51aca61f16..21b54b9112f970d90d0bf863980308d61a2b38c1 100644 (file)
@@ -48,14 +48,17 @@ InsetBibtex::~InsetBibtex()
 
 dispatch_result InsetBibtex::localDispatch(FuncRequest const & cmd)
 {
-       Inset::RESULT result = UNDISPATCHED;
-
        switch (cmd.action) {
+
+       case LFUN_INSET_EDIT:
+               InsetCommandMailer("bibtex", *this).showDialog(cmd.view());
+               return DISPATCHED;
+
        case LFUN_INSET_MODIFY: {
                InsetCommandParams p;
                InsetCommandMailer::string2params(cmd.argument, p);
                if (p.getCmdName().empty())
-                       break;
+                       return DISPATCHED;
 
                if (view() && p.getContents() != params().getContents()) {
                        view()->ChangeCitationsIfUnique(params().getContents(),
@@ -63,15 +66,14 @@ dispatch_result InsetBibtex::localDispatch(FuncRequest const & cmd)
                }
 
                setParams(p);
-               cmd.view()->updateInset(this, true);
-               result = DISPATCHED;
+               cmd.view()->updateInset(this);
+               return  DISPATCHED;
        }
-       break;
+
        default:
-               result = InsetCommand::localDispatch(cmd);
+               return InsetCommand::localDispatch(cmd);
        }
 
-       return result;
 }
 
 string const InsetBibtex::getScreenLabel(Buffer const *) const
@@ -218,19 +220,6 @@ void InsetBibtex::fillWithBibKeys
 }
 
 
-void InsetBibtex::edit(BufferView *, int, int, mouse_button::state)
-{
-       InsetCommandMailer mailer("bibtex", *this);
-       mailer.showDialog();
-}
-
-
-void InsetBibtex::edit(BufferView * bv, bool)
-{
-       edit(bv, 0, 0, mouse_button::none);
-}
-
-
 bool InsetBibtex::addDatabase(string const & db)
 {
        string contents(getContents());