mirror of
https://invent.kde.org/graphics/okular
synced 2024-09-17 23:11:48 +00:00
IO_ReadOnly -> QIODevice::ReadOnly
svn path=/branches/work/kde4/playground/graphics/okular/; revision=541290
This commit is contained in:
parent
f1cd775633
commit
ec385777e6
|
@ -136,7 +136,7 @@ bool KPDFDocument::openDocument( const QString & docFile, const KUrl& url, const
|
|||
{
|
||||
// docFile is always local so we can use QFile on it
|
||||
QFile fileReadTest( docFile );
|
||||
if ( !fileReadTest.open( IO_ReadOnly ) )
|
||||
if ( !fileReadTest.open( QIODevice::ReadOnly ) )
|
||||
{
|
||||
d->docFileName.clear();
|
||||
return false;
|
||||
|
@ -1373,7 +1373,7 @@ int KPDFDocument::getTotalMemory()
|
|||
#ifdef __linux__
|
||||
// if /proc/meminfo doesn't exist, return 128MB
|
||||
QFile memFile( "/proc/meminfo" );
|
||||
if ( !memFile.open( IO_ReadOnly ) )
|
||||
if ( !memFile.open( QIODevice::ReadOnly ) )
|
||||
return (cachedValue = 134217728);
|
||||
|
||||
// read /proc/meminfo and sum up the contents of 'MemFree', 'Buffers'
|
||||
|
@ -1394,7 +1394,7 @@ int KPDFDocument::getFreeMemory()
|
|||
#ifdef __linux__
|
||||
// if /proc/meminfo doesn't exist, return MEMORY FULL
|
||||
QFile memFile( "/proc/meminfo" );
|
||||
if ( !memFile.open( IO_ReadOnly ) )
|
||||
if ( !memFile.open( QIODevice::ReadOnly ) )
|
||||
return 0;
|
||||
|
||||
// read /proc/meminfo and sum up the contents of 'MemFree', 'Buffers'
|
||||
|
@ -1427,7 +1427,7 @@ void KPDFDocument::loadDocumentInfo()
|
|||
{
|
||||
//kDebug() << "Using '" << d->xmlFileName << "' as document info file." << endl;
|
||||
QFile infoFile( d->xmlFileName );
|
||||
if ( !infoFile.exists() || !infoFile.open( IO_ReadOnly ) )
|
||||
if ( !infoFile.exists() || !infoFile.open( QIODevice::ReadOnly ) )
|
||||
return;
|
||||
|
||||
// Load DOM from XML file
|
||||
|
|
|
@ -295,7 +295,7 @@ bool Shell::handleCompressed(KUrl & url, const QString &path, const KMimeType::P
|
|||
return false;
|
||||
}
|
||||
|
||||
if ( !filterDev->open(IO_ReadOnly) )
|
||||
if ( !filterDev->open(QIODevice::ReadOnly) )
|
||||
{
|
||||
KMessageBox::detailedError( this,
|
||||
i18n("<qt><strong>File Error!</strong> Could not open the file "
|
||||
|
|
|
@ -892,7 +892,7 @@ void NewStuffDialog::slotItemResult( KIO::Job * job )
|
|||
|
||||
/* UNCOMPRESS (specify uncompression method)
|
||||
KTar tar( fileName, "application/x-gzip" );
|
||||
tar.open( IO_ReadOnly );
|
||||
tar.open( QIODevice::ReadOnly );
|
||||
const KArchiveDirectory *dir = tar.directory();
|
||||
dir->copyTo( "somedir" );
|
||||
tar.close();
|
||||
|
|
|
@ -371,7 +371,7 @@ PageViewAnnotator::PageViewAnnotator( PageView * parent, KPDFDocument * storage
|
|||
{
|
||||
// load the tools from the 'xml tools definition' file. store the tree internally.
|
||||
QFile infoFile( locate("data", "oKular/tools.xml") );
|
||||
if ( infoFile.exists() && infoFile.open( IO_ReadOnly ) )
|
||||
if ( infoFile.exists() && infoFile.open( QIODevice::ReadOnly ) )
|
||||
{
|
||||
QDomDocument doc( "annotatingTools" );
|
||||
if ( doc.setContent( &infoFile ) )
|
||||
|
|
Loading…
Reference in a new issue