summaryrefslogtreecommitdiffstats
path: root/noatun/modules/simple/propertiesdialog.ui.h
diff options
context:
space:
mode:
authortoma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2009-11-25 17:56:58 +0000
committertoma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2009-11-25 17:56:58 +0000
commite2de64d6f1beb9e492daf5b886e19933c1fa41dd (patch)
tree9047cf9e6b5c43878d5bf82660adae77ceee097a /noatun/modules/simple/propertiesdialog.ui.h
downloadtdemultimedia-e2de64d6f1beb9e492daf5b886e19933c1fa41dd.tar.gz
tdemultimedia-e2de64d6f1beb9e492daf5b886e19933c1fa41dd.zip
Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features.
BUG:215923 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdemultimedia@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'noatun/modules/simple/propertiesdialog.ui.h')
-rw-r--r--noatun/modules/simple/propertiesdialog.ui.h58
1 files changed, 58 insertions, 0 deletions
diff --git a/noatun/modules/simple/propertiesdialog.ui.h b/noatun/modules/simple/propertiesdialog.ui.h
new file mode 100644
index 00000000..a712d776
--- /dev/null
+++ b/noatun/modules/simple/propertiesdialog.ui.h
@@ -0,0 +1,58 @@
+/*
+ This file is part of KDE/aRts (Noatun) - xine integration
+ Copyright (C) 2002 Ewald Snel <ewald@rambo.its.tudelft.nl>
+
+ This library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 of the License, or (at your option) any later version.
+*/
+
+#include <klocale.h>
+
+void PropertiesDialog::setPlayObject( PlaylistItem pi, Arts::PlayObject po )
+{
+ // Arts::PlayObject properties
+ if (!po.isNull())
+ {
+ Arts::poCapabilities ncaps = po.capabilities();
+ QCheckListItem *item;
+
+ descriptionLabel->setText( po.description().c_str() );
+
+ // Determine capabilities
+ if (!(item = (QCheckListItem *)capsList->findItem( "capSeek", 0 )))
+ {
+ item = new QCheckListItem( capsList, "capSeek",
+ QCheckListItem::CheckBox );
+ }
+ item->setOn( (ncaps & Arts::capSeek) );
+
+ if (!(item = (QCheckListItem *)capsList->findItem( "capPause", 0 )))
+ {
+ item = new QCheckListItem( capsList, "capPause",
+ QCheckListItem::CheckBox );
+ }
+ item->setOn( (ncaps & Arts::capPause) );
+
+ // Defaults
+ nameField->setText( i18n("unknown") );
+ typeLabel->setText( i18n("unknown") );
+ lengthLabel->setText( i18n("unknown") );
+ audioLabel->setText( i18n("unknown") );
+ videoLabel->setText( i18n("unknown") );
+ }
+
+ // PlaylistItem properties (name and mimetype)
+ if (!pi.isNull())
+ {
+ setCaption( i18n("Properties for %1").arg(pi.url().fileName()) );
+
+ KSharedPtr<KMimeType> mime = KMimeType::mimeType( pi.mimetype() );
+ iconLabel->setPixmap( mime->pixmap( KIcon::Desktop, KIcon::SizeMedium ) );
+
+ nameField->setText( pi.url().fileName() );
+ typeLabel->setText( pi.mimetype() );
+ lengthLabel->setText( pi.lengthString() );
+ }
+}