]> git.lyx.org Git - lyx.git/blobdiff - src/factory.cpp
Buffer: Rename function names:
[lyx.git] / src / factory.cpp
index 70bd42f59e47f5cd39f076f7802c3349611219ef..7fa0c55dce7f0b1751012bdc4dc9a3e86c44bdf5 100644 (file)
@@ -82,9 +82,6 @@ Inset * createInsetHelper(Buffer * buf, FuncRequest const & cmd)
 
                switch (cmd.action()) {
 
-               case LFUN_LINE_INSERT:
-                       return new InsetLine;
-
                case LFUN_NEWPAGE_INSERT: {
                        string const name = cmd.getArg(0);
                        InsetNewpageParams inp;
@@ -203,9 +200,6 @@ Inset * createInsetHelper(Buffer * buf, FuncRequest const & cmd)
                        return new InsetPrintNomencl(buf, icp);
                }
 
-               case LFUN_TOC_INSERT:
-                       return new InsetTOC(buf, InsetCommandParams(TOC_CODE));
-
                case LFUN_INFO_INSERT: {
                        InsetInfo * inset = new InsetInfo(buf, to_utf8(cmd.argument()));
                        inset->updateInfo();
@@ -292,6 +286,12 @@ Inset * createInsetHelper(Buffer * buf, FuncRequest const & cmd)
                                return new InsetLabel(buf, icp);
                        }
                        
+                       case LINE_CODE: {
+                               InsetCommandParams icp(code);
+                               InsetCommand::string2params(name, to_utf8(cmd.argument()), icp);
+                               return new InsetLine(buf, icp);
+                       }
+                               
                        case LISTINGS_CODE: {
                                InsetListingsParams par;
                                InsetListings::string2params(to_utf8(cmd.argument()), par);