navienginebsp/naviengine_assp/staticextension.cpp
author William Roberts <williamr@symbian.org>
Fri, 01 Oct 2010 11:40:18 +0100
changeset 2 048b58430d46
parent 0 5de814552237
permissions -rw-r--r--
Comment out sdcontroller MMP files, which can't be built from the contributed source code.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
0
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
     1
/*
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
     2
* Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
     3
* All rights reserved.
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
     4
* This component and the accompanying materials are made available
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
     5
* under the terms of "Eclipse Public License v1.0"
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
     6
* which accompanies this distribution, and is available
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
     7
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
     8
*
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
     9
* Initial Contributors:
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    10
* Nokia Corporation - initial contribution.
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    11
*
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    12
* Contributors:
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    13
*
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    14
* Description:
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    15
*
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    16
*/
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    17
#include <dfcs.h>
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    18
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    19
#ifdef __USE_GPIO_STATIC_EXTENSION__
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    20
// test standard extension handler number. *DO NOT USE*
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    21
#define KTestStaticExtension 0x80000000
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    22
#include <staticextension.h>
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    23
#endif
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    24
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    25
#include <gpio.h>
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    26
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    27
EXPORT_C TInt GPIO::StaticExtension(TInt /*aId*/, TInt aCmd, TAny* /*aArg1*/, TAny* /*aArg2*/)
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    28
	{
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    29
	TInt k;
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    30
	switch (aCmd)
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    31
		{
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    32
	case ETestStaticExtension:
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    33
		k = KErrNone;
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    34
		break;
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    35
	default:
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    36
		k = KErrNotSupported;
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    37
		break;
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    38
		}
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    39
	return k;
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    40
	}
5de814552237 Initial contribution supporting NaviEngine 1
Ryan Harkin <ryan.harkin@nokia.com>
parents:
diff changeset
    41