camerauis/cameraxui/cxengine/tsrc/unit/unittest_cxecameradevice/unittest_cxecameradevice.h
branchRCL_3
changeset 24 bac7acad7cb3
parent 23 61bc0f252b2b
child 25 2c87b2808fd7
equal deleted inserted replaced
23:61bc0f252b2b 24:bac7acad7cb3
     1 /*
       
     2 * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:
       
    15 *
       
    16 */
       
    17 #ifndef UNITTEST_CXECAMERADEVICE_H
       
    18 #define UNITTEST_CXECAMERADEVICE_H
       
    19 
       
    20 #include <QObject>
       
    21 #include <QDebug>
       
    22 
       
    23 #include <ecam.h>
       
    24 #include "cxenamespace.h"
       
    25 
       
    26 class CxeCameraDevice;
       
    27 class CxeDummyCamera;
       
    28 
       
    29 class UnitTestCxeCameraDevice : public QObject, public MCameraObserver2
       
    30 {
       
    31     Q_OBJECT
       
    32 
       
    33 public:
       
    34     UnitTestCxeCameraDevice();
       
    35     ~UnitTestCxeCameraDevice();
       
    36 
       
    37     // from MCameraObserver2
       
    38     virtual void HandleEvent(const TECAMEvent& /*aEvent*/){};
       
    39     virtual void ViewFinderReady(MCameraBuffer& /*aCameraBuffer*/,TInt /*aError*/){};
       
    40     virtual void ImageBufferReady(MCameraBuffer& /*aCameraBuffer*/,TInt /*aError*/){};
       
    41     virtual void VideoBufferReady(MCameraBuffer& /*aCameraBuffer*/,TInt /*aError*/){};
       
    42 
       
    43 private slots:
       
    44     void init();
       
    45     void cleanup();
       
    46 
       
    47     void testNewCamera();
       
    48     void testReleaseCamera();
       
    49     void testDeleteCamera();
       
    50     void testSetCamera();
       
    51 
       
    52 private:
       
    53 
       
    54     // class to be tested
       
    55     CxeCameraDevice *mCameraDevice;
       
    56 
       
    57 };
       
    58 
       
    59 
       
    60 #endif /* UNITTEST_CXECAMERADEVICE_H_ */