Changeset 3375 for doxygenplugin/0.10/doxygentrac
- Timestamp:
- 03/17/08 05:18:48 (9 months ago)
- Files:
-
- doxygenplugin/0.10/doxygentrac/doxygentrac.py (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
doxygenplugin/0.10/doxygentrac/doxygentrac.py
r2651 r3375 197 197 # Search in documentation directories 198 198 path = os.path.join(self.base_path, doc) 199 path = os.path.join(path, self.html_output) 199 200 if os.path.isdir(path): 200 201 index = os.path.join(path, 'search.idx') … … 208 209 209 210 # Search in common documentation directory 210 index = os.path.join(self.base_path, 'search.idx') 211 index = os.path.join(self.base_path, self.html_output) 212 index = os.path.join(index, 'search.idx') 211 213 if os.path.exists(index): 212 214 creation = os.path.getctime(index) … … 342 344 def _search_in_documentation(self, doc, keywords): 343 345 # Open index file for documentation 344 index = os.path.join(self.base_path, doc, 'search.idx')346 index = os.path.join(self.base_path, doc, self.html_output, 'search.idx') 345 347 if os.path.exists(index): 346 348 fd = open(index) … … 388 390 for i in range(numDocs): 389 391 idx = self._readInt(fd) 390 freq = self._readInt(fd) 392 if idx == -1: 393 freq = 0 394 else: 395 freq = self._readInt(fd) 391 396 results.append({'idx': idx, 'freq': freq >> 1, 392 397 'hi': freq & 1, 'multi': multiplier}) … … 398 403 399 404 for i in range(numDocs): 405 if results[count]['idx'] == -1: 406 results[count]['name'] = '' 407 results[count]['url'] = '' 408 count += 1 409 continue 400 410 fd.seek(results[count]['idx']) 401 411 name = self._readString(fd) 402 412 url = self._readString(fd) 403 413 results[count]['name'] = name 404 results[count]['url'] = url414 results[count]['url'] = self.html_output + '/' + url 405 415 count += 1 406 416 … … 436 446 b3 = fd.read(1) 437 447 b4 = fd.read(1) 448 449 if not b1 or not b2 or not b3 or not b4: 450 return -1; 438 451 439 452 return (ord(b1) << 24) | (ord(b2) << 16) | (ord(b3) << 8) | ord(b4)
