calendarui/calenviewerservice/inc/calenviewerservice.h
author Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
Wed, 23 Jun 2010 18:11:28 +0300
changeset 49 5de72ea7a065
permissions -rw-r--r--
Revision: 201023 Kit: 2010125

/*
* Copyright (c) 2010 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 __CALEN_VIEWER_SERVICE_H__
#define __CALEN_VIEWER_SERVICE_H__

// System includes
#include <xqserviceprovider.h>
#include <xqsharablefile.h>

// Forward declarations
class AgendaUtil;
class AgendaEventViewer;

class CalenViewerService : public XQServiceProvider
{
    Q_OBJECT
public:
	CalenViewerService(QObject *parent = 0);
	~CalenViewerService();

public slots:
	bool view(QString file);
	bool view(XQSharableFile file);
	
private slots:
    void entryViewReady(int error);
    void handleClientDisconnected();
    
private:
    void viewEntry();
    void complete(bool ok);
    
private:
    QString mFileName;
    AgendaUtil *mAgendaUtil;
    AgendaEventViewer *mViewer;
    bool mEntryViewReady;
    bool mWaitingForEntryViewReady;
    int mAsyncReqIndex;
};

#endif		// __CALEN_VIEWER_SERVICE_H__