qtinternetradio/ui/src/irdocumentloader.cpp
changeset 3 ee64f059b8e1
parent 0 09774dfdd46b
child 14 896e9dbc5f19
--- a/qtinternetradio/ui/src/irdocumentloader.cpp	Mon May 03 12:25:23 2010 +0300
+++ b/qtinternetradio/ui/src/irdocumentloader.cpp	Fri May 14 15:43:29 2010 +0300
@@ -14,84 +14,13 @@
 * Description:
 *
 */
-
-#include "irdocumentloader.h"
-#include "irbannerlabel.h"
-#include "ircombobox.h"
-#include "irlineeditor.h"
-
-IRDocumentLoader::IRDocumentLoader(QObject *aParent) : iParent(aParent)
-{
-    
-}
-
-QObjectList IRDocumentLoader::load(const QString &aFileName, const QString &aSection, QObject *aParent)
-{
-    bool ok = false;
-    QObjectList list = HbDocumentLoader::load(aFileName, aSection, &ok);
-    Q_ASSERT_X(ok, "void IRDocumentLoader::load(const QString &aFileName, const QString &aSection)", "load failed");
-    
-    int size = list.count();
-    QObject *parent = aParent ? aParent : iParent;
-    for (int i = 0; i < size; i++)
-    {
-        QObject *obj = list[i];
-        if (obj != parent)
-        {
-            obj->setParent(parent);
-        }
-    }
-    
-    return list;
-}
-
-QObjectList IRDocumentLoader::load(const QString &aFileName, QObject *aParent)
-{
-    bool ok = false;
-    QObjectList list = HbDocumentLoader::load(aFileName, &ok);
-    Q_ASSERT_X(ok, "void IRDocumentLoader::load(const QString &aFileName)", "load failed");
-    
-    int size = list.count();
-    QObject *parent = aParent ? aParent : iParent;
-    for (int i = 0; i < size; i++)
-    {
-        QObject *obj = list[i];
-        if (obj != parent)
-        {
-            obj->setParent(parent);
-        }
-    }
-    
-    return list;
-}
+#include <HbTextItem>
+#include <HbMarqueeItem>
+#include "irdocumentloader.h" 
 
 QObject *IRDocumentLoader::createObject(const QString& aType, const QString &aName)
 {
-    if (aType == IrViewBannerLabel::staticMetaObject.className())
-    {
-        QObject *object = new IrViewBannerLabel();
-        object->setObjectName(aName);
-        return object;
-    }
-    else if(aType == IrNowPlayingBannerLabel::staticMetaObject.className())
-    {
-        QObject *object = new IrNowPlayingBannerLabel();
-        object->setObjectName(aName);
-        return object;
-    }
-    else if(aType == IrComboBox::staticMetaObject.className())
-    {
-        QObject *object = new IrComboBox();
-        object->setObjectName(aName);
-        return object;
-    }
-    else if(aType == IrLineEditor::staticMetaObject.className())
-    {
-        QObject *object = new IrLineEditor();
-        object->setObjectName(aName);
-        return object;
-    }
-    else if (aType == HbTextItem::staticMetaObject.className())
+    if (aType == HbTextItem::staticMetaObject.className())
     {
         QObject *object = new HbTextItem;
         object->setObjectName(aName);