locationmapnavfw/library/src/mnnavigationserviceclient.cpp
changeset 0 667063e416a2
equal deleted inserted replaced
-1:000000000000 0:667063e416a2
       
     1 /*
       
     2 * Copyright (c) 2005-2006 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:  RMnNavigationServiceClient class implementation
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #include <e32base.h>
       
    20 
       
    21 #include <EPos_CPosLandmark.h>
       
    22 #include <epos_poslandmarkserialization.h>
       
    23 
       
    24 #include "mndebug.h"
       
    25 #include "mninternal.h"
       
    26 #include "mnerrors.h"
       
    27 
       
    28 #include "mnappserviceuids.hrh"
       
    29 #include "mnnavigationserviceclient.h"
       
    30 
       
    31 // ======== LOCAL FUNCTIONS ========
       
    32 
       
    33 // ======== MEMBER FUNCTIONS ========
       
    34 
       
    35 // ---------------------------------------------------------------------------
       
    36 // ---------------------------------------------------------------------------
       
    37 //
       
    38 RMnNavigationServiceClient::RMnNavigationServiceClient()
       
    39     {
       
    40     }
       
    41 
       
    42 // ---------------------------------------------------------------------------
       
    43 // ---------------------------------------------------------------------------
       
    44 //
       
    45 RMnNavigationServiceClient::~RMnNavigationServiceClient()
       
    46     {
       
    47     }
       
    48 
       
    49 // ---------------------------------------------------------------------------
       
    50 // ---------------------------------------------------------------------------
       
    51 //
       
    52 void RMnNavigationServiceClient::NavigateToL( const CPosLandmark& aDestinationLanmdark )
       
    53     {
       
    54     LOG("RMnNavigationServiceClient::NavigateToL");
       
    55     TIpcArgs args;
       
    56     
       
    57     // landmark
       
    58     HBufC8* lmBuf = PosLandmarkSerialization::PackL( aDestinationLanmdark ); 
       
    59     CleanupStack::PushL( lmBuf );
       
    60 
       
    61     args.Set( EMnIpcNaviLandmarkParamIndex, lmBuf );
       
    62     
       
    63     User::LeaveIfError( SendReceive( EMnIpcNavigateTo, args ) );
       
    64     CleanupStack::PopAndDestroy( lmBuf );
       
    65     }
       
    66 
       
    67 // ---------------------------------------------------------------------------
       
    68 // From class RApaAppServiceBase.
       
    69 // ---------------------------------------------------------------------------
       
    70 //
       
    71 TUid RMnNavigationServiceClient::ServiceUid() const
       
    72     { 
       
    73     return TUid::Uid(KMnAppNavigationService); 
       
    74     }