--- ark/tar.cpp~ 2006-05-22 20:08:38.000000000 +0200 +++ ark/tar.cpp 2007-10-28 10:19:42.000000000 +0100 @@ -211,6 +211,9 @@ if( m_fileMimeType == "application/x-tzo" ) return QString( "lzop" ); + if( m_fileMimeType == "application/x-tlz" ) + return QString( "lzma" ); + return QString::null; } @@ -229,6 +232,9 @@ if( m_fileMimeType == "application/x-tzo" ) return QString( "lzop" ); + if( m_fileMimeType == "application/x-tlz" ) + return QString( "unlzma" ); + return QString::null; } --- ark/archiveformatinfo.cpp~ 2006-01-19 17:49:29.000000000 +0100 +++ ark/archiveformatinfo.cpp 2007-10-28 10:22:44.000000000 +0100 @@ -53,6 +53,7 @@ addFormatInfo( TAR_FORMAT, "application/x-tarz", ".tar.z" ); addFormatInfo( TAR_FORMAT, "application/x-tbz", ".tar.bz2" ); addFormatInfo( TAR_FORMAT, "application/x-tbz2", ".tar.bz2" ); + addFormatInfo( TAR_FORMAT, "application/x-tlz", ".tar.lzma" ); // x-tar as the last one to get its comment for all the others, too addFormatInfo( TAR_FORMAT, "application/x-tar", ".tar" ); @@ -67,6 +68,7 @@ addFormatInfo( COMPRESSED_FORMAT, "application/x-bzip2", ".bz2" ); addFormatInfo( COMPRESSED_FORMAT, "application/x-lzop", ".lzo" ); addFormatInfo( COMPRESSED_FORMAT, "application/x-compress", ".Z" ); + addFormatInfo( COMPRESSED_FORMAT, "application/x-lzma", ".lzma" ); find( COMPRESSED_FORMAT ).description = i18n( "Compressed File" ); addFormatInfo( ZOO_FORMAT, "application/x-zoo", ".zoo" ); @@ -208,7 +210,7 @@ QString ArchiveFormatInfo::findMimeType( const KURL & url ) { QString mimeType = KMimeType::findByURL( url )->name(); - if ( mimeType != "application/x-bzip2" && mimeType != "application/x-gzip" ) + if ( mimeType != "application/x-bzip2" && mimeType != "application/x-gzip" && mimeType != "application/x-lzma" ) return mimeType; QIODevice * dev = KFilterDev::deviceForFile( url.path(), mimeType ); @@ -225,6 +227,8 @@ { if (mimeType == "application/x-bzip2") return "application/x-tbz"; + else if (mimeType == "application/x-lzma") + return "application/x-tlz"; else return "application/x-tgz"; } --- ark/compressedfile.cpp~ 2006-05-22 20:08:38.000000000 +0200 +++ ark/compressedfile.cpp 2007-10-28 10:24:56.000000000 +0100 @@ -135,7 +135,12 @@ m_archiver_program = "compress"; m_defaultExtensions = ".Z"; } - + if ( mimeType == "application/x-lzma" ) + { + m_unarchiver_program = "unlzma"; + m_archiver_program = "lzma"; + m_defaultExtensions << ".lzma"; + } } QString CompressedFile::extension() --- superkaramba/src/sknewstuff.cpp~ 2006-01-19 17:49:35.000000000 +0100 +++ superkaramba/src/sknewstuff.cpp 2007-10-28 10:26:02.000000000 +0100 @@ -66,9 +66,11 @@ result->name() == "application/x-tbz" || result->name() == "application/x-tbz2" || result->name() == "application/x-tar" || - result->name() == "application/x-tarz") + result->name() == "application/x-tarz" || + result->name() == "application/x-lzma" || + result->name() == "application/x-tlz") { - kdDebug() << "SKNewStuff::install() gzip/bzip2 mimetype encountered" << + kdDebug() << "SKNewStuff::install() gzip/bzip2/lzma mimetype encountered" << endl; KTar archive( fileName ); if ( !archive.open( IO_ReadOnly ) )