4883 lines
188 KiB
Diff
4883 lines
188 KiB
Diff
diff -ru CMakeLists.txt CMakeLists.txt
|
||
--- CMakeLists.txt 2009-05-26 20:43:38.000000000 +0200
|
||
+++ CMakeLists.txt 2009-07-23 11:42:06.000000000 +0200
|
||
@@ -6,7 +6,7 @@
|
||
|
||
################## K3b version ################################
|
||
set(K3B_VERSION_MAJOR 1)
|
||
-set(K3B_VERSION_MINOR 66)
|
||
+set(K3B_VERSION_MINOR 67)
|
||
set(K3B_VERSION_RELEASE 0)
|
||
set(K3B_VERSION_STRING "${K3B_VERSION_MAJOR}.${K3B_VERSION_MINOR}.${K3B_VERSION_RELEASE}")
|
||
|
||
diff -ru k3bsetup/k3bsetup.desktop k3bsetup/k3bsetup.desktop
|
||
--- k3bsetup/k3bsetup.desktop 2009-05-26 16:22:58.000000000 +0200
|
||
+++ k3bsetup/k3bsetup.desktop 2009-07-23 11:42:05.000000000 +0200
|
||
@@ -1,12 +1,16 @@
|
||
[Desktop Entry]
|
||
Encoding=UTF-8
|
||
Comment=K3bSetup - modify permission for CD/DVD burning with K3b
|
||
+Comment[bg]=Настройване на K3b - промяна на правата за запис на CD/DVD
|
||
+Comment[da]=K3bSetup - ændr rettigheder til cd-/dvd-brænding med K3b
|
||
Comment[de]=K3b-Einrichtungsassistent - Zugriffsrechte zum Brennen mit K3b anpassen
|
||
Comment[es]=K3bSetup - modificar los permisos para la grabación de CD o DVD con K3b
|
||
Comment[et]=K3b seadistamine - võimalus muuta õigusi CD/DVD kirjutamiseks K3b-ga
|
||
Comment[fr]=K3bSetup - modification des droits d'accès pour la gravure de CD / DVD avec K3b
|
||
+Comment[it]=K3bSetup - modifica i permessi per CD/DVD per scrivere con K3b
|
||
Comment[km]=K3bSetup - កែប្រែសិទ្ធិសម្រាប់ដុតស៊ីឌី/ឌីវីឌីដែលមាន K3b
|
||
Comment[nb]=K3bSetup – endre tillatelser for CD-/DVD-brenning med K3b
|
||
+Comment[nds]=K3b-Inrichthölper - Verlöven för't Brennen vun CDs oder DVDs mit K3b ännern
|
||
Comment[nl]=K3bSetup - stelt de toegangsrechten in voor cd/dvd-branden met K3b
|
||
Comment[pt]=K3bSetup - modificar as permissões para a gravação de CDs/DVDs com o K3b
|
||
Comment[pt_BR]=Configurações Avançadas do K3b - modificar permissões para a queima de CD/DVD com o K3b
|
||
@@ -14,12 +18,17 @@
|
||
Comment[sv]=Ställ in K3b: ändra rättigheter för att bränna cd/dvd med K3b
|
||
Comment[tr]=K3bSetup - K3b ile CD/DVD yazdırma izinlerini ayarlayın
|
||
Comment[uk]=K3bSetup — змініть права для запису КД/DVD у K3b
|
||
+Comment[x-test]=xxK3bSetup - modify permission for CD/DVD burning with K3bxx
|
||
+Comment[zh_TW]=K3bSetup - 變更 CD/DVD 燒錄的權限
|
||
Exec=k3bsetup
|
||
Keywords=K3bSetup,k3bsetup
|
||
+Keywords[bg]=K3bSetup2,k3bsetup2,Настройване на K3b
|
||
Keywords[de]=K3b, Einrichtungsassistent, Rechte, Setup
|
||
Keywords[et]=K3bSetup,k3bsetup,k3b seadistamine
|
||
+Keywords[nds]=K3bSetup,k3bsetup,K3b-Inrichthölper
|
||
Keywords[pt_BR]=Configurações Avançadas do K3b,configurações avançadas do K3b
|
||
Keywords[sv]=Ställ in K3b,k3bsetup
|
||
+Keywords[x-test]=xxK3bSetup,k3bsetupxx
|
||
Name=K3bSetup
|
||
Name[bg]=Настройване на K3b
|
||
Name[de]=K3b-Einrichtungsassistent
|
||
@@ -62,6 +71,7 @@
|
||
GenericName[he]=הגדרות צריבת CD ו DVD
|
||
GenericName[hne]=सीडी डीवीडी बर्निंग सेटअप
|
||
GenericName[hsb]=CD & DVD setup za palenje
|
||
+GenericName[it]=Impostazioni di scrittura per CD e DVD
|
||
GenericName[ja]=CD / DVD 作成の設定
|
||
GenericName[km]=រៀបចំការដុតស៊ីឌី និងឌីវីឌី
|
||
GenericName[ko]=CD와 DVD 쓰기 설정
|
||
@@ -85,3 +95,4 @@
|
||
GenericName[uk]=Налаштування запису КД і DVD
|
||
GenericName[x-test]=xxCD & DVD Burning Setupxx
|
||
GenericName[zh_CN]=CD & DVD 刻录程序设置
|
||
+GenericName[zh_TW]=CD 與 DVD 燒錄設定
|
||
diff -ru kioslaves/videodvd/videodvd.desktop kioslaves/videodvd/videodvd.desktop
|
||
--- kioslaves/videodvd/videodvd.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ kioslaves/videodvd/videodvd.desktop 2009-07-23 11:42:06.000000000 +0200
|
||
@@ -4,7 +4,7 @@
|
||
URL=videodvd:/
|
||
Icon=dvd_unmount
|
||
Name=Video DVD Browser
|
||
-Name[bg]=Браузър за видео DVD
|
||
+Name[bg]=Програма за преглед на видео DVD
|
||
Name[ca]=Navegador de DVDs de vídeo
|
||
Name[cs]=Prohlížeč Video DVD
|
||
Name[csb]=Przezérnik platów DVD Video
|
||
@@ -22,6 +22,7 @@
|
||
Name[he]=דפדפן וידאו DVD
|
||
Name[hne]=वीडियो डीवीडी ब्राउजर
|
||
Name[hsb]=Wideo DVD Browser
|
||
+Name[it]=Navigatore DVD video
|
||
Name[ja]=ビデオ DVD ブラウザ
|
||
Name[km]=កម្មវិធីរុករកឌីវីឌីវីដេអូ
|
||
Name[ko]=비디오 DVD 탐색기
|
||
@@ -44,6 +45,7 @@
|
||
Name[uk]=Навігатор відео-DVD
|
||
Name[x-test]=xxVideo DVD Browserxx
|
||
Name[zh_CN]=视频 DVD 浏览器
|
||
+Name[zh_TW]=影像 DVD 瀏覽器
|
||
Open=false
|
||
X-KDE-TreeModule=Directory
|
||
X-KDE-KonqSidebarModule=konqsidebar_tree
|
||
diff -ru kioslaves/videodvd/videodvd.protocol kioslaves/videodvd/videodvd.protocol
|
||
--- kioslaves/videodvd/videodvd.protocol 2009-05-03 15:17:04.000000000 +0200
|
||
+++ kioslaves/videodvd/videodvd.protocol 2009-07-23 11:42:06.000000000 +0200
|
||
@@ -25,6 +25,7 @@
|
||
Description[gl]=Un kioslave que permite copiar ficheiros desde un DVD de vídeo (incluindo a decifraxe)
|
||
Description[he]=עבד קלט/פלט של KDE המאפשר לקבצים להיות מועתקים מתקליטור וידאו של DVD (כולל פענוח)
|
||
Description[hsb]=kioslave, kiž zmóžni kopěrowanje datajow z Wideo-DVD (tež šifrowaneje)
|
||
+Description[it]=Un kioslave per permettere ai file di essere copiati da un DVD video (inclusa decifrazione)
|
||
Description[ja]=ビデオ DVD からファイルをコピーすることを可能にする kioslave (暗号解除も含む)
|
||
Description[km]=kioslave អនុញ្ញាតឲ្យចម្លងឯកសារពីឌីវីឌីវីដេអូ (ដោយរួមបញ្ចូលការឌិគ្រីប)
|
||
Description[ko]=비디오 DVD에서 파일을 복사하는 KIO 슬레이브 (암호화 해제 포함)
|
||
@@ -47,3 +48,4 @@
|
||
Description[uk]=Підлеглий В/В, який дає змогу копіювати файли з відео-DVD (включаючи розшифровування)
|
||
Description[x-test]=xxA kioslave that allows files to be copied from a Video DVD (including decryption)xx
|
||
Description[zh_CN]=允许从视频 DVD(包括加密影碟)中复制文件的 kioslave
|
||
+Description[zh_TW]=允許檔案從影像 DVD 中(解壓並)複製出來的 kioslave
|
||
diff -ru libk3b/core/k3bglobals.cpp libk3b/core/k3bglobals.cpp
|
||
--- libk3b/core/k3bglobals.cpp 2009-05-27 11:58:34.000000000 +0200
|
||
+++ libk3b/core/k3bglobals.cpp 2009-07-23 11:41:53.000000000 +0200
|
||
@@ -34,7 +34,17 @@
|
||
#include <kio/netaccess.h>
|
||
#include <kurl.h>
|
||
#include <kprocess.h>
|
||
+#if KDE_IS_VERSION(4,2,0)
|
||
#include <KDiskFreeSpaceInfo>
|
||
+#else
|
||
+#include <sys/stat.h>
|
||
+#ifdef HAVE_SYS_STATVFS_H
|
||
+# include <sys/statvfs.h>
|
||
+#endif
|
||
+#ifdef HAVE_SYS_VFS_H
|
||
+# include <sys/vfs.h>
|
||
+#endif
|
||
+#endif
|
||
|
||
#include <kmountpoint.h>
|
||
#include <Solid/Device>
|
||
@@ -210,6 +220,7 @@
|
||
|
||
bool K3b::kbFreeOnFs( const QString& path, unsigned long& size, unsigned long& avail )
|
||
{
|
||
+#if KDE_IS_VERSION(4,2,0)
|
||
KDiskFreeSpaceInfo fs = KDiskFreeSpaceInfo::freeSpaceInfo( path );
|
||
if ( fs.isValid() ) {
|
||
size = fs.size()/1024;
|
||
@@ -219,6 +230,21 @@
|
||
else {
|
||
return false;
|
||
}
|
||
+#else
|
||
+#ifdef HAVE_SYS_STATVFS_H
|
||
+ struct statvfs fs;
|
||
+ if( ::statvfs( QFile::encodeName(path), &fs ) == 0 ) {
|
||
+ unsigned long kBfak = fs.f_frsize/1024;
|
||
+
|
||
+ size = fs.f_blocks*kBfak;
|
||
+ avail = fs.f_bavail*kBfak;
|
||
+
|
||
+ return true;
|
||
+ }
|
||
+ else
|
||
+#endif
|
||
+ return false;
|
||
+#endif
|
||
}
|
||
|
||
|
||
diff -ru libk3b/core/k3bthreadjobcommunicationevent.cpp libk3b/core/k3bthreadjobcommunicationevent.cpp
|
||
--- libk3b/core/k3bthreadjobcommunicationevent.cpp 2009-03-23 09:47:00.000000000 +0100
|
||
+++ libk3b/core/k3bthreadjobcommunicationevent.cpp 2009-07-23 11:41:53.000000000 +0200
|
||
@@ -16,11 +16,8 @@
|
||
|
||
#include <QtCore/QMutex>
|
||
|
||
-
|
||
-K3b::ThreadJobCommunicationEvent::ThreadJobCommunicationEvent( int type )
|
||
- : QEvent( QEvent::User ),
|
||
- m_type( type ),
|
||
- m_device( 0 ),
|
||
+K3b::ThreadJobCommunicationEvent::Data::Data()
|
||
+ : m_device( 0 ),
|
||
m_wantedMediaState( 0 ),
|
||
m_wantedMediaType( 0 ),
|
||
m_result( 0 )
|
||
@@ -28,78 +25,69 @@
|
||
}
|
||
|
||
|
||
-K3b::ThreadJobCommunicationEvent::~ThreadJobCommunicationEvent()
|
||
-{
|
||
-}
|
||
-
|
||
-
|
||
-int K3b::ThreadJobCommunicationEvent::type() const
|
||
-{
|
||
- return m_type;
|
||
-}
|
||
|
||
|
||
-K3b::Device::Device* K3b::ThreadJobCommunicationEvent::device() const
|
||
+K3b::Device::Device* K3b::ThreadJobCommunicationEvent::Data::device() const
|
||
{
|
||
return m_device;
|
||
}
|
||
|
||
|
||
-K3b::Device::MediaStates K3b::ThreadJobCommunicationEvent::wantedMediaState() const
|
||
+K3b::Device::MediaStates K3b::ThreadJobCommunicationEvent::Data::wantedMediaState() const
|
||
{
|
||
return m_wantedMediaState;
|
||
}
|
||
|
||
|
||
-K3b::Device::MediaTypes K3b::ThreadJobCommunicationEvent::wantedMediaType() const
|
||
+K3b::Device::MediaTypes K3b::ThreadJobCommunicationEvent::Data::wantedMediaType() const
|
||
{
|
||
return m_wantedMediaType;
|
||
}
|
||
|
||
|
||
-QString K3b::ThreadJobCommunicationEvent::message() const
|
||
+QString K3b::ThreadJobCommunicationEvent::Data::message() const
|
||
{
|
||
return m_text;
|
||
}
|
||
|
||
|
||
-QString K3b::ThreadJobCommunicationEvent::text() const
|
||
+QString K3b::ThreadJobCommunicationEvent::Data::text() const
|
||
{
|
||
return m_text;
|
||
}
|
||
|
||
|
||
-QString K3b::ThreadJobCommunicationEvent::caption() const
|
||
+QString K3b::ThreadJobCommunicationEvent::Data::caption() const
|
||
{
|
||
return m_caption;
|
||
}
|
||
|
||
|
||
-QString K3b::ThreadJobCommunicationEvent::yesText() const
|
||
+QString K3b::ThreadJobCommunicationEvent::Data::yesText() const
|
||
{
|
||
return m_yesText;
|
||
}
|
||
|
||
|
||
-QString K3b::ThreadJobCommunicationEvent::noText() const
|
||
+QString K3b::ThreadJobCommunicationEvent::Data::noText() const
|
||
{
|
||
return m_noText;
|
||
}
|
||
|
||
|
||
-int K3b::ThreadJobCommunicationEvent::intResult() const
|
||
+int K3b::ThreadJobCommunicationEvent::Data::intResult() const
|
||
{
|
||
return m_result;
|
||
}
|
||
|
||
|
||
-bool K3b::ThreadJobCommunicationEvent::boolResult() const
|
||
+bool K3b::ThreadJobCommunicationEvent::Data::boolResult() const
|
||
{
|
||
return ( m_result != 0 );
|
||
}
|
||
|
||
|
||
-void K3b::ThreadJobCommunicationEvent::wait()
|
||
+void K3b::ThreadJobCommunicationEvent::Data::wait()
|
||
{
|
||
QMutex mutex;
|
||
mutex.lock();
|
||
@@ -108,23 +96,43 @@
|
||
}
|
||
|
||
|
||
-void K3b::ThreadJobCommunicationEvent::done( int result )
|
||
+void K3b::ThreadJobCommunicationEvent::Data::done( int result )
|
||
{
|
||
m_result = result;
|
||
m_threader.wakeAll();
|
||
}
|
||
|
||
|
||
+K3b::ThreadJobCommunicationEvent::ThreadJobCommunicationEvent( int type )
|
||
+ : QEvent( QEvent::User ),
|
||
+ m_type( type ),
|
||
+ m_data( new Data() )
|
||
+{
|
||
+}
|
||
+
|
||
+
|
||
+K3b::ThreadJobCommunicationEvent::~ThreadJobCommunicationEvent()
|
||
+{
|
||
+ // Do NOT delete m_data here. It is needed after destruction by K3b::ThreadJob
|
||
+}
|
||
+
|
||
+
|
||
+int K3b::ThreadJobCommunicationEvent::type() const
|
||
+{
|
||
+ return m_type;
|
||
+}
|
||
+
|
||
+
|
||
K3b::ThreadJobCommunicationEvent* K3b::ThreadJobCommunicationEvent::waitForMedium( K3b::Device::Device* device,
|
||
Device::MediaStates mediaState,
|
||
Device::MediaTypes mediaType,
|
||
const QString& message )
|
||
{
|
||
K3b::ThreadJobCommunicationEvent* event = new K3b::ThreadJobCommunicationEvent( WaitForMedium );
|
||
- event->m_device = device;
|
||
- event->m_wantedMediaState = mediaState;
|
||
- event->m_wantedMediaType = mediaType;
|
||
- event->m_text = message;
|
||
+ event->m_data->m_device = device;
|
||
+ event->m_data->m_wantedMediaState = mediaState;
|
||
+ event->m_data->m_wantedMediaType = mediaType;
|
||
+ event->m_data->m_text = message;
|
||
return event;
|
||
}
|
||
|
||
@@ -135,10 +143,10 @@
|
||
const QString& noText )
|
||
{
|
||
K3b::ThreadJobCommunicationEvent* event = new K3b::ThreadJobCommunicationEvent( QuestionYesNo );
|
||
- event->m_text = text;
|
||
- event->m_caption = caption;
|
||
- event->m_yesText = yesText;
|
||
- event->m_noText = noText;
|
||
+ event->m_data->m_text = text;
|
||
+ event->m_data->m_caption = caption;
|
||
+ event->m_data->m_yesText = yesText;
|
||
+ event->m_data->m_noText = noText;
|
||
return event;
|
||
}
|
||
|
||
@@ -147,7 +155,7 @@
|
||
const QString& caption )
|
||
{
|
||
K3b::ThreadJobCommunicationEvent* event = new K3b::ThreadJobCommunicationEvent( BlockingInfo );
|
||
- event->m_text = text;
|
||
- event->m_caption = caption;
|
||
+ event->m_data->m_text = text;
|
||
+ event->m_data->m_caption = caption;
|
||
return event;
|
||
}
|
||
diff -ru libk3b/core/k3bthreadjobcommunicationevent.h libk3b/core/k3bthreadjobcommunicationevent.h
|
||
--- libk3b/core/k3bthreadjobcommunicationevent.h 2009-03-23 09:47:00.000000000 +0100
|
||
+++ libk3b/core/k3bthreadjobcommunicationevent.h 2009-07-23 11:41:53.000000000 +0200
|
||
@@ -42,29 +42,55 @@
|
||
|
||
int type() const;
|
||
|
||
- Device::Device* device() const;
|
||
- Device::MediaStates wantedMediaState() const;
|
||
- Device::MediaTypes wantedMediaType() const;
|
||
- QString message() const;
|
||
-
|
||
- QString text() const;
|
||
- QString caption() const;
|
||
-
|
||
- QString yesText() const;
|
||
- QString noText() const;
|
||
-
|
||
- int intResult() const;
|
||
- bool boolResult() const;
|
||
-
|
||
/**
|
||
- * Used by the calling thread to wait for the result
|
||
+ * Separate data object are used since events are deleted once delivered.
|
||
+ * However, we need the data after the event has been delivered.
|
||
*/
|
||
- void wait();
|
||
+ class Data {
|
||
+ public:
|
||
+ Data();
|
||
+
|
||
+ Device::Device* device() const;
|
||
+ Device::MediaStates wantedMediaState() const;
|
||
+ Device::MediaTypes wantedMediaType() const;
|
||
+ QString message() const;
|
||
+
|
||
+ QString text() const;
|
||
+ QString caption() const;
|
||
+
|
||
+ QString yesText() const;
|
||
+ QString noText() const;
|
||
+
|
||
+ int intResult() const;
|
||
+ bool boolResult() const;
|
||
+
|
||
+
|
||
+ /**
|
||
+ * Used by the calling thread to wait for the result
|
||
+ */
|
||
+ void wait();
|
||
+
|
||
+ /**
|
||
+ * Signal back to the calling thread.
|
||
+ */
|
||
+ void done( int result );
|
||
+
|
||
+ private:
|
||
+ Device::Device* m_device;
|
||
+ Device::MediaStates m_wantedMediaState;
|
||
+ Device::MediaTypes m_wantedMediaType;
|
||
+ QString m_text;
|
||
+ QString m_caption;
|
||
+ QString m_yesText;
|
||
+ QString m_noText;
|
||
|
||
- /**
|
||
- * Signal back to the calling thread.
|
||
- */
|
||
- void done( int result );
|
||
+ QWaitCondition m_threader;
|
||
+ int m_result;
|
||
+
|
||
+ friend class ThreadJobCommunicationEvent;
|
||
+ };
|
||
+
|
||
+ Data* data() const { return m_data; }
|
||
|
||
static ThreadJobCommunicationEvent* waitForMedium( Device::Device* device,
|
||
Device::MediaStates mediaState,
|
||
@@ -81,16 +107,7 @@
|
||
ThreadJobCommunicationEvent( int type );
|
||
|
||
int m_type;
|
||
- Device::Device* m_device;
|
||
- Device::MediaStates m_wantedMediaState;
|
||
- Device::MediaTypes m_wantedMediaType;
|
||
- QString m_text;
|
||
- QString m_caption;
|
||
- QString m_yesText;
|
||
- QString m_noText;
|
||
-
|
||
- QWaitCondition m_threader;
|
||
- int m_result;
|
||
+ Data* m_data;
|
||
};
|
||
}
|
||
|
||
diff -ru libk3b/core/k3bthreadjob.cpp libk3b/core/k3bthreadjob.cpp
|
||
--- libk3b/core/k3bthreadjob.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ libk3b/core/k3bthreadjob.cpp 2009-07-23 11:41:53.000000000 +0200
|
||
@@ -20,6 +20,8 @@
|
||
#include <kdebug.h>
|
||
#include <kapplication.h>
|
||
|
||
+#include <QtCore/QSharedPointer>
|
||
+
|
||
|
||
class K3b::ThreadJob::Private
|
||
{
|
||
@@ -102,9 +104,10 @@
|
||
mediaState,
|
||
mediaType,
|
||
message );
|
||
+ QSharedPointer<K3b::ThreadJobCommunicationEvent::Data> data( event->data() );
|
||
QApplication::postEvent( this, event );
|
||
- event->wait();
|
||
- return (Device::MediaType)event->intResult();
|
||
+ data->wait();
|
||
+ return (Device::MediaType)data->intResult();
|
||
}
|
||
|
||
|
||
@@ -117,9 +120,10 @@
|
||
caption,
|
||
yesText,
|
||
noText );
|
||
+ QSharedPointer<K3b::ThreadJobCommunicationEvent::Data> data( event->data() );
|
||
QApplication::postEvent( this, event );
|
||
- event->wait();
|
||
- return event->boolResult();
|
||
+ data->wait();
|
||
+ return data->boolResult();
|
||
}
|
||
|
||
|
||
@@ -128,36 +132,38 @@
|
||
{
|
||
K3b::ThreadJobCommunicationEvent* event = K3b::ThreadJobCommunicationEvent::blockingInformation( text,
|
||
caption );
|
||
+ QSharedPointer<K3b::ThreadJobCommunicationEvent::Data> data( event->data() );
|
||
QApplication::postEvent( this, event );
|
||
- event->wait();
|
||
+ data->wait();
|
||
}
|
||
|
||
|
||
void K3b::ThreadJob::customEvent( QEvent* e )
|
||
{
|
||
if( K3b::ThreadJobCommunicationEvent* ce = dynamic_cast<K3b::ThreadJobCommunicationEvent*>(e) ) {
|
||
+ K3b::ThreadJobCommunicationEvent::Data* data = ce->data();
|
||
int result = 0;
|
||
switch( ce->type() ) {
|
||
case K3b::ThreadJobCommunicationEvent::WaitForMedium:
|
||
- result = K3b::Job::waitForMedia( ce->device(),
|
||
- ce->wantedMediaState(),
|
||
- ce->wantedMediaType(),
|
||
- ce->text() );
|
||
+ result = K3b::Job::waitForMedia( data->device(),
|
||
+ data->wantedMediaState(),
|
||
+ data->wantedMediaType(),
|
||
+ data->text() );
|
||
break;
|
||
|
||
case K3b::ThreadJobCommunicationEvent::QuestionYesNo:
|
||
- result = K3b::Job::questionYesNo( ce->text(),
|
||
- ce->caption(),
|
||
- ce->yesText(),
|
||
- ce->noText() )
|
||
+ result = K3b::Job::questionYesNo( data->text(),
|
||
+ data->caption(),
|
||
+ data->yesText(),
|
||
+ data->noText() )
|
||
? 1 : 0;
|
||
break;
|
||
|
||
case K3b::ThreadJobCommunicationEvent::BlockingInfo:
|
||
- K3b::Job::blockingInformation( ce->text(), ce->caption() );
|
||
+ K3b::Job::blockingInformation( data->text(), data->caption() );
|
||
break;
|
||
}
|
||
- ce->done( result );
|
||
+ data->done( result );
|
||
}
|
||
}
|
||
|
||
diff -ru libk3b/plugin/k3bplugin.desktop libk3b/plugin/k3bplugin.desktop
|
||
--- libk3b/plugin/k3bplugin.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ libk3b/plugin/k3bplugin.desktop 2009-07-23 11:41:57.000000000 +0200
|
||
@@ -2,7 +2,6 @@
|
||
Type=ServiceType
|
||
X-KDE-ServiceType=K3b/Plugin
|
||
Name=K3b Plugin
|
||
-Name[bg]=Приставка за K3b
|
||
Name[cs]=Modul K3b
|
||
Name[csb]=Wtëkôcz K3b
|
||
Name[da]=K3b-plugin
|
||
@@ -37,3 +36,4 @@
|
||
Name[uk]=Додаток K3b
|
||
Name[x-test]=xxK3b Pluginxx
|
||
Name[zh_CN]=k3b 插件
|
||
+Name[zh_TW]=K3b 外掛程式
|
||
diff -ru libk3b/plugin/k3bprojectplugin.cpp libk3b/plugin/k3bprojectplugin.cpp
|
||
--- libk3b/plugin/k3bprojectplugin.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ libk3b/plugin/k3bprojectplugin.cpp 2009-07-23 11:41:57.000000000 +0200
|
||
@@ -13,7 +13,7 @@
|
||
*/
|
||
#include "k3bprojectplugin.h"
|
||
|
||
-K3b::ProjectPlugin::ProjectPlugin( int type, bool gui, QObject* parent )
|
||
+K3b::ProjectPlugin::ProjectPlugin( Type type, bool gui, QObject* parent )
|
||
: K3b::Plugin( parent ),
|
||
m_type(type),
|
||
m_hasGUI(gui)
|
||
diff -ru libk3b/plugin/k3bprojectplugin.h libk3b/plugin/k3bprojectplugin.h
|
||
--- libk3b/plugin/k3bprojectplugin.h 2009-04-21 19:54:02.000000000 +0200
|
||
+++ libk3b/plugin/k3bprojectplugin.h 2009-07-23 11:41:57.000000000 +0200
|
||
@@ -15,14 +15,16 @@
|
||
#ifndef _K3B_PROJECT_PLUGIN_H_
|
||
#define _K3B_PROJECT_PLUGIN_H_
|
||
|
||
+#include "k3bdoc.h"
|
||
#include "k3bplugin.h"
|
||
|
||
+#include <QFlags>
|
||
+
|
||
#include "k3b_export.h"
|
||
|
||
class KConfigGroup;
|
||
|
||
namespace K3b {
|
||
- class Doc;
|
||
|
||
/**
|
||
* In case your plugin provides a GUI it is recommended to use the
|
||
@@ -71,31 +73,19 @@
|
||
Q_OBJECT
|
||
|
||
public:
|
||
+ Q_DECLARE_FLAGS( Type, Doc::Type )
|
||
+
|
||
/**
|
||
- * @param type The type of the plugin
|
||
+ * @param type The type of the plugin which can be a combination of @see Doc::Type
|
||
* @param gui If true the plugin is supposed to provide a widget via @p createGUI(). In that case
|
||
* @p activate() will not be used. A plugin has a GUI if it's functionality is started
|
||
* by some user input.
|
||
*/
|
||
- ProjectPlugin( int type, bool gui = false, QObject* parent = 0 );
|
||
+ ProjectPlugin( Type type, bool gui = false, QObject* parent = 0 );
|
||
|
||
virtual ~ProjectPlugin() {
|
||
}
|
||
|
||
- // TODO: move this to Doc?
|
||
- enum Type {
|
||
- AUDIO_CD = 0x1,
|
||
- DATA_CD = 0x2,
|
||
- MIXED_CD = 0x4,
|
||
- VIDEO_CD = 0x8,
|
||
- MOVIX_CD = 0x10,
|
||
- DATA_DVD = 0x20,
|
||
- VIDEO_DVD = 0x40,
|
||
- MOVIX_DVD = 0x80,
|
||
- DATA_PROJECTS = DATA_CD|DATA_DVD,
|
||
- MOVIX_PROJECTS = MOVIX_CD|MOVIX_DVD
|
||
- };
|
||
-
|
||
// TODO: maybe we should use something like "ProjectPlugin/AudioCD" based on the type?
|
||
QString category() const { return "ProjectPlugin"; }
|
||
|
||
@@ -106,7 +96,7 @@
|
||
* Needs to return a proper type. The default implementation returns the type specified
|
||
* in the constructor.
|
||
*/
|
||
- virtual int type() const { return m_type; }
|
||
+ virtual Type type() const { return m_type; }
|
||
|
||
/**
|
||
* Text used for menu entries and the like.
|
||
@@ -148,7 +138,7 @@
|
||
void setIcon( const QString& s ) { m_icon = s; }
|
||
|
||
private:
|
||
- int m_type;
|
||
+ Type m_type;
|
||
bool m_hasGUI;
|
||
QString m_text;
|
||
QString m_toolTip;
|
||
@@ -157,5 +147,6 @@
|
||
};
|
||
}
|
||
|
||
+Q_DECLARE_OPERATORS_FOR_FLAGS( K3b::ProjectPlugin::Type )
|
||
|
||
#endif
|
||
diff -ru libk3b/projects/audiocd/k3baudiodoc.cpp libk3b/projects/audiocd/k3baudiodoc.cpp
|
||
--- libk3b/projects/audiocd/k3baudiodoc.cpp 2009-04-15 11:34:06.000000000 +0200
|
||
+++ libk3b/projects/audiocd/k3baudiodoc.cpp 2009-07-23 11:41:55.000000000 +0200
|
||
@@ -26,29 +26,21 @@
|
||
#include "k3bcore.h"
|
||
#include "k3baudiodecoder.h"
|
||
|
||
-
|
||
-// QT-includes
|
||
-#include <qstring.h>
|
||
-#include <qstringlist.h>
|
||
-#include <qfile.h>
|
||
-#include <qfileinfo.h>
|
||
-#include <qdatastream.h>
|
||
-#include <qdir.h>
|
||
-#include <qdom.h>
|
||
-#include <qdatetime.h>
|
||
-#include <qtextstream.h>
|
||
-
|
||
-// KDE-includes
|
||
-#include <kurl.h>
|
||
-#include <kapplication.h>
|
||
-#include <kmessagebox.h>
|
||
-#include <kconfig.h>
|
||
-#include <klocale.h>
|
||
-#include <kstandarddirs.h>
|
||
+#include <QFile>
|
||
+#include <QFileInfo>
|
||
+#include <QDataStream>
|
||
+#include <QDir>
|
||
+#include <QDomElement>
|
||
+#include <QStringList>
|
||
+#include <QTextStream>
|
||
+
|
||
+#include <KApplication>
|
||
+#include <KConfig>
|
||
+#include <KDebug>
|
||
+#include <KLocale>
|
||
+#include <KMessageBox>
|
||
#include <kio/global.h>
|
||
-#include <kdebug.h>
|
||
-
|
||
-#include <iostream>
|
||
+#include <KStandardDirs>
|
||
|
||
|
||
class K3b::AudioDoc::Private
|
||
@@ -72,7 +64,6 @@
|
||
m_lastTrack(0)
|
||
{
|
||
d = new Private;
|
||
- m_docType = AUDIO;
|
||
}
|
||
|
||
K3b::AudioDoc::~AudioDoc()
|
||
@@ -497,12 +488,6 @@
|
||
}
|
||
|
||
|
||
-QString K3b::AudioDoc::typeString() const
|
||
-{
|
||
- return "audio";
|
||
-}
|
||
-
|
||
-
|
||
bool K3b::AudioDoc::loadDocumentData( QDomElement* root )
|
||
{
|
||
newDocument();
|
||
diff -ru libk3b/projects/audiocd/k3baudiodoc.h libk3b/projects/audiocd/k3baudiodoc.h
|
||
--- libk3b/projects/audiocd/k3baudiodoc.h 2009-04-21 19:54:02.000000000 +0200
|
||
+++ libk3b/projects/audiocd/k3baudiodoc.h 2009-07-23 11:41:55.000000000 +0200
|
||
@@ -18,16 +18,10 @@
|
||
#define K3BAUDIODOC_H
|
||
|
||
#include "k3bdoc.h"
|
||
-
|
||
#include "k3bcdtext.h"
|
||
#include "k3btoc.h"
|
||
|
||
-#include <qfile.h>
|
||
-#include <qstring.h>
|
||
-#include <qstringlist.h>
|
||
-#include <qdatetime.h>
|
||
#include "k3b_export.h"
|
||
-#include <kurl.h>
|
||
|
||
class QDomElement;
|
||
|
||
@@ -53,6 +47,9 @@
|
||
AudioDoc( QObject* );
|
||
~AudioDoc();
|
||
|
||
+ virtual Type type() const { return AudioProject; }
|
||
+ virtual QString typeString() const { return QString::fromLatin1("audio"); }
|
||
+
|
||
QString name() const;
|
||
|
||
bool newDocument();
|
||
@@ -204,8 +201,6 @@
|
||
/** reimplemented from Doc */
|
||
bool saveDocumentData( QDomElement* );
|
||
|
||
- QString typeString() const;
|
||
-
|
||
private:
|
||
// the stuff for adding files
|
||
// ---------------------------------------------------------
|
||
diff -ru libk3b/projects/datacd/k3bdatadoc.cpp libk3b/projects/datacd/k3bdatadoc.cpp
|
||
--- libk3b/projects/datacd/k3bdatadoc.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ libk3b/projects/datacd/k3bdatadoc.cpp 2009-07-23 11:41:54.000000000 +0200
|
||
@@ -34,25 +34,21 @@
|
||
#include "k3bvalidators.h"
|
||
#include "k3bglobalsettings.h"
|
||
|
||
-#include <qdir.h>
|
||
-#include <qstring.h>
|
||
-#include <qfileinfo.h>
|
||
-#include <qfile.h>
|
||
-#include <q3textstream.h>
|
||
-#include <qtimer.h>
|
||
-#include <qdom.h>
|
||
-
|
||
-#include <kstandarddirs.h>
|
||
-#include <kurl.h>
|
||
-#include <kstatusbar.h>
|
||
-#include <klocale.h>
|
||
-#include <kinputdialog.h>
|
||
-#include <kmessagebox.h>
|
||
-#include <kdebug.h>
|
||
-#include <kglobal.h>
|
||
-#include <kconfig.h>
|
||
-#include <kapplication.h>
|
||
-
|
||
+#include <QDir>
|
||
+#include <QDomElement>
|
||
+#include <QFile>
|
||
+#include <QFileInfo>
|
||
+#include <QTimer>
|
||
+
|
||
+#include <KApplication>
|
||
+#include <KConfig>
|
||
+#include <KDebug>
|
||
+#include <KGlobal>
|
||
+#include <KInputDialog>
|
||
+#include <KLocale>
|
||
+#include <KMessageBox>
|
||
+#include <KStandardDirs>
|
||
+#include <KStatusBar>
|
||
|
||
#include <string.h>
|
||
#include <stdlib.h>
|
||
@@ -263,12 +259,6 @@
|
||
}
|
||
|
||
|
||
-QString K3b::DataDoc::typeString() const
|
||
-{
|
||
- return QString::fromLatin1("data");
|
||
-}
|
||
-
|
||
-
|
||
bool K3b::DataDoc::loadDocumentData( QDomElement* rootElem )
|
||
{
|
||
if( !root() )
|
||
diff -ru libk3b/projects/datacd/k3bdatadoc.h libk3b/projects/datacd/k3bdatadoc.h
|
||
--- libk3b/projects/datacd/k3bdatadoc.h 2009-04-21 19:54:02.000000000 +0200
|
||
+++ libk3b/projects/datacd/k3bdatadoc.h 2009-07-23 11:41:54.000000000 +0200
|
||
@@ -18,20 +18,16 @@
|
||
|
||
#include "k3bdoc.h"
|
||
#include "k3bdataitem.h"
|
||
-
|
||
#include "k3bisooptions.h"
|
||
|
||
-#include <qfileinfo.h>
|
||
-#include <qstringlist.h>
|
||
-//Added by qt3to4:
|
||
+#include <QStringList>
|
||
|
||
-#include <kurl.h>
|
||
#include <kio/global.h>
|
||
+
|
||
#include "k3b_export.h"
|
||
|
||
class KConfig;
|
||
class QString;
|
||
-class QStringList;
|
||
class QDomDocument;
|
||
class QDomElement;
|
||
|
||
@@ -60,8 +56,8 @@
|
||
DataDoc( QObject* parent = 0 );
|
||
virtual ~DataDoc();
|
||
|
||
- virtual int type() const { return DATA; }
|
||
- virtual QString typeString() const;
|
||
+ virtual Type type() const { return DataProject; }
|
||
+ virtual QString typeString() const { return QString::fromLatin1("data"); }
|
||
|
||
virtual QString name() const;
|
||
|
||
diff -ru libk3b/projects/datacd/k3bdatajob.cpp libk3b/projects/datacd/k3bdatajob.cpp
|
||
--- libk3b/projects/datacd/k3bdatajob.cpp 2009-05-27 11:58:34.000000000 +0200
|
||
+++ libk3b/projects/datacd/k3bdatajob.cpp 2009-07-23 11:41:54.000000000 +0200
|
||
@@ -406,18 +406,24 @@
|
||
jobFinished( false );
|
||
}
|
||
}
|
||
- else if( !success ) { // on-the-fly
|
||
- //
|
||
- // In case the imager failed let's make sure the writer does not emit an unusable
|
||
- // error message.
|
||
- //
|
||
- if( m_writerJob && m_writerJob->active() )
|
||
- m_writerJob->setSourceUnreadable( true );
|
||
-
|
||
- // there is one special case which we need to handle here: the iso imager might be canceled
|
||
- // FIXME: the iso imager should not be able to cancel itself
|
||
- if( m_isoImager->hasBeenCanceled() && !this->hasBeenCanceled() )
|
||
- cancel();
|
||
+ else { // on-the-fly
|
||
+ if( success ) {
|
||
+ if ( !m_writerJob->active() )
|
||
+ finishCopy();
|
||
+ }
|
||
+ else {
|
||
+ //
|
||
+ // In case the imager failed let's make sure the writer does not emit an unusable
|
||
+ // error message.
|
||
+ //
|
||
+ if( m_writerJob && m_writerJob->active() )
|
||
+ m_writerJob->setSourceUnreadable( true );
|
||
+
|
||
+ // there is one special case which we need to handle here: the iso imager might be canceled
|
||
+ // FIXME: the iso imager should not be able to cancel itself
|
||
+ if( m_isoImager->hasBeenCanceled() && !this->hasBeenCanceled() )
|
||
+ cancel();
|
||
+ }
|
||
}
|
||
}
|
||
}
|
||
@@ -467,77 +473,85 @@
|
||
kDebug();
|
||
|
||
if( success ) {
|
||
- // allright
|
||
- // the writerJob should have emitted the "simulation/writing successful" signal
|
||
+ if ( !d->doc->onTheFly() ||
|
||
+ !m_isoImager->active() ) {
|
||
+ finishCopy();
|
||
+ }
|
||
+ }
|
||
+ else {
|
||
+ if ( !cancelAll() ) {
|
||
+ cleanup();
|
||
+ jobFinished( false );
|
||
+ }
|
||
+ }
|
||
+}
|
||
|
||
- if( d->doc->verifyData() ) {
|
||
- if( !d->verificationJob ) {
|
||
- d->verificationJob = new K3b::VerificationJob( this, this );
|
||
- connect( d->verificationJob, SIGNAL(infoMessage(const QString&, int)),
|
||
- this, SIGNAL(infoMessage(const QString&, int)) );
|
||
- connect( d->verificationJob, SIGNAL(newTask(const QString&)),
|
||
- this, SIGNAL(newSubTask(const QString&)) );
|
||
- connect( d->verificationJob, SIGNAL(newSubTask(const QString&)),
|
||
- this, SIGNAL(newSubTask(const QString&)) );
|
||
- connect( d->verificationJob, SIGNAL(percent(int)),
|
||
- this, SLOT(slotVerificationProgress(int)) );
|
||
- connect( d->verificationJob, SIGNAL(percent(int)),
|
||
- this, SIGNAL(subPercent(int)) );
|
||
- connect( d->verificationJob, SIGNAL(finished(bool)),
|
||
- this, SLOT(slotVerificationFinished(bool)) );
|
||
- connect( d->verificationJob, SIGNAL(debuggingOutput(const QString&, const QString&)),
|
||
- this, SIGNAL(debuggingOutput(const QString&, const QString&)) );
|
||
-
|
||
- }
|
||
- d->verificationJob->clear();
|
||
- d->verificationJob->setDevice( d->doc->burner() );
|
||
- d->verificationJob->setGrownSessionSize( m_isoImager->size() );
|
||
- d->verificationJob->addTrack( 0, d->checksumCache, m_isoImager->size() );
|
||
|
||
- emit burning(false);
|
||
+void K3b::DataJob::finishCopy()
|
||
+{
|
||
+ // the writerJob should have emitted the "simulation/writing successful" signal
|
||
|
||
- emit newTask( i18n("Verifying written data") );
|
||
+ if( d->doc->verifyData() ) {
|
||
+ if( !d->verificationJob ) {
|
||
+ d->verificationJob = new K3b::VerificationJob( this, this );
|
||
+ connect( d->verificationJob, SIGNAL(infoMessage(const QString&, int)),
|
||
+ this, SIGNAL(infoMessage(const QString&, int)) );
|
||
+ connect( d->verificationJob, SIGNAL(newTask(const QString&)),
|
||
+ this, SIGNAL(newSubTask(const QString&)) );
|
||
+ connect( d->verificationJob, SIGNAL(newSubTask(const QString&)),
|
||
+ this, SIGNAL(newSubTask(const QString&)) );
|
||
+ connect( d->verificationJob, SIGNAL(percent(int)),
|
||
+ this, SLOT(slotVerificationProgress(int)) );
|
||
+ connect( d->verificationJob, SIGNAL(percent(int)),
|
||
+ this, SIGNAL(subPercent(int)) );
|
||
+ connect( d->verificationJob, SIGNAL(finished(bool)),
|
||
+ this, SLOT(slotVerificationFinished(bool)) );
|
||
+ connect( d->verificationJob, SIGNAL(debuggingOutput(const QString&, const QString&)),
|
||
+ this, SIGNAL(debuggingOutput(const QString&, const QString&)) );
|
||
|
||
- d->verificationJob->start();
|
||
}
|
||
- else {
|
||
- d->copiesDone++;
|
||
+ d->verificationJob->clear();
|
||
+ d->verificationJob->setDevice( d->doc->burner() );
|
||
+ d->verificationJob->setGrownSessionSize( m_isoImager->size() );
|
||
+ d->verificationJob->addTrack( 0, d->checksumCache, m_isoImager->size() );
|
||
|
||
- if( d->copiesDone < d->copies ) {
|
||
- if( !K3b::eject( d->doc->burner() ) ) {
|
||
- blockingInformation( i18n("K3b was unable to eject the written disk. Please do so manually.") );
|
||
- }
|
||
-
|
||
- bool failed = false;
|
||
- if( d->doc->onTheFly() )
|
||
- failed = !startOnTheFlyWriting();
|
||
- else
|
||
- failed = !prepareWriterJob() || !startWriterJob();
|
||
+ emit burning(false);
|
||
|
||
- if( failed ) {
|
||
- cancel();
|
||
- }
|
||
- else if( !d->doc->onTheFly() ) {
|
||
+ emit newTask( i18n("Verifying written data") );
|
||
+
|
||
+ d->verificationJob->start();
|
||
+ }
|
||
+ else {
|
||
+ d->copiesDone++;
|
||
+
|
||
+ if( d->copiesDone < d->copies ) {
|
||
+ if( !K3b::eject( d->doc->burner() ) ) {
|
||
+ blockingInformation( i18n("K3b was unable to eject the written disk. Please do so manually.") );
|
||
+ }
|
||
+
|
||
+ bool failed = false;
|
||
+ if( d->doc->onTheFly() )
|
||
+ failed = !startOnTheFlyWriting();
|
||
+ else
|
||
+ failed = !prepareWriterJob() || !startWriterJob();
|
||
+
|
||
+ if( failed ) {
|
||
+ cancel();
|
||
+ }
|
||
+ else if( !d->doc->onTheFly() ) {
|
||
#ifdef __GNUC__
|
||
#warning Growisofs needs stdin to be closed in order to exit gracefully. Cdrecord does not. However, if closed with cdrecord we loose parts of stderr. Why?
|
||
#endif
|
||
- d->pipe->writeTo( m_writerJob->ioDevice(), d->usedWritingApp != K3b::WritingAppCdrecord );
|
||
- d->pipe->open(true);
|
||
- }
|
||
- }
|
||
- else {
|
||
- cleanup();
|
||
- if ( k3bcore->globalSettings()->ejectMedia() ) {
|
||
- K3b::Device::eject( d->doc->burner() );
|
||
- }
|
||
- jobFinished(true);
|
||
+ d->pipe->writeTo( m_writerJob->ioDevice(), d->usedWritingApp != K3b::WritingAppCdrecord );
|
||
+ d->pipe->open(true);
|
||
}
|
||
}
|
||
- }
|
||
- else {
|
||
- if ( !cancelAll() ) {
|
||
+ else {
|
||
cleanup();
|
||
- jobFinished( false );
|
||
+ if ( k3bcore->globalSettings()->ejectMedia() ) {
|
||
+ K3b::Device::eject( d->doc->burner() );
|
||
+ }
|
||
+ jobFinished(true);
|
||
}
|
||
}
|
||
}
|
||
diff -ru libk3b/projects/datacd/k3bdatajob.h libk3b/projects/datacd/k3bdatajob.h
|
||
--- libk3b/projects/datacd/k3bdatajob.h 2009-04-21 19:54:02.000000000 +0200
|
||
+++ libk3b/projects/datacd/k3bdatajob.h 2009-07-23 11:41:54.000000000 +0200
|
||
@@ -106,6 +106,7 @@
|
||
bool setupCdrdaoJob();
|
||
bool setupGrowisofsJob();
|
||
void startPipe();
|
||
+ void finishCopy();
|
||
|
||
class Private;
|
||
Private* d;
|
||
diff -ru libk3b/projects/datacd/k3bdatamultisessionparameterjob.cpp libk3b/projects/datacd/k3bdatamultisessionparameterjob.cpp
|
||
--- libk3b/projects/datacd/k3bdatamultisessionparameterjob.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ libk3b/projects/datacd/k3bdatamultisessionparameterjob.cpp 2009-07-23 11:41:54.000000000 +0200
|
||
@@ -200,15 +200,13 @@
|
||
// 2. Special case for the 4GB boundary which seems to be enforced by a linux kernel issue
|
||
//
|
||
|
||
- kDebug() << "(K3b::DataMultiSessionParameterJob) found empty or complete medium.";
|
||
-
|
||
if( d->doc->size() >= info.capacity().mode1Bytes()*9/10 ||
|
||
d->doc->writingMode() == K3b::WritingModeSao ) {
|
||
return K3b::DataDoc::NONE;
|
||
}
|
||
- else if( ( info.capacity() < 2621440 /* ~ 5 GB */ &&
|
||
- d->doc->size() + 11400 /* used size + project size + session gap */ > 2097152 /* 4 GB */ ) ||
|
||
- d->doc->writingMode() == K3b::WritingModeSao ) {
|
||
+ else if( info.isDvdMedia() &&
|
||
+ info.capacity() < 2621440 /* ~ 5 GB */ &&
|
||
+ d->doc->length() + 11400 /* used size + project size + session gap */ > 2097152 /* 4 GB */ ) {
|
||
return K3b::DataDoc::NONE;
|
||
}
|
||
else {
|
||
diff -ru libk3b/projects/datacd/k3bdatapreparationjob.cpp libk3b/projects/datacd/k3bdatapreparationjob.cpp
|
||
--- libk3b/projects/datacd/k3bdatapreparationjob.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ libk3b/projects/datacd/k3bdatapreparationjob.cpp 2009-07-23 11:41:54.000000000 +0200
|
||
@@ -26,6 +26,7 @@
|
||
#include <KStringHandler>
|
||
|
||
#include <QFile>
|
||
+#include <QFileInfo>
|
||
#include <QList>
|
||
|
||
namespace {
|
||
diff -ru libk3b/projects/datacd/k3bisoimager.cpp libk3b/projects/datacd/k3bisoimager.cpp
|
||
--- libk3b/projects/datacd/k3bisoimager.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ libk3b/projects/datacd/k3bisoimager.cpp 2009-07-23 11:41:54.000000000 +0200
|
||
@@ -131,6 +131,8 @@
|
||
{
|
||
kDebug();
|
||
|
||
+ cleanup();
|
||
+
|
||
if( m_canceled ) {
|
||
emit canceled();
|
||
jobFinished(false);
|
||
@@ -179,8 +181,6 @@
|
||
jobFinished( false );
|
||
}
|
||
}
|
||
-
|
||
- cleanup();
|
||
}
|
||
|
||
|
||
@@ -444,7 +444,7 @@
|
||
// something went wrong when starting the program
|
||
// it "should" be the executable
|
||
kDebug() << "(K3b::IsoImager) could not start mkisofs";
|
||
- emit infoMessage( i18n("Could not start %1.",QString("mkisofs")), K3b::Job::MessageError );
|
||
+ emit infoMessage( i18n("Could not start %1.", QLatin1String("mkisofs")), K3b::Job::MessageError );
|
||
jobFinished( false );
|
||
cleanup();
|
||
}
|
||
diff -ru libk3b/projects/k3bdoc.cpp libk3b/projects/k3bdoc.cpp
|
||
--- libk3b/projects/k3bdoc.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ libk3b/projects/k3bdoc.cpp 2009-07-23 11:41:56.000000000 +0200
|
||
@@ -12,17 +12,6 @@
|
||
* See the file "COPYING" for the exact licensing terms.
|
||
*/
|
||
|
||
-
|
||
-// include files for Qt
|
||
-#include <qwidget.h>
|
||
-#include <qstring.h>
|
||
-#include <qdom.h>
|
||
-
|
||
-// include files for KDE
|
||
-#include <klocale.h>
|
||
-#include <kdebug.h>
|
||
-
|
||
-// application specific includes
|
||
#include "k3bdoc.h"
|
||
#include "k3bglobals.h"
|
||
#include "k3bdevice.h"
|
||
@@ -30,6 +19,13 @@
|
||
#include "k3bcore.h"
|
||
#include "k3bdevicemanager.h"
|
||
|
||
+#include <QDomElement>
|
||
+#include <QString>
|
||
+#include <QWidget>
|
||
+
|
||
+#include <KDebug>
|
||
+#include <KLocale>
|
||
+
|
||
|
||
K3b::Doc::Doc( QObject* parent )
|
||
: QObject( parent ),
|
||
diff -ru libk3b/projects/k3bdoc.h libk3b/projects/k3bdoc.h
|
||
--- libk3b/projects/k3bdoc.h 2009-03-21 23:36:06.000000000 +0100
|
||
+++ libk3b/projects/k3bdoc.h 2009-07-23 11:41:56.000000000 +0200
|
||
@@ -19,14 +19,12 @@
|
||
#include "config-k3b.h"
|
||
#include "k3bglobals.h"
|
||
|
||
-// include files for QT
|
||
-#include <qobject.h>
|
||
-#include <qstring.h>
|
||
+#include <QObject>
|
||
+#include <QString>
|
||
|
||
-
|
||
-// include files for KDE
|
||
-#include <kurl.h>
|
||
+#include <KUrl>
|
||
#include <kio/global.h>
|
||
+
|
||
#include "k3b_export.h"
|
||
|
||
class QDomElement;
|
||
@@ -51,27 +49,27 @@
|
||
Doc( QObject* = 0 );
|
||
virtual ~Doc();
|
||
|
||
- enum DocType {
|
||
- AUDIO = 1,
|
||
- DATA,
|
||
- MIXED,
|
||
- VCD,
|
||
- MOVIX,
|
||
- VIDEODVD
|
||
+ enum Type {
|
||
+ AudioProject = 0x1,
|
||
+ DataProject = 0x2,
|
||
+ MixedProject = 0x4,
|
||
+ VcdProject = 0x8,
|
||
+ MovixProject = 0x10,
|
||
+ VideoDvdProject = 0x20
|
||
};
|
||
|
||
- virtual int type() const { return m_docType; }
|
||
+ virtual Type type() const = 0;
|
||
|
||
/**
|
||
- * \return A name for the project which might for example be used as a suggestion for a file name
|
||
- * when saving. The default implementation extracts a name from the URL.
|
||
+ * \return A string representation of the document type.
|
||
*/
|
||
- virtual QString name() const;
|
||
+ virtual QString typeString() const = 0;
|
||
|
||
/**
|
||
- * \return A string representation of the document type.
|
||
+ * \return A name for the project which might for example be used as a suggestion for a file name
|
||
+ * when saving. The default implementation extracts a name from the URL.
|
||
*/
|
||
- virtual QString typeString() const = 0;
|
||
+ virtual QString name() const;
|
||
|
||
/**
|
||
* The media types that are supported by this project type.
|
||
@@ -199,8 +197,6 @@
|
||
virtual void addUrls( const KUrl::List& urls ) = 0;
|
||
|
||
protected:
|
||
- int m_docType;
|
||
-
|
||
bool saveGeneralDocumentData( QDomElement* );
|
||
|
||
bool readGeneralDocumentData( const QDomElement& );
|
||
diff -ru libk3b/projects/mixedcd/k3bmixeddoc.cpp libk3b/projects/mixedcd/k3bmixeddoc.cpp
|
||
--- libk3b/projects/mixedcd/k3bmixeddoc.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ libk3b/projects/mixedcd/k3bmixeddoc.cpp 2009-07-23 11:41:55.000000000 +0200
|
||
@@ -14,19 +14,18 @@
|
||
|
||
#include "k3bmixeddoc.h"
|
||
#include "k3bmixedjob.h"
|
||
-
|
||
#include "k3bdatadoc.h"
|
||
#include "k3baudiodoc.h"
|
||
#include "k3bglobals.h"
|
||
#include "k3bmsf.h"
|
||
|
||
-#include <qfileinfo.h>
|
||
-#include <qdom.h>
|
||
+#include <QFileInfo>
|
||
+#include <QDomElement>
|
||
|
||
-#include <klocale.h>
|
||
-#include <kconfig.h>
|
||
-#include <kapplication.h>
|
||
-#include <kmessagebox.h>
|
||
+#include <KLocale>
|
||
+#include <KConfig>
|
||
+#include <KApplication>
|
||
+#include <KMessageBox>
|
||
|
||
|
||
|
||
diff -ru libk3b/projects/mixedcd/k3bmixeddoc.h libk3b/projects/mixedcd/k3bmixeddoc.h
|
||
--- libk3b/projects/mixedcd/k3bmixeddoc.h 2009-03-21 23:36:06.000000000 +0100
|
||
+++ libk3b/projects/mixedcd/k3bmixeddoc.h 2009-07-23 11:41:55.000000000 +0200
|
||
@@ -32,6 +32,9 @@
|
||
public:
|
||
MixedDoc( QObject* parent = 0 );
|
||
~MixedDoc();
|
||
+
|
||
+ virtual Type type() const { return MixedProject; }
|
||
+ virtual QString typeString() const { return QString::fromLatin1("mixed"); }
|
||
|
||
QString name() const;
|
||
|
||
@@ -58,7 +61,6 @@
|
||
DATA_SECOND_SESSION };
|
||
|
||
int mixedType() const { return m_mixedType; }
|
||
- int type() const { return MIXED; }
|
||
|
||
void setURL( const KUrl& url );
|
||
|
||
@@ -79,7 +81,6 @@
|
||
protected:
|
||
bool loadDocumentData( QDomElement* );
|
||
bool saveDocumentData( QDomElement* );
|
||
- QString typeString() const { return "mixed"; }
|
||
|
||
private:
|
||
DataDoc* m_dataDoc;
|
||
diff -ru libk3b/projects/movixcd/k3bmovixdoc.cpp libk3b/projects/movixcd/k3bmovixdoc.cpp
|
||
--- libk3b/projects/movixcd/k3bmovixdoc.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ libk3b/projects/movixcd/k3bmovixdoc.cpp 2009-07-23 11:41:55.000000000 +0200
|
||
@@ -17,21 +17,19 @@
|
||
#include "k3bmovixdoc.h"
|
||
#include "k3bmovixjob.h"
|
||
#include "k3bmovixfileitem.h"
|
||
-
|
||
#include "k3bdiritem.h"
|
||
#include "k3bfileitem.h"
|
||
#include "k3bglobals.h"
|
||
|
||
-#include <klocale.h>
|
||
-#include <kdebug.h>
|
||
-#include <kurl.h>
|
||
-#include <kinputdialog.h>
|
||
-#include <kmessagebox.h>
|
||
-#include <kapplication.h>
|
||
-
|
||
-#include <qdom.h>
|
||
-#include <qfileinfo.h>
|
||
-#include <kglobal.h>
|
||
+#include <QDomElement>
|
||
+#include <QFileInfo>
|
||
+
|
||
+#include <KApplication>
|
||
+#include <KDebug>
|
||
+#include <KGlobal>
|
||
+#include <KInputDialog>
|
||
+#include <KLocale>
|
||
+#include <KMessageBox>
|
||
|
||
|
||
K3b::MovixDoc::MovixDoc( QObject* parent )
|
||
@@ -51,12 +49,6 @@
|
||
}
|
||
|
||
|
||
-QString K3b::MovixDoc::typeString() const
|
||
-{
|
||
- return QString::fromLatin1("movix");
|
||
-}
|
||
-
|
||
-
|
||
bool K3b::MovixDoc::newDocument()
|
||
{
|
||
m_loopPlaylist = 1;
|
||
diff -ru libk3b/projects/movixcd/k3bmovixdoc.h libk3b/projects/movixcd/k3bmovixdoc.h
|
||
--- libk3b/projects/movixcd/k3bmovixdoc.h 2009-04-21 19:54:02.000000000 +0200
|
||
+++ libk3b/projects/movixcd/k3bmovixdoc.h 2009-07-23 11:41:55.000000000 +0200
|
||
@@ -17,10 +17,10 @@
|
||
#ifndef _K3B_MOVIX_DOC_H_
|
||
#define _K3B_MOVIX_DOC_H_
|
||
|
||
-
|
||
#include "k3bdatadoc.h"
|
||
|
||
-#include <qlist.h>
|
||
+#include <QList>
|
||
+
|
||
#include "k3b_export.h"
|
||
|
||
class KUrl;
|
||
@@ -37,8 +37,8 @@
|
||
MovixDoc( QObject* parent = 0 );
|
||
virtual ~MovixDoc();
|
||
|
||
- virtual int type() const { return MOVIX; }
|
||
- virtual QString typeString() const;
|
||
+ virtual Type type() const { return MovixProject; }
|
||
+ virtual QString typeString() const { return QString::fromLatin1("movix"); }
|
||
|
||
bool newDocument();
|
||
|
||
diff -ru libk3b/projects/videocd/k3bvcddoc.cpp libk3b/projects/videocd/k3bvcddoc.cpp
|
||
--- libk3b/projects/videocd/k3bvcddoc.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ libk3b/projects/videocd/k3bvcddoc.cpp 2009-07-23 11:41:56.000000000 +0200
|
||
@@ -13,33 +13,28 @@
|
||
* See the file "COPYING" for the exact licensing terms.
|
||
*/
|
||
|
||
-// QT-includes
|
||
-#include <qstring.h>
|
||
-#include <qstringlist.h>
|
||
-#include <qfile.h>
|
||
-#include <qdatastream.h>
|
||
-#include <qdom.h>
|
||
-#include <qdatetime.h>
|
||
-#include <qtimer.h>
|
||
-
|
||
-// KDE-includes
|
||
-#include <kurl.h>
|
||
-#include <kapplication.h>
|
||
-#include <kmessagebox.h>
|
||
-#include <kconfig.h>
|
||
-#include <klocale.h>
|
||
-#include <kstandarddirs.h>
|
||
-#include <kio/global.h>
|
||
-#include <kdebug.h>
|
||
-#include <kstdguiitem.h>
|
||
-
|
||
-// K3b-includes
|
||
#include "k3bvcddoc.h"
|
||
#include "k3bvcdtrack.h"
|
||
#include "k3bvcdjob.h"
|
||
#include "k3bglobals.h"
|
||
#include "k3bmsf.h"
|
||
|
||
+#include <QDataStream>
|
||
+#include <QDomElement>
|
||
+#include <QFile>
|
||
+#include <QImage>
|
||
+#include <QTimer>
|
||
+
|
||
+#include <KApplication>
|
||
+#include <KConfig>
|
||
+#include <KDebug>
|
||
+#include <kio/global.h>
|
||
+#include <KLocale>
|
||
+#include <KMessageBox>
|
||
+#include <KStandardDirs>
|
||
+#include <kstdguiitem.h>
|
||
+
|
||
+
|
||
#if 0
|
||
bool desperate_mode = false;
|
||
bool preserve_header = false;
|
||
@@ -54,7 +49,6 @@
|
||
m_tracks = 0L;
|
||
m_vcdOptions = new K3b::VcdOptions();
|
||
|
||
- m_docType = VCD;
|
||
m_vcdType = NONE;
|
||
|
||
m_urlAddingTimer = new QTimer( this );
|
||
@@ -407,12 +401,6 @@
|
||
}
|
||
|
||
|
||
-QString K3b::VcdDoc::typeString() const
|
||
-{
|
||
- return "vcd";
|
||
-}
|
||
-
|
||
-
|
||
K3b::BurnJob* K3b::VcdDoc::newBurnJob( K3b::JobHandler* hdl, QObject* parent )
|
||
{
|
||
return new K3b::VcdJob( this, hdl, parent );
|
||
diff -ru libk3b/projects/videocd/k3bvcddoc.h libk3b/projects/videocd/k3bvcddoc.h
|
||
--- libk3b/projects/videocd/k3bvcddoc.h 2009-03-21 23:36:06.000000000 +0100
|
||
+++ libk3b/projects/videocd/k3bvcddoc.h 2009-07-23 11:41:56.000000000 +0200
|
||
@@ -16,21 +16,13 @@
|
||
#ifndef K3BVCDDOC_H
|
||
#define K3BVCDDOC_H
|
||
|
||
-// Qt Includes
|
||
-#include <qfile.h>
|
||
-#include <qstring.h>
|
||
-#include <qstringlist.h>
|
||
-#include <qdatetime.h>
|
||
-#include <qimage.h>
|
||
-#include <qqueue.h>
|
||
-
|
||
-// Kde Includes
|
||
-#include <kurl.h>
|
||
-
|
||
-// K3b Includes
|
||
+#include "k3bdoc.h"
|
||
#include "k3bvcdoptions.h"
|
||
#include "mpeginfo/k3bmpeginfo.h"
|
||
-#include "k3bdoc.h"
|
||
+
|
||
+#include <QStringList>
|
||
+#include <QQueue>
|
||
+
|
||
#include "k3b_export.h"
|
||
|
||
class QTimer;
|
||
@@ -47,7 +39,8 @@
|
||
VcdDoc( QObject* );
|
||
~VcdDoc();
|
||
|
||
- int type() const { return VCD; }
|
||
+ virtual Type type() const { return VcdProject; }
|
||
+ virtual QString typeString() const { return QString::fromLatin1("vcd"); }
|
||
|
||
Device::MediaTypes supportedMediaTypes() const;
|
||
|
||
@@ -156,8 +149,6 @@
|
||
/** reimplemented from Doc */
|
||
bool saveDocumentData( QDomElement* );
|
||
|
||
- QString typeString() const;
|
||
-
|
||
private:
|
||
VcdTrack* createTrack( const KUrl& url );
|
||
void informAboutNotFoundFiles();
|
||
diff -ru libk3b/projects/videodvd/k3bvideodvddoc.cpp libk3b/projects/videodvd/k3bvideodvddoc.cpp
|
||
--- libk3b/projects/videodvd/k3bvideodvddoc.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ libk3b/projects/videodvd/k3bvideodvddoc.cpp 2009-07-23 11:41:55.000000000 +0200
|
||
@@ -15,12 +15,10 @@
|
||
|
||
#include "k3bvideodvddoc.h"
|
||
#include "k3bvideodvdjob.h"
|
||
-
|
||
#include "k3bdiritem.h"
|
||
-
|
||
#include "k3bisooptions.h"
|
||
|
||
-#include <kconfig.h>
|
||
+#include <KConfig>
|
||
|
||
|
||
K3b::VideoDvdDoc::VideoDvdDoc( QObject* parent )
|
||
diff -ru libk3b/projects/videodvd/k3bvideodvddoc.h libk3b/projects/videodvd/k3bvideodvddoc.h
|
||
--- libk3b/projects/videodvd/k3bvideodvddoc.h 2009-04-21 19:54:02.000000000 +0200
|
||
+++ libk3b/projects/videodvd/k3bvideodvddoc.h 2009-07-23 11:41:55.000000000 +0200
|
||
@@ -25,7 +25,8 @@
|
||
VideoDvdDoc( QObject* parent = 0 );
|
||
virtual ~VideoDvdDoc();
|
||
|
||
- virtual int type() const { return VIDEODVD; }
|
||
+ virtual Type type() const { return VideoDvdProject; }
|
||
+ virtual QString typeString() const { return QString::fromLatin1("video_dvd"); }
|
||
|
||
Device::MediaTypes supportedMediaTypes() const;
|
||
|
||
@@ -37,9 +38,6 @@
|
||
|
||
// TODO: implement load- and saveDocumentData since we do not need all those options
|
||
|
||
- protected:
|
||
- virtual QString typeString() const { return "video_dvd"; }
|
||
-
|
||
private:
|
||
DirItem* m_videoTsDir;
|
||
};
|
||
diff -ru libk3b/tools/k3biso9660.cpp libk3b/tools/k3biso9660.cpp
|
||
--- libk3b/tools/k3biso9660.cpp 2009-04-22 12:40:45.000000000 +0200
|
||
+++ libk3b/tools/k3biso9660.cpp 2009-07-23 11:41:53.000000000 +0200
|
||
@@ -618,6 +618,8 @@
|
||
else
|
||
d->backend = new K3b::Iso9660DeviceBackend( d->cdDevice );
|
||
}
|
||
+ else
|
||
+ return false;
|
||
}
|
||
|
||
d->isOpen = d->backend->open();
|
||
diff -ru libk3b/tools/k3bmediacache.cpp libk3b/tools/k3bmediacache.cpp
|
||
--- libk3b/tools/k3bmediacache.cpp 2009-05-27 11:58:34.000000000 +0200
|
||
+++ libk3b/tools/k3bmediacache.cpp 2009-07-23 11:41:53.000000000 +0200
|
||
@@ -75,24 +75,31 @@
|
||
emit checkingMedium( m_deviceEntry->medium.device(), QString() );
|
||
|
||
//
|
||
+ // we block for writing before the update
|
||
+ // This is important to make sure we do not overwrite a reset operation
|
||
+ //
|
||
+ m_deviceEntry->writeMutex.lock();
|
||
+
|
||
+ //
|
||
// The medium has changed. We need to update the information.
|
||
//
|
||
K3b::Medium m( m_deviceEntry->medium.device() );
|
||
m.update();
|
||
|
||
// block the info since it is not valid anymore
|
||
- m_deviceEntry->mutex.lock();
|
||
+ m_deviceEntry->readMutex.lock();
|
||
|
||
m_deviceEntry->medium = m;
|
||
|
||
+ // the information is valid. let the info go.
|
||
+ m_deviceEntry->readMutex.unlock();
|
||
+ m_deviceEntry->writeMutex.unlock();
|
||
+
|
||
//
|
||
// inform the media cache about the media change
|
||
//
|
||
if( m_deviceEntry->blockedId == 0 )
|
||
emit mediumChanged( m_deviceEntry->medium.device() );
|
||
-
|
||
- // the information is valid. let the info go.
|
||
- m_deviceEntry->mutex.unlock();
|
||
}
|
||
|
||
if( m_deviceEntry->blockedId == 0 )
|
||
@@ -173,19 +180,20 @@
|
||
|
||
int K3b::MediaCache::blockDevice( K3b::Device::Device* dev )
|
||
{
|
||
+ kDebug() << dev->blockDeviceName();
|
||
DeviceEntry* e = findDeviceEntry( dev );
|
||
if( e ) {
|
||
if( e->blockedId )
|
||
return -1;
|
||
else {
|
||
// block the information
|
||
- e->mutex.lock();
|
||
+ e->readMutex.lock();
|
||
|
||
// create (hopefully) unique id
|
||
e->blockedId = KRandom::random();
|
||
|
||
// let the info go
|
||
- e->mutex.unlock();
|
||
+ e->readMutex.unlock();
|
||
|
||
// wait for the thread to stop
|
||
e->thread->wait();
|
||
@@ -200,12 +208,12 @@
|
||
|
||
bool K3b::MediaCache::unblockDevice( K3b::Device::Device* dev, int id )
|
||
{
|
||
+ kDebug() << dev->blockDeviceName();
|
||
DeviceEntry* e = findDeviceEntry( dev );
|
||
if( e && e->blockedId && e->blockedId == id ) {
|
||
e->blockedId = 0;
|
||
|
||
e->medium = K3b::Medium( dev );
|
||
- emit mediumChanged( dev );
|
||
|
||
// restart the poll thread
|
||
e->thread->start();
|
||
@@ -229,9 +237,9 @@
|
||
K3b::Medium K3b::MediaCache::medium( K3b::Device::Device* dev )
|
||
{
|
||
if( DeviceEntry* e = findDeviceEntry( dev ) ) {
|
||
- e->mutex.lock();
|
||
+ e->readMutex.lock();
|
||
K3b::Medium m = e->medium;
|
||
- e->mutex.unlock();
|
||
+ e->readMutex.unlock();
|
||
return m;
|
||
}
|
||
else
|
||
@@ -242,9 +250,9 @@
|
||
K3b::Device::DiskInfo K3b::MediaCache::diskInfo( K3b::Device::Device* dev )
|
||
{
|
||
if( DeviceEntry* e = findDeviceEntry( dev ) ) {
|
||
- e->mutex.lock();
|
||
+ e->readMutex.lock();
|
||
K3b::Device::DiskInfo di = e->medium.diskInfo();
|
||
- e->mutex.unlock();
|
||
+ e->readMutex.unlock();
|
||
return di;
|
||
}
|
||
else
|
||
@@ -255,9 +263,9 @@
|
||
K3b::Device::Toc K3b::MediaCache::toc( K3b::Device::Device* dev )
|
||
{
|
||
if( DeviceEntry* e = findDeviceEntry( dev ) ) {
|
||
- e->mutex.lock();
|
||
+ e->readMutex.lock();
|
||
K3b::Device::Toc toc = e->medium.toc();
|
||
- e->mutex.unlock();
|
||
+ e->readMutex.unlock();
|
||
return toc;
|
||
}
|
||
else
|
||
@@ -268,9 +276,9 @@
|
||
K3b::Device::CdText K3b::MediaCache::cdText( K3b::Device::Device* dev )
|
||
{
|
||
if( DeviceEntry* e = findDeviceEntry( dev ) ) {
|
||
- e->mutex.lock();
|
||
+ e->readMutex.lock();
|
||
K3b::Device::CdText cdt = e->medium.cdText();
|
||
- e->mutex.unlock();
|
||
+ e->readMutex.unlock();
|
||
return cdt;
|
||
}
|
||
else
|
||
@@ -281,9 +289,9 @@
|
||
QList<int> K3b::MediaCache::writingSpeeds( K3b::Device::Device* dev )
|
||
{
|
||
if( DeviceEntry* e = findDeviceEntry( dev ) ) {
|
||
- e->mutex.lock();
|
||
+ e->readMutex.lock();
|
||
QList<int> ws = e->medium.writingSpeeds();
|
||
- e->mutex.unlock();
|
||
+ e->readMutex.unlock();
|
||
return ws;
|
||
}
|
||
else
|
||
@@ -376,11 +384,13 @@
|
||
void K3b::MediaCache::resetDevice( K3b::Device::Device* dev )
|
||
{
|
||
if( DeviceEntry* e = findDeviceEntry( dev ) ) {
|
||
- e->mutex.lock();
|
||
kDebug() << "Resetting medium in" << dev->blockDeviceName();
|
||
+ e->writeMutex.lock();
|
||
+ e->readMutex.lock();
|
||
e->medium.reset();
|
||
- e->mutex.unlock();
|
||
- emit mediumChanged( dev );
|
||
+ e->readMutex.unlock();
|
||
+ e->writeMutex.unlock();
|
||
+ // no need to emit mediumChanged here. The poll thread will act on it soon
|
||
}
|
||
}
|
||
|
||
diff -ru libk3b/tools/k3bmediacache_p.h libk3b/tools/k3bmediacache_p.h
|
||
--- libk3b/tools/k3bmediacache_p.h 2009-02-23 00:22:53.000000000 +0100
|
||
+++ libk3b/tools/k3bmediacache_p.h 2009-07-23 11:41:53.000000000 +0200
|
||
@@ -28,7 +28,8 @@
|
||
|
||
int blockedId;
|
||
|
||
- QMutex mutex;
|
||
+ QMutex readMutex;
|
||
+ QMutex writeMutex;
|
||
|
||
MediaCache::PollThread* thread;
|
||
|
||
diff -ru libk3b/tools/k3bmedium.cpp libk3b/tools/k3bmedium.cpp
|
||
--- libk3b/tools/k3bmedium.cpp 2009-04-30 01:12:43.000000000 +0200
|
||
+++ libk3b/tools/k3bmedium.cpp 2009-07-23 11:41:53.000000000 +0200
|
||
@@ -155,11 +155,14 @@
|
||
d->diskInfo = d->device->diskInfo();
|
||
|
||
if( d->diskInfo.diskState() != K3b::Device::STATE_NO_MEDIA ) {
|
||
- kDebug() << "(K3b::Medium) found medium: (" << d->device->blockDeviceName() << ')' << endl
|
||
+ kDebug() << "found medium: (" << d->device->blockDeviceName() << ')' << endl
|
||
<< "=====================================================";
|
||
d->diskInfo.debug();
|
||
kDebug() << "=====================================================";
|
||
}
|
||
+ else {
|
||
+ kDebug() << "no medium found";
|
||
+ }
|
||
|
||
if( diskInfo().diskState() == K3b::Device::STATE_COMPLETE ||
|
||
diskInfo().diskState() == K3b::Device::STATE_INCOMPLETE ) {
|
||
diff -ru plugins/decoder/ffmpeg/CMakeLists.txt plugins/decoder/ffmpeg/CMakeLists.txt
|
||
--- plugins/decoder/ffmpeg/CMakeLists.txt 2008-09-27 08:33:36.000000000 +0200
|
||
+++ plugins/decoder/ffmpeg/CMakeLists.txt 2009-07-23 11:41:58.000000000 +0200
|
||
@@ -3,14 +3,14 @@
|
||
|
||
########### next target ###############
|
||
|
||
-find_file(newffmpegavcodecpath avcodec.h /usr/include/libavcodec)
|
||
-
|
||
-if(newffmpegavcodecpath)
|
||
+if(FFMPEG_INCLUDE_DIR_OLD_STYLE)
|
||
+ message(STATUS "didn't find new ffmpegcodecpath")
|
||
+ include_directories (${FFMPEG_INCLUDE_DIR_OLD_STYLE})
|
||
+else(FFMPEG_INCLUDE_DIR_OLD_STYLE)
|
||
message(STATUS "found new ffmpegcodecpath")
|
||
add_definitions(-DNEWFFMPEGAVCODECPATH)
|
||
-else(newffmpegavcodecpath)
|
||
- message(STATUS "didn't find new ffmpegcodecpath")
|
||
-endif(newffmpegavcodecpath)
|
||
+ include_directories (${FFMPEG_INCLUDE_DIR})
|
||
+endif(FFMPEG_INCLUDE_DIR_OLD_STYLE)
|
||
|
||
set(k3bffmpegdecoder_PART_SRCS k3bffmpegdecoder.cpp k3bffmpegwrapper.cpp )
|
||
|
||
diff -ru plugins/decoder/ffmpeg/k3bffmpegdecoder.desktop plugins/decoder/ffmpeg/k3bffmpegdecoder.desktop
|
||
--- plugins/decoder/ffmpeg/k3bffmpegdecoder.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ plugins/decoder/ffmpeg/k3bffmpegdecoder.desktop 2009-07-23 11:41:58.000000000 +0200
|
||
@@ -14,6 +14,7 @@
|
||
Name[gl]=Descodificador FFMpeg para K3b
|
||
Name[he]=מפענח FFMpeg של K3b
|
||
Name[hne]=के3बी एफएफएमपीईजी डिकोडर
|
||
+Name[it]=Decodificatore FFMpeg di K3b
|
||
Name[ja]=K3b FFMpeg デコーダ
|
||
Name[km]=កម្មវីធីឌិកូដ FFMpeg របស់ K3b
|
||
Name[ko]=K3b FFMpeg 디코더
|
||
@@ -34,8 +35,8 @@
|
||
Name[uk]=K3b декодувальник FFMpeg
|
||
Name[x-test]=xxK3b FFMpeg Decoderxx
|
||
Name[zh_CN]=K3b FFMpeg 解码器
|
||
+Name[zh_TW]=K3b FFMpeg 解碼器
|
||
Comment=Decoding module to decode wma files
|
||
-Comment[bg]=Декодиращ модул за wma файлове
|
||
Comment[cs]=Modul pro dekódování souborů wma
|
||
Comment[csb]=Mòdul dekòdërëjący lopczi wma
|
||
Comment[da]=Dekodermodul til dekodning af WMA-filer
|
||
@@ -50,6 +51,7 @@
|
||
Comment[gl]=Modulo de descodificación para descodificar ficheiros wma
|
||
Comment[he]=מודול המפענח קבצי wma
|
||
Comment[hne]=डबल्यूएमए फाइल ल डिकोड करे बर डिकोडिंग माड्यूल
|
||
+Comment[it]=Decodifica modulare per i file WMA
|
||
Comment[ja]=WMA ファイルをデコードするモジュール
|
||
Comment[km]=ម៉ូឌុលឌិកូដ ដែលត្រូវឌិកូដឯកសារ wma
|
||
Comment[ko]=WMA 파일 디코딩 모듈
|
||
@@ -69,6 +71,7 @@
|
||
Comment[uk]=Модуль для декодування файлів wma
|
||
Comment[x-test]=xxDecoding module to decode wma filesxx
|
||
Comment[zh_CN]=用于解码 WMA 文件的解码模块
|
||
+Comment[zh_TW]=解碼 wma 檔案格式的模組
|
||
Type=Service
|
||
ServiceTypes=K3b/Plugin
|
||
Icon=preferences-plugin
|
||
diff -ru plugins/decoder/flac/k3bflacdecoder.desktop plugins/decoder/flac/k3bflacdecoder.desktop
|
||
--- plugins/decoder/flac/k3bflacdecoder.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ plugins/decoder/flac/k3bflacdecoder.desktop 2009-07-23 11:41:59.000000000 +0200
|
||
@@ -14,6 +14,7 @@
|
||
Name[gl]=Descodificador FLAC para K3b
|
||
Name[he]=מפענח FLAC של K3b
|
||
Name[hne]=के3बी फ्लेक डिकोडर
|
||
+Name[it]=Decodificatore FLAC di K3b
|
||
Name[ja]=K3b FLAC デコーダ
|
||
Name[km]=កម្មវិធីឌិកូដ FLAC របស់ K3b
|
||
Name[ko]=K3b FLAC 디코더
|
||
@@ -34,8 +35,8 @@
|
||
Name[uk]=K3b декодувальник FLAC
|
||
Name[x-test]=xxK3b FLAC Decoderxx
|
||
Name[zh_CN]=K3b FLAC 解码器
|
||
+Name[zh_TW]=K3b FLAC 解碼器
|
||
Comment=Decoding module to decode FLAC files
|
||
-Comment[bg]=Декодиращ модул за FLAC файлове
|
||
Comment[cs]=Modul pro dekódování souborů FLAC
|
||
Comment[csb]=Mòdul dekòdërëjący lopczi FLAC
|
||
Comment[da]=Dekodermodul til dekodning af FLAC-filer
|
||
@@ -50,6 +51,7 @@
|
||
Comment[gl]=Módulo de descodificación de ficheiros FLAC
|
||
Comment[he]=מודול המפענח קבצי FLAC
|
||
Comment[hne]=फ्लेक फाइल ल डिकोड करे बर डिकोडिंग माड्यूल
|
||
+Comment[it]=Decodifica modulare per i file FLAC
|
||
Comment[ja]=FLAC ファイルをデコードするモジュール
|
||
Comment[km]=ម៉ូឌុលឌិកូដ ដែលត្រូវឌិកូដឯកសារ FLAC
|
||
Comment[ko]=FLAC 파일 디코딩 모듈
|
||
@@ -69,6 +71,7 @@
|
||
Comment[uk]=Модуль декодування для файлів FLAC
|
||
Comment[x-test]=xxDecoding module to decode FLAC filesxx
|
||
Comment[zh_CN]=用于解码 FLAC 文件的解码模块
|
||
+Comment[zh_TW]=解碼 FLAC 檔案格式的模組
|
||
Type=Service
|
||
ServiceTypes=K3b/Plugin
|
||
Icon=preferences-plugin
|
||
diff -ru plugins/decoder/libsndfile/k3blibsndfiledecoder.desktop plugins/decoder/libsndfile/k3blibsndfiledecoder.desktop
|
||
--- plugins/decoder/libsndfile/k3blibsndfiledecoder.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ plugins/decoder/libsndfile/k3blibsndfiledecoder.desktop 2009-07-23 11:41:59.000000000 +0200
|
||
@@ -14,6 +14,7 @@
|
||
Name[gl]=Descodificador Libsndfile para K3b
|
||
Name[he]=מפענח libsndfile של K3b
|
||
Name[hne]=के3बी लिबसेंडफाइल डिकोडर
|
||
+Name[it]=Decodificatore Libsndfile di K3b
|
||
Name[ja]=K3b Libsndfile デコーダ
|
||
Name[km]=កម្មវិធីឌិកូដ Libsndfile របស់ K3b
|
||
Name[ko]=K3b Libsndfile 디코더
|
||
@@ -34,8 +35,8 @@
|
||
Name[uk]=Декодер Libsndfile для K3b
|
||
Name[x-test]=xxK3b Libsndfile Decoderxx
|
||
Name[zh_CN]=K3b Libsndfile 解码器
|
||
+Name[zh_TW]=K3b Libsndfile 解碼器
|
||
Comment=Decoding module to decode audio files supported by libsndfile
|
||
-Comment[bg]=Декодиращ модул за декодиране на аудио файлове с поддръжка на libsndfile
|
||
Comment[cs]=Modul pro dekódování audio souborů posporovaných libsndfile
|
||
Comment[csb]=Mòdul dekòdërëjący lopczi aùdio wpiséróné przez libsndfile
|
||
Comment[da]=Dekodermodul til dekodning af filer som undersøttes af libsndfile
|
||
@@ -49,6 +50,7 @@
|
||
Comment[ga]=Modúl díchódaithe a dhíchódaíonn comhaid fhuaime a dtacaíonn libsndfile leo
|
||
Comment[gl]=Módulo de descodificación de ficheiros de son soportados por libsndfile
|
||
Comment[he]=מודול המפענח קבצי שמע הנתמכים על ידי libsndfile
|
||
+Comment[it]=Decodifica modulare per i file audio supportati da libsndfile
|
||
Comment[ja]=libsndfile がサポートするオーディオファイルをデコードするモジュール
|
||
Comment[km]=ម៉ូឌុលឌិកូដ ដែលត្រូវឌិកូដឯកសារអូឌីយ៉ូដែលបានគាំទ្រដោយ libsndfile
|
||
Comment[ko]=libsndfile이 지원하는 오디오 파일 디코딩 모듈
|
||
@@ -68,6 +70,7 @@
|
||
Comment[uk]=Модуль декодування звукових файлів, що підтримується libsndfile
|
||
Comment[x-test]=xxDecoding module to decode audio files supported by libsndfilexx
|
||
Comment[zh_CN]=用于解码被 libsndfile 支持的文件的解码模块
|
||
+Comment[zh_TW]=解碼 libsndfile 支援的音效檔的模組
|
||
Type=Service
|
||
ServiceTypes=K3b/Plugin
|
||
Icon=preferences-plugin
|
||
diff -ru plugins/decoder/mp3/k3bmaddecoder.desktop plugins/decoder/mp3/k3bmaddecoder.desktop
|
||
--- plugins/decoder/mp3/k3bmaddecoder.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ plugins/decoder/mp3/k3bmaddecoder.desktop 2009-07-23 11:41:58.000000000 +0200
|
||
@@ -14,6 +14,7 @@
|
||
Name[gl]=Descodificador MAD para K3b
|
||
Name[he]=מפענח MAD של K3b
|
||
Name[hne]=के3बी एमएडी डिकोडर
|
||
+Name[it]=Decodificatore MAD di K3b
|
||
Name[ja]=K3b MAD デコーダ
|
||
Name[km]=កម្មវិធីឌិកូដ MAD របស់ K3b
|
||
Name[ko]=K3b MAD 디코더
|
||
@@ -34,8 +35,8 @@
|
||
Name[uk]=Декодер MAD для K3b
|
||
Name[x-test]=xxK3b MAD Decoderxx
|
||
Name[zh_CN]=K3b MAD 解码器
|
||
+Name[zh_TW]=K3b MAD 解碼器
|
||
Comment=Decoding module to decode MPEG 1 Layer III files
|
||
-Comment[bg]=Декодиращ модул за MPEG 1 Layer III файлове
|
||
Comment[cs]=Modul pro dekódování souborů MPEG 1 Layer III
|
||
Comment[csb]=Mòdul dekòdërëjący lopczi MPEG Layer III
|
||
Comment[da]=Dekodermodul til dekodning af MPEG 1 Layer III-filer
|
||
@@ -50,6 +51,7 @@
|
||
Comment[gl]=Módulo de descodificación de ficheiros MPEG 1 capa III
|
||
Comment[he]=מודול המפענח קבצי MPEG 1 שכבה lll
|
||
Comment[hne]=एमपीईजी १ लेयर फाइल ल डिकोड करे बर डिकोडिंग माड्यूल
|
||
+Comment[it]=Decodifica modulare di file MPEG 1 Layer III
|
||
Comment[ja]=MPEG 1 Layer III ファイルをデコードするモジュール
|
||
Comment[km]=ម៉ូឌុលឌិកូដ ដែលត្រូវឌិកូដឯកសារ MPEG 1 ស្រទាប់ III
|
||
Comment[ko]=MPEG 1 레이어 3(MP3) 파일 디코딩 모듈
|
||
@@ -69,6 +71,7 @@
|
||
Comment[uk]=Модуль декодування файлів MPEG 1 Layer III
|
||
Comment[x-test]=xxDecoding module to decode MPEG 1 Layer III filesxx
|
||
Comment[zh_CN]=用于解码 MPEG 1 Layer III(mp3) 文件的解码模块
|
||
+Comment[zh_TW]=解碼 MP3 檔案格式的模組
|
||
Type=Service
|
||
ServiceTypes=K3b/Plugin
|
||
Icon=preferences-plugin
|
||
diff -ru plugins/decoder/musepack/k3bmpcdecoder.desktop plugins/decoder/musepack/k3bmpcdecoder.desktop
|
||
--- plugins/decoder/musepack/k3bmpcdecoder.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ plugins/decoder/musepack/k3bmpcdecoder.desktop 2009-07-23 11:41:59.000000000 +0200
|
||
@@ -14,6 +14,7 @@
|
||
Name[gl]=Descodificador Musepack para K3b
|
||
Name[he]=מפענח Musepack של K3b
|
||
Name[hne]=के3बी म्यूजपैक डिकोडर
|
||
+Name[it]=Decodificatore Musepack di K3b
|
||
Name[ja]=K3b Musepack デコーダ
|
||
Name[km]=កម្មវិធីឌិកូដ Musepack របស់ K3b
|
||
Name[ko]=K3b Musepack 디코더
|
||
@@ -34,8 +35,8 @@
|
||
Name[uk]=Декодер Musepack для K3b
|
||
Name[x-test]=xxK3b Musepack Decoderxx
|
||
Name[zh_CN]=K3b Musepack 解码器
|
||
+Name[zh_TW]=K3b Musepack 解碼器
|
||
Comment=Decoding module to decode Musepack audio files
|
||
-Comment[bg]=Декодиращ модул за аудио файлове Musepack
|
||
Comment[cs]=Modul pro dekódování souborů Musepack
|
||
Comment[csb]=Mòdul dekòdërëjący lopczi Musepack
|
||
Comment[da]=Dekodermodul til dekodning af Musepack-lydfiler
|
||
@@ -50,6 +51,7 @@
|
||
Comment[gl]=Módulo de descodificación de ficheiros de son Musepack
|
||
Comment[he]=מודול המפענח קבצי שמע Musepack
|
||
Comment[hne]=म्यूजपैक फाइल ल डिकोड करे बर डिकोडिंग माड्यूल
|
||
+Comment[it]=Decodifica modulare per i file audio Musepack
|
||
Comment[ja]=Musepack オーディオファイルをデコードするモジュール
|
||
Comment[km]=ម៉ូឌុលឌិកូដ ដែលត្រូវឌិកូដឯកសារអូឌីយ៉ូ Musepack
|
||
Comment[ko]=Musepack 오디오 파일 디코딩 모듈
|
||
@@ -69,6 +71,7 @@
|
||
Comment[uk]=Модуль декодування звукових файлів Musepack
|
||
Comment[x-test]=xxDecoding module to decode Musepack audio filesxx
|
||
Comment[zh_CN]=用于解码 Musepack 音频文件的解码模块
|
||
+Comment[zh_TW]=解碼 Musepack 音效檔格式的模組
|
||
Type=Service
|
||
ServiceTypes=K3b/Plugin
|
||
Icon=preferences-plugin
|
||
diff -ru plugins/decoder/ogg/k3boggvorbisdecoder.desktop plugins/decoder/ogg/k3boggvorbisdecoder.desktop
|
||
--- plugins/decoder/ogg/k3boggvorbisdecoder.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ plugins/decoder/ogg/k3boggvorbisdecoder.desktop 2009-07-23 11:41:59.000000000 +0200
|
||
@@ -14,6 +14,7 @@
|
||
Name[gl]=Descodificador de Ogg Vorbis para K3b
|
||
Name[he]=מפענח Ogg Vorbis של K3b
|
||
Name[hne]=के3बी ओग वार्बिस डिकोडर
|
||
+Name[it]=Decodificatore Ogg Vorbis di K3b
|
||
Name[ja]=K3b Ogg Vorbis デコーダ
|
||
Name[km]=កម្មវិធីឌិកូដ Ogg Vorbis របស់ K3b
|
||
Name[ko]=K3b Ogg 보비스 디코더
|
||
@@ -34,9 +35,9 @@
|
||
Name[uk]=Декодер Ogg Vorbis для K3b
|
||
Name[x-test]=xxK3b Ogg Vorbis Decoderxx
|
||
Name[zh_CN]=K3b Ogg Vorbis 解码器
|
||
+Name[zh_TW]=K3b Ogg Vorbis 解碼器
|
||
X-KDE-ServiceTypes=K3b/Plugin
|
||
Comment=Decoding module to decode Ogg Vorbis files
|
||
-Comment[bg]=Декодиращ модул за Ogg Vorbis файлове
|
||
Comment[cs]=Modul pro dekódování souborů Ogg Vorbis
|
||
Comment[csb]=Mòdul dekòdërëjący lopczi Ogg Vorbis
|
||
Comment[da]=Dekodermodul til dekodning af Ogg Vorbis-filer
|
||
@@ -51,6 +52,7 @@
|
||
Comment[gl]=Módulo de descodificación de ficheiros de son Ogg Vorbis
|
||
Comment[he]=מודול המפענח קבצי Ogg Vorbis
|
||
Comment[hne]=ओग वार्बिस फाइल ल डिकोड करे बर डिकोडिंग माड्यूल
|
||
+Comment[it]=Decodifica modulare per i file Ogg Vorbis
|
||
Comment[ja]=Ogg Vorbis ファイルをデコードするモジュール
|
||
Comment[km]=ម៉ូឌុលឌិកូដ ដែលត្រូវឌិកូដឯកសារ Ogg Vorbis
|
||
Comment[ko]=Ogg 보비스 파일 디코딩 모듈
|
||
@@ -70,6 +72,7 @@
|
||
Comment[uk]=Модуль декодування файлів Ogg Vorbis
|
||
Comment[x-test]=xxDecoding module to decode Ogg Vorbis filesxx
|
||
Comment[zh_CN]=用于解码 Ogg Vorbis 文件的解码模块
|
||
+Comment[zh_TW]=解碼 Ogg Vorbis 檔案格式的模組
|
||
Type=Service
|
||
ServiceTypes=K3b/Plugin
|
||
Icon=preferences-plugin
|
||
diff -ru plugins/decoder/skeleton.desktop plugins/decoder/skeleton.desktop
|
||
--- plugins/decoder/skeleton.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ plugins/decoder/skeleton.desktop 2009-07-23 11:41:59.000000000 +0200
|
||
@@ -13,6 +13,7 @@
|
||
Name[gl]=Descodificador ??? para K3b
|
||
Name[he]=מפענח ??? של K3b
|
||
Name[hne]=के3बी ??? डिकोडर
|
||
+Name[it]=Decodificatore ??? di K3b
|
||
Name[ja]=K3b ??? デコーダ
|
||
Name[km]=កម្មវិធីឌិកូដ ??? របស់ K3b
|
||
Name[ko]=K3b ??? 디코더
|
||
@@ -32,8 +33,8 @@
|
||
Name[uk]=Декодер ??? для K3b
|
||
Name[x-test]=xxK3b ??? Decoderxx
|
||
Name[zh_CN]=K3b ??? 解码器
|
||
+Name[zh_TW]=K3b ??? 解碼器
|
||
Comment=Decoding module to decode ??? files
|
||
-Comment[bg]=Декодиращ модул за ??? файлове
|
||
Comment[cs]=Modul pro dekódování souborů ???
|
||
Comment[csb]=Mòdul dekòdërëjący lopczi ???
|
||
Comment[da]=Dekodermodul til dekodning af ???-filer
|
||
@@ -47,6 +48,7 @@
|
||
Comment[gl]=Módulo de descodificación de ficheiros ???
|
||
Comment[he]=מודול המפענח קבצי ???
|
||
Comment[hne]=??? फाइल ल डिकोड करे बर डिकोडिंग माड्यूल
|
||
+Comment[it]=Decodifica modulare dei file ???
|
||
Comment[ja]=??? ファイルをデコードするモジュール
|
||
Comment[km]=ម៉ូឌុលឌិកូដ ដែលត្រូវឌិកូដឯកសារ ???
|
||
Comment[ko]=??? 파일 디코딩 모듈
|
||
@@ -66,6 +68,7 @@
|
||
Comment[uk]=Модуль декодування файлів ???
|
||
Comment[x-test]=xxDecoding module to decode ??? filesxx
|
||
Comment[zh_CN]=用于解码 ??? 文件的解码模块
|
||
+Comment[zh_TW]=解碼 ??? 檔案的模組
|
||
Type=Service
|
||
X-KDE-ServiceTypes=K3b/Plugin
|
||
|
||
diff -ru plugins/decoder/wave/k3bwavedecoder.desktop plugins/decoder/wave/k3bwavedecoder.desktop
|
||
--- plugins/decoder/wave/k3bwavedecoder.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ plugins/decoder/wave/k3bwavedecoder.desktop 2009-07-23 11:41:58.000000000 +0200
|
||
@@ -14,6 +14,7 @@
|
||
Name[gl]=Descodificador de Wave para K3b
|
||
Name[he]=מפענח Wave של K3b
|
||
Name[hne]=के3बी वेव डिकोडर
|
||
+Name[it]=Decodificatore Wave di K3b
|
||
Name[ja]=K3b wave デコーダ
|
||
Name[km]=កម្មវិធីឌិកូដ Wave របស់ K3b
|
||
Name[ko]=K3b 웨이브 디코더
|
||
@@ -34,8 +35,8 @@
|
||
Name[uk]=Декодер Wave для K3b
|
||
Name[x-test]=xxK3b Wave Decoderxx
|
||
Name[zh_CN]=K3b Wave 解码器
|
||
+Name[zh_TW]=K3b Wave 解碼器
|
||
Comment=Decoding module to decode wave files
|
||
-Comment[bg]=Декодиращ модул за wave файлове
|
||
Comment[cs]=Modul pro dekódování souborů wave
|
||
Comment[csb]=Mòdul dekòdërëjący lopczi wave
|
||
Comment[da]=Dekodermodul til dekodning af wave-filer
|
||
@@ -50,6 +51,7 @@
|
||
Comment[gl]=Módulo de descodificación de ficheiros wave
|
||
Comment[he]=מודול המפענח קבצי Wave
|
||
Comment[hne]=वेव फाइल ल डिकोड करे बर डिकोडिंग माड्यूल
|
||
+Comment[it]=Decodifica modulare di file WAVE
|
||
Comment[ja]=wave ファイルをデコードするモジュール
|
||
Comment[km]=ម៉ូឌុលឌិកូដ ដែលត្រូវឌិកូដឯកសារ wave
|
||
Comment[ko]=웨이브 파일 디코딩 모듈
|
||
@@ -69,6 +71,7 @@
|
||
Comment[uk]=Модуль декодування файлів wave
|
||
Comment[x-test]=xxDecoding module to decode wave filesxx
|
||
Comment[zh_CN]=用于解码 WAVE 文件的解码模块
|
||
+Comment[zh_TW]=解碼 wave 檔案格式的模組
|
||
Type=Service
|
||
ServiceTypes=K3b/Plugin
|
||
Icon=preferences-plugin
|
||
diff -ru plugins/encoder/external/k3bexternalencodercommand.cpp plugins/encoder/external/k3bexternalencodercommand.cpp
|
||
--- plugins/encoder/external/k3bexternalencodercommand.cpp 2009-05-26 13:37:33.000000000 +0200
|
||
+++ plugins/encoder/external/k3bexternalencodercommand.cpp 2009-07-23 11:41:58.000000000 +0200
|
||
@@ -28,7 +28,7 @@
|
||
KSharedConfig::Ptr c = KGlobal::config();
|
||
KConfigGroup grp(c,"K3bExternalEncoderPlugin" );
|
||
|
||
- QList<K3bExternalEncoderCommand> cl;
|
||
+ QHash<QString, K3bExternalEncoderCommand> cl;
|
||
|
||
QStringList cmds = grp.readEntry( "commands",QStringList() );
|
||
for( QStringList::iterator it = cmds.begin(); it != cmds.end(); ++it ) {
|
||
@@ -43,21 +43,36 @@
|
||
else if( cmdString[i] == "wave" )
|
||
cmd.writeWaveHeader = true;
|
||
}
|
||
- cl.append(cmd);
|
||
+ cl.insert( cmd.name, cmd );
|
||
}
|
||
|
||
// some defaults
|
||
- if( cmds.isEmpty() ) {
|
||
- // check if the lame encoding plugin has been compiled
|
||
+ // check if the lame encoding plugin has been compiled
|
||
#ifndef HAVE_LAME
|
||
- K3bExternalEncoderCommand lameCmd;
|
||
- lameCmd.name = "Mp3 (Lame)";
|
||
- lameCmd.extension = "mp3";
|
||
- lameCmd.command = "lame -h --tt %t --ta %a --tl %m --ty %y --tc %c - %f";
|
||
+ if ( !cl.contains( "Mp3 (Lame)" ) ) {
|
||
+ if( !KStandardDirs::findExe( "lame" ).isEmpty() ) {
|
||
+ K3bExternalEncoderCommand lameCmd;
|
||
+ lameCmd.name = "Mp3 (Lame)";
|
||
+ lameCmd.extension = "mp3";
|
||
+ lameCmd.command = "lame "
|
||
+ "-r "
|
||
+ "--bitwidth 16 "
|
||
+ "--little-endian "
|
||
+ "-s 44.1 "
|
||
+ "-h "
|
||
+ "--tt %t "
|
||
+ "--ta %a "
|
||
+ "--tl %m "
|
||
+ "--ty %y "
|
||
+ "--tc %c "
|
||
+ "- %f";
|
||
|
||
- cl.append( lameCmd );
|
||
+ cl.insert( lameCmd.name, lameCmd );
|
||
+ }
|
||
+ }
|
||
#endif
|
||
|
||
+ if ( !cl.contains( "Flac" ) ) {
|
||
if( !KStandardDirs::findExe( "flac" ).isEmpty() ) {
|
||
K3bExternalEncoderCommand flacCmd;
|
||
flacCmd.name = "Flac";
|
||
@@ -66,7 +81,7 @@
|
||
"-V "
|
||
"-o %f "
|
||
"--force-raw-format "
|
||
- "--endian=big "
|
||
+ "--endian=little "
|
||
"--channels=2 "
|
||
"--sample-rate=44100 "
|
||
"--sign=signed "
|
||
@@ -78,9 +93,11 @@
|
||
"-T ALBUM=%m "
|
||
"-";
|
||
|
||
- cl.append( flacCmd );
|
||
+ cl.insert( flacCmd.name, flacCmd );
|
||
}
|
||
+ }
|
||
|
||
+ if ( !cl.contains( "Musepack" ) ) {
|
||
if( !KStandardDirs::findExe( "mppenc" ).isEmpty() ) {
|
||
K3bExternalEncoderCommand mppCmd;
|
||
mppCmd.name = "Musepack";
|
||
@@ -97,14 +114,13 @@
|
||
"--year %y "
|
||
"- "
|
||
"%f";
|
||
- mppCmd.swapByteOrder = true;
|
||
mppCmd.writeWaveHeader = true;
|
||
|
||
- cl.append( mppCmd );
|
||
+ cl.insert( mppCmd.name, mppCmd );
|
||
}
|
||
}
|
||
|
||
- return cl;
|
||
+ return cl.values();
|
||
}
|
||
|
||
|
||
diff -ru plugins/encoder/external/k3bexternalencoder.cpp plugins/encoder/external/k3bexternalencoder.cpp
|
||
--- plugins/encoder/external/k3bexternalencoder.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ plugins/encoder/external/k3bexternalencoder.cpp 2009-07-23 11:41:58.000000000 +0200
|
||
@@ -1,10 +1,8 @@
|
||
/*
|
||
- *
|
||
- *
|
||
- * Copyright (C) 2003-2008 Sebastian Trueg <trueg@k3b.org>
|
||
+ * Copyright (C) 2003-2009 Sebastian Trueg <trueg@k3b.org>
|
||
*
|
||
* This file is part of the K3b project.
|
||
- * Copyright (C) 1998-2008 Sebastian Trueg <trueg@k3b.org>
|
||
+ * Copyright (C) 1998-2009 Sebastian Trueg <trueg@k3b.org>
|
||
*
|
||
* This program is free software; you can redistribute it and/or modify
|
||
* it under the terms of the GNU General Public License as published by
|
||
@@ -26,9 +24,9 @@
|
||
#include <kstandarddirs.h>
|
||
#include <KProcess>
|
||
|
||
-#include <qregexp.h>
|
||
-#include <qfile.h>
|
||
-#include <QList>
|
||
+#include <QtCore/QRegExp>
|
||
+#include <QtCore/QFile>
|
||
+#include <QtCore/QList>
|
||
|
||
#include <sys/types.h>
|
||
|
||
@@ -289,7 +287,7 @@
|
||
return false;
|
||
}
|
||
|
||
- return true;
|
||
+ return d->process->waitForBytesWritten( -1 );
|
||
}
|
||
|
||
|
||
@@ -303,15 +301,7 @@
|
||
|
||
long written = 0;
|
||
|
||
- //
|
||
- // we swap the bytes to reduce user irritation ;)
|
||
- // This is a little confused: We used to swap the byte order
|
||
- // in older versions of this encoder since little endian seems
|
||
- // to "feel" more natural.
|
||
- // So now that we have a swap option we have to invert it to ensure
|
||
- // compatibility
|
||
- //
|
||
- if( !d->cmd.swapByteOrder ) {
|
||
+ if( d->cmd.swapByteOrder ) {
|
||
char* buffer = new char[len];
|
||
for( unsigned int i = 0; i < len-1; i+=2 ) {
|
||
buffer[i] = data[i+1];
|
||
@@ -324,6 +314,8 @@
|
||
else
|
||
written = d->process->write( data, len );
|
||
|
||
+ d->process->waitForBytesWritten( -1 );
|
||
+
|
||
return written;
|
||
}
|
||
else
|
||
diff -ru plugins/encoder/external/k3bexternalencoder.desktop plugins/encoder/external/k3bexternalencoder.desktop
|
||
--- plugins/encoder/external/k3bexternalencoder.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ plugins/encoder/external/k3bexternalencoder.desktop 2009-07-23 11:41:58.000000000 +0200
|
||
@@ -14,6 +14,7 @@
|
||
Name[gl]=Codificador externo de son para K3b
|
||
Name[he]=מקודד שמע חיצוני של K3b
|
||
Name[hne]=के३बी बाहरी आडियो एनकोडर
|
||
+Name[it]=Codificatore audio esterno di K3b
|
||
Name[ja]=K3b 外部オーディオエンコーダ
|
||
Name[km]=កម្មវិធីអ៊ិនកូដអូឌីយ៉ូខាងក្រៅរបស់ K3b
|
||
Name[ko]=K3b 외부 오디오 인코더
|
||
@@ -26,7 +27,7 @@
|
||
Name[pt]=Codificador de Áudio Externo do K3b
|
||
Name[pt_BR]=Codificador de Áudio Externo do K3b
|
||
Name[ro]=Codor K3b Audio extern
|
||
-Name[ru]=Внешнй кодер звука
|
||
+Name[ru]=Внешний кодер звука
|
||
Name[sl]=K3b-jev zunanji zvočni kodirnik
|
||
Name[sv]=K3b extern ljudkodare
|
||
Name[th]=K3b - ตัวเข้ารหัสเสียงภายนอก
|
||
@@ -34,8 +35,8 @@
|
||
Name[uk]=Зовнішній кодувальник аудіо для K3b
|
||
Name[x-test]=xxK3b External Audio Encoderxx
|
||
Name[zh_CN]=K3b 扩展音频编码器
|
||
+Name[zh_TW]=K3b 外部音效編碼器
|
||
Comment=Encoding module that allows specifying an encoding command
|
||
-Comment[bg]=Кодиращ модул, позволяващ задаването на команда
|
||
Comment[csb]=Mòdul kòdërëjący, jaczi zezwôlô na wpisanié kòderëjącegò pòletu
|
||
Comment[da]=Indkodningsmodul som muliggør angivelse af en indkodningskommando
|
||
Comment[de]=Kodierungsmodul zur Unterstützung externer Kodierprogramme
|
||
@@ -48,6 +49,7 @@
|
||
Comment[ga]=Modúl ionchódaithe a cheadaíonn duit ordú ionchódaithe a roghnú
|
||
Comment[gl]=Módulo de codificación que permite especificar un comando
|
||
Comment[he]=מודול קידוד אשר מאפשר לציין פקודת קידוד ספציפית
|
||
+Comment[it]=Codifica modulare che permette di specificare un comando di codifica
|
||
Comment[ja]=エンコードコマンドの指定を可能にするエンコードモジュール
|
||
Comment[km]=ម៉ូឌុលអ៊ិនកូដ ដែលអនុញ្ញាតឲ្យបញ្ជាក់ពាក្យបញ្ជាអ៊ិនកូដ
|
||
Comment[lv]=Kodēšanas modulis, kurš ļauj norādīt kodēšanas komandu
|
||
@@ -66,6 +68,7 @@
|
||
Comment[uk]=Модуль кодування, що дозволяє визначення команди кодування
|
||
Comment[x-test]=xxEncoding module that allows specifying an encoding commandxx
|
||
Comment[zh_CN]=允许指定编码命令的编码模块
|
||
+Comment[zh_TW]=讓您透過指定外部指令的方式做編碼的模組
|
||
Type=Service
|
||
ServiceTypes=K3b/Plugin
|
||
Icon=preferences-plugin
|
||
diff -ru plugins/encoder/external/k3bexternalencoder.h plugins/encoder/external/k3bexternalencoder.h
|
||
--- plugins/encoder/external/k3bexternalencoder.h 2009-04-21 19:54:02.000000000 +0200
|
||
+++ plugins/encoder/external/k3bexternalencoder.h 2009-07-23 11:41:58.000000000 +0200
|
||
@@ -1,10 +1,8 @@
|
||
/*
|
||
- *
|
||
- *
|
||
- * Copyright (C) 2003-2008 Sebastian Trueg <trueg@k3b.org>
|
||
+ * Copyright (C) 2003-2009 Sebastian Trueg <trueg@k3b.org>
|
||
*
|
||
* This file is part of the K3b project.
|
||
- * Copyright (C) 1998-2008 Sebastian Trueg <trueg@k3b.org>
|
||
+ * Copyright (C) 1998-2009 Sebastian Trueg <trueg@k3b.org>
|
||
*
|
||
* This program is free software; you can redistribute it and/or modify
|
||
* it under the terms of the GNU General Public License as published by
|
||
diff -ru plugins/encoder/external/kcm_k3bexternalencoder.desktop plugins/encoder/external/kcm_k3bexternalencoder.desktop
|
||
--- plugins/encoder/external/kcm_k3bexternalencoder.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ plugins/encoder/external/kcm_k3bexternalencoder.desktop 2009-07-23 11:41:58.000000000 +0200
|
||
@@ -1,6 +1,5 @@
|
||
[Desktop Entry]
|
||
Name=K3b External Audio Encoder Config Widget
|
||
-Name[bg]=Настройване на K3b External Audio Encoder
|
||
Name[cs]=Externí audio enkodér K3b
|
||
Name[csb]=Òkno nastôwów bùtnowegò kòdera audio dlô K3b
|
||
Name[da]=Konfigurationskontrol til K3b ekstern lydindkodning
|
||
@@ -15,6 +14,7 @@
|
||
Name[gl]=Widget de configuración do Codificador externo de son para K3b
|
||
Name[he]=וידג'ט הגדרות מקודד חיצוני של K3b
|
||
Name[hne]=के३बी बाहरी आडियो एनकोडर कान्फिग विजेट
|
||
+Name[it]=Elemento di configurazione codificatore audio esterno di K3b
|
||
Name[ja]=K3b 外部オーディオエンコーダ設定ウィジェット
|
||
Name[km]=ធាតុក្រាហ្វិកកំណត់រចនាសម្ព័ន្ធកម្មវិធីអ៊ិនកូដអូឌីយ៉ូខាងក្រៅរបស់ K3b
|
||
Name[lv]=K3b ārējā audio kodētāja konfigurācijas logdaļa
|
||
@@ -34,6 +34,7 @@
|
||
Name[uk]=Віджет налаштування зовнішнього кодувальника звуку для K3b
|
||
Name[x-test]=xxK3b External Audio Encoder Config Widgetxx
|
||
Name[zh_CN]=K3b 扩展音频编码器配置部件
|
||
+Name[zh_TW]=K3b 外部音效編碼器設定元件
|
||
Type=Service
|
||
X-KDE-ServiceTypes=KCModule
|
||
X-KDE-Library=kcm_k3bexternalencoder
|
||
diff -ru plugins/encoder/lame/k3blameencoder.desktop plugins/encoder/lame/k3blameencoder.desktop
|
||
--- plugins/encoder/lame/k3blameencoder.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ plugins/encoder/lame/k3blameencoder.desktop 2009-07-23 11:41:58.000000000 +0200
|
||
@@ -14,6 +14,7 @@
|
||
Name[gl]=Codificador de Mp3 Lame para K3b
|
||
Name[he]=מקודד קבצי Lame Mp3 של K3b
|
||
Name[hne]=के३बी लेम एमपी३ एनकोडर
|
||
+Name[it]=Codificatore MP3 Lame di K3b
|
||
Name[ja]=K3b Lame MP3 エンコーダ
|
||
Name[km]=កម្មវិធីអ៊ិនកូដ Lame Mp3 របស់ K3b
|
||
Name[ko]=K3b Lame Mp3 인코더
|
||
@@ -34,8 +35,8 @@
|
||
Name[uk]=Кодувальник Lame Mp3 для K3b
|
||
Name[x-test]=xxK3b Lame Mp3 Encoderxx
|
||
Name[zh_CN]=K3b Lame Mp3 编码器
|
||
+Name[zh_TW]=K3b Lame MP3 編碼器
|
||
Comment=Encoding module to encode MPEG1 Layer III (mp3) files
|
||
-Comment[bg]=Кодиращ модул за MPEG1 Layer III (mp3) файлове
|
||
Comment[csb]=Mòdul kòdërëjący lopczi MPEG1 Layer III (mp3)
|
||
Comment[da]=Indkodningsmodul til MPEG 1 Layer III-filer (mp3)
|
||
Comment[de]=Kodierungsmodul zur Kodierung von MPEG1 Layer III-Dateien (MP3)
|
||
@@ -49,6 +50,7 @@
|
||
Comment[gl]=Módulo de codificación para ficheiros MPEG capa III (mp3)
|
||
Comment[he]=מודול קידוד לקבצי MPEG1 שכבה lll (mp3)
|
||
Comment[hne]=एमपीईजी १ लेयर III (एमपी३) फाइल ल डिकोड करे बर एनकोडिंग माड्यूल
|
||
+Comment[it]=Codifica modulare per file MPEG1 Layer III (MP3)
|
||
Comment[ja]=MPEG 1 Layer III (MP3) ファイルをエンコードするモジュール
|
||
Comment[km]=ម៉ូឌុលអ៊ិនកូដ ដែលត្រូវអ៊ិនកូដឯកសារ MPEG1 ស្រទាប់ III (mp3)
|
||
Comment[ko]=MPEG 1 레이어 3(MP3) 파일 인코딩 모듈
|
||
@@ -68,6 +70,7 @@
|
||
Comment[uk]=Модуль кодування файлів MPEG1 Layer III (mp3)
|
||
Comment[x-test]=xxEncoding module to encode MPEG1 Layer III (mp3) filesxx
|
||
Comment[zh_CN]=用于编码 MPEG 1 Layer III(mp3) 文件的编码模块
|
||
+Comment[zh_TW]=編碼 MP3 檔案格式的模組
|
||
Type=Service
|
||
ServiceTypes=K3b/Plugin
|
||
Icon=preferences-plugin
|
||
diff -ru plugins/encoder/lame/kcm_k3blameencoder.desktop plugins/encoder/lame/kcm_k3blameencoder.desktop
|
||
--- plugins/encoder/lame/kcm_k3blameencoder.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ plugins/encoder/lame/kcm_k3blameencoder.desktop 2009-07-23 11:41:58.000000000 +0200
|
||
@@ -1,6 +1,5 @@
|
||
[Desktop Entry]
|
||
Name=K3b Lame Mp3 Encoder Config Module
|
||
-Name[bg]=Модул за настройване на K3b Lame Mp3 Encoder
|
||
Name[cs]=Ovládací modul K3b Lame Mp3 formátu
|
||
Name[csb]=Mòdul nastôwów kòdera Lame Mp3 dlô K3b
|
||
Name[da]=Konfigurationsmodul til K3b Lame mp3-indkodning
|
||
@@ -15,6 +14,7 @@
|
||
Name[gl]=Módulo de configuración do Codificador mp3 Lame para K3b
|
||
Name[he]=הגדרות מודול קידוד קבצי Lame Mp3 של K3b
|
||
Name[hne]=के३बी लेम एमपी३ एनकोडर कान्फिग माड्यूल
|
||
+Name[it]=Modulo di configurazione codificatore MP3 Lame di K3b
|
||
Name[ja]=K3b Lame MP3 エンコーダ設定モジュール
|
||
Name[km]=ម៉ូឌុលកំណត់រចនាសម្ព័ន្ធកម្មវិធីអ៊ិនកូដ Lame Mp3 របស់ K3b
|
||
Name[lv]=K3b Lame Mp3 kodētāja configurācijas modulis
|
||
@@ -32,6 +32,7 @@
|
||
Name[uk]=Модуль налаштування кодувальника Lame Mp3 K3b
|
||
Name[x-test]=xxK3b Lame Mp3 Encoder Config Modulexx
|
||
Name[zh_CN]=K3b Lame Mp3 编码器配置部件
|
||
+Name[zh_TW]=K3b Lame MP3 編碼器設定模組
|
||
Type=Service
|
||
X-KDE-ServiceTypes=KCModule
|
||
X-KDE-Library=kcm_k3blameencoder
|
||
diff -ru plugins/encoder/ogg/k3boggvorbisencoder.desktop plugins/encoder/ogg/k3boggvorbisencoder.desktop
|
||
--- plugins/encoder/ogg/k3boggvorbisencoder.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ plugins/encoder/ogg/k3boggvorbisencoder.desktop 2009-07-23 11:41:58.000000000 +0200
|
||
@@ -14,6 +14,7 @@
|
||
Name[gl]=Codificador de Ogg Vorbis para K3b
|
||
Name[he]=מקודד Ogg Vorbis של K3b
|
||
Name[hne]=के3बी ओग वार्बिस एनकोडर
|
||
+Name[it]=Codificatore Ogg Vorbis di K3b
|
||
Name[ja]=K3b Ogg Vorbis エンコーダ
|
||
Name[km]=កម្មវិធីអ៊ិនកូដ Ogg Vorbis របស់ K3b
|
||
Name[ko]=K3b Ogg 보비스 인코더
|
||
@@ -33,8 +34,8 @@
|
||
Name[uk]=Кодувальник Ogg Vorbis для K3b
|
||
Name[x-test]=xxK3b Ogg Vorbis Encoderxx
|
||
Name[zh_CN]=K3b Ogg Vorbis 编码器
|
||
+Name[zh_TW]=K3b Ogg Vorbis 編碼器
|
||
Comment=Encoding module to encode Ogg Vorbis files
|
||
-Comment[bg]=Кодиращ модул за Ogg Vorbis файлове
|
||
Comment[cs]=Modul pro kompresi do souborů Ogg Vorbis
|
||
Comment[csb]=Mòdul kòdërëjący lopczi Ogg Vorbis
|
||
Comment[da]=Indkodnignsmodul til Ogg Vorbis-filer
|
||
@@ -49,6 +50,7 @@
|
||
Comment[gl]=Módulo de codificación para ficheiros Ogg Vorbis
|
||
Comment[he]=מודול קידוד על מנת לקודד קבצי Ogg Vorbis
|
||
Comment[hne]=ओग वार्बिस फाइल ल एनकोड करे बर एनकोडिंग माड्यूल
|
||
+Comment[it]=Codifica modulare di file Ogg Vorbis
|
||
Comment[ja]=Ogg Vorbis ファイルをエンコードするモジュール
|
||
Comment[km]=ម៉ូឌុលអ៊ិនកូដ ដែលត្រូវអ៊ិនកូដឯកសារ Ogg Vorbis
|
||
Comment[ko]=Ogg 보비스 파일 인코딩 모듈
|
||
@@ -67,6 +69,7 @@
|
||
Comment[uk]=Модуль кодування файлів Ogg Vorbis
|
||
Comment[x-test]=xxEncoding module to encode Ogg Vorbis filesxx
|
||
Comment[zh_CN]=用于编码 Ogg Vorbis 文件的编码模块
|
||
+Comment[zh_TW]=編碼 Ogg Vorbis 檔案格式的模組
|
||
Type=Service
|
||
ServiceTypes=K3b/Plugin
|
||
Icon=preferences-plugin
|
||
diff -ru plugins/encoder/ogg/kcm_k3boggvorbisencoder.desktop plugins/encoder/ogg/kcm_k3boggvorbisencoder.desktop
|
||
--- plugins/encoder/ogg/kcm_k3boggvorbisencoder.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ plugins/encoder/ogg/kcm_k3boggvorbisencoder.desktop 2009-07-23 11:41:58.000000000 +0200
|
||
@@ -1,6 +1,5 @@
|
||
[Desktop Entry]
|
||
Name=K3b Ogg Vorbis Encoder Config Widget
|
||
-Name[bg]=Настройване на K3b Ogg Vorbis Encoder
|
||
Name[csb]=Òkno nastôwów kòdera Ogg Vorbis dlô K3b
|
||
Name[da]=Konfigurationskontrol til K3b Ogg Vorbis-indkodning
|
||
Name[de]=K3b-Bedienelement zur Kodierung von Ogg Vorbis
|
||
@@ -13,6 +12,7 @@
|
||
Name[gl]=Widget de configuración do Codificador Ogg Vorbis para K3b
|
||
Name[he]=וידג'ט הגדרות קידוד קבצי Ogg Vorbis של K3b
|
||
Name[hne]=के3बी ओग वार्बिस एनकोडर कान्फिग विजेट
|
||
+Name[it]=Elemento di configurazione codificatore Ogg Vorbis di K3b
|
||
Name[ja]=K3b Ogg Vorbis エンコーダ設定ウィジェット
|
||
Name[km]=ធាតុក្រាហ្វិកកំណត់រចនាសម្ព័ន្ធកម្មវិធីអ៊ិនកូដ Ogg Vorbis របស់ K3b
|
||
Name[lv]=K3b Ogg Vorbis kodētāja konfigurācijas logdaļa
|
||
@@ -30,6 +30,7 @@
|
||
Name[uk]=Віджет налаштування кодувальника Ogg Vorbis K3b
|
||
Name[x-test]=xxK3b Ogg Vorbis Encoder Config Widgetxx
|
||
Name[zh_CN]=K3b Ogg Vorbis 编码器配置部件
|
||
+Name[zh_TW]=K3b Ogg Vorbis 編碼器設定元件
|
||
Type=Service
|
||
X-KDE-ServiceTypes=KCModule
|
||
X-KDE-Library=kcm_k3boggvorbisencoder
|
||
diff -ru plugins/encoder/skeleton.desktop plugins/encoder/skeleton.desktop
|
||
--- plugins/encoder/skeleton.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ plugins/encoder/skeleton.desktop 2009-07-23 11:41:58.000000000 +0200
|
||
@@ -13,6 +13,7 @@
|
||
Name[gl]=Codificador ??? para K3b
|
||
Name[he]=מקודד ??? של K3b
|
||
Name[hne]=के३बी ??? एनकोडर
|
||
+Name[it]=Codificatore ??? di K3b
|
||
Name[ja]=K3b ??? エンコーダ
|
||
Name[km]=កម្មវិធីអ៊ិនកូដ ??? របស់ K3b
|
||
Name[ko]=K3b ??? 인코더
|
||
@@ -32,8 +33,8 @@
|
||
Name[uk]=Кодувальник ??? для K3b
|
||
Name[x-test]=xxK3b ??? Encoderxx
|
||
Name[zh_CN]=K3b ??? 编码器
|
||
+Name[zh_TW]=K3b ??? 編碼器
|
||
Comment=Encoding module to encode <name> files
|
||
-Comment[bg]=Кодиращ модул за <name> файлове
|
||
Comment[cs]=Modul pro kompresi do souborů <name>
|
||
Comment[csb]=Mòdul kòdërëjący lopczi <name>
|
||
Comment[da]=Indkodningsmodul til <name>-filer
|
||
@@ -47,6 +48,7 @@
|
||
Comment[gl]=Módulo de configuración para codificar ficheiros <name>
|
||
Comment[he]=מודל קידוד לקבצי <name>
|
||
Comment[hne]=<name> फाइल ल एनकोड करे बर एनकोडिंग माड्यूल
|
||
+Comment[it]=Codificatore modulare di file <name>
|
||
Comment[ja]=<name> ファイルをエンコードするモジュール
|
||
Comment[km]=ម៉ូឌុលអ៊ិនកូដ ដែលត្រូវអ៊ិនកូដឯកសារ <ឈ្មោះ>
|
||
Comment[ko]=<name> 파일 인코딩 모듈
|
||
@@ -65,6 +67,7 @@
|
||
Comment[uk]=Модуль кодування файлів <name>
|
||
Comment[x-test]=xxEncoding module to encode <name> filesxx
|
||
Comment[zh_CN]=用于编码 <name> 文件的编码模块
|
||
+Comment[zh_TW]=編碼 <名稱> 檔案的模組
|
||
Type=Service
|
||
X-KDE-ServiceTypes=K3b/Plugin
|
||
|
||
diff -ru plugins/encoder/sox/k3bsoxencoder.desktop plugins/encoder/sox/k3bsoxencoder.desktop
|
||
--- plugins/encoder/sox/k3bsoxencoder.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ plugins/encoder/sox/k3bsoxencoder.desktop 2009-07-23 11:41:58.000000000 +0200
|
||
@@ -14,6 +14,7 @@
|
||
Name[gl]=Codificador de son SoX para K3b
|
||
Name[he]=מקודד קבצי שמע SoX של K3b
|
||
Name[hne]=के३बी साक्स आडियो एनकोडर
|
||
+Name[it]=Codificatore audio SoX di K3b
|
||
Name[ja]=K3b SoX オーディオエンコーダ
|
||
Name[km]=កម្មវិធីអ៊ិនកូដ អូឌីយ៉ូ SoX របស់ K3b
|
||
Name[ko]=K3b SoX 오디오 인코더
|
||
@@ -33,8 +34,8 @@
|
||
Name[uk]=Кодувальник звуку SoX для K3b
|
||
Name[x-test]=xxK3b SoX Audio Encoderxx
|
||
Name[zh_CN]=K3b SoX 音频编码器
|
||
+Name[zh_TW]=K3b SoX 音效編碼器
|
||
Comment=Encoding module to encode many file formats using SoX
|
||
-Comment[bg]=Кодиращ модул (с SoX) за много файлови формати
|
||
Comment[cs]=Modul pro kompresi do mnoha formátů pomocí SoX
|
||
Comment[csb]=Mòdul kòdërëjący wiele fòrmôtów z pòmòcą SoX
|
||
Comment[da]=Indkodningsmodul til mange filformater med brug af SoX
|
||
@@ -48,6 +49,7 @@
|
||
Comment[ga]=Modúl ionchódaithe a ionchódaíonn a lán formáidí comhaid le SoX
|
||
Comment[gl]=Módulo de configuración para codificar varios formatos de ficheiro mediante SoX
|
||
Comment[he]=מודול קידוד על מנת לקודד הרבה סוגי קבצים בעזרת SoX
|
||
+Comment[it]=Codifica modulare per i molti formati di file che usano SoX
|
||
Comment[ja]=SoX を使ってさまざまなファイルフォーマットをエンコードするモジュール
|
||
Comment[km]=ម៉ូឌុលអ៊ិនកូដ ដែលត្រូវអ៊ិនកូដទ្រង់ទ្រាយឯកសារច្រើនដោយប្រើ SoX
|
||
Comment[ko]=SoX를 사용하여 많은 파일을 인코딩하는 모듈
|
||
@@ -66,6 +68,7 @@
|
||
Comment[uk]=Модуль кодування багатьох форматів файлів за допомогою SoX
|
||
Comment[x-test]=xxEncoding module to encode many file formats using SoXxx
|
||
Comment[zh_CN]=用于编码很多使用 SoX 格式的文件的编码模块
|
||
+Comment[zh_TW]=編碼許多 SoX 支援的檔案格式的模組
|
||
Type=Service
|
||
ServiceTypes=K3b/Plugin
|
||
Icon=preferences-plugin
|
||
diff -ru plugins/project/audiometainforenamer/k3baudiometainforenamerplugin.cpp plugins/project/audiometainforenamer/k3baudiometainforenamerplugin.cpp
|
||
--- plugins/project/audiometainforenamer/k3baudiometainforenamerplugin.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ plugins/project/audiometainforenamer/k3baudiometainforenamerplugin.cpp 2009-07-23 11:41:59.000000000 +0200
|
||
@@ -380,7 +380,7 @@
|
||
|
||
|
||
K3bAudioMetainfoRenamerPlugin::K3bAudioMetainfoRenamerPlugin( QObject* parent, const QVariantList& )
|
||
- : K3b::ProjectPlugin( DATA_PROJECTS, true, parent )
|
||
+ : K3b::ProjectPlugin( K3b::Doc::DataProject, true, parent )
|
||
{
|
||
setText( i18n("Rename Audio Files") );
|
||
setToolTip( i18n("Rename audio files based on their meta info.") );
|
||
diff -ru plugins/project/audiometainforenamer/k3baudiometainforenamerplugin.desktop plugins/project/audiometainforenamer/k3baudiometainforenamerplugin.desktop
|
||
--- plugins/project/audiometainforenamer/k3baudiometainforenamerplugin.desktop 2009-05-26 16:22:58.000000000 +0200
|
||
+++ plugins/project/audiometainforenamer/k3baudiometainforenamerplugin.desktop 2009-07-23 11:41:59.000000000 +0200
|
||
@@ -4,8 +4,10 @@
|
||
Name[de]=K3b-Audio-Metadaten-Umbenennungs-Modul
|
||
Name[es]=Renombrador de meta información de audio de K3b
|
||
Name[et]=K3b helifailide metainfo põhjal ümbernimetaja
|
||
+Name[eu]=K3b-ren audioaren meta-informazioen izen-aldatzailea
|
||
Name[fr]=Renommeur de méta-données audio K3b
|
||
Name[ga]=Athainmneoir Meiteafhaisnéise Fuaime K3b
|
||
+Name[it]=Rinominatore di Meta informazioni audio di K3b
|
||
Name[km]=កម្មវិធីប្ដូរឈ្មោះព័ត៌មានមេតាអូឌីយ៉ូ K3b
|
||
Name[nb]=K3b metainfo-omnavner for lyd
|
||
Name[nds]=Audiometadaten-Ümnömer för K3b
|
||
@@ -16,13 +18,16 @@
|
||
Name[sv]=K3b namnändring av ljud med metainformation
|
||
Name[uk]=Інструмент перейменування за метаданими K3b
|
||
Name[x-test]=xxK3b Audio Metainfo Renamerxx
|
||
+Name[zh_TW]=K3b 音效中繼資訊重命名
|
||
Comment=Plugin to rename audio files in a data project based on the meta info.
|
||
Comment[da]=Plugin til at omdøbe lydfiler i et dataprojekt baseret på metainfo.
|
||
Comment[de]=Modul zum Umbenennen von Audio-Dateien in einem Daten-Projekt, basierend auf den Metadaten.
|
||
Comment[es]=Complemento basado en la meta información para renombrar archivos de audio en un proyecto de datos .
|
||
Comment[et]=Plugin andmeprojekti helifailide ümbernimetamiseks metainfo põhjal.
|
||
+Comment[eu]=Meta-informazioan oinarritutako plugina audioko fitxategiak izenez aldatzeko datuen proiektuan.
|
||
Comment[fr]=Module pour renommer des fichiers audio dans un projet de données fondé sur les informations de méta-données.
|
||
Comment[ga]=Breiseán a athainmníonn comhaid fhuaime i dtionscadal sonraí, bunaithe ar an mheiteafhaisnéis.
|
||
+Comment[it]=Estensione usata per rinominare i file audio in un progetto dati basato su meta informazioni.
|
||
Comment[km]=កម្មវិធីជំនួយត្រូវប្ដូរឈ្មោះឯកសារអូឌីយ៉ូនៅក្នុងគម្រោងទិន្នន័យ ដែលមានមូលដ្ឋានលើព័ត៌មានមេតា ។
|
||
Comment[nb]=Programtillegg som gir nytt navn til lydfiler i et dataprosjekt basert på deres metainfo.
|
||
Comment[nds]=Moduul för't Ümnömen vun Klangdateien binnen en Datenprojekt na ehr Meta-Informatschonen
|
||
@@ -33,6 +38,7 @@
|
||
Comment[sv]=Insticksprogram för att byta namn på ljudfiler i ett dataprojekt baserat på metainformation.
|
||
Comment[uk]=Додаток для перейменування звукових файлів у проектах даних на основі метаданих.
|
||
Comment[x-test]=xxPlugin to rename audio files in a data project based on the meta info.xx
|
||
+Comment[zh_TW]=根據中繼資料來重新命名資料專案中的音效檔的外掛程式。
|
||
Type=Service
|
||
ServiceTypes=K3b/Plugin
|
||
Icon=preferences-plugin
|
||
diff -ru plugins/project/audioprojectcddb/k3baudioprojectcddbplugin.cpp plugins/project/audioprojectcddb/k3baudioprojectcddbplugin.cpp
|
||
--- plugins/project/audioprojectcddb/k3baudioprojectcddbplugin.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ plugins/project/audioprojectcddb/k3baudioprojectcddbplugin.cpp 2009-07-23 11:41:59.000000000 +0200
|
||
@@ -41,7 +41,7 @@
|
||
|
||
|
||
K3bAudioProjectCddbPlugin::K3bAudioProjectCddbPlugin( QObject* parent, const QVariantList& )
|
||
- : K3b::ProjectPlugin( AUDIO_CD, false, parent ),
|
||
+ : K3b::ProjectPlugin( K3b::Doc::AudioProject, false, parent ),
|
||
m_progress(0)
|
||
{
|
||
setText( i18n("Query Cddb") );
|
||
diff -ru plugins/project/audioprojectcddb/k3baudioprojectcddbplugin.desktop plugins/project/audioprojectcddb/k3baudioprojectcddbplugin.desktop
|
||
--- plugins/project/audioprojectcddb/k3baudioprojectcddbplugin.desktop 2009-05-26 16:22:58.000000000 +0200
|
||
+++ plugins/project/audioprojectcddb/k3baudioprojectcddbplugin.desktop 2009-07-23 11:41:59.000000000 +0200
|
||
@@ -4,8 +4,10 @@
|
||
Name[de]=K3b-CDDB-Audio-Modul
|
||
Name[es]=Complemento de audio Cddb de K3b
|
||
Name[et]=K3b CDDB plugin
|
||
+Name[eu]=K3b-ren Cddb audioaren plugina
|
||
Name[fr]=Module audio CDDB K3b
|
||
Name[ga]=Breiseán Fuaime Cddb K3b
|
||
+Name[it]=Estensione audio CDDB di K3b
|
||
Name[km]=កម្មវិធីជំនួយអូឌីយ៉ូ K3b Cddb
|
||
Name[nb]=K3b programtillegg for Cddb.lyd
|
||
Name[nds]=CDDB-Audiomoduul för K3b
|
||
@@ -18,23 +20,27 @@
|
||
Name[tr]=K3b Cddb Ses Eklentisi
|
||
Name[uk]=Додаток для роботи з CDDB у K3b
|
||
Name[x-test]=xxK3b Cddb Audio Pluginxx
|
||
+Name[zh_TW]=K3b Cddb 音效外掛程式
|
||
Comment=Plugin to query a cddb server for information about an audio project.
|
||
Comment[da]=Plugin til at forespørge en cddb-server om information om et lydprojekt.
|
||
Comment[de]=Modul zur Abfrage eines CDDB-Servers nach Informationen zu einem Audio-Projekt
|
||
Comment[es]=Complemento para preguntar a un servidor cddb sobre información en un proyecto de audio.
|
||
Comment[et]=Plugin CDDB serverist teabe hankimiseks audioprojekti kohta.
|
||
+Comment[eu]=Cddb zerbitzariari audioaren proiektuaren informazioari buruz kontsulta egiteko plugina.
|
||
Comment[fr]=Module pour interroger un serveur CDDB pour des informations sur un projet audio.
|
||
Comment[ga]=Breiseán a dhéanann iarratais ar eolas faoi thionscadal fuaime ó fhreastalaí cddb.
|
||
+Comment[it]=Estensione di interrogazione di un server CDDB per le informazioni su un progetto audio.
|
||
Comment[km]=កម្មវិធីជំនួយត្រូវសួរម៉ាស៊ីនបម្រើ cddb រកព័ត៌មានបន្ថែមអំពីគម្រោងអូឌីយ៉ូ ។
|
||
Comment[nb]=Programtillegg som søker i en cddb-tjener etter informasjon om et lydprosjekt.
|
||
Comment[nds]=Moduul för de Söök vun Informatschonen över en Klangprojekt op en CDDB-Server
|
||
Comment[nl]=Plugin om op een cddb-server informatie op te zoeken over een audioproject.
|
||
Comment[pt]=Um 'plugin' para consultar um servidor de CDDB por informações acerca de um projecto de áudio.
|
||
Comment[pt_BR]=Plug-in para consultar o servidor cddb por informações sobre um projeto de áudio.
|
||
-Comment[ru]=Модуль получения сведений о аудиопроекте с сревера CDDB.
|
||
+Comment[ru]=Модуль получения сведений о аудиопроекте с сервера CDDB.
|
||
Comment[sv]=Insticksprogram för att hämta information om ett ljudprojekt från en CDDB-server.
|
||
Comment[uk]=Додаток для опитування сервера cddb щодо даних про аудіо-проект.
|
||
Comment[x-test]=xxPlugin to query a cddb server for information about an audio project.xx
|
||
+Comment[zh_TW]=到 cddb 伺服器查詢音效專案的資訊的外掛程式。
|
||
Type=Service
|
||
ServiceTypes=K3b/Plugin
|
||
Icon=preferences-plugin
|
||
diff -ru src/k3b.cpp src/k3b.cpp
|
||
--- src/k3b.cpp 2009-05-11 09:58:10.000000000 +0200
|
||
+++ src/k3b.cpp 2009-07-23 11:42:05.000000000 +0200
|
||
@@ -463,13 +463,13 @@
|
||
// create the proper K3b::View (maybe we should put this into some other class like K3b::ProjectManager)
|
||
K3b::View* view = 0;
|
||
switch( doc->type() ) {
|
||
- case K3b::Doc::AUDIO:
|
||
+ case K3b::Doc::AudioProject:
|
||
view = new K3b::AudioView( static_cast<K3b::AudioDoc*>(doc), m_documentTab );
|
||
break;
|
||
- case K3b::Doc::DATA:
|
||
+ case K3b::Doc::DataProject:
|
||
view = new K3b::DataView( static_cast<K3b::DataDoc*>(doc), m_documentTab );
|
||
break;
|
||
- case K3b::Doc::MIXED:
|
||
+ case K3b::Doc::MixedProject:
|
||
{
|
||
K3b::MixedDoc* mixedDoc = static_cast<K3b::MixedDoc*>(doc);
|
||
view = new K3b::MixedView( mixedDoc, m_documentTab );
|
||
@@ -477,13 +477,13 @@
|
||
mixedDoc->audioDoc()->setView( view );
|
||
break;
|
||
}
|
||
- case K3b::Doc::VCD:
|
||
+ case K3b::Doc::VcdProject:
|
||
view = new K3b::VcdView( static_cast<K3b::VcdDoc*>(doc), m_documentTab );
|
||
break;
|
||
- case K3b::Doc::MOVIX:
|
||
+ case K3b::Doc::MovixProject:
|
||
view = new K3b::MovixView( static_cast<K3b::MovixDoc*>(doc), m_documentTab );
|
||
break;
|
||
- case K3b::Doc::VIDEODVD:
|
||
+ case K3b::Doc::VideoDvdProject:
|
||
view = new K3b::VideoDvdView( static_cast<K3b::VideoDvdDoc*>(doc), m_documentTab );
|
||
break;
|
||
}
|
||
@@ -529,7 +529,7 @@
|
||
// see if it's an audio cue file
|
||
K3b::CueFileParser parser( url.toLocalFile() );
|
||
if( parser.isValid() && parser.toc().contentType() == K3b::Device::AUDIO ) {
|
||
- K3b::Doc* doc = k3bappcore->projectManager()->createProject( K3b::Doc::AUDIO );
|
||
+ K3b::Doc* doc = k3bappcore->projectManager()->createProject( K3b::Doc::AudioProject );
|
||
doc->addUrl( url );
|
||
return doc;
|
||
}
|
||
@@ -1055,7 +1055,7 @@
|
||
{
|
||
slotStatusMsg(i18n("Creating new Audio CD Project."));
|
||
|
||
- K3b::Doc* doc = k3bappcore->projectManager()->createProject( K3b::Doc::AUDIO );
|
||
+ K3b::Doc* doc = k3bappcore->projectManager()->createProject( K3b::Doc::AudioProject );
|
||
|
||
return doc;
|
||
}
|
||
@@ -1064,7 +1064,7 @@
|
||
{
|
||
slotStatusMsg(i18n("Creating new Data CD Project."));
|
||
|
||
- K3b::Doc* doc = k3bappcore->projectManager()->createProject( K3b::Doc::DATA );
|
||
+ K3b::Doc* doc = k3bappcore->projectManager()->createProject( K3b::Doc::DataProject );
|
||
|
||
return doc;
|
||
}
|
||
@@ -1080,7 +1080,7 @@
|
||
{
|
||
slotStatusMsg(i18n("Creating new Video DVD Project."));
|
||
|
||
- K3b::Doc* doc = k3bappcore->projectManager()->createProject( K3b::Doc::VIDEODVD );
|
||
+ K3b::Doc* doc = k3bappcore->projectManager()->createProject( K3b::Doc::VideoDvdProject );
|
||
|
||
return doc;
|
||
}
|
||
@@ -1090,7 +1090,7 @@
|
||
{
|
||
slotStatusMsg(i18n("Creating new Mixed Mode CD Project."));
|
||
|
||
- K3b::Doc* doc = k3bappcore->projectManager()->createProject( K3b::Doc::MIXED );
|
||
+ K3b::Doc* doc = k3bappcore->projectManager()->createProject( K3b::Doc::MixedProject );
|
||
|
||
return doc;
|
||
}
|
||
@@ -1099,7 +1099,7 @@
|
||
{
|
||
slotStatusMsg(i18n("Creating new Video CD Project."));
|
||
|
||
- K3b::Doc* doc = k3bappcore->projectManager()->createProject( K3b::Doc::VCD );
|
||
+ K3b::Doc* doc = k3bappcore->projectManager()->createProject( K3b::Doc::VcdProject );
|
||
|
||
return doc;
|
||
}
|
||
@@ -1109,7 +1109,7 @@
|
||
{
|
||
slotStatusMsg(i18n("Creating new eMovix Project."));
|
||
|
||
- K3b::Doc* doc = k3bappcore->projectManager()->createProject( K3b::Doc::MOVIX );
|
||
+ K3b::Doc* doc = k3bappcore->projectManager()->createProject( K3b::Doc::MovixProject );
|
||
|
||
return doc;
|
||
}
|
||
diff -ru src/k3b.desktop src/k3b.desktop
|
||
--- src/k3b.desktop 2009-05-22 15:37:17.000000000 +0200
|
||
+++ src/k3b.desktop 2009-07-23 11:42:05.000000000 +0200
|
||
@@ -22,6 +22,7 @@
|
||
GenericName[he]=צריבת CD ו- DVD
|
||
GenericName[hne]=सीडी अउ डीवीडी बर्निंग
|
||
GenericName[hsb]=Palenje CD & DVD
|
||
+GenericName[it]=Masterizzazione CD e DVD
|
||
GenericName[ja]=CD / DVD 作成
|
||
GenericName[km]=ការដុតស៊ីឌី និងឌីវីឌី
|
||
GenericName[ko]=CD와 DVD 쓰기
|
||
@@ -45,6 +46,7 @@
|
||
GenericName[uk]=Записування КД і DVD
|
||
GenericName[x-test]=xxCD & DVD Burningxx
|
||
GenericName[zh_CN]=CD & DVD 刻录程序
|
||
+GenericName[zh_TW]=燒錄 CD 與 DVD
|
||
Comment=CD writing program
|
||
Comment[be]=Праграма запісу CD
|
||
Comment[bg]=Програма за запис на CD
|
||
@@ -65,6 +67,7 @@
|
||
Comment[he]=תוכנת כתיבת CD
|
||
Comment[hne]=सीडी लिखइया प्रोग्राम
|
||
Comment[hsb]=Program za pisanje CDow
|
||
+Comment[it]=Programma di masterizzazione CD
|
||
Comment[ja]=CD 書き込みプログラム
|
||
Comment[km]=កម្មវិធីសរសេរស៊ីឌី
|
||
Comment[ko]=CD 쓰기 프로그램
|
||
@@ -88,6 +91,7 @@
|
||
Comment[uk]=Програма запису КД
|
||
Comment[x-test]=xxCD writing programxx
|
||
Comment[zh_CN]=CD 刻录程序
|
||
+Comment[zh_TW]=CD 燒錄程式
|
||
Terminal=false
|
||
Name=K3b
|
||
Name[hi]=के3बी
|
||
diff -ru src/k3bfiletreeview.cpp src/k3bfiletreeview.cpp
|
||
--- src/k3bfiletreeview.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/k3bfiletreeview.cpp 2009-07-23 11:42:05.000000000 +0200
|
||
@@ -276,6 +276,7 @@
|
||
header()->hide();
|
||
|
||
setContextMenuPolicy( Qt::CustomContextMenu );
|
||
+ setEditTriggers( QAbstractItemView::NoEditTriggers );
|
||
setSelectionMode(QAbstractItemView::SingleSelection);
|
||
// setSortingEnabled( true );
|
||
// setRootIsDecorated( false );
|
||
@@ -296,10 +297,6 @@
|
||
connect( d->model, SIGNAL( expand( const QModelIndex& ) ),
|
||
this, SLOT( slotExpandUrl( const QModelIndex& ) ) );
|
||
|
||
- // add the default places
|
||
- d->model->addPlace( i18n( "Home" ), KIcon("user-home"), QDir::homePath() );
|
||
- d->model->addPlace( i18n( "Root" ), KIcon("folder-red"), KUrl( "/" ) );
|
||
-
|
||
connect( this, SIGNAL(clicked(const QModelIndex&)), SLOT(slotClicked(const QModelIndex&)) );
|
||
connect( this, SIGNAL(customContextMenuRequested( const QPoint& )), SLOT( slotContextMenu( const QPoint& ) ) );
|
||
}
|
||
diff -ru src/k3bmetaitemmodel.cpp src/k3bmetaitemmodel.cpp
|
||
--- src/k3bmetaitemmodel.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/k3bmetaitemmodel.cpp 2009-07-23 11:42:05.000000000 +0200
|
||
@@ -324,6 +324,16 @@
|
||
}
|
||
|
||
|
||
+QModelIndex K3b::MetaItemModel::indexForSubModel( QAbstractItemModel* model ) const
|
||
+{
|
||
+ if( !d->places.empty() ) {
|
||
+ if( Place* place = d->placeForModel( model ) )
|
||
+ return createIndex( place->row, 0, place );
|
||
+ }
|
||
+ return QModelIndex();
|
||
+}
|
||
+
|
||
+
|
||
QAbstractItemModel* K3b::MetaItemModel::subModelForIndex( const QModelIndex& index ) const
|
||
{
|
||
if ( index.isValid() ) {
|
||
diff -ru src/k3bmetaitemmodel.h src/k3bmetaitemmodel.h
|
||
--- src/k3bmetaitemmodel.h 2009-05-26 11:39:57.000000000 +0200
|
||
+++ src/k3bmetaitemmodel.h 2009-07-23 11:42:05.000000000 +0200
|
||
@@ -41,6 +41,7 @@
|
||
MetaItemModel( QObject* parent = 0 );
|
||
~MetaItemModel();
|
||
|
||
+ QModelIndex indexForSubModel( QAbstractItemModel* model ) const;
|
||
QAbstractItemModel* subModelForIndex( const QModelIndex& index ) const;
|
||
|
||
/**
|
||
diff -ru src/k3b.notifyrc src/k3b.notifyrc
|
||
--- src/k3b.notifyrc 2009-05-03 15:17:04.000000000 +0200
|
||
+++ src/k3b.notifyrc 2009-07-23 11:42:05.000000000 +0200
|
||
@@ -25,6 +25,7 @@
|
||
Name[hi]=प्रक्रिया सफल
|
||
Name[hne]=काम सफल
|
||
Name[hsb]=Proces wuspěšny
|
||
+Name[it]=Processo riuscito
|
||
Name[ja]=プロセス成功
|
||
Name[km]=ដំណើរការដោយជោគជ័យ
|
||
Name[ko]=진행 성공
|
||
@@ -48,6 +49,7 @@
|
||
Name[uk]=Процес успішний
|
||
Name[x-test]=xxProcess successfulxx
|
||
Name[zh_CN]=处理成功
|
||
+Name[zh_TW]=行程成功
|
||
Comment=Process successfully finished
|
||
Comment[bg]=Процесът завърши успешно
|
||
Comment[cs]=Proces úspěšně dokončen
|
||
@@ -65,6 +67,7 @@
|
||
Comment[he]=תהליך הסתיים בהצלחה
|
||
Comment[hne]=काम सफलता के साथ पूरा
|
||
Comment[hsb]=Proces wuspěšnje zakónčeny
|
||
+Comment[it]=Processo terminato correttamente
|
||
Comment[ja]=プロセスが正常に終了しました
|
||
Comment[km]=បានបញ្ចប់ដំណើរការដោយជោគជ័យ
|
||
Comment[ko]=진행이 성공적으로 끝났습니다
|
||
@@ -88,6 +91,7 @@
|
||
Comment[uk]=Процес закінчився успішно
|
||
Comment[x-test]=xxProcess successfully finishedxx
|
||
Comment[zh_CN]=处理成功完成
|
||
+Comment[zh_TW]=行程已成功結束
|
||
Sound=k3b_success1.wav
|
||
Action=Sound
|
||
|
||
@@ -110,6 +114,7 @@
|
||
Name[hi]=प्रक्रिया त्रुटि
|
||
Name[hne]=काम गलती
|
||
Name[hsb]=Zmylk procesa
|
||
+Name[it]=Errore del processo
|
||
Name[ja]=プロセスエラー
|
||
Name[km]=កំហុសដំណើរការ
|
||
Name[ko]=진행 오류
|
||
@@ -133,6 +138,7 @@
|
||
Name[uk]=Помилка процесу
|
||
Name[x-test]=xxProcess errorxx
|
||
Name[zh_CN]=处理错误
|
||
+Name[zh_TW]=行程發生錯誤
|
||
Comment=Process finished with errors
|
||
Comment[bg]=Процесът завърши с грешки
|
||
Comment[cs]=Proces ukončen s chybami
|
||
@@ -151,6 +157,7 @@
|
||
Comment[hi]=प्रक्रिया त्रुटि के साथ पूर्ण
|
||
Comment[hne]=काम गलती के साथ पूरा
|
||
Comment[hsb]=Proces ze zmylkami zakónčeny
|
||
+Comment[it]=Processo terminato con errori
|
||
Comment[ja]=プロセスがエラーで終了しました
|
||
Comment[km]=បានបញ្ចប់ដំណើរការ ដោយមានកំហុស
|
||
Comment[ko]=진행 중 오류가 발생했습니다
|
||
@@ -174,6 +181,7 @@
|
||
Comment[uk]=Процес закінчився з помилками
|
||
Comment[x-test]=xxProcess finished with errorsxx
|
||
Comment[zh_CN]=处理完成,有错误
|
||
+Comment[zh_TW]=行程已完成,但是發生錯誤
|
||
Sound=k3b_error1.wav
|
||
Action=Sound
|
||
|
||
@@ -196,6 +204,7 @@
|
||
Name[he]=מחכה למדיה
|
||
Name[hne]=मीडियम के इंतजार करत हे
|
||
Name[hsb]=Čakam na medium
|
||
+Name[it]=Si è in attesa di un supporto
|
||
Name[ja]=メディア待ち
|
||
Name[km]=រង់ចាំឧបករណ៍ផ្ទុក
|
||
Name[ko]=미디어 기다리는 중
|
||
@@ -219,6 +228,7 @@
|
||
Name[uk]=Очікування носія
|
||
Name[x-test]=xxWaiting for mediumxx
|
||
Name[zh_CN]=正在等待存储介质
|
||
+Name[zh_TW]=等候媒體中
|
||
Comment=The user needs to insert a medium
|
||
Comment[bg]=Потребителят трябва да постави диск в устройството
|
||
Comment[cs]=Uživatel musí vložit médium
|
||
@@ -236,6 +246,7 @@
|
||
Comment[he]=המשתמש צריך להכניס מדיה
|
||
Comment[hne]=कमइया ल एक मीडियम डालना पड़ही
|
||
Comment[hsb]=Wužiwar dyrbi medium do palaka tyknyć
|
||
+Comment[it]=L'utente deve inserire un supporto
|
||
Comment[ja]=ユーザがメディアを挿入する必要があります
|
||
Comment[km]=អ្នកប្រើត្រូវបញ្ចូលឧបករណ៍ផ្ទុក
|
||
Comment[ko]=사용자가 미디어를 삽입해야 합니다
|
||
@@ -259,5 +270,6 @@
|
||
Comment[uk]=Користувач повинен вставити носій
|
||
Comment[x-test]=xxThe user needs to insert a mediumxx
|
||
Comment[zh_CN]=用户需要插入存储介质
|
||
+Comment[zh_TW]=使用者需要插入媒體
|
||
Sound=k3b_wait_media1.wav
|
||
Action=Sound
|
||
diff -ru src/k3bplacesmodel.cpp src/k3bplacesmodel.cpp
|
||
--- src/k3bplacesmodel.cpp 2009-05-26 23:58:58.000000000 +0200
|
||
+++ src/k3bplacesmodel.cpp 2009-07-23 11:42:05.000000000 +0200
|
||
@@ -22,14 +22,20 @@
|
||
#include <KDirModel>
|
||
#include <kdirsortfilterproxymodel.h> // use .h to build with KDE 4.2
|
||
#include <KDirLister>
|
||
+#include <KFilePlacesModel>
|
||
#include <KIcon>
|
||
+#include <Solid/StorageAccess>
|
||
+
|
||
+
|
||
+typedef QMap<KDirModel*, KDirSortFilterProxyModel*> DirModels;
|
||
|
||
|
||
class K3b::PlacesModel::Private
|
||
{
|
||
public:
|
||
K3b::DeviceModel* deviceModel;
|
||
- QMap<KDirModel*, KDirSortFilterProxyModel*> dirModels;
|
||
+ KFilePlacesModel* filePlacesModel;
|
||
+ DirModels dirModels;
|
||
};
|
||
|
||
|
||
@@ -39,7 +45,24 @@
|
||
d( new Private() )
|
||
{
|
||
d->deviceModel = new K3b::DeviceModel( this );
|
||
+ d->filePlacesModel = new KFilePlacesModel( this );
|
||
addSubModel( "Devices", KIcon( "media-optical" ), d->deviceModel, true );
|
||
+
|
||
+ // TODO: Currently our place list doesn't follow changes KFilePlacesModel.
|
||
+ // This needs to be changed. Adding, removing and editing places would be also nice.
|
||
+ for( int i = 0; i < d->filePlacesModel->rowCount(); ++i ) {
|
||
+ QModelIndex place = d->filePlacesModel->index( i, 0 );
|
||
+ KUrl url = d->filePlacesModel->url( place );
|
||
+
|
||
+ // Let's filter out device-related places
|
||
+ // and custom protocols (we doesn't support burning from them)
|
||
+ if( !d->filePlacesModel->isDevice( place ) && url.isLocalFile() ) {
|
||
+ addPlace(
|
||
+ d->filePlacesModel->text( place ),
|
||
+ d->filePlacesModel->icon( place ),
|
||
+ url );
|
||
+ }
|
||
+ }
|
||
|
||
connect( d->deviceModel, SIGNAL( modelAboutToBeReset() ),
|
||
this, SIGNAL( modelAboutToBeReset() ) );
|
||
@@ -87,26 +110,43 @@
|
||
void K3b::PlacesModel::expandToUrl( const KUrl& url )
|
||
{
|
||
kDebug() << url;
|
||
+
|
||
+ // Check if url is not device's
|
||
+ Q_FOREACH( Device::Device* device, d->deviceModel->devices() )
|
||
+ {
|
||
+ if( Solid::StorageAccess* solidStorage = device->solidStorage() ) {
|
||
+ KUrl parent( solidStorage->filePath() );
|
||
+ if( parent.isParentOf( url ) ) {
|
||
+ kDebug() << url << " will be expanded to device " << device->description();
|
||
+ emit expand( mapFromSubModel( d->deviceModel->indexForDevice( device ) ) );
|
||
+ return;
|
||
+ }
|
||
+ }
|
||
+ }
|
||
|
||
// search for the best suited place that contains this URL
|
||
int maxDepth = 0;
|
||
KDirModel* modelToExpand = 0;
|
||
|
||
- for( QMap<KDirModel*, KDirSortFilterProxyModel*>::iterator it = d->dirModels.begin();
|
||
- it != d->dirModels.end(); ++it ) {
|
||
+ for( DirModels::iterator it = d->dirModels.begin(); it != d->dirModels.end(); ++it ) {
|
||
KDirModel* model = it.key();
|
||
- KUrl url = model->dirLister()->url();
|
||
- if ( url.isParentOf( url ) ) {
|
||
- if ( url.path().length() > maxDepth ) {
|
||
- maxDepth = url.path().length();
|
||
+ KUrl parent = model->dirLister()->url();
|
||
+ if ( parent.isParentOf( url ) ) {
|
||
+ if ( parent.path().length() > maxDepth ) {
|
||
+ maxDepth = parent.path().length();
|
||
modelToExpand = model;
|
||
}
|
||
}
|
||
}
|
||
|
||
if ( modelToExpand ) {
|
||
- kDebug() << modelToExpand->dirLister()->url() << "will be expanded.";
|
||
- modelToExpand->expandToUrl( url );
|
||
+ kDebug() << modelToExpand->dirLister()->url() << " will be expanded.";
|
||
+ if( modelToExpand->dirLister()->url().equals( url, KUrl::CompareWithoutTrailingSlash ) ) {
|
||
+ emit expand( indexForSubModel( d->dirModels[ modelToExpand ] ) );
|
||
+ }
|
||
+ else {
|
||
+ modelToExpand->expandToUrl( url );
|
||
+ }
|
||
}
|
||
}
|
||
|
||
diff -ru src/k3bprojectmanager.cpp src/k3bprojectmanager.cpp
|
||
--- src/k3bprojectmanager.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/k3bprojectmanager.cpp 2009-07-23 11:42:05.000000000 +0200
|
||
@@ -179,7 +179,7 @@
|
||
}
|
||
|
||
|
||
-K3b::Doc* K3b::ProjectManager::createEmptyProject( K3b::Doc::DocType type )
|
||
+K3b::Doc* K3b::ProjectManager::createEmptyProject( K3b::Doc::Type type )
|
||
{
|
||
kDebug() << type;
|
||
|
||
@@ -187,37 +187,37 @@
|
||
QString fileName;
|
||
|
||
switch( type ) {
|
||
- case K3b::Doc::AUDIO: {
|
||
+ case K3b::Doc::AudioProject: {
|
||
doc = new K3b::AudioDoc( this );
|
||
fileName = i18n("AudioCD%1",d->audioUntitledCount++);
|
||
break;
|
||
}
|
||
|
||
- case K3b::Doc::DATA: {
|
||
+ case K3b::Doc::DataProject: {
|
||
doc = new K3b::DataDoc( this );
|
||
fileName = i18n("Data%1",d->dataUntitledCount++);
|
||
break;
|
||
}
|
||
|
||
- case K3b::Doc::MIXED: {
|
||
+ case K3b::Doc::MixedProject: {
|
||
doc = new K3b::MixedDoc( this );
|
||
fileName=i18n("MixedCD%1",d->mixedUntitledCount++);
|
||
break;
|
||
}
|
||
|
||
- case K3b::Doc::VCD: {
|
||
+ case K3b::Doc::VcdProject: {
|
||
doc = new K3b::VcdDoc( this );
|
||
fileName=i18n("VideoCD%1",d->vcdUntitledCount++);
|
||
break;
|
||
}
|
||
|
||
- case K3b::Doc::MOVIX: {
|
||
+ case K3b::Doc::MovixProject: {
|
||
doc = new K3b::MovixDoc( this );
|
||
fileName=i18n("eMovix%1",d->movixUntitledCount++);
|
||
break;
|
||
}
|
||
|
||
- case K3b::Doc::VIDEODVD: {
|
||
+ case K3b::Doc::VideoDvdProject: {
|
||
doc = new K3b::VideoDvdDoc( this );
|
||
fileName = i18n("VideoDVD%1",d->videoDvdUntitledCount++);
|
||
break;
|
||
@@ -236,7 +236,7 @@
|
||
}
|
||
|
||
|
||
-K3b::Doc* K3b::ProjectManager::createProject( K3b::Doc::DocType type )
|
||
+K3b::Doc* K3b::ProjectManager::createProject( K3b::Doc::Type type )
|
||
{
|
||
kDebug() << type;
|
||
|
||
@@ -288,7 +288,7 @@
|
||
|
||
|
||
switch( doc->type() ) {
|
||
- case K3b::Doc::AUDIO: {
|
||
+ case K3b::Doc::AudioProject: {
|
||
K3b::AudioDoc* audioDoc = static_cast<K3b::AudioDoc*>(doc);
|
||
|
||
audioDoc->writeCdText( c.readEntry( "cd_text", true ) );
|
||
@@ -301,7 +301,7 @@
|
||
break;
|
||
}
|
||
|
||
- case K3b::Doc::MOVIX: {
|
||
+ case K3b::Doc::MovixProject: {
|
||
K3b::MovixDoc* movixDoc = static_cast<K3b::MovixDoc*>(doc);
|
||
|
||
movixDoc->setSubtitleFontset( c.readEntry("subtitle_fontset") );
|
||
@@ -322,7 +322,7 @@
|
||
// fallthrough
|
||
}
|
||
|
||
- case K3b::Doc::DATA: {
|
||
+ case K3b::Doc::DataProject: {
|
||
K3b::DataDoc* dataDoc = static_cast<K3b::DataDoc*>(doc);
|
||
|
||
dataDoc->setIsoOptions( K3b::IsoOptions::load( c, false ) );
|
||
@@ -352,7 +352,7 @@
|
||
break;
|
||
}
|
||
|
||
- case K3b::Doc::VIDEODVD: {
|
||
+ case K3b::Doc::VideoDvdProject: {
|
||
// the only defaults we need here are the volume id and stuff
|
||
K3b::DataDoc* dataDoc = static_cast<K3b::DataDoc*>(doc);
|
||
dataDoc->setIsoOptions( K3b::IsoOptions::load( c, false ) );
|
||
@@ -360,7 +360,7 @@
|
||
break;
|
||
}
|
||
|
||
- case K3b::Doc::MIXED: {
|
||
+ case K3b::Doc::MixedProject: {
|
||
K3b::MixedDoc* mixedDoc = static_cast<K3b::MixedDoc*>(doc);
|
||
|
||
mixedDoc->audioDoc()->writeCdText( c.readEntry( "cd_text", true ) );
|
||
@@ -390,7 +390,7 @@
|
||
break;
|
||
}
|
||
|
||
- case K3b::Doc::VCD: {
|
||
+ case K3b::Doc::VcdProject: {
|
||
K3b::VcdDoc* vcdDoc = static_cast<K3b::VcdDoc*>(doc);
|
||
|
||
// FIXME: I think we miss a lot here!
|
||
@@ -407,9 +407,9 @@
|
||
}
|
||
}
|
||
|
||
- if( doc->type() == K3b::Doc::DATA ||
|
||
- doc->type() == K3b::Doc::MOVIX ||
|
||
- doc->type() == K3b::Doc::VIDEODVD ) {
|
||
+ if( doc->type() == K3b::Doc::DataProject ||
|
||
+ doc->type() == K3b::Doc::MovixProject ||
|
||
+ doc->type() == K3b::Doc::VideoDvdProject ) {
|
||
if( static_cast<K3b::DataDoc*>(doc)->isoOptions().volumeID().isEmpty() )
|
||
static_cast<K3b::DataDoc*>(doc)->setVolumeID( doc->URL().fileName() );
|
||
}
|
||
@@ -507,23 +507,23 @@
|
||
}
|
||
|
||
// check the documents DOCTYPE
|
||
- K3b::Doc::DocType type = K3b::Doc::AUDIO;
|
||
+ K3b::Doc::Type type = K3b::Doc::AudioProject;
|
||
if( xmlDoc.doctype().name() == "k3b_audio_project" )
|
||
- type = K3b::Doc::AUDIO;
|
||
+ type = K3b::Doc::AudioProject;
|
||
else if( xmlDoc.doctype().name() == "k3b_data_project" )
|
||
- type = K3b::Doc::DATA;
|
||
+ type = K3b::Doc::DataProject;
|
||
else if( xmlDoc.doctype().name() == "k3b_vcd_project" )
|
||
- type = K3b::Doc::VCD;
|
||
+ type = K3b::Doc::VcdProject;
|
||
else if( xmlDoc.doctype().name() == "k3b_mixed_project" )
|
||
- type = K3b::Doc::MIXED;
|
||
+ type = K3b::Doc::MixedProject;
|
||
else if( xmlDoc.doctype().name() == "k3b_movix_project" )
|
||
- type = K3b::Doc::MOVIX;
|
||
+ type = K3b::Doc::MovixProject;
|
||
else if( xmlDoc.doctype().name() == "k3b_movixdvd_project" )
|
||
- type = K3b::Doc::MOVIX; // backward compatibility
|
||
+ type = K3b::Doc::MovixProject; // backward compatibility
|
||
else if( xmlDoc.doctype().name() == "k3b_dvd_project" )
|
||
- type = K3b::Doc::DATA; // backward compatibility
|
||
+ type = K3b::Doc::DataProject; // backward compatibility
|
||
else if( xmlDoc.doctype().name() == "k3b_video_dvd_project" ) {
|
||
- type = K3b::Doc::VIDEODVD;
|
||
+ type = K3b::Doc::VideoDvdProject;
|
||
} else {
|
||
kDebug() << "(K3b::Doc) unknown doc type: " << xmlDoc.doctype().name();
|
||
QApplication::restoreOverrideCursor();
|
||
diff -ru src/k3bprojectmanager.h src/k3bprojectmanager.h
|
||
--- src/k3bprojectmanager.h 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/k3bprojectmanager.h 2009-07-23 11:42:05.000000000 +0200
|
||
@@ -41,7 +41,7 @@
|
||
* Create a new project including loading user defaults and creating
|
||
* the dcop interface.
|
||
*/
|
||
- Doc* createProject( Doc::DocType type );
|
||
+ Doc* createProject( Doc::Type type );
|
||
|
||
/**
|
||
* Opens a K3b project.
|
||
@@ -82,7 +82,7 @@
|
||
|
||
private:
|
||
// used internal
|
||
- Doc* createEmptyProject( Doc::DocType );
|
||
+ Doc* createEmptyProject( Doc::Type );
|
||
|
||
class Private;
|
||
Private* d;
|
||
diff -ru src/k3bstatusbarmanager.cpp src/k3bstatusbarmanager.cpp
|
||
--- src/k3bstatusbarmanager.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/k3bstatusbarmanager.cpp 2009-07-23 11:42:05.000000000 +0200
|
||
@@ -194,19 +194,19 @@
|
||
K3b::Doc* doc = k3bappcore->projectManager()->activeProject();
|
||
if( doc ) {
|
||
switch( doc->type() ) {
|
||
- case K3b::Doc::AUDIO: {
|
||
+ case K3b::Doc::AudioProject: {
|
||
K3b::AudioDoc* audioDoc = static_cast<K3b::AudioDoc*>( doc );
|
||
m_labelProjectInfo->setText( i18np("Audio CD (1 track)", "Audio CD (%1 tracks)", audioDoc->numOfTracks() ) );
|
||
break;
|
||
}
|
||
|
||
- case K3b::Doc::DATA: {
|
||
+ case K3b::Doc::DataProject: {
|
||
K3b::DataDoc* dataDoc = static_cast<K3b::DataDoc*>( doc );
|
||
m_labelProjectInfo->setText( i18n("Data Project (%1)",dataDocStats(dataDoc)) );
|
||
break;
|
||
}
|
||
|
||
- case K3b::Doc::MIXED: {
|
||
+ case K3b::Doc::MixedProject: {
|
||
K3b::AudioDoc* audioDoc = static_cast<K3b::MixedDoc*>( doc )->audioDoc();
|
||
K3b::DataDoc* dataDoc = static_cast<K3b::MixedDoc*>( doc )->dataDoc();
|
||
m_labelProjectInfo->setText( i18np("Mixed CD (1 track and %2)", "Mixed CD (%1 tracks and %2)", audioDoc->numOfTracks(),
|
||
@@ -214,19 +214,19 @@
|
||
break;
|
||
}
|
||
|
||
- case K3b::Doc::VCD: {
|
||
+ case K3b::Doc::VcdProject: {
|
||
K3b::VcdDoc* vcdDoc = static_cast<K3b::VcdDoc*>( doc );
|
||
m_labelProjectInfo->setText( i18np("Video CD (1 track)", "Video CD (%1 tracks)", vcdDoc->numOfTracks() ) );
|
||
break;
|
||
}
|
||
|
||
- case K3b::Doc::MOVIX: {
|
||
+ case K3b::Doc::MovixProject: {
|
||
K3b::DataDoc* dataDoc = static_cast<K3b::DataDoc*>( doc );
|
||
m_labelProjectInfo->setText( i18n("eMovix Project (%1)",dataDocStats(dataDoc)) );
|
||
break;
|
||
}
|
||
|
||
- case K3b::Doc::VIDEODVD: {
|
||
+ case K3b::Doc::VideoDvdProject: {
|
||
K3b::DataDoc* dataDoc = static_cast<K3b::DataDoc*>( doc );
|
||
m_labelProjectInfo->setText( i18n("Video DVD (%1)",dataDocStats(dataDoc)) );
|
||
break;
|
||
diff -ru src/k3bthememanager.cpp src/k3bthememanager.cpp
|
||
--- src/k3bthememanager.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/k3bthememanager.cpp 2009-07-23 11:42:05.000000000 +0200
|
||
@@ -236,7 +236,7 @@
|
||
|
||
void K3b::ThemeManager::setCurrentTheme( K3b::Theme* theme )
|
||
{
|
||
- if( !theme )
|
||
+ if( !theme && !d->themes.isEmpty() )
|
||
theme = d->themes.first();
|
||
|
||
if( theme ) {
|
||
diff -ru src/k3burlnavigator.cpp src/k3burlnavigator.cpp
|
||
--- src/k3burlnavigator.cpp 2009-02-22 23:39:42.000000000 +0100
|
||
+++ src/k3burlnavigator.cpp 2009-07-23 11:42:05.000000000 +0200
|
||
@@ -25,6 +25,9 @@
|
||
K3b::UrlNavigator::UrlNavigator( KFilePlacesModel* model, QWidget* parent )
|
||
: KUrlNavigator( model, KUrl(QDir::home().absolutePath()), parent )
|
||
{
|
||
+ // Curently we don't support burning from custom protocols so let's filter them out
|
||
+ KUrlNavigator::setCustomProtocols( QStringList() << "file" );
|
||
+
|
||
connect( this, SIGNAL(urlChanged(const KUrl&)), this, SLOT(urlActivated(const KUrl&)) );
|
||
}
|
||
|
||
diff -ru src/konqi/k3b_audiocd_rip.desktop src/konqi/k3b_audiocd_rip.desktop
|
||
--- src/konqi/k3b_audiocd_rip.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ src/konqi/k3b_audiocd_rip.desktop 2009-07-23 11:42:04.000000000 +0200
|
||
@@ -24,6 +24,7 @@
|
||
Name[he]=חלק שמע דיגיטלי עם K3b
|
||
Name[hne]=के३बी के साथ डिजिटल आडियो एक्सट्रेक्ट करव
|
||
Name[hsb]=Digitalne awdijo z K3b ekstrahować
|
||
+Name[it]=Estrai audio digitale con K3b
|
||
Name[ja]=K3b でデジタルオーディオを吸い出し
|
||
Name[km]=ស្រង់អូឌីយ៉ូឌីជីថល ដោយប្រើ K3b
|
||
Name[ko]=K3b로 디지털 오디오 추출하기
|
||
@@ -45,5 +46,6 @@
|
||
Name[uk]=Витягти цифрове аудіо через K3b
|
||
Name[x-test]=xxExtract Digital Audio with K3bxx
|
||
Name[zh_CN]=用 K3b 抓取数字音频
|
||
+Name[zh_TW]=用 K3b 解開數位音效
|
||
Exec=k3b --cddarip %i
|
||
Icon=k3b
|
||
diff -ru src/konqi/k3b_copy_disc.desktop src/konqi/k3b_copy_disc.desktop
|
||
--- src/konqi/k3b_copy_disc.desktop 2009-05-26 16:22:58.000000000 +0200
|
||
+++ src/konqi/k3b_copy_disc.desktop 2009-07-23 11:42:04.000000000 +0200
|
||
@@ -6,12 +6,15 @@
|
||
|
||
[Desktop Action K3bCopy]
|
||
Name=Copy with K3b
|
||
+Name[bg]=Копиране на CD с K3b
|
||
Name[da]=Kopiér med K3b
|
||
Name[de]=Mit K3b kopieren
|
||
Name[es]=Copiar con K3b
|
||
Name[et]=Kopeeri K3b abil
|
||
+Name[eu]=Kopiatu K3b-rekin
|
||
Name[fr]=Copier avec K3b
|
||
Name[ga]=Cóipeáil le K3b
|
||
+Name[it]=Copia con K3b
|
||
Name[km]=ចម្លងដោយប្រើ K3b
|
||
Name[nb]=Kopier med K3b
|
||
Name[nds]=Mit K3b koperen
|
||
@@ -25,5 +28,6 @@
|
||
Name[tr]=K3b ile Kopyala
|
||
Name[uk]=Скопіювати за допомогою K3b
|
||
Name[x-test]=xxCopy with K3bxx
|
||
+Name[zh_TW]=使用 K3b 複製
|
||
Exec=k3b --copy %i
|
||
Icon=k3b
|
||
diff -ru src/konqi/k3b_create_audio_cd.desktop src/konqi/k3b_create_audio_cd.desktop
|
||
--- src/konqi/k3b_create_audio_cd.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ src/konqi/k3b_create_audio_cd.desktop 2009-07-23 11:42:04.000000000 +0200
|
||
@@ -8,7 +8,7 @@
|
||
[Desktop Action CreateK3bAudioProject]
|
||
Exec=k3b --audiocd %F
|
||
Name=Create Audio CD with K3b...
|
||
-Name[bg]=Създаване на аудио CD с K3b...
|
||
+Name[bg]=Създаване на звуков диск с K3b...
|
||
Name[ca]=Crea un CD d'àudio amb el K3b...
|
||
Name[cs]=Vytvořit zvukové CD...
|
||
Name[csb]=Ùsôdzë platã CD audio z pòmòcą K3b...
|
||
@@ -27,6 +27,7 @@
|
||
Name[hi]=के3बी के जरिए ऑडियो सीडी बनाएं....
|
||
Name[hne]=के3बी के साथ आडियो सीडी बनाव....
|
||
Name[hsb]=awdijo-CD z K3b stworić
|
||
+Name[it]=Crea CD audio con K3b...
|
||
Name[ja]=K3b でオーディオ CD を作成...
|
||
Name[km]=បង្កើតស៊ីឌីអូឌីយ៉ូដោយប្រើ K3b...
|
||
Name[ko]=K3b로 오디오 CD 만들기...
|
||
@@ -50,4 +51,5 @@
|
||
Name[uk]=Створити аудіо-КД через K3b...
|
||
Name[x-test]=xxCreate Audio CD with K3b...xx
|
||
Name[zh_CN]=用 K3b 创建音频 CD...
|
||
+Name[zh_TW]=用 K3b 建立音效 CD...
|
||
Icon=k3b
|
||
diff -ru src/konqi/k3b_create_audio_cd_from_blank_medium.desktop src/konqi/k3b_create_audio_cd_from_blank_medium.desktop
|
||
--- src/konqi/k3b_create_audio_cd_from_blank_medium.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ src/konqi/k3b_create_audio_cd_from_blank_medium.desktop 2009-07-23 11:42:04.000000000 +0200
|
||
@@ -1,5 +1,5 @@
|
||
[Desktop Entry]
|
||
-X-KDE-Solid-Predicate=[[StorageVolume.ignored == false AND OpticalDisc.isBlank == true ] AND OpticalDisc.discType == 'CdRecordable|CdRewritable']
|
||
+X-KDE-Solid-Predicate=[[StorageVolume.ignored == false AND OpticalDisc.blank == true ] AND OpticalDisc.discType == 'CdRecordable|CdRewritable']
|
||
Actions=K3bAudioCDProject;
|
||
Type=Service
|
||
X-KDE-Priority=TopLevel
|
||
@@ -7,7 +7,7 @@
|
||
[Desktop Action K3bAudioCDProject]
|
||
Exec=k3b --device %i --audiocd
|
||
Name=Create Audio CD with K3b...
|
||
-Name[bg]=Създаване на аудио CD с K3b...
|
||
+Name[bg]=Създаване на звуков диск с K3b...
|
||
Name[ca]=Crea un CD d'àudio amb el K3b...
|
||
Name[cs]=Vytvořit zvukové CD...
|
||
Name[csb]=Ùsôdzë platã CD audio z pòmòcą K3b...
|
||
@@ -26,6 +26,7 @@
|
||
Name[hi]=के3बी के जरिए ऑडियो सीडी बनाएं....
|
||
Name[hne]=के3बी के साथ आडियो सीडी बनाव....
|
||
Name[hsb]=awdijo-CD z K3b stworić
|
||
+Name[it]=Crea CD audio con K3b...
|
||
Name[ja]=K3b でオーディオ CD を作成...
|
||
Name[km]=បង្កើតស៊ីឌីអូឌីយ៉ូដោយប្រើ K3b...
|
||
Name[ko]=K3b로 오디오 CD 만들기...
|
||
@@ -49,4 +50,5 @@
|
||
Name[uk]=Створити аудіо-КД через K3b...
|
||
Name[x-test]=xxCreate Audio CD with K3b...xx
|
||
Name[zh_CN]=用 K3b 创建音频 CD...
|
||
+Name[zh_TW]=用 K3b 建立音效 CD...
|
||
Icon=k3b
|
||
diff -ru src/konqi/k3b_create_data_project.desktop src/konqi/k3b_create_data_project.desktop
|
||
--- src/konqi/k3b_create_data_project.desktop 2009-05-26 16:22:58.000000000 +0200
|
||
+++ src/konqi/k3b_create_data_project.desktop 2009-07-23 11:42:04.000000000 +0200
|
||
@@ -8,12 +8,15 @@
|
||
[Desktop Action CreateK3bDataProject]
|
||
Exec=k3b --data %F
|
||
Name=Create file project with K3b...
|
||
+Name[bg]=Създаване диск с файлове с K3b...
|
||
Name[da]=Opret filprojekt med K3b...
|
||
Name[de]=Daten-CD mit K3b erstellen ...
|
||
Name[es]=Crear proyecto de archivo con K3b...
|
||
Name[et]=Loo failiprojekt K3b abil...
|
||
+Name[eu]=Sortu fitxategi-proiektua K3b-rekin...
|
||
Name[fr]=Créer un projet avec K3b...
|
||
Name[ga]=Cruthaigh tionscadal comhaid le K3b...
|
||
+Name[it]=Crea file di progetto con K3b...
|
||
Name[km]=បង្កើតគម្រោងឯកសារដោយប្រើ K3b...
|
||
Name[nb]=Lag filprosjekt med K3b …
|
||
Name[nds]=Dateiprojekt mit K3b opstellen...
|
||
@@ -27,4 +30,5 @@
|
||
Name[tr]=K3b ile dosya projesi oluştur...
|
||
Name[uk]=Створити файловий проект за допомогою K3b...
|
||
Name[x-test]=xxCreate file project with K3b...xx
|
||
+Name[zh_TW]=用 K3b 建立檔案專案...
|
||
Icon=k3b
|
||
diff -ru src/konqi/k3b_create_data_project_from_blank_medium.desktop src/konqi/k3b_create_data_project_from_blank_medium.desktop
|
||
--- src/konqi/k3b_create_data_project_from_blank_medium.desktop 2009-05-26 16:22:58.000000000 +0200
|
||
+++ src/konqi/k3b_create_data_project_from_blank_medium.desktop 2009-07-23 11:42:04.000000000 +0200
|
||
@@ -1,5 +1,5 @@
|
||
[Desktop Entry]
|
||
-X-KDE-Solid-Predicate=[StorageVolume.ignored == false AND OpticalDisc.isBlank == true]
|
||
+X-KDE-Solid-Predicate=[StorageVolume.ignored == false AND OpticalDisc.blank == true]
|
||
Actions=K3bDataProject;
|
||
Type=Service
|
||
X-KDE-Priority=TopLevel
|
||
@@ -7,12 +7,15 @@
|
||
[Desktop Action K3bDataProject]
|
||
Exec=k3b --device %i --data
|
||
Name=Create file project with K3b...
|
||
+Name[bg]=Създаване диск с файлове с K3b...
|
||
Name[da]=Opret filprojekt med K3b...
|
||
Name[de]=Daten-CD mit K3b erstellen ...
|
||
Name[es]=Crear proyecto de archivo con K3b...
|
||
Name[et]=Loo failiprojekt K3b abil...
|
||
+Name[eu]=Sortu fitxategi-proiektua K3b-rekin...
|
||
Name[fr]=Créer un projet avec K3b...
|
||
Name[ga]=Cruthaigh tionscadal comhaid le K3b...
|
||
+Name[it]=Crea file di progetto con K3b...
|
||
Name[km]=បង្កើតគម្រោងឯកសារដោយប្រើ K3b...
|
||
Name[nb]=Lag filprosjekt med K3b …
|
||
Name[nds]=Dateiprojekt mit K3b opstellen...
|
||
@@ -26,4 +29,5 @@
|
||
Name[tr]=K3b ile dosya projesi oluştur...
|
||
Name[uk]=Створити файловий проект за допомогою K3b...
|
||
Name[x-test]=xxCreate file project with K3b...xx
|
||
+Name[zh_TW]=用 K3b 建立檔案專案...
|
||
Icon=k3b
|
||
diff -ru src/konqi/k3b_create_video_cd.desktop src/konqi/k3b_create_video_cd.desktop
|
||
--- src/konqi/k3b_create_video_cd.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ src/konqi/k3b_create_video_cd.desktop 2009-07-23 11:42:04.000000000 +0200
|
||
@@ -26,6 +26,7 @@
|
||
Name[hi]=के3बी के जरिए वीडियो सीडी बनाएं....
|
||
Name[hne]=के3बी के साथ वीडियो सीडी बनाव....
|
||
Name[hsb]=Widejo-CDku z K3b stworić ...
|
||
+Name[it]=Crea Video CD con K3b...
|
||
Name[ja]=K3b でビデオ CD を作成...
|
||
Name[km]=បង្កើតវីដេអូស៊ីឌី ដោយប្រើ K3b...
|
||
Name[ko]=K3b로 비디오 CD 만들기...
|
||
@@ -49,4 +50,5 @@
|
||
Name[uk]=Створити відео-КД через K3b...
|
||
Name[x-test]=xxCreate Video CD with K3b...xx
|
||
Name[zh_CN]=用 K3b 创建 VCD...
|
||
+Name[zh_TW]=用 K3b 建立影像 CD...
|
||
Icon=k3b
|
||
diff -ru src/konqi/k3b_dvd_copy.desktop src/konqi/k3b_dvd_copy.desktop
|
||
--- src/konqi/k3b_dvd_copy.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ src/konqi/k3b_dvd_copy.desktop 2009-07-23 11:42:04.000000000 +0200
|
||
@@ -24,6 +24,7 @@
|
||
Name[he]=העתק DVD עם K3b
|
||
Name[hne]=के३बी के साथ डीवीडी नकल बनाव
|
||
Name[hsb]=DVD z K3b kopěrować
|
||
+Name[it]=Copia DVD con K3b
|
||
Name[ja]=K3b で DVD をコピー...
|
||
Name[km]=ចម្លងឌីវីឌី ដោយប្រើ K3b
|
||
Name[ko]=K3b로 DVD 복사하기
|
||
@@ -46,5 +47,6 @@
|
||
Name[uk]=Скопіювати DVD через K3b
|
||
Name[x-test]=xxCopy DVD with K3bxx
|
||
Name[zh_CN]=用 K3b 复制 DVD
|
||
+Name[zh_TW]=用 K3b 複製 DVD
|
||
Exec=k3b --copydvd %u
|
||
Icon=k3b
|
||
diff -ru src/konqi/k3b_videodvd_rip.desktop src/konqi/k3b_videodvd_rip.desktop
|
||
--- src/konqi/k3b_videodvd_rip.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ src/konqi/k3b_videodvd_rip.desktop 2009-07-23 11:42:04.000000000 +0200
|
||
@@ -24,6 +24,7 @@
|
||
Name[he]=קריעת כותר וידאו DVD עם K3b
|
||
Name[hne]=के3बी के साथ वीडियो डीवीडी रिप करव....
|
||
Name[hsb]=Dźěle widejo-DVDki z K3b ekstrahować
|
||
+Name[it]=Estrai i titoli DVD video con K3b
|
||
Name[ja]=K3b で DVD タイトルを吸い出し...
|
||
Name[km]=ច្រៀកចំណងជើងឌីវីឌីវីដេអូស ដោយប្រើ K3b
|
||
Name[ko]=K3b로 비디오 DVD 타이틀 추출하기
|
||
@@ -45,5 +46,6 @@
|
||
Name[uk]=Видерти відео DVD з K3b
|
||
Name[x-test]=xxRip Video DVD Titles with K3bxx
|
||
Name[zh_CN]=用 K3b 提取视频 DVD
|
||
+Name[zh_TW]=用 K3b 擷取影像 DVD 標題
|
||
Exec=k3b --videodvdrip %i
|
||
Icon=k3b
|
||
diff -ru src/konqi/k3b_write_bin_image.desktop src/konqi/k3b_write_bin_image.desktop
|
||
--- src/konqi/k3b_write_bin_image.desktop 2009-05-03 15:17:04.000000000 +0200
|
||
+++ src/konqi/k3b_write_bin_image.desktop 2009-07-23 11:42:04.000000000 +0200
|
||
@@ -18,7 +18,7 @@
|
||
Name[eo]=Skribi KD imagon per K3b...
|
||
Name[es]=Escribir imagen de CD con K3b...
|
||
Name[et]=Kirjuta CD-tõmmis K3b abil plaadile...
|
||
-Name[eu]=Idatzi CD irudia K3b-rekin...
|
||
+Name[eu]=Grabatu CD irudia K3b-rekin...
|
||
Name[fi]=Polta levykuva cd-levylle K3b:llä...
|
||
Name[fr]=Graver une image CD avec K3b...
|
||
Name[ga]=Scríobh Íomhá Dhlúthdhiosca le K3b...
|
||
@@ -27,6 +27,7 @@
|
||
Name[hi]=के3बी के जरिए इमेज सीडी पर लिखें....
|
||
Name[hne]=के3बी के साथ इमेज सीडी मं लिखव....
|
||
Name[hsb]=CD-image z K3b pisać ...
|
||
+Name[it]=Scrivi immagine CD con K3b...
|
||
Name[ja]=K3b で CD イメージを書き込み...
|
||
Name[km]=សរសេររូបភាពស៊ីឌី ដោយប្រើ K3b...
|
||
Name[ko]=K3b로 CD 이미지 쓰기...
|
||
@@ -50,4 +51,5 @@
|
||
Name[uk]=Записати штамп КД через K3b...
|
||
Name[x-test]=xxWrite CD Image with K3b...xx
|
||
Name[zh_CN]=用 K3b 刻录 CD 映像...
|
||
+Name[zh_TW]=用 K3b 寫入 CD 映像檔...
|
||
Icon=k3b
|
||
diff -ru src/konqi/k3b_write_iso_image.desktop src/konqi/k3b_write_iso_image.desktop
|
||
--- src/konqi/k3b_write_iso_image.desktop 2009-05-26 16:22:58.000000000 +0200
|
||
+++ src/konqi/k3b_write_iso_image.desktop 2009-07-23 11:42:04.000000000 +0200
|
||
@@ -7,15 +7,18 @@
|
||
[Desktop Action WriteCdImage]
|
||
Exec=k3b --image %F
|
||
Name=Write image to disc with K3b...
|
||
+Name[bg]=Запис на дисково изображение с K3b...
|
||
Name[da]=Brænd image-fil til disk med K3b...
|
||
Name[de]=Abbild mit K3b brennen ...
|
||
Name[es]=Escribir imagen a disco con K3b...
|
||
Name[et]=Kirjuta tõmmis K3b abil plaadile...
|
||
+Name[eu]=Grabatu irudia diskoan K3b-rekin...
|
||
Name[fr]=Écrire une image vers le disque avec K3b...
|
||
Name[ga]=Scríobh íomhá go dtí an diosca le K3b...
|
||
+Name[it]=Scrivi immagine su disco con K3b...
|
||
Name[km]=សរសេររូបភាពទៅថាសដោយប្រើ K3b...
|
||
Name[nb]=Skriv bilde til harddisk med K3b …
|
||
-Name[nds]=Afbild mit K3b op Fastplaat schrieven...
|
||
+Name[nds]=Afbild mit K3b na Fastplaat schrieven...
|
||
Name[nl]=Image naar schijf schrijven met K3b...
|
||
Name[pt]=Gravar uma imagem no disco com o K3b...
|
||
Name[pt_BR]=Gravar imagem para disco com o K3b...
|
||
@@ -26,4 +29,5 @@
|
||
Name[tr]=K3b ile kalıp yazdır...
|
||
Name[uk]=Записати штамп на диск за допомогою K3b...
|
||
Name[x-test]=xxWrite image to disc with K3b...xx
|
||
+Name[zh_TW]=用 K3b 寫入光碟映像檔到磁碟中...
|
||
Icon=k3b
|
||
diff -ru src/misc/k3bimagewritingdialog.cpp src/misc/k3bimagewritingdialog.cpp
|
||
--- src/misc/k3bimagewritingdialog.cpp 2009-04-21 23:00:49.000000000 +0200
|
||
+++ src/misc/k3bimagewritingdialog.cpp 2009-07-23 11:42:00.000000000 +0200
|
||
@@ -182,9 +182,10 @@
|
||
QString image = c.readPathEntry( "last written image", QString() );
|
||
if( QFile::exists( image ) )
|
||
m_editImagePath->setUrl( image );
|
||
+
|
||
+ m_comboRecentImages->clear();
|
||
}
|
||
|
||
- m_comboRecentImages->clear();
|
||
m_comboRecentImages->addItems( c.readPathEntry( "recent images", QStringList() ) );
|
||
}
|
||
|
||
diff -ru src/option/base_k3bmiscoptiontab.ui src/option/base_k3bmiscoptiontab.ui
|
||
--- src/option/base_k3bmiscoptiontab.ui 2009-03-21 22:55:41.000000000 +0100
|
||
+++ src/option/base_k3bmiscoptiontab.ui 2009-07-23 11:42:03.000000000 +0200
|
||
@@ -69,7 +69,7 @@
|
||
<string>Check system Configuration</string>
|
||
</property>
|
||
<property name="whatsThis" >
|
||
- <string><p>If this option is checked K3b will check the system configuration for any problems on startup and when the the user changes the settings.</string>
|
||
+ <string><p>If this option is checked K3b will check the system configuration for any problems on startup and when the user changes the settings.</string>
|
||
</property>
|
||
<property name="text" >
|
||
<string>&Check system configuration</string>
|
||
diff -ru src/option/k3badvancedoptiontab.cpp src/option/k3badvancedoptiontab.cpp
|
||
--- src/option/k3badvancedoptiontab.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/option/k3badvancedoptiontab.cpp 2009-07-23 11:42:03.000000000 +0200
|
||
@@ -106,10 +106,7 @@
|
||
"elements which allow to influence the behaviour of K3b are shown. "
|
||
"This includes the manual selection of the used burning tool "
|
||
"(Choose between cdrecord and cdrdao when writing a CD or between "
|
||
- "cdrecord and growisofs when writing a DVD/BD.) or the forcing of "
|
||
- "a medium in case K3b fails to detect it properly."
|
||
- "<p>This may be useful if one of the programs "
|
||
- "does not support the used writer."
|
||
+ "cdrecord and growisofs when writing a DVD/BD)."
|
||
"<p><b>Be aware that K3b does not support all possible tools "
|
||
"in all project types and actions.</b>") );
|
||
|
||
diff -ru src/projects/k3baudioview.cpp src/projects/k3baudioview.cpp
|
||
--- src/projects/k3baudioview.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/projects/k3baudioview.cpp 2009-07-23 11:42:02.000000000 +0200
|
||
@@ -3,6 +3,7 @@
|
||
* Copyright (C) 2003-2008 Sebastian Trueg <trueg@k3b.org>
|
||
* (C) 2009 Arthur Mello <arthur@mandriva.com>
|
||
* (C) 2009 Gustavo Pichorim Boiko <gustavo.boiko@kdemail.net>
|
||
+ * (C) 2009 Michal Malek <michalm@jabster.pl>
|
||
*
|
||
* This file is part of the K3b project.
|
||
* Copyright (C) 1998-2009 Sebastian Trueg <trueg@k3b.org>
|
||
@@ -40,7 +41,6 @@
|
||
|
||
#include "k3bfillstatusdisplay.h"
|
||
#include "k3bmsf.h"
|
||
-#include "k3bprojectplugin.h"
|
||
|
||
// QT-includes
|
||
#include <qlayout.h>
|
||
@@ -61,6 +61,8 @@
|
||
: K3b::StandardView( pDoc, parent ),
|
||
m_updatingColumnWidths(false)
|
||
{
|
||
+ connect( this, SIGNAL(activated(QModelIndex)), SLOT(slotItemActivated(QModelIndex)) );
|
||
+
|
||
m_doc = pDoc;
|
||
|
||
m_model = new K3b::AudioProjectModel(m_doc, this);
|
||
@@ -109,7 +111,7 @@
|
||
#endif
|
||
#endif
|
||
|
||
- addPluginButtons( K3b::ProjectPlugin::AUDIO_CD );
|
||
+ addPluginButtons();
|
||
|
||
// this is just for testing (or not?)
|
||
// most likely every project type will have it's rc file in the future
|
||
@@ -192,18 +194,64 @@
|
||
actionCollection()->addAction( "project_audio_musicbrainz", mbAction );
|
||
mbAction->setToolTip( i18n("Try to determine meta information over the Internet") );
|
||
#endif
|
||
+
|
||
+ m_popupMenu = new KMenu( this );
|
||
+ if( m_actionPlayTrack != 0 ) {
|
||
+ m_popupMenu->addAction( m_actionPlayTrack );
|
||
+ m_popupMenu->addSeparator();
|
||
+ }
|
||
+ m_popupMenu->addAction( m_actionRemove );
|
||
+ m_popupMenu->addAction( m_actionAddSilence );
|
||
+ m_popupMenu->addSeparator();
|
||
+ m_popupMenu->addAction( m_actionSplitSource );
|
||
+ m_popupMenu->addAction( m_actionSplitTrack );
|
||
+ m_popupMenu->addAction( m_actionEditSource );
|
||
+ m_popupMenu->addAction( m_actionMergeTracks );
|
||
+ m_popupMenu->addAction( m_actionProperties );
|
||
+ m_popupMenu->addSeparator();
|
||
+ m_popupMenu->addAction( actionCollection()->action("project_burn") );
|
||
+}
|
||
+
|
||
+
|
||
+void K3b::AudioView::trackProperties( const QModelIndexList& indexes )
|
||
+{
|
||
+ QList<K3b::AudioTrack*> tracks;
|
||
+ QList<K3b::AudioDataSource*> sources;
|
||
+ getSelectedItems( tracks, sources, indexes );
|
||
+
|
||
+ // TODO: add tracks from sources to tracks
|
||
|
||
+ if( !tracks.isEmpty() ) {
|
||
+ K3b::AudioTrackDialog d( tracks, this );
|
||
+ d.exec();
|
||
+ }
|
||
+ else {
|
||
+ slotProperties();
|
||
+ }
|
||
}
|
||
|
||
|
||
void K3b::AudioView::getSelectedItems( QList<K3b::AudioTrack*>& tracks,
|
||
QList<K3b::AudioDataSource*>& sources )
|
||
{
|
||
+ getSelectedItems( tracks, sources, currentSelection() );
|
||
+}
|
||
+
|
||
+
|
||
+
|
||
+K3b::ProjectBurnDialog* K3b::AudioView::newBurnDialog( QWidget* parent )
|
||
+{
|
||
+ return new K3b::AudioBurnDialog( m_doc, parent );
|
||
+}
|
||
+
|
||
+
|
||
+void K3b::AudioView::getSelectedItems( QList<AudioTrack*>& tracks,
|
||
+ QList<AudioDataSource*>& sources,
|
||
+ const QModelIndexList& indexes )
|
||
+{
|
||
tracks.clear();
|
||
sources.clear();
|
||
|
||
- QModelIndexList indexes = currentSelection();
|
||
-
|
||
foreach( const QModelIndex& index, indexes ) {
|
||
if ( K3b::AudioTrack* track = m_model->trackForIndex( index ) ) {
|
||
tracks << track;
|
||
@@ -221,60 +269,51 @@
|
||
}
|
||
|
||
|
||
-
|
||
-K3b::ProjectBurnDialog* K3b::AudioView::newBurnDialog( QWidget* parent )
|
||
-{
|
||
- return new K3b::AudioBurnDialog( m_doc, parent );
|
||
-}
|
||
-
|
||
-
|
||
-void K3b::AudioView::contextMenuForSelection(const QModelIndexList &selectedIndexes, const QPoint &pos)
|
||
+void K3b::AudioView::selectionChanged( const QModelIndexList& indexes )
|
||
{
|
||
QList<K3b::AudioTrack*> tracks;
|
||
QList<K3b::AudioDataSource*> sources;
|
||
- getSelectedItems( tracks, sources );
|
||
+ getSelectedItems( tracks, sources, indexes );
|
||
|
||
int numTracks = tracks.count();
|
||
int numSources = sources.count();
|
||
|
||
- // build the menu
|
||
- KMenu popupMenu;
|
||
-
|
||
- if( m_actionPlayTrack && numTracks >= 1 ) {
|
||
- popupMenu.addAction( m_actionPlayTrack );
|
||
- popupMenu.addSeparator();
|
||
+ if( m_actionPlayTrack != 0 ) {
|
||
+ m_actionPlayTrack->setVisible( numTracks >= 1 );
|
||
}
|
||
-
|
||
- if( numTracks + numSources )
|
||
- popupMenu.addAction( m_actionRemove );
|
||
-
|
||
- if( numSources + numTracks == 1 )
|
||
- popupMenu.addAction( m_actionAddSilence );
|
||
+ m_actionRemove->setVisible( numTracks + numSources );
|
||
+ m_actionAddSilence->setVisible( numSources + numTracks == 1 );
|
||
|
||
if( numSources == 1 && numTracks == 0 ) {
|
||
- popupMenu.addSeparator();
|
||
- popupMenu.addAction( m_actionSplitSource );
|
||
- popupMenu.addAction( m_actionEditSource );
|
||
+ m_actionSplitSource->setVisible( true );
|
||
+ m_actionSplitTrack->setVisible( false );
|
||
+ m_actionEditSource->setVisible( true );
|
||
+ m_actionMergeTracks->setVisible( false );
|
||
}
|
||
else if( numTracks == 1 && numSources == 0 ) {
|
||
- popupMenu.addSeparator();
|
||
-
|
||
- if( tracks.first()->length().lba() > 60 )
|
||
- popupMenu.addAction( m_actionSplitTrack );
|
||
-
|
||
- popupMenu.addAction( m_actionEditSource );
|
||
-
|
||
+ m_actionSplitSource->setVisible( false );
|
||
+ m_actionSplitTrack->setVisible( tracks.first()->length().lba() > 60 );
|
||
+ m_actionEditSource->setVisible( true );
|
||
+ m_actionMergeTracks->setVisible( false );
|
||
}
|
||
- else if( numTracks > 1 ) {
|
||
- popupMenu.addSeparator();
|
||
- popupMenu.addAction( m_actionMergeTracks );
|
||
+ else {
|
||
+ m_actionSplitSource->setVisible( false );
|
||
+ m_actionSplitTrack->setVisible( false );
|
||
+ m_actionEditSource->setVisible( false );
|
||
+ m_actionMergeTracks->setVisible( numTracks > 1 );
|
||
}
|
||
+}
|
||
+
|
||
+
|
||
+void K3b::AudioView::contextMenu( const QPoint& pos )
|
||
+{
|
||
+ m_popupMenu->exec( pos );
|
||
+}
|
||
|
||
- popupMenu.addAction( m_actionProperties );
|
||
- popupMenu.addSeparator();
|
||
- popupMenu.addAction( static_cast<K3b::View*>(m_doc->view())->actionCollection()->action( "project_burn" ) );
|
||
|
||
- popupMenu.exec( pos );
|
||
+void K3b::AudioView::slotItemActivated( const QModelIndex& index )
|
||
+{
|
||
+ trackProperties( QModelIndexList() << index );
|
||
}
|
||
|
||
|
||
@@ -466,19 +505,7 @@
|
||
|
||
void K3b::AudioView::slotTrackProperties()
|
||
{
|
||
- QList<K3b::AudioTrack*> tracks;
|
||
- QList<K3b::AudioDataSource*> sources;
|
||
- getSelectedItems( tracks, sources );
|
||
-
|
||
- // TODO: add tracks from sources to tracks
|
||
-
|
||
- if( !tracks.isEmpty() ) {
|
||
- K3b::AudioTrackDialog d( tracks, this );
|
||
- d.exec();
|
||
- }
|
||
- else {
|
||
- slotProperties();
|
||
- }
|
||
+ trackProperties( currentSelection() );
|
||
}
|
||
|
||
void K3b::AudioView::slotAdjustColumns()
|
||
diff -ru src/projects/k3baudioview.h src/projects/k3baudioview.h
|
||
--- src/projects/k3baudioview.h 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/projects/k3baudioview.h 2009-07-23 11:42:02.000000000 +0200
|
||
@@ -3,6 +3,7 @@
|
||
* Copyright (C) 2003-2007 Sebastian Trueg <trueg@k3b.org>
|
||
* (C) 2009 Arthur Mello <arthur@mandriva.com>
|
||
* (C) 2009 Gustavo Pichorim Boiko <gustavo.boiko@kdemail.net>
|
||
+ * (C) 2009 Michal Malek <michalm@jabster.pl>
|
||
*
|
||
* This file is part of the K3b project.
|
||
* Copyright (C) 1998-2009 Sebastian Trueg <trueg@k3b.org>
|
||
@@ -23,6 +24,7 @@
|
||
|
||
#include <qstringlist.h>
|
||
|
||
+class KMenu;
|
||
|
||
namespace K3b {
|
||
|
||
@@ -50,14 +52,20 @@
|
||
protected:
|
||
ProjectBurnDialog* newBurnDialog( QWidget* parent = 0 );
|
||
|
||
+ void getSelectedItems( QList<AudioTrack*>& tracks,
|
||
+ QList<AudioDataSource*>& sources,
|
||
+ const QModelIndexList& indexes );
|
||
+
|
||
/**
|
||
* reimplemented from \ref K3b::StandardView
|
||
*/
|
||
- void contextMenuForSelection(const QModelIndexList &selectedIndexes, const QPoint &pos);
|
||
+ virtual void selectionChanged( const QModelIndexList& indexes );
|
||
+ virtual void contextMenu( const QPoint& pos );
|
||
|
||
void init();
|
||
|
||
private Q_SLOTS:
|
||
+ void slotItemActivated( const QModelIndex& index );
|
||
void slotAudioConversion();
|
||
|
||
// action slots
|
||
@@ -74,6 +82,7 @@
|
||
|
||
private:
|
||
void setupActions();
|
||
+ void trackProperties( const QModelIndexList& indexes );
|
||
|
||
AudioDoc* m_doc;
|
||
K3b::AudioProjectModel* m_model;
|
||
@@ -86,6 +95,7 @@
|
||
KAction* m_actionSplitTrack;
|
||
KAction* m_actionEditSource;
|
||
KAction* m_actionPlayTrack;
|
||
+ KMenu* m_popupMenu;
|
||
|
||
K3b::ViewColumnAdjuster* m_columnAdjuster;
|
||
bool m_updatingColumnWidths;
|
||
diff -ru src/projects/k3bdataburndialog.cpp src/projects/k3bdataburndialog.cpp
|
||
--- src/projects/k3bdataburndialog.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/projects/k3bdataburndialog.cpp 2009-07-23 11:42:02.000000000 +0200
|
||
@@ -153,8 +153,10 @@
|
||
QWidget* frame = new QWidget( this );
|
||
QGridLayout* frameLayout = new QGridLayout( frame );
|
||
|
||
- m_groupDataMode = new Q3GroupBox( 1, Qt::Vertical, i18n("Datatrack Mode"), frame );
|
||
+ m_groupDataMode = new QGroupBox( i18n("Datatrack Mode"), frame );
|
||
m_dataModeWidget = new K3b::DataModeWidget( m_groupDataMode );
|
||
+ QVBoxLayout* groupDataModeLayout = new QVBoxLayout( m_groupDataMode );
|
||
+ groupDataModeLayout->addWidget( m_dataModeWidget );
|
||
|
||
QGroupBox* groupMultiSession = new QGroupBox( i18n("Multisession Mode"), frame );
|
||
m_comboMultisession = new K3b::DataMultiSessionCombobox( groupMultiSession );
|
||
diff -ru src/projects/k3bdataburndialog.h src/projects/k3bdataburndialog.h
|
||
--- src/projects/k3bdataburndialog.h 2009-02-24 08:23:40.000000000 +0100
|
||
+++ src/projects/k3bdataburndialog.h 2009-07-23 11:42:02.000000000 +0200
|
||
@@ -1,9 +1,9 @@
|
||
/*
|
||
*
|
||
- * Copyright (C) 2003-2007 Sebastian Trueg <trueg@k3b.org>
|
||
+ * Copyright (C) 2003-2009 Sebastian Trueg <trueg@k3b.org>
|
||
*
|
||
* This file is part of the K3b project.
|
||
- * Copyright (C) 1998-2007 Sebastian Trueg <trueg@k3b.org>
|
||
+ * Copyright (C) 1998-2009 Sebastian Trueg <trueg@k3b.org>
|
||
*
|
||
* This program is free software; you can redistribute it and/or modify
|
||
* it under the terms of the GNU General Public License as published by
|
||
@@ -17,11 +17,9 @@
|
||
#define K3BDATABURNDIALOG_H
|
||
|
||
#include "k3bprojectburndialog.h"
|
||
-//Added by qt3to4:
|
||
-#include <QLabel>
|
||
|
||
class QCheckBox;
|
||
-class Q3GroupBox;
|
||
+class QGroupBox;
|
||
class QLabel;
|
||
|
||
namespace K3b {
|
||
@@ -52,7 +50,7 @@
|
||
DataImageSettingsWidget* m_imageSettingsWidget;
|
||
// ----------------------------------------------
|
||
|
||
- Q3GroupBox* m_groupDataMode;
|
||
+ QGroupBox* m_groupDataMode;
|
||
DataModeWidget* m_dataModeWidget;
|
||
DataMultiSessionCombobox* m_comboMultisession;
|
||
|
||
diff -ru src/projects/k3bdataprojectmodel.cpp src/projects/k3bdataprojectmodel.cpp
|
||
--- src/projects/k3bdataprojectmodel.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/projects/k3bdataprojectmodel.cpp 2009-07-23 11:42:02.000000000 +0200
|
||
@@ -187,6 +187,19 @@
|
||
if ( index.isValid() ) {
|
||
K3b::DataItem* item = itemForIndex( index );
|
||
|
||
+ if ( role == K3b::ItemTypeRole ) {
|
||
+ if (item->isDir())
|
||
+ return (int) K3b::DirItemType;
|
||
+ else
|
||
+ return (int) K3b::FileItemType;
|
||
+ }
|
||
+ else if ( role == K3b::CustomFlagsRole ) {
|
||
+ if (item->isRemoveable())
|
||
+ return (int) K3b::ItemIsRemovable;
|
||
+ else
|
||
+ return 0;
|
||
+ }
|
||
+
|
||
switch( index.column() ) {
|
||
case FilenameColumn:
|
||
if( role == Qt::DisplayRole ||
|
||
@@ -204,18 +217,6 @@
|
||
return KIcon( item->mimeType()->iconName() );
|
||
}
|
||
}
|
||
- else if ( role == K3b::ItemTypeRole ) {
|
||
- if (item->isDir())
|
||
- return (int) K3b::DirItemType;
|
||
- else
|
||
- return (int) K3b::FileItemType;
|
||
- }
|
||
- else if ( role == K3b::CustomFlagsRole ) {
|
||
- if (item->isRemoveable())
|
||
- return (int) K3b::ItemIsRemovable;
|
||
- else
|
||
- return 0;
|
||
- }
|
||
break;
|
||
|
||
case TypeColumn:
|
||
diff -ru src/projects/k3bdataview.cpp src/projects/k3bdataview.cpp
|
||
--- src/projects/k3bdataview.cpp 2009-04-26 11:20:20.000000000 +0200
|
||
+++ src/projects/k3bdataview.cpp 2009-07-23 11:42:02.000000000 +0200
|
||
@@ -2,6 +2,7 @@
|
||
*
|
||
* Copyright (C) 2003-2008 Sebastian Trueg <trueg@k3b.org>
|
||
* (C) 2009 Gustavo Pichorim Boiko <gustavo.boiko@kdemail.net>
|
||
+ * (C) 2009 Michal Malek <michalm@jabster.pl>
|
||
*
|
||
* This file is part of the K3b project.
|
||
* Copyright (C) 1998-2009 Sebastian Trueg <trueg@k3b.org>
|
||
@@ -28,7 +29,6 @@
|
||
#include "k3bdeviceselectiondialog.h"
|
||
#include "k3bfillstatusdisplay.h"
|
||
#include "k3bcore.h"
|
||
-#include "k3bprojectplugin.h"
|
||
#include "k3bvalidators.h"
|
||
#include "k3baction.h"
|
||
|
||
@@ -68,31 +68,12 @@
|
||
setModel(m_model);
|
||
|
||
connect( m_doc, SIGNAL(changed()), this, SLOT(slotDocChanged()) );
|
||
+ connect( this, SIGNAL(currentRootChanged(QModelIndex)), SLOT(slotCurrentRootChanged(QModelIndex)) );
|
||
+ connect( this, SIGNAL(activated(QModelIndex)), SLOT(slotFileItemActivated(QModelIndex)) );
|
||
|
||
- setupContextMenu();
|
||
+ setupActions();
|
||
|
||
- // the data actions
|
||
- KAction* actionImportSession = K3b::createAction( this, i18n("&Import Session..."), "document-import", 0, this, SLOT(importSession()),
|
||
- actionCollection(), "project_data_import_session" );
|
||
- KAction* actionClearSession = K3b::createAction( this, i18n("&Clear Imported Session"), "edit-clear", 0, this,
|
||
- SLOT(clearImportedSession()), actionCollection(),
|
||
- "project_data_clear_imported_session" );
|
||
- KAction* actionEditBootImages = K3b::createAction( this, i18n("&Edit Boot Images..."), "document-properties", 0, this,
|
||
- SLOT(editBootImages()), actionCollection(),
|
||
- "project_data_edit_boot_images" );
|
||
-
|
||
- actionImportSession->setToolTip( i18n("Import a previously burned session into the current project") );
|
||
- actionClearSession->setToolTip( i18n("Remove the imported items from a previous session") );
|
||
- actionEditBootImages->setToolTip( i18n("Modify the bootable settings of the current project") );
|
||
-
|
||
- toolBox()->addAction( actionImportSession );
|
||
- toolBox()->addAction( actionClearSession );
|
||
- toolBox()->addAction( actionEditBootImages );
|
||
- toolBox()->addSeparator();
|
||
- toolBox()->addAction( actionCollection()->action("parent_dir") );
|
||
- toolBox()->addSeparator();
|
||
-
|
||
- addPluginButtons( K3b::ProjectPlugin::DATA_CD );
|
||
+ addPluginButtons();
|
||
|
||
m_volumeIDEdit = new QLineEdit( doc->isoOptions().volumeID(), toolBox() );
|
||
m_volumeIDEdit->setValidator( new K3b::Latin1Validator( m_volumeIDEdit ) );
|
||
@@ -101,6 +82,9 @@
|
||
connect( m_volumeIDEdit, SIGNAL(textChanged(const QString&)),
|
||
m_doc,
|
||
SLOT(setVolumeID(const QString&)) );
|
||
+
|
||
+ // Update actions associated with current directory
|
||
+ slotCurrentRootChanged( currentRoot() );
|
||
|
||
// this is just for testing (or not?)
|
||
// most likely every project type will have it's rc file in the future
|
||
@@ -182,8 +166,22 @@
|
||
DataUrlAddingDialog::addUrls( urls, item);
|
||
}
|
||
|
||
-void K3b::DataView::setupContextMenu()
|
||
+void K3b::DataView::setupActions()
|
||
{
|
||
+ // the data actions
|
||
+ m_actionImportSession = K3b::createAction( this, i18n("&Import Session..."), "document-import", 0, this, SLOT(importSession()),
|
||
+ actionCollection(), "project_data_import_session" );
|
||
+ m_actionClearSession = K3b::createAction( this, i18n("&Clear Imported Session"), "edit-clear", 0, this,
|
||
+ SLOT(clearImportedSession()), actionCollection(),
|
||
+ "project_data_clear_imported_session" );
|
||
+ m_actionEditBootImages = K3b::createAction( this, i18n("&Edit Boot Images..."), "document-properties", 0, this,
|
||
+ SLOT(editBootImages()), actionCollection(),
|
||
+ "project_data_edit_boot_images" );
|
||
+
|
||
+ m_actionImportSession->setToolTip( i18n("Import a previously burned session into the current project") );
|
||
+ m_actionClearSession->setToolTip( i18n("Remove the imported items from a previous session") );
|
||
+ m_actionEditBootImages->setToolTip( i18n("Modify the bootable settings of the current project") );
|
||
+
|
||
m_actionProperties = new KAction( this );
|
||
m_actionProperties->setText( i18n("Properties") );
|
||
m_actionProperties->setIcon( KIcon( "document-properties" ) );
|
||
@@ -205,7 +203,16 @@
|
||
actionCollection(), "parent_dir" );
|
||
m_actionOpen = K3b::createAction( this, i18n("Open"), "document-open", 0, this, SLOT(slotOpen()),
|
||
actionCollection(), "open" );
|
||
-
|
||
+
|
||
+ // Setup toolbar
|
||
+ toolBox()->addAction( m_actionImportSession );
|
||
+ toolBox()->addAction( m_actionClearSession );
|
||
+ toolBox()->addAction( m_actionEditBootImages );
|
||
+ toolBox()->addSeparator();
|
||
+ toolBox()->addAction( m_actionParentDir );
|
||
+ toolBox()->addSeparator();
|
||
+
|
||
+ // Create context menu
|
||
m_popupMenu = new KMenu( this );
|
||
m_popupMenu->addAction( m_actionParentDir );
|
||
m_popupMenu->addSeparator();
|
||
@@ -220,20 +227,21 @@
|
||
m_popupMenu->addAction( actionCollection()->action("project_burn") );
|
||
}
|
||
|
||
-void K3b::DataView::contextMenuForSelection(const QModelIndexList &selectedIndexes, const QPoint &pos)
|
||
+
|
||
+void K3b::DataView::selectionChanged( const QModelIndexList& indexes )
|
||
{
|
||
- bool open = true, rename = true, remove = true, parent = true;
|
||
+ bool open = true, rename = true, remove = true;
|
||
|
||
// we can only rename one item at a time
|
||
// also, we can only create a new dir over a single directory
|
||
- if (selectedIndexes.count() > 1)
|
||
+ if (indexes.count() > 1)
|
||
{
|
||
rename = false;
|
||
open = false;
|
||
}
|
||
- else if (selectedIndexes.count() == 1)
|
||
+ else if (indexes.count() == 1)
|
||
{
|
||
- QModelIndex index = selectedIndexes.first();
|
||
+ QModelIndex index = indexes.first();
|
||
rename = (index.flags() & Qt::ItemIsEditable);
|
||
open = (index.data(K3b::ItemTypeRole).toInt() == (int) K3b::FileItemType);
|
||
}
|
||
@@ -245,7 +253,7 @@
|
||
}
|
||
|
||
// check if all selected items can be removed
|
||
- foreach(const QModelIndex &index, selectedIndexes)
|
||
+ foreach(const QModelIndex &index, indexes)
|
||
{
|
||
if (!index.data(K3b::CustomFlagsRole).toInt() & K3b::ItemIsRemovable)
|
||
{
|
||
@@ -254,17 +262,18 @@
|
||
}
|
||
}
|
||
|
||
- if (m_model->indexForItem(m_doc->root()) == currentRoot())
|
||
- parent = false;
|
||
-
|
||
m_actionRename->setEnabled( rename );
|
||
m_actionRemove->setEnabled( remove );
|
||
m_actionOpen->setEnabled( open );
|
||
- m_actionParentDir->setEnabled( parent );
|
||
+}
|
||
|
||
- m_popupMenu->exec(pos);
|
||
+
|
||
+void K3b::DataView::contextMenu( const QPoint& pos )
|
||
+{
|
||
+ m_popupMenu->exec( pos );
|
||
}
|
||
|
||
+
|
||
void K3b::DataView::slotNewDir()
|
||
{
|
||
K3b::DirItem *parent = 0;
|
||
@@ -297,6 +306,7 @@
|
||
m_doc->addEmptyDir( name, parent );
|
||
}
|
||
|
||
+
|
||
void K3b::DataView::slotItemProperties()
|
||
{
|
||
QModelIndexList selection = currentSelection();
|
||
@@ -341,4 +351,28 @@
|
||
}
|
||
}
|
||
|
||
+
|
||
+void K3b::DataView::slotCurrentRootChanged( const QModelIndex& newRoot )
|
||
+{
|
||
+ m_actionParentDir->setEnabled( m_model->indexForItem(m_doc->root()) != newRoot );
|
||
+}
|
||
+
|
||
+
|
||
+void K3b::DataView::slotFileItemActivated( const QModelIndex& index )
|
||
+{
|
||
+ if( index.isValid() ) {
|
||
+ int type = index.data(ItemTypeRole).toInt();
|
||
+ if( type == (int)DirItemType ) {
|
||
+ StandardView::setCurrentRoot( index );
|
||
+ }
|
||
+ else if( type == (int)FileItemType ) {
|
||
+ QList<DataItem*> items;
|
||
+ items.append( m_model->itemForIndex(index) );
|
||
+ DataPropertiesDialog dlg( items, this );
|
||
+ dlg.exec();
|
||
+ }
|
||
+ }
|
||
+}
|
||
+
|
||
+
|
||
#include "k3bdataview.moc"
|
||
diff -ru src/projects/k3bdataview.h src/projects/k3bdataview.h
|
||
--- src/projects/k3bdataview.h 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/projects/k3bdataview.h 2009-07-23 11:42:02.000000000 +0200
|
||
@@ -1,6 +1,7 @@
|
||
/*
|
||
*
|
||
* Copyright (C) 2003-2007 Sebastian Trueg <trueg@k3b.org>
|
||
+ * (C) 2009 Michal Malek <michalm@jabster.pl>
|
||
*
|
||
* This file is part of the K3b project.
|
||
* Copyright (C) 1998-2007 Sebastian Trueg <trueg@k3b.org>
|
||
@@ -55,6 +56,8 @@
|
||
void slotNewDir();
|
||
void slotItemProperties();
|
||
void slotOpen();
|
||
+ void slotCurrentRootChanged( const QModelIndex& newRoot );
|
||
+ void slotFileItemActivated( const QModelIndex& index );
|
||
|
||
protected:
|
||
QLineEdit* m_volumeIDEdit;
|
||
@@ -64,14 +67,19 @@
|
||
/**
|
||
* reimplemented from @ref StandardView
|
||
*/
|
||
- virtual void contextMenuForSelection(const QModelIndexList &selectedIndexes, const QPoint &pos);
|
||
+ virtual void selectionChanged( const QModelIndexList& indexes );
|
||
+ virtual void contextMenu( const QPoint& pos );
|
||
+
|
||
+ KAction* m_actionImportSession;
|
||
+ KAction* m_actionClearSession;
|
||
+ KAction* m_actionEditBootImages;
|
||
|
||
private:
|
||
+ void setupActions();
|
||
+
|
||
DataDoc* m_doc;
|
||
K3b::DataProjectModel* m_model;
|
||
|
||
- void setupContextMenu();
|
||
-
|
||
KMenu* m_popupMenu;
|
||
KAction* m_actionParentDir;
|
||
KAction* m_actionRemove;
|
||
diff -ru src/projects/k3bmixedview.cpp src/projects/k3bmixedview.cpp
|
||
--- src/projects/k3bmixedview.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/projects/k3bmixedview.cpp 2009-07-23 11:42:02.000000000 +0200
|
||
@@ -27,7 +27,6 @@
|
||
#include "k3baudiodoc.h"
|
||
#include "k3bdatadoc.h"
|
||
#include "k3bfillstatusdisplay.h"
|
||
-#include "k3bprojectplugin.h"
|
||
#include "k3bdiritem.h"
|
||
|
||
#include <kdialog.h>
|
||
@@ -69,7 +68,7 @@
|
||
toolBox()->addSeparator();
|
||
#endif
|
||
#endif
|
||
- addPluginButtons( K3b::ProjectPlugin::MIXED_CD );
|
||
+ addPluginButtons();
|
||
}
|
||
|
||
|
||
diff -ru src/projects/k3bmovixview.cpp src/projects/k3bmovixview.cpp
|
||
--- src/projects/k3bmovixview.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/projects/k3bmovixview.cpp 2009-07-23 11:42:02.000000000 +0200
|
||
@@ -3,6 +3,7 @@
|
||
* Copyright (C) 2003-2007 Sebastian Trueg <trueg@k3b.org>
|
||
* (C) 2009 Arthur Renato Mello <arthur@mandriva.com>
|
||
* (C) 2009 Gustavo Pichorim Boiko <gustavo.boiko@kdemail.net>
|
||
+ * (C) 2009 Michal Malek <michalm@jabster.pl>
|
||
*
|
||
* This file is part of the K3b project.
|
||
* Copyright (C) 1998-2009 Sebastian Trueg <trueg@k3b.org>
|
||
@@ -23,7 +24,6 @@
|
||
|
||
#include "k3bfillstatusdisplay.h"
|
||
#include "k3bdatapropertiesdialog.h"
|
||
-#include "k3bprojectplugin.h"
|
||
#include "k3baction.h"
|
||
|
||
#include <klocale.h>
|
||
@@ -77,7 +77,7 @@
|
||
// k3bMain()->actionCollection()->action("file_burn")->plug( m_popupMenu );
|
||
|
||
|
||
- addPluginButtons( K3b::ProjectPlugin::MOVIX_CD );
|
||
+ addPluginButtons();
|
||
|
||
m_volumeIDEdit = new QLineEdit( doc->isoOptions().volumeID(), toolBox() );
|
||
toolBox()->addWidget( new QLabel( i18n("Volume Name:"), toolBox() ) );
|
||
@@ -95,34 +95,6 @@
|
||
}
|
||
|
||
|
||
-void K3b::MovixView::contextMenuForSelection(const QModelIndexList &selectedIndexes, const QPoint &pos)
|
||
-{
|
||
- if( selectedIndexes.count() >= 1 ) {
|
||
- m_actionRemove->setEnabled(true);
|
||
-
|
||
- bool subtitle = false;
|
||
- // check if any of the items have a subtitle
|
||
- foreach (const QModelIndex &index, selectedIndexes) {
|
||
- K3b::MovixFileItem *item = m_model->itemForIndex(index);
|
||
- if (item && item->subTitleItem()) {
|
||
- subtitle = true;
|
||
- break;
|
||
- }
|
||
- }
|
||
- m_actionRemoveSubTitle->setEnabled( subtitle );
|
||
- // only enable the subtitle adding if there is just one item selected
|
||
- m_actionAddSubTitle->setEnabled( selectedIndexes.count() == 1 );
|
||
- }
|
||
- else {
|
||
- m_actionRemove->setEnabled(false);
|
||
- m_actionRemoveSubTitle->setEnabled( false );
|
||
- m_actionAddSubTitle->setEnabled( false );
|
||
- }
|
||
-
|
||
- m_popupMenu->popup( pos );
|
||
-}
|
||
-
|
||
-
|
||
void K3b::MovixView::showPropertiesDialog()
|
||
{
|
||
QModelIndexList selection = currentSelection();
|
||
@@ -187,6 +159,38 @@
|
||
}
|
||
|
||
|
||
+void K3b::MovixView::selectionChanged( const QModelIndexList& indexes )
|
||
+{
|
||
+ if( indexes.count() >= 1 ) {
|
||
+ m_actionRemove->setEnabled(true);
|
||
+
|
||
+ bool subtitle = false;
|
||
+ // check if any of the items have a subtitle
|
||
+ foreach (const QModelIndex &index, indexes) {
|
||
+ K3b::MovixFileItem *item = m_model->itemForIndex(index);
|
||
+ if (item && item->subTitleItem()) {
|
||
+ subtitle = true;
|
||
+ break;
|
||
+ }
|
||
+ }
|
||
+ m_actionRemoveSubTitle->setEnabled( subtitle );
|
||
+ // only enable the subtitle adding if there is just one item selected
|
||
+ m_actionAddSubTitle->setEnabled( indexes.count() == 1 );
|
||
+ }
|
||
+ else {
|
||
+ m_actionRemove->setEnabled(false);
|
||
+ m_actionRemoveSubTitle->setEnabled( false );
|
||
+ m_actionAddSubTitle->setEnabled( false );
|
||
+ }
|
||
+}
|
||
+
|
||
+
|
||
+void K3b::MovixView::contextMenu( const QPoint& pos )
|
||
+{
|
||
+ m_popupMenu->popup( pos );
|
||
+}
|
||
+
|
||
+
|
||
K3b::ProjectBurnDialog* K3b::MovixView::newBurnDialog( QWidget* parent )
|
||
{
|
||
return new K3b::MovixBurnDialog( m_doc, parent );
|
||
diff -ru src/projects/k3bmovixview.h src/projects/k3bmovixview.h
|
||
--- src/projects/k3bmovixview.h 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/projects/k3bmovixview.h 2009-07-23 11:42:02.000000000 +0200
|
||
@@ -3,6 +3,7 @@
|
||
* Copyright (C) 2003-2007 Sebastian Trueg <trueg@k3b.org>
|
||
* (C) 2009 Arthur Renato Mello <arthur@mandriva.com>
|
||
* (C) 2009 Gustavo Pichorim Boiko <gustavo.boiko@kdemail.net>
|
||
+ * (C) 2009 Michal Malek <michalm@jabster.pl>
|
||
*
|
||
* This file is part of the K3b project.
|
||
* Copyright (C) 1998-2009 Sebastian Trueg <trueg@k3b.org>
|
||
@@ -44,13 +45,18 @@
|
||
virtual ~MovixView();
|
||
|
||
private Q_SLOTS:
|
||
- void contextMenuForSelection(const QModelIndexList &selectedIndexes, const QPoint &pos);
|
||
void slotRemoveSubTitleItems();
|
||
void showPropertiesDialog();
|
||
void slotAddSubTitleFile();
|
||
void slotDocChanged();
|
||
|
||
protected:
|
||
+ /**
|
||
+ * reimplemented from @ref StandardView
|
||
+ */
|
||
+ virtual void selectionChanged( const QModelIndexList& indexes );
|
||
+ virtual void contextMenu( const QPoint& pos );
|
||
+
|
||
virtual ProjectBurnDialog* newBurnDialog( QWidget* parent = 0 );
|
||
|
||
private:
|
||
diff -ru src/projects/k3bstandardview.cpp src/projects/k3bstandardview.cpp
|
||
--- src/projects/k3bstandardview.cpp 2009-04-08 22:48:47.000000000 +0200
|
||
+++ src/projects/k3bstandardview.cpp 2009-07-23 11:42:02.000000000 +0200
|
||
@@ -1,6 +1,7 @@
|
||
/*
|
||
*
|
||
* Copyright (C) 2009 Gustavo Pichorim Boiko <gustavo.boiko@kdemail.net>
|
||
+ * (C) 2009 Michal Malek <michalm@jabster.pl>
|
||
*
|
||
* This file is part of the K3b project.
|
||
* Copyright (C) 1998-2009 Sebastian Trueg <trueg@k3b.org>
|
||
@@ -16,11 +17,13 @@
|
||
#include "k3bdirproxymodel.h"
|
||
|
||
#include <QAbstractItemModel>
|
||
+#include <QApplication>
|
||
#include <QTreeView>
|
||
#include <QSplitter>
|
||
#include <QLayout>
|
||
-#include <QDebug>
|
||
#include <QHeaderView>
|
||
+#include <KDebug>
|
||
+#include <KGlobalSettings>
|
||
|
||
K3b::StandardView::StandardView(K3b::Doc* doc, QWidget *parent )
|
||
: K3b::View(doc, parent)
|
||
@@ -44,18 +47,22 @@
|
||
m_dirView->setSelectionMode(QTreeView::SingleSelection);
|
||
m_dirView->setModel(m_dirProxy);
|
||
m_dirView->setContextMenuPolicy(Qt::CustomContextMenu);
|
||
- m_dirView->setAnimated(true);
|
||
+ m_dirView->setAnimated( KGlobalSettings::graphicEffectsLevel() == KGlobalSettings::SimpleAnimationEffects ||
|
||
+ KGlobalSettings::graphicEffectsLevel() == KGlobalSettings::ComplexAnimationEffects );
|
||
|
||
// File panel
|
||
m_fileView->setAcceptDrops(true);
|
||
m_fileView->setDragEnabled(true);
|
||
m_fileView->setDragDropMode(QTreeView::DragDrop);
|
||
+ m_fileView->setItemsExpandable(false);
|
||
m_fileView->setRootIsDecorated(false);
|
||
m_fileView->setSelectionMode(QTreeView::ExtendedSelection);
|
||
m_fileView->setContextMenuPolicy(Qt::CustomContextMenu);
|
||
- m_fileView->setAnimated(true);
|
||
+ m_fileView->setAnimated( KGlobalSettings::graphicEffectsLevel() == KGlobalSettings::SimpleAnimationEffects ||
|
||
+ KGlobalSettings::graphicEffectsLevel() == KGlobalSettings::ComplexAnimationEffects );
|
||
// FIXME: make QHeaderView::Interactive the default but connect to model changes and call header()->resizeSections( QHeaderView::ResizeToContents );
|
||
m_fileView->header()->setResizeMode( QHeaderView::ResizeToContents );
|
||
+ m_fileView->setEditTriggers( QAbstractItemView::NoEditTriggers );
|
||
|
||
m_expanded = false;
|
||
// connect signals/slots
|
||
@@ -63,6 +70,8 @@
|
||
this, SLOT(slotCustomContextMenu(const QPoint&)));
|
||
connect(m_fileView, SIGNAL(customContextMenuRequested(const QPoint&)),
|
||
this, SLOT(slotCustomContextMenu(const QPoint&)));
|
||
+ connect(qApp, SIGNAL(focusChanged(QWidget*,QWidget*)),
|
||
+ this, SLOT(slotFocusChanged(QWidget*,QWidget*)) );
|
||
}
|
||
|
||
K3b::StandardView::~StandardView()
|
||
@@ -82,10 +91,14 @@
|
||
// connect signals/slots
|
||
// this signal is better to get connected before the setCurrentIndex is called,
|
||
// so that it updates the file view
|
||
- connect(m_dirView->selectionModel(), SIGNAL(selectionChanged(const QItemSelection &, const QItemSelection&)),
|
||
+ connect(m_dirView->selectionModel(), SIGNAL(selectionChanged(QItemSelection,QItemSelection)),
|
||
this, SLOT(slotCurrentDirChanged()));
|
||
+ connect(m_fileView, SIGNAL(doubleClicked(QModelIndex)),
|
||
+ SIGNAL(activated(QModelIndex)));
|
||
connect(model, SIGNAL(rowsInserted(const QModelIndex&, int, int)),
|
||
this, SLOT(slotItemsAdded()));
|
||
+ connect(m_fileView->selectionModel(), SIGNAL(selectionChanged(QItemSelection,QItemSelection)),
|
||
+ this, SLOT(slotFileViewSelectionChanged()));
|
||
|
||
// select the first item from the model
|
||
if (m_dirProxy->rowCount() > 0)
|
||
@@ -99,15 +112,36 @@
|
||
m_fileView->setRootIndex(QModelIndex());
|
||
}
|
||
|
||
-void K3b::StandardView::contextMenuForSelection(const QModelIndexList &selectedIndexes, const QPoint &pos)
|
||
+void K3b::StandardView::selectionChanged( const QModelIndexList& indexes )
|
||
{
|
||
// do nothing in the default implementation (at least for now)
|
||
- qDebug() << "Gotta show a menu for " << selectedIndexes.count() << " items at " << pos;
|
||
+ kDebug() << "Selected " << indexes.count() << " items";
|
||
+}
|
||
+
|
||
+void K3b::StandardView::contextMenu( const QPoint& pos )
|
||
+{
|
||
+ // do nothing in the default implementation (at least for now)
|
||
+ kDebug() << "Gotta show a menu at " << pos;
|
||
}
|
||
|
||
QModelIndexList K3b::StandardView::currentSelection() const
|
||
{
|
||
- return m_currentSelection;
|
||
+ QModelIndexList selected;
|
||
+ if( m_dirView->hasFocus() ) {
|
||
+ // if dirview has focus, we need to map the indexes to the source model
|
||
+ foreach( const QModelIndex& index, m_dirView->selectionModel()->selectedRows() ) {
|
||
+ selected.append( m_dirProxy->mapToSource( index ) );
|
||
+ }
|
||
+ }
|
||
+ else if( m_fileView->hasFocus() ) {
|
||
+ selected = m_fileView->selectionModel()->selectedRows();
|
||
+ }
|
||
+ return selected;
|
||
+}
|
||
+
|
||
+void K3b::StandardView::setCurrentRoot( const QModelIndex& index )
|
||
+{
|
||
+ m_dirView->setCurrentIndex( m_dirProxy->mapFromSource( index ) );
|
||
}
|
||
|
||
QModelIndex K3b::StandardView::currentRoot() const
|
||
@@ -133,44 +167,30 @@
|
||
QModelIndexList indexes = m_dirView->selectionModel()->selectedRows();
|
||
|
||
QModelIndex currentDir;
|
||
- if (indexes.count())
|
||
+ if (indexes.count()) {
|
||
currentDir = m_dirProxy->mapToSource(indexes.first());
|
||
+
|
||
+ if( m_dirView->hasFocus() ) {
|
||
+ selectionChanged( QModelIndexList() << currentDir );
|
||
+ }
|
||
+ }
|
||
|
||
// make the file view show only the child nodes of the currently selected
|
||
// directory from dir view
|
||
m_fileView->setRootIndex(currentDir);
|
||
m_fileView->header()->resizeSections( QHeaderView::Stretch );
|
||
-
|
||
+
|
||
emit currentRootChanged( currentDir );
|
||
}
|
||
|
||
-void K3b::StandardView::slotCustomContextMenu(const QPoint &pos)
|
||
+void K3b::StandardView::slotCustomContextMenu( const QPoint &pos )
|
||
{
|
||
- QModelIndexList selection;
|
||
// detect which view emitted the signal
|
||
- QTreeView *view = dynamic_cast<QTreeView*>(sender());
|
||
-
|
||
- // this should not happen, but just in case...
|
||
- if (!view)
|
||
- return;
|
||
-
|
||
- // if the signal was emitted by the dirview, we need to map the indexes to the
|
||
- // source model
|
||
- if (view == m_dirView)
|
||
- {
|
||
- foreach(const QModelIndex &index, view->selectionModel()->selectedRows())
|
||
- selection.append( m_dirProxy->mapToSource(index) );
|
||
- }
|
||
- else
|
||
- {
|
||
- selection = view->selectionModel()->selectedRows();
|
||
- }
|
||
-
|
||
- m_currentSelection = selection;
|
||
-
|
||
- // call the context menu method so that derived classes can place customized
|
||
- // context menus
|
||
- contextMenuForSelection(selection, view->viewport()->mapToGlobal(pos));
|
||
+ if( QTreeView *view = dynamic_cast<QTreeView*>(sender()) ) {
|
||
+ // call the context menu method so that derived classes can place customized
|
||
+ // context menus
|
||
+ contextMenu( view->viewport()->mapToGlobal(pos) );
|
||
+ }
|
||
}
|
||
|
||
void K3b::StandardView::slotParentDir()
|
||
@@ -186,27 +206,26 @@
|
||
|
||
// create a list of persistent model indexes to be able to remove all of them
|
||
QList<QPersistentModelIndex> indexes;
|
||
- foreach(const QModelIndex &index, m_currentSelection)
|
||
+ foreach( const QModelIndex &index, currentSelection() ) {
|
||
indexes.append( QPersistentModelIndex(index) );
|
||
-
|
||
+ }
|
||
|
||
// and now ask the indexes to be removed
|
||
- foreach(const QPersistentModelIndex &index, indexes)
|
||
+ foreach(const QPersistentModelIndex &index, indexes) {
|
||
model->removeRow(index.row(), index.parent());
|
||
-
|
||
- // clear the selection, just to make sure
|
||
- m_currentSelection.clear();
|
||
+ }
|
||
}
|
||
|
||
void K3b::StandardView::slotRenameItem()
|
||
{
|
||
- if (m_currentSelection.isEmpty())
|
||
- return;
|
||
-
|
||
- if (m_dirView->hasFocus())
|
||
- m_dirView->edit( m_dirProxy->mapFromSource(m_currentSelection.first()) );
|
||
- else
|
||
- m_fileView->edit( m_currentSelection.first() );
|
||
+ QModelIndexList selected = currentSelection();
|
||
+
|
||
+ if (!selected.isEmpty()) {
|
||
+ if (m_dirView->hasFocus())
|
||
+ m_dirView->edit( m_dirProxy->mapFromSource(selected.first()) );
|
||
+ else
|
||
+ m_fileView->edit( selected.first() );
|
||
+ }
|
||
}
|
||
|
||
void K3b::StandardView::slotItemsAdded()
|
||
@@ -215,4 +234,18 @@
|
||
m_fileView->expandAll();
|
||
}
|
||
|
||
+void K3b::StandardView::slotFileViewSelectionChanged()
|
||
+{
|
||
+ if( m_fileView->hasFocus() ) {
|
||
+ selectionChanged( m_fileView->selectionModel()->selectedRows() );
|
||
+ }
|
||
+}
|
||
+
|
||
+void K3b::StandardView::slotFocusChanged( QWidget*, QWidget* now )
|
||
+{
|
||
+ if( now == m_dirView || now == m_fileView ) {
|
||
+ selectionChanged( currentSelection() );
|
||
+ }
|
||
+}
|
||
+
|
||
#include "k3bstandardview.moc"
|
||
diff -ru src/projects/k3bstandardview.h src/projects/k3bstandardview.h
|
||
--- src/projects/k3bstandardview.h 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/projects/k3bstandardview.h 2009-07-23 11:42:02.000000000 +0200
|
||
@@ -1,6 +1,7 @@
|
||
/*
|
||
*
|
||
* Copyright (C) 2009 Gustavo Pichorim Boiko <gustavo.boiko@kdemail.net>
|
||
+ * (C) 2009 Michal Malek <michalm@jabster.pl>
|
||
*
|
||
* This file is part of the K3b project.
|
||
* Copyright (C) 1998-2009 Sebastian Trueg <trueg@k3b.org>
|
||
@@ -63,27 +64,33 @@
|
||
* or not.
|
||
*/
|
||
void setShowDirPanel(bool show);
|
||
+
|
||
+ /**
|
||
+ * Called when set of selected items is changed.
|
||
+ * Can be used to updated state of actions working on selected items.
|
||
+ *
|
||
+ * The default implementation does nothing (at least for now)
|
||
+ */
|
||
+ virtual void selectionChanged( const QModelIndexList& indexes );
|
||
|
||
/**
|
||
- * Context menu for a list of indexes.
|
||
- * This method should be reimplemented in derived classes to get
|
||
- * custom context menus for the selected items.
|
||
+ * Called when context menu is supposed to show at specified point.
|
||
+ * This method should be reimplemented in derived classes to show
|
||
+ * custom context menus.
|
||
*
|
||
* The default implementation does nothing (at least for now)
|
||
*/
|
||
- virtual void contextMenuForSelection(const QModelIndexList &selectedIndexes, const QPoint &pos);
|
||
+ virtual void contextMenu( const QPoint& pos );
|
||
|
||
/**
|
||
* Returns a list of the currently selected indexes.
|
||
- * This method is meant to be used together with @ref contextMenuForSelection()
|
||
- * meaning that when @ref contextMenuForSelection() is called, currentSelection()
|
||
- * will provide the same list as the one used in the previous slot.
|
||
*
|
||
* The main purpose of its existence is for slots connected to actions in the context menu
|
||
* to know which items they should operate in
|
||
*/
|
||
QModelIndexList currentSelection() const;
|
||
|
||
+ void setCurrentRoot( const QModelIndex& index );
|
||
QModelIndex currentRoot() const;
|
||
|
||
/**
|
||
@@ -130,16 +137,18 @@
|
||
* file view
|
||
*/
|
||
void slotItemsAdded();
|
||
+ void slotFileViewSelectionChanged();
|
||
+ void slotFocusChanged( QWidget* old, QWidget* now );
|
||
|
||
signals:
|
||
void currentRootChanged( const QModelIndex& newRoot );
|
||
+ void activated( const QModelIndex& index );
|
||
|
||
private:
|
||
QTreeView* m_dirView;
|
||
QTreeView* m_fileView;
|
||
QSplitter* m_splitter;
|
||
DirProxyModel* m_dirProxy;
|
||
- QModelIndexList m_currentSelection;
|
||
bool m_expanded;
|
||
};
|
||
}
|
||
diff -ru src/projects/k3bvcdview.cpp src/projects/k3bvcdview.cpp
|
||
--- src/projects/k3bvcdview.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/projects/k3bvcdview.cpp 2009-07-23 11:42:02.000000000 +0200
|
||
@@ -2,6 +2,7 @@
|
||
*
|
||
* Copyright (C) 2003-2004 Christian Kvasny <chris@k3b.org>
|
||
* (C) 2009 Arthur Renato Mello <arthur@mandriva.com>
|
||
+* (C) 2009 Michal Malek <michalm@jabster.pl>
|
||
*
|
||
* This file is part of the K3b project.
|
||
* Copyright (C) 1998-2009 Sebastian Trueg <trueg@k3b.org>
|
||
@@ -96,15 +97,19 @@
|
||
}
|
||
|
||
|
||
-void K3b::VcdView::contextMenuForSelection(const QModelIndexList &selectedIndexes, const QPoint &pos)
|
||
+void K3b::VcdView::selectionChanged( const QModelIndexList& indexes )
|
||
{
|
||
- if( selectedIndexes.count() >= 1 ) {
|
||
+ if( indexes.count() >= 1 ) {
|
||
m_actionRemove->setEnabled(true);
|
||
}
|
||
else {
|
||
m_actionRemove->setEnabled(false);
|
||
}
|
||
+}
|
||
+
|
||
|
||
+void K3b::VcdView::contextMenu( const QPoint& pos )
|
||
+{
|
||
m_popupMenu->popup( pos );
|
||
}
|
||
|
||
diff -ru src/projects/k3bvcdview.h src/projects/k3bvcdview.h
|
||
--- src/projects/k3bvcdview.h 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/projects/k3bvcdview.h 2009-07-23 11:42:02.000000000 +0200
|
||
@@ -2,6 +2,7 @@
|
||
*
|
||
* Copyright (C) 2003-2004 Christian Kvasny <chris@k3b.org>
|
||
* (C) 2009 Arthur Renato Mello <arthur@mandriva.com>
|
||
+* (C) 2009 Michal Malek <michalm@jabster.pl>
|
||
*
|
||
* This file is part of the K3b project.
|
||
* Copyright (C) 1998-2009 Sebastian Trueg <trueg@k3b.org>
|
||
@@ -49,7 +50,11 @@
|
||
~VcdView();
|
||
|
||
private Q_SLOTS:
|
||
- void contextMenuForSelection(const QModelIndexList &selectedIndexes, const QPoint &pos);
|
||
+ /**
|
||
+ * reimplemented from @ref StandardView
|
||
+ */
|
||
+ virtual void selectionChanged( const QModelIndexList& indexes );
|
||
+ virtual void contextMenu( const QPoint& pos );
|
||
void showPropertiesDialog();
|
||
|
||
protected:
|
||
diff -ru src/projects/k3bvideodvdburndialog.cpp src/projects/k3bvideodvdburndialog.cpp
|
||
--- src/projects/k3bvideodvdburndialog.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/projects/k3bvideodvdburndialog.cpp 2009-07-23 11:42:02.000000000 +0200
|
||
@@ -31,6 +31,7 @@
|
||
#include <kio/global.h>
|
||
#include <kmessagebox.h>
|
||
|
||
+#include <QFileInfo>
|
||
#include <qlayout.h>
|
||
#include <qcheckbox.h>
|
||
#include <qlabel.h>
|
||
diff -ru src/projects/k3bvideodvdview.cpp src/projects/k3bvideodvdview.cpp
|
||
--- src/projects/k3bvideodvdview.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/projects/k3bvideodvdview.cpp 2009-07-23 11:42:02.000000000 +0200
|
||
@@ -2,6 +2,7 @@
|
||
*
|
||
* Copyright (C) 2005-2007 Sebastian Trueg <trueg@k3b.org>
|
||
* (C) 2009 Arthur Renato Mello <arthur@mandriva.com>
|
||
+ * (C) 2009 Michal Malek <michalm@jabster.pl>
|
||
*
|
||
* This file is part of the K3b project.
|
||
* Copyright (C) 1998-2009 Sebastian Trueg <trueg@k3b.org>
|
||
@@ -14,46 +15,25 @@
|
||
*/
|
||
|
||
#include "k3bvideodvdview.h"
|
||
-#include "k3bvideodvddoc.h"
|
||
-#include "k3bdataprojectmodel.h"
|
||
#include "k3bvideodvdburndialog.h"
|
||
-//#include "k3bdatadirtreeview.h"
|
||
-//#include "k3bdatafileview.h"
|
||
-#include "k3bdataurladdingdialog.h"
|
||
-#include "k3bfillstatusdisplay.h"
|
||
-#include "k3bprojectplugin.h"
|
||
-
|
||
-#include <klocale.h>
|
||
-#include <kmessagebox.h>
|
||
-#include <kactioncollection.h>
|
||
+#include "k3bvideodvddoc.h"
|
||
|
||
-#include <qsplitter.h>
|
||
+#include <KAction>
|
||
+#include <KLocale>
|
||
+#include <KMessageBox>
|
||
|
||
|
||
K3b::VideoDvdView::VideoDvdView( K3b::VideoDvdDoc* doc, QWidget *parent )
|
||
- : K3b::StandardView( doc, parent ),
|
||
+ : K3b::DataView( doc, parent ),
|
||
m_doc(doc)
|
||
{
|
||
- m_model = new K3b::DataProjectModel(m_doc, this);
|
||
- // set the model for the K3b::StandardView's views
|
||
- setModel(m_model);
|
||
-
|
||
-#if 0
|
||
- // --- setup GUI ---------------------------------------------------
|
||
- QSplitter* mainSplitter = new QSplitter( this );
|
||
- m_dataDirTree = new K3b::DataDirTreeView( this, doc, mainSplitter );
|
||
- m_dataFileView = new K3b::DataFileView( this, doc, mainSplitter );
|
||
- mainSplitter->setStretchFactor( 0, 1 );
|
||
- mainSplitter->setStretchFactor( 1, 3 );
|
||
- setMainWidget( mainSplitter );
|
||
-
|
||
- connect( m_dataFileView, SIGNAL(dirSelected(K3b::DirItem*)), m_dataDirTree, SLOT(setCurrentDir(K3b::DirItem*)) );
|
||
-#endif
|
||
- addPluginButtons( K3b::ProjectPlugin::VIDEO_DVD );
|
||
+ m_actionImportSession->setEnabled( false );
|
||
+ m_actionImportSession->setVisible( false );
|
||
+ m_actionClearSession->setEnabled( false );
|
||
+ m_actionClearSession->setVisible( false );
|
||
+ m_actionEditBootImages->setEnabled( false );
|
||
+ m_actionEditBootImages->setVisible( false );
|
||
}
|
||
-#ifdef __GNUC__
|
||
-#warning get the currentDir connections from K3b::DataView or maybe inherit from it
|
||
-#endif
|
||
|
||
|
||
K3b::VideoDvdView::~VideoDvdView()
|
||
@@ -79,11 +59,4 @@
|
||
}
|
||
|
||
|
||
-void K3b::VideoDvdView::addUrls( const KUrl::List& urls )
|
||
-{
|
||
- /*
|
||
- K3b::DataUrlAddingDialog::addUrls( urls, m_dataFileView->currentDir() );
|
||
- */
|
||
-}
|
||
-
|
||
#include "k3bvideodvdview.moc"
|
||
diff -ru src/projects/k3bvideodvdview.h src/projects/k3bvideodvdview.h
|
||
--- src/projects/k3bvideodvdview.h 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/projects/k3bvideodvdview.h 2009-07-23 11:42:02.000000000 +0200
|
||
@@ -2,6 +2,7 @@
|
||
*
|
||
* Copyright (C) 2005-2007 Sebastian Trueg <trueg@k3b.org>
|
||
* (C) 2009 Arthur Renato Mello <arthur@mandriva.com>
|
||
+ * (C) 2009 Michal Malek <michalm@jabster.pl>
|
||
*
|
||
* This file is part of the K3b project.
|
||
* Copyright (C) 1998-2009 Sebastian Trueg <trueg@k3b.org>
|
||
@@ -17,13 +18,12 @@
|
||
#ifndef _K3B_VIDEO_DVDVIEW_H_
|
||
#define _K3B_VIDEO_DVDVIEW_H_
|
||
|
||
-#include "k3bstandardview.h"
|
||
+#include "k3bdataview.h"
|
||
|
||
namespace K3b {
|
||
class VideoDvdDoc;
|
||
- class DataProjectModel;
|
||
|
||
- class VideoDvdView : public StandardView
|
||
+ class VideoDvdView : public DataView
|
||
{
|
||
Q_OBJECT
|
||
|
||
@@ -31,8 +31,6 @@
|
||
VideoDvdView( VideoDvdDoc* doc, QWidget *parent = 0 );
|
||
~VideoDvdView();
|
||
|
||
- void addUrls( const KUrl::List& );
|
||
-
|
||
protected:
|
||
virtual ProjectBurnDialog* newBurnDialog( QWidget* parent = 0 );
|
||
|
||
@@ -40,9 +38,6 @@
|
||
|
||
private:
|
||
VideoDvdDoc* m_doc;
|
||
- //DataDirTreeView* m_dataDirTree;
|
||
- //DataFileView* m_dataFileView;
|
||
- K3b::DataProjectModel* m_model;
|
||
};
|
||
}
|
||
|
||
diff -ru src/projects/k3bview.cpp src/projects/k3bview.cpp
|
||
--- src/projects/k3bview.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/projects/k3bview.cpp 2009-07-23 11:42:02.000000000 +0200
|
||
@@ -117,13 +117,13 @@
|
||
}
|
||
|
||
|
||
-void K3b::View::addPluginButtons( int projectType )
|
||
+void K3b::View::addPluginButtons()
|
||
{
|
||
QList<K3b::Plugin*> pl = k3bcore->pluginManager()->plugins( "ProjectPlugin" );
|
||
for( QList<K3b::Plugin*>::const_iterator it = pl.constBegin();
|
||
it != pl.constEnd(); ++it ) {
|
||
K3b::ProjectPlugin* pp = dynamic_cast<K3b::ProjectPlugin*>( *it );
|
||
- if( pp && (pp->type() & projectType) ) {
|
||
+ if( pp && (pp->type() & m_doc->type()) ) {
|
||
QAction* button = toolBox()->addAction( pp->text(),
|
||
this,
|
||
SLOT(slotPluginButtonClicked()) );
|
||
diff -ru src/projects/k3bview.h src/projects/k3bview.h
|
||
--- src/projects/k3bview.h 2009-02-22 23:46:14.000000000 +0100
|
||
+++ src/projects/k3bview.h 2009-07-23 11:42:02.000000000 +0200
|
||
@@ -86,10 +86,8 @@
|
||
/**
|
||
* Call this to add the projectplugin buttons to the toolbox. It is not called
|
||
* automatically to make it possible to add other buttons before.
|
||
- *
|
||
- * @param projectType the type of the project (@see ProjectPlugin)
|
||
*/
|
||
- void addPluginButtons( int projectType );
|
||
+ void addPluginButtons();
|
||
|
||
FillStatusDisplay* fillStatusDisplay() const { return m_fillStatusDisplay; }
|
||
KToolBar* toolBox() const { return m_toolBox; }
|
||
diff -ru src/rip/k3baudioripjob.cpp src/rip/k3baudioripjob.cpp
|
||
--- src/rip/k3baudioripjob.cpp 2009-05-27 11:58:34.000000000 +0200
|
||
+++ src/rip/k3baudioripjob.cpp 2009-07-23 11:42:04.000000000 +0200
|
||
@@ -284,9 +284,6 @@
|
||
return false;
|
||
}
|
||
else {
|
||
- if( k3bcore->globalSettings()->ejectMedia() )
|
||
- K3b::eject( m_device );
|
||
-
|
||
return success;
|
||
}
|
||
}
|
||
diff -ru src/rip/videodvd/k3bvideodvdrippingtitlelistview.cpp src/rip/videodvd/k3bvideodvdrippingtitlelistview.cpp
|
||
--- src/rip/videodvd/k3bvideodvdrippingtitlelistview.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/rip/videodvd/k3bvideodvdrippingtitlelistview.cpp 2009-07-23 11:42:04.000000000 +0200
|
||
@@ -243,7 +243,7 @@
|
||
case 1:
|
||
// Title X + length
|
||
return i18n("<p><b>Title %1 (%2)</b><br>%3",
|
||
- QString::number( m_title.titleNumber(), 2 ),
|
||
+ QString::number( m_title.titleNumber() ).rightJustified( 2 ),
|
||
m_title.playbackTime().toString( false ),
|
||
i18np("%1 chapter", "%1 chapters", m_title.numPTTs() ) );
|
||
|
||
diff -ru src/rip/videodvd/k3bvideodvdrippingwidget.cpp src/rip/videodvd/k3bvideodvdrippingwidget.cpp
|
||
--- src/rip/videodvd/k3bvideodvdrippingwidget.cpp 2009-04-21 19:54:02.000000000 +0200
|
||
+++ src/rip/videodvd/k3bvideodvdrippingwidget.cpp 2009-04-24 10:39:13.000000000 +0200
|
||
@@ -26,7 +26,10 @@
|
||
#include <kurllabel.h>
|
||
#include <kdialog.h>
|
||
#include <klineedit.h>
|
||
+#include <kdeversion.h>
|
||
+#if KDE_IS_VERSION(4,2,0)
|
||
#include <KDiskFreeSpaceInfo>
|
||
+#endif
|
||
|
||
#include <qcombobox.h>
|
||
#include <qspinbox.h>
|
||
@@ -255,10 +258,17 @@
|
||
path.truncate( path.lastIndexOf('/') );
|
||
|
||
QPalette pal( m_labelFreeSpace->palette() );
|
||
+#if KDE_IS_VERSION(4,2,0)
|
||
KDiskFreeSpaceInfo free = KDiskFreeSpaceInfo::freeSpaceInfo( path );
|
||
if( free.isValid() ) {
|
||
m_labelFreeSpace->setText( KIO::convertSizeFromKiB(free.available()) );
|
||
if( free.available() < m_neededSize/1024 )
|
||
+#else
|
||
+ unsigned long size, avail;
|
||
+ if( K3b::kbFreeOnFs( path, size, avail ) ) {
|
||
+ m_labelFreeSpace->setText( KIO::convertSizeFromKiB(avail) );
|
||
+ if( avail < m_neededSize/1024 )
|
||
+#endif
|
||
pal.setColor( QPalette::Text, Qt::red );
|
||
else
|
||
pal.setColor( QPalette::Text, palette().color( QPalette::Text ) );
|