diff options
author | gman@google.com <gman@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-06-17 06:29:23 +0000 |
---|---|---|
committer | gman@google.com <gman@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-06-17 06:29:23 +0000 |
commit | 5335a2097ca95ba95856ea9af73a5e1c6158689c (patch) | |
tree | a14f7c154461bcd0f130998e208f4797ff97727c /o3d/documentation | |
parent | 1dc3ba84c3da4edfeaf22cedf65750533a20de00 (diff) | |
download | chromium_src-5335a2097ca95ba95856ea9af73a5e1c6158689c.zip chromium_src-5335a2097ca95ba95856ea9af73a5e1c6158689c.tar.gz chromium_src-5335a2097ca95ba95856ea9af73a5e1c6158689c.tar.bz2 |
Undoing gcl bug damage AGAIN
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18600 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'o3d/documentation')
-rw-r--r-- | o3d/documentation/jsdoc-toolkit-templates/publish.js | 65 |
1 files changed, 29 insertions, 36 deletions
diff --git a/o3d/documentation/jsdoc-toolkit-templates/publish.js b/o3d/documentation/jsdoc-toolkit-templates/publish.js index d4e102a..1890434 100644 --- a/o3d/documentation/jsdoc-toolkit-templates/publish.js +++ b/o3d/documentation/jsdoc-toolkit-templates/publish.js @@ -543,35 +543,38 @@ function linkifySingleType(type) { } } } else if (type.indexOf(':') >= 0) { // check for records. - if (type.indexOf('::') >= 0) { // check for CPP scope - print ('WARNING: CPP "::" scope operator found for type "' + type + - '" must be Javascript "." scope operator.'); - } else { - var elements = type.split(/\s*,\s*/); - var output = '{'; - for (var ii = 0; ii < elements.length; ++ii) { - if (ii > 0) { - output += ', '; - } - var element = elements[ii]; - var colon = element.indexOf(': '); - if (colon < 0) { - print ("WARNING: Malformed record specification. Format must be " + - "{id1: type1, id2: type2, ...}."); - output += element; - } else { - var name = element.substring(0, colon); - var subType = element.substring(colon + 2); - output += name + ': ' + linkifyTypeSpec(subType) - } + var elements = type.split(/\s*,\s*/); + var output = '{'; + for (var ii = 0; ii < elements.length; ++ii) { + if (ii > 0) { + output += ', '; + } + var element = elements[ii]; + var colon = element.indexOf(': '); + if (colon < 0) { + print ("WARNING: Malformed record specification. Format must be " + + "{id1: type1, id2: type2, ...}."); + output += element; + } else { + var name = element.substring(0, colon); + var subType = element.substring(colon + 2); + output += name + ': ' + linkifyTypeSpec(subType) } - link = output + '}'; } + link = output + '}'; } else { var symbol = getSymbol(type); if (symbol) { link = '<a class="el" href="' + getLinkToSymbol(symbol) + '">' + type + '</a>'; + } else if (startsWith(type, 'o3d.')) { + // TODO: remove this hack, make nixysa generate JSDOC js + // files instead of C++ headers and pass those into + // jsdoctoolkit. + reportUnknownType(type); + link = '<a class="el" href="../classo3d_1_1_' + + camelCaseToUnderscore(type.substring(4)) + '.html">' + + type + '</a>'; } else { // See if the symbol is a property or field. var period = type.lastIndexOf('.'); @@ -583,21 +586,11 @@ function linkifySingleType(type) { link = '<a class="el" href="' + getLinkToSymbol(symbol) + '#' + field + '">' + type + '</a>'; } else { - if (startsWith(type, 'o3d.')) { - // TODO(gman): remove this hack, make nixysa generate JSDOC js - // files instead of C++ headers and pass those into - // jsdoctoolkit. + if (subType[0] == '?') { + subType = subType.substring(1); + } + if (!g_validJSDOCTypes[subType]) { reportUnknownType(type); - link = '<a class="el" href="../classo3d_1_1_' + - camelCaseToUnderscore(type.substring(4)) + '.html">' + - type + '</a>'; - } else { - if (subType[0] == '?') { - subType = subType.substring(1); - } - if (!g_validJSDOCTypes[subType]) { - reportUnknownType(type); - } } } } |