[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: extragear/multimedia/k3b
From: Sebastian Trueg <sebastian () trueg ! de>
Date: 2009-03-30 11:58:28
Message-ID: 1238414308.280386.2372.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 946795 by trueg:
Removed unused methods, code cleanup
M +1 -1 CMakeLists.txt
M +0 -6 ConfigureChecks.cmake
M +0 -54 libk3b/core/k3bglobals.cpp
M +5 -10 libk3b/core/k3bglobals.h
M +2 -2 libk3b/jobs/k3bdatatrackreader.h
M +31 -31 libk3b/tools/k3biso9660.h
M +5 -4 src/rip/videodvd/k3bvideodvdrippingwidget.cpp
--- trunk/extragear/multimedia/k3b/CMakeLists.txt #946794:946795
@@ -6,7 +6,7 @@
################## K3b version ################################
set(K3B_VERSION_MAJOR 1)
-set(K3B_VERSION_MINOR 62)
+set(K3B_VERSION_MINOR 63)
set(K3B_VERSION_RELEASE 0)
set(K3B_VERSION_STRING "${K3B_VERSION_MAJOR}.${K3B_VERSION_MINOR}.${K3B_VERSION_RELEASE}")
--- trunk/extragear/multimedia/k3b/ConfigureChecks.cmake #946794:946795
@@ -7,10 +7,4 @@
include(CheckStructMember)
include(CheckCXXSourceCompiles)
-check_type_size("int" SIZEOF_INT)
-check_type_size("long" SIZEOF_LONG)
-
-check_include_files(sys/vfs.h HAVE_SYS_VFS_H)
-check_include_files(sys/statvfs.h HAVE_SYS_STATVFS_H)
-
check_function_exists(stat64 HAVE_STAT64)
--- trunk/extragear/multimedia/k3b/libk3b/core/k3bglobals.cpp #946794:946795
@@ -62,55 +62,7 @@
#include <windows.h>
#endif
-/*
- struct Sample {
- unsigned char msbLeft;
- unsigned char lsbLeft;
- unsigned char msbRight;
- unsigned char lsbRight;
- short left() const {
- return ( msbLeft << 8 ) | lsbLeft;
- }
- short right() const {
- return ( msbRight << 8 ) | lsbRight;
- }
- void left( short d ) {
- msbLeft = d >> 8;
- lsbLeft = d;
- }
- void right( short d ) {
- msbRight = d >> 8;
- lsbRight = d;
- }
- };
-*/
-
-QString K3b::framesToString( int h, bool showFrames )
-{
- int m = h / 4500;
- int s = (h % 4500) / 75;
- int f = h % 75;
-
- QString str;
-
- if( showFrames ) {
- // cdrdao needs the MSF format where 1 second has 75 frames!
- str.sprintf( "%.2i:%.2i:%.2i", m, s, f );
- }
- else
- str.sprintf( "%.2i:%.2i", m, s );
-
- return str;
-}
-
-/*QString K3b::sizeToTime(long size)
- {
- int h = size / sizeof(Sample) / 588;
- return framesToString(h, false);
- }*/
-
-
qint16 K3b::swapByteOrder( const qint16& i )
{
return bswap_16( i );
@@ -131,12 +83,6 @@
}
-int K3b::round( double d )
-{
- return (int)( floor(d) + 0.5 <= d ? ceil(d) : floor(d) );
-}
-
-
QString K3b::findUniqueFilePrefix( const QString& _prefix, const QString& path )
{
QString url;
--- trunk/extragear/multimedia/k3b/libk3b/core/k3bglobals.h #946794:946795
@@ -78,9 +78,9 @@
enum SectorSize {
SectorSizeAudio = 2352,
SectorSizeData2048 = 2048,
- SectorSizeData2048_SUBHEADER = 2056,
+ SectorSizeData2048Subheader = 2056,
SectorSizeData2324 = 2324,
- SectorSizeData2324_SUBHEADER = 2332,
+ SectorSizeData2324Subheader = 2332,
SectorSizeRaw = 2448
};
@@ -104,15 +104,10 @@
LIBK3B_EXPORT QString writingModeString( WritingModes );
- LIBK3B_EXPORT QString framesToString( int h, bool showFrames = true );
- /*LIBK3B_EXPORT QString sizeToTime( long size );*/
-
LIBK3B_EXPORT qint16 swapByteOrder( const qint16& i );
LIBK3B_EXPORT qint32 swapByteOrder( const qint32& i );
LIBK3B_EXPORT qint64 swapByteOrder( const qint64& i );
- int round( double );
-
/**
* This checks the free space on the filesystem path is in.
* We use this since we encountered problems with the KDE version.
@@ -166,7 +161,7 @@
*
* Example: /usr/share/doc -> /usr/share/
*/
- QString parentDir( const QString& path );
+ LIBK3B_EXPORT QString parentDir( const QString& path );
/**
* For now this just replaces multiple occurrences of / with a single /
@@ -185,7 +180,7 @@
*/
LIBK3B_EXPORT Version simpleKernelVersion();
- QString systemName();
+ LIBK3B_EXPORT QString systemName();
LIBK3B_EXPORT KIO::filesize_t filesize( const KUrl& );
@@ -214,7 +209,7 @@
* Used to create a parameter for cdrecord, cdrdao or readcd.
* Takes care of SCSI and ATAPI.
*/
- QString externalBinDeviceParameter( Device::Device* dev, const ExternalBin* );
+ LIBK3B_EXPORT QString externalBinDeviceParameter( Device::Device* dev, const ExternalBin* );
/**
* Tries to convert urls from local protocols != "file" to file (for now supports media:/)
--- trunk/extragear/multimedia/k3b/libk3b/jobs/k3bdatatrackreader.h #946794:946795
@@ -52,8 +52,8 @@
enum SectorSize {
AUTO = 0,
MODE1 = SectorSizeData2048,
- MODE2FORM1 = SectorSizeData2048_SUBHEADER,
- MODE2FORM2 = SectorSizeData2324_SUBHEADER
+ MODE2FORM1 = SectorSizeData2048Subheader,
+ MODE2FORM2 = SectorSizeData2324Subheader
};
void setSectorSize( SectorSize size );
--- trunk/extragear/multimedia/k3b/libk3b/tools/k3biso9660.h #946794:946795
@@ -80,15 +80,15 @@
{
public:
Iso9660Entry( Iso9660* archive,
- const QString& isoName,
- const QString& name,
- int access,
- int date,
- int adate,
- int cdate,
- const QString& user,
- const QString& group,
- const QString& symlink );
+ const QString& isoName,
+ const QString& name,
+ int access,
+ int date,
+ int adate,
+ int cdate,
+ const QString& user,
+ const QString& group,
+ const QString& symlink );
virtual ~Iso9660Entry();
int adate() const { return m_adate; }
@@ -174,17 +174,17 @@
{
public:
Iso9660Directory( Iso9660* archive,
- const QString& isoName,
- const QString& name,
- int access,
- int date,
- int adate,
- int cdate,
- const QString& user,
- const QString& group,
- const QString& symlink,
- unsigned int pos = 0,
- unsigned int size = 0 );
+ const QString& isoName,
+ const QString& name,
+ int access,
+ int date,
+ int adate,
+ int cdate,
+ const QString& user,
+ const QString& group,
+ const QString& symlink,
+ unsigned int pos = 0,
+ unsigned int size = 0 );
~Iso9660Directory();
/**
@@ -261,17 +261,17 @@
* @param pos start sector
*/
Iso9660File( Iso9660* archive,
- const QString& isoName,
- const QString& name,
- int access,
- int date,
- int adate,
- int cdate,
- const QString& user,
- const QString& group,
- const QString& symlink,
- unsigned int pos,
- unsigned int size );
+ const QString& isoName,
+ const QString& name,
+ int access,
+ int date,
+ int adate,
+ int cdate,
+ const QString& user,
+ const QString& group,
+ const QString& symlink,
+ unsigned int pos,
+ unsigned int size );
~Iso9660File();
bool isFile() const { return true; }
--- trunk/extragear/multimedia/k3b/src/rip/videodvd/k3bvideodvdrippingwidget.cpp #946794:946795
@@ -26,6 +26,7 @@
#include <kurllabel.h>
#include <kdialog.h>
#include <klineedit.h>
+#include <KDiskFreeSpaceInfo>
#include <qcombobox.h>
#include <qspinbox.h>
@@ -254,10 +255,10 @@
path.truncate( path.lastIndexOf('/') );
QPalette pal( m_labelFreeSpace->palette() );
- unsigned long size, avail;
- if( K3b::kbFreeOnFs( path, size, avail ) ) {
- m_labelFreeSpace->setText( KIO::convertSizeFromKiB(avail) );
- if( avail < m_neededSize/1024 )
+ KDiskFreeSpaceInfo free = KDiskFreeSpaceInfo::freeSpaceInfo( path );
+ if( free.isValid() ) {
+ m_labelFreeSpace->setText( KIO::convertSizeFromKiB(free.available()) );
+ if( free.available() < m_neededSize/1024 )
pal.setColor( QPalette::Text, Qt::red );
else
pal.setColor( QPalette::Text, palette().color( QPalette::Text ) );
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic