diff -r a2b50a479edf -r 6df133bd92e1 radioapp/radiowidgets/inc/radiohistoryview.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/radioapp/radiowidgets/inc/radiohistoryview.h Fri Jun 04 10:21:36 2010 +0100 @@ -0,0 +1,93 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + +#ifndef RADIOHISTORYVIEW_H +#define RADIOHISTORYVIEW_H + +// System includes +#include +#include + +// User includes +#include "radioviewbase.h" +#include "radiowidgetsexport.h" + +// Forward declarations +class RadioXmlUiLoader; +class HbListView; +class HbAction; +class HbAbstractViewItem; +class RadioHistoryModel; +class RadioHistoryItem; + +// Class declaration +class WIDGETS_DLL_EXPORT RadioHistoryView : public RadioViewBase +{ + Q_OBJECT + Q_PROPERTY(HbIcon nonTaggedIcon READ nonTaggedIcon WRITE setNonTaggedIcon) + Q_PROPERTY(HbIcon taggedIcon READ taggedIcon WRITE setTaggedIcon) + +public: + + RadioHistoryView(); + ~RadioHistoryView(); + + void setNonTaggedIcon( const HbIcon& nonTaggedIcon ); + HbIcon nonTaggedIcon() const; + + void setTaggedIcon( const HbIcon& taggedIcon ); + HbIcon taggedIcon() const; + +private slots: + + void deckButtonPressed(); + void clearList(); + void updateVisibilities(); + void showContextMenu( const QModelIndex& index ); + void toggleTagging(); + void openOviStore(); + void openOtherStore(); + void addSongs(); // Temporary test code + void addOneSong(); // Temporary test code + +private: + +// from base class RadioViewBase + + void init(); + void setOrientation(); + void userAccepted(); + +// New functions + + RadioHistoryModel& historyModel() const; + +private: //data + + HbListView* mHistoryList; + HbAction* mAllSongsButton; + HbAction* mTaggedSongsButton; + QScopedPointer mSelectedItem; + int mCurrentRow; + HbIcon mNonTaggedIcon; + HbIcon mTaggedIcon; + + int mSongIndex; // Temporary test variable + +}; + +#endif // RADIOHISTORYVIEW_H