rem: var newLayout = new Layout(this._parent instanceof Site ? this._parent : null, 
add: var newLayout = new Layout(this._parent instanceof Site ? this._parent : null, 
context: function evalImport(param, creator) {   if (param.uploadError) {      // looks like the file uploaded has exceeded uploadLimit ...      throw new Exception("layoutImportTooBig");   } else if (!param.zipfile || param.zipfile.contentLength == 0) {      // looks like nothing was uploaded ...      throw new Exception("layoutImportNoUpload");   }   try {      var contents = ZipLib.extractAll(param.zipfile.getContent());      // first, check if there's a file called "preferences" in the archive      // and convert it into a HopObject      var data = contents.files["preferences.xml"].data;      var importLayout = Xml.readFromString(new java.lang.String(data, 0, data.length));      // start with the actual import      var newLayout = new Layout(this._parent instanceof Site ? this._parent : null,                                  importLayout.title, session.user);      newLayout.parent = param.layout ? root.layouts.get(param.layout) : null;      newLayout.preferences.setAll(importLayout.preferences);      newLayout.shareable = 0;      newLayout.imported = 1;      newLayout.alias = buildAlias(importLayout.alias, this);      newLayout.description = importLayout.description;      newLayout.creator = session.user;      // FIXME: this should be done after importing skins      // and images, buf for some reasons skins then      // won't be stored persistent      this.add(newLayout);      // import skins      newLayout.skins.evalImport(contents.files.skins);      // import images      newLayout.images.evalImport(contents.files.imagedata, contents.files.images);      return new Message("layoutImport", newLayout.title);   } catch (err) {      throw new Exception("layoutImportCorrupt");   }   return;}
meta: 993	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/993/55da42d4753e5f8d558730c5aadf81386326c423/objectFunctions.js/clean/code/LayoutMgr/objectFunctions.js