Diff for /Amaya/amaya/templates.c between versions 1.36 and 1.37

version 1.36, 2005/08/12 15:04:51 version 1.37, 2005/08/16 13:15:09
Line 257  void InitTemplateList () Line 257  void InitTemplateList ()
     }      }
   TtaFreeMemory (urlstring);    TtaFreeMemory (urlstring);
 }  }
   
 /*-------------------------------------------------  /*-------------------------------------------------
  Insert the meta element identifying the template's   Insert the meta element identifying the template's
  instance   instance
Line 265  void insertTemplateMeta (Document newdoc Line 266  void insertTemplateMeta (Document newdoc
 {  {
   Element el = TtaGetMainRoot (newdoc);    Element el = TtaGetMainRoot (newdoc);
   Element meta;    Element meta;
   Element head = NULL;    Element head;
   ElementType elType;    ElementType elType;
   AttributeType attrType;    AttributeType attrType;
   Attribute attr;    Attribute attr;
Line 382  int CreateInstanceOfTemplate (Document d Line 383  int CreateInstanceOfTemplate (Document d
               
       templateFile[0] = EOS;        templateFile[0] = EOS;
               
         insertTemplateMeta(newdoc);
         
       LoadDocument (newdoc, templatename, NULL, NULL, CE_ABSOLUTE,        LoadDocument (newdoc, templatename, NULL, NULL, CE_ABSOLUTE,
                     "", DocumentName, NULL, FALSE, &DontReplaceOldDoc);                      "", DocumentName, NULL, FALSE, &DontReplaceOldDoc);
               
Line 413  int CreateInstanceOfTemplate (Document d Line 416  int CreateInstanceOfTemplate (Document d
       /* check parsing errors */        /* check parsing errors */
       CheckParsingErrors (newdoc);        CheckParsingErrors (newdoc);
               
       /* Set elements access rights  
          according to free_* elements */  
       Element el = TtaGetMainRoot (newdoc);  
       LockFixedAreas (newdoc, el);  
       insertTemplateMeta(newdoc);  
     }      }
    BackupDocument = 0;     BackupDocument = 0;
    return (newdoc);     return (newdoc);
   
 }  }
   
   void LoadInstanceOfTemplate (Document doc)
   {
     Element el = TtaGetMainRoot (doc);
     LockFixedAreas (doc, el);
   }

Removed from v.1.36  
changed lines
  Added in v.1.37


Webmaster