ui/viewmanagement/statehandler/src/glxdetailstate.cpp
branchRCL_3
changeset 59 8e5f6eea9c9f
equal deleted inserted replaced
57:ea65f74e6de4 59:8e5f6eea9c9f
       
     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:   ?Description
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 #include <glxdetailstate.h>
       
    21 
       
    22 GlxDetailState::GlxDetailState(GlxState *preState) : GlxState(GLX_DETAILSVIEW_ID, preState)
       
    23 {
       
    24 	mState = NO_DETAIL_S ;
       
    25 }
       
    26 
       
    27 
       
    28 void GlxDetailState::eventHandler(qint32 &id)
       
    29 {
       
    30     Q_UNUSED(id)	
       
    31 }
       
    32 
       
    33 void GlxDetailState::setTranstionParameter(NavigationDir dir, GlxEffect &effect, GlxViewEffect &viewEffect)
       
    34 {
       
    35     GlxState *preState = previousState();
       
    36     effect = NO_EFFECT ;
       
    37     viewEffect = NO_VIEW ;
       
    38     
       
    39     if ( preState == NULL ) {
       
    40         return ;        
       
    41     }
       
    42     
       
    43     if ( dir == FORWARD_DIR ){
       
    44          if ( preState->compare( GLX_FULLSCREENVIEW_ID ) ) {
       
    45              effect = FULLSCREEN_TO_DETAIL ;
       
    46              viewEffect = BOTH_VIEW ;
       
    47          }
       
    48     }    
       
    49     else if ( dir == BACKWARD_DIR ) {
       
    50         if ( preState->compare( GLX_FULLSCREENVIEW_ID ) ) {
       
    51             effect = DETAIL_TO_FULLSCREEN;
       
    52             viewEffect = BOTH_VIEW;
       
    53         }       
       
    54     }    
       
    55 }
       
    56