/*
* 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 HOMESCREEN_TEST_TESTWIDGETPROVIDER_H
#define HOMESCREEN_TEST_TESTWIDGETPROVIDER_H
#include "hsiwidgetprovider.h"
#include "hswidget.h"
class TestWidget : public HsWidget
{
Q_OBJECT
public:
TestWidget(QGraphicsItem* aParent = 0, Qt::WindowFlags aFlags = 0)
: HsWidget(aParent, aFlags) {}
protected:
StartResult onStart()
{
return StartResultFinished;
}
StopResult onStop()
{
return StopResultFinished;
}
};
class TestWidgetProvider : public QObject, public IHsWidgetProvider
{
Q_OBJECT
Q_INTERFACES(IHsWidgetProvider)
public:
TestWidgetProvider();
virtual ~TestWidgetProvider();
public:
QList<HsWidgetToken> widgets();
HsWidget* createWidget(const HsWidgetToken& aToken);
private:
HsWidgetToken mTestWidgetToken;
};
#endif