equal
deleted
inserted
replaced
526 } |
526 } |
527 |
527 |
528 QByteArray data = fi.readAll(); |
528 QByteArray data = fi.readAll(); |
529 if (fileName.endsWith(QLatin1String(".html")) |
529 if (fileName.endsWith(QLatin1String(".html")) |
530 || fileName.endsWith(QLatin1String(".htm"))) { |
530 || fileName.endsWith(QLatin1String(".htm"))) { |
531 charSet = QHelpGlobal::charsetFromData(data); |
531 charSet = QHelpGlobal::codecFromData(data); |
532 QTextStream stream(&data); |
532 QTextStream stream(&data); |
533 stream.setCodec(QTextCodec::codecForName(charSet.toLatin1().constData())); |
533 stream.setCodec(QTextCodec::codecForName(charSet.toLatin1().constData())); |
534 title = QHelpGlobal::documentTitle(stream.readAll()); |
534 title = QHelpGlobal::documentTitle(stream.readAll()); |
535 } else { |
535 } else { |
536 title = fileName.mid(fileName.lastIndexOf(QLatin1Char('/')) + 1); |
536 title = fileName.mid(fileName.lastIndexOf(QLatin1Char('/')) + 1); |