Changeset View
Changeset View
Standalone View
Standalone View
core/scripter.cpp
Show First 20 Lines • Show All 53 Lines • ▼ Show 20 Line(s) | 53 | #if 0 | |||
---|---|---|---|---|---|
54 | if ( script.length() < 1000 ) | 54 | if ( script.length() < 1000 ) | ||
55 | qDebug() << script; | 55 | qDebug() << script; | ||
56 | else | 56 | else | ||
57 | qDebug() << script.left( 1000 ) << "[...]"; | 57 | qDebug() << script.left( 1000 ) << "[...]"; | ||
58 | #endif | 58 | #endif | ||
59 | static QString builtInScript; | 59 | static QString builtInScript; | ||
60 | if ( builtInScript.isNull() ) | 60 | if ( builtInScript.isNull() ) | ||
61 | { | 61 | { | ||
62 | QFile builtInResource ( ":/script/builtin.js" ); | 62 | QFile builtInResource ( QStringLiteral(":/script/builtin.js") ); | ||
63 | if (!builtInResource.open( QIODevice::ReadOnly )) | 63 | if (!builtInResource.open( QIODevice::ReadOnly )) | ||
64 | { | 64 | { | ||
65 | qCDebug(OkularCoreDebug) << "failed to load builtin script"; | 65 | qCDebug(OkularCoreDebug) << "failed to load builtin script"; | ||
66 | } | 66 | } | ||
67 | else | 67 | else | ||
68 | { | 68 | { | ||
69 | builtInScript = QString::fromUtf8( builtInResource.readAll() ); | 69 | builtInScript = QString::fromUtf8( builtInResource.readAll() ); | ||
70 | builtInResource.close(); | 70 | builtInResource.close(); | ||
Show All 26 Lines |