imagingandcamerafws/cameraunittest/src/ECamUnitTestPlugin/directviewfinder.cpp
changeset 0 40261b775718
equal deleted inserted replaced
-1:000000000000 0:40261b775718
       
     1 // Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     2 // All rights reserved.
       
     3 // This component and the accompanying materials are made available
       
     4 // under the terms of "Eclipse Public License v1.0"
       
     5 // which accompanies this distribution, and is available
       
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     7 //
       
     8 // Initial Contributors:
       
     9 // Nokia Corporation - initial contribution.
       
    10 //
       
    11 // Contributors:
       
    12 //
       
    13 // Description:
       
    14 //
       
    15 
       
    16 #include "directviewfinder.h"
       
    17 
       
    18 /**
       
    19 *	For Direct View Finder Pause/Resume functionality
       
    20 */
       
    21 CCamDirectViewFinder* CCamDirectViewFinder::NewL(CCamUnitTestPlugin& aOwner)
       
    22 	{
       
    23 	return new (ELeave) CCamDirectViewFinder(aOwner);
       
    24 	}
       
    25 	
       
    26 CCamDirectViewFinder::~CCamDirectViewFinder()
       
    27 	{
       
    28 	}
       
    29 	
       
    30 CCamDirectViewFinder::CCamDirectViewFinder(CCamUnitTestPlugin& aOwner):iOwner(aOwner),
       
    31 																	   iVFState(CCamera::CCameraDirectViewFinder::EViewFinderInActive)
       
    32 	{
       
    33 	}
       
    34 
       
    35 void CCamDirectViewFinder::PauseViewFinderDirectL()
       
    36 	{
       
    37 	// dummy implementation
       
    38 	// Pause view finder
       
    39 	// Boundary checking of CCamera::ViewFinderActive() = ETrue should be there in real implementation 
       
    40 	// otherwise Leave with KErrECamSettingDisabled
       
    41 			
       
    42 	iVFState = CCamera::CCameraDirectViewFinder::EViewFinderPause;
       
    43 	}
       
    44 	
       
    45 void CCamDirectViewFinder::ResumeViewFinderDirectL()
       
    46 	{
       
    47 	// dummy implementation
       
    48 	// Resume view finder
       
    49 	// Boundary checking of CCamera::ViewFinderActive() = ETrue should be there in real implementation 
       
    50 	// otherwise Leave with KErrECamSettingDisabled
       
    51 			
       
    52 	iVFState = CCamera::CCameraDirectViewFinder::EViewFinderActive;
       
    53 	}
       
    54 	
       
    55 CCamera::CCameraDirectViewFinder::TViewFinderState CCamDirectViewFinder::ViewFinderState() const
       
    56 	{
       
    57 	return iVFState;
       
    58 	}
       
    59 
       
    60 void CCamDirectViewFinder::Release()
       
    61 	{
       
    62 	delete this;
       
    63 	}