<?xml version="1.0" encoding="UTF-8"?>
<!-- Copyright (c) 2006 Nokia Corporation and/or its subsidiary(-ies). -->
<!-- All rights reserved. -->
<!-- This component and the accompanying materials are made available -->
<!-- under the terms of the License "Eclipse Public License v1.0" -->
<!-- which accompanies this distribution, and is available -->
<!-- at the URL "http://www.eclipse.org/legal/epl-v10.html". -->

<componentDefinition xmlns="http://www.nokia.com/sdt/emf/component" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
	<enumPropertyDeclaration qualifiedName="com.nokia.sdt.series60.StandardNote.type">
		<enumElement value="CAknConfirmationNote"/>
		<enumElement value="CAknInformationNote"/>
		<enumElement value="CAknWarningNote"/>
		<enumElement value="CAknErrorNote"/>
	</enumPropertyDeclaration>

	<component baseComponent="com.nokia.sdt.series60.NonLayoutBase" 
		friendlyName="%friendlyName" 
		qualifiedName="com.nokia.sdt.series60.StandardNote" 
		category="NotesDialogs"
		instanceNameRoot="note"
		version="1.0">
		<documentation>
			<information>%information</information>
		</documentation>
		<symbian sdkName="com.nokia.series60" minSDKVersion="2.0" 
			className="CAknResourceNoteDialog" classHelpTopic=""
			resourceType="AVKON_NOTE" resourceHelpTopic="" />
		<designerImages smallIconFile="StandardNote_sm.png" 
			largeIconFile="StandardNote.png"/>
		<attributes>
			<attribute key="is-transient-object">true</attribute>
			<attribute key="is-non-resizable-or-moveable-layout-object">true</attribute>
		</attributes>
		<properties>
			<compoundProperty category="Hidden" name="location" type="com.nokia.sdt.series60.locationProperty"
				editorClass="com.nokia.sdt.symbian.ui.editors.ReadOnlySummaryEditorFactory"/>
			<compoundProperty category="Hidden" name="size" type="com.nokia.sdt.series60.sizeProperty"
				editorClass="com.nokia.sdt.symbian.ui.editors.ReadOnlySummaryEditorFactory"/>
			<enumProperty category="Appearance" name="type" type="com.nokia.sdt.series60.StandardNote.type" 
				default="CAknConfirmationNote"
				descriptionKey="typeDescription" />
			<property category="Data" name="text" type="localizedString" 
				default="Note" descriptionKey="textDescription"
				editorClass="com.nokia.sdt.symbian.ui.editors.ScalableTextEditorFactory" />
		</properties>
		<implementations>
			<implementation>
				<interface id="com.nokia.sdt.datamodel.adapter.IVisualAppearance"/>
				<interface id="com.nokia.sdt.datamodel.adapter.IDirectLabelEdit"/>
				<script file="StandardNote_visual.js" prototype="StandardNoteVisual"/>
			</implementation>
			<implementation>
				<interface id="com.nokia.sdt.datamodel.adapter.ILayout"/>
				<interface id="com.nokia.sdt.datamodel.adapter.IComponentInstancePropertyListener"/> 
				<script file="StandardNote_layout.js" prototype="StandardNoteLayout"/>
			</implementation>
		</implementations>
		<sourceMapping>
			<mapResource struct="TBUF" headers="eikon.rh">
				<mapSimpleMember property="text" member="buf"/>
			</mapResource>
		</sourceMapping>
		<sourceGen>
			<template phase="ClassMethods">
static void Run${instanceName$title}L( const TDesC* aOverrideText = NULL );
			</template>
			<defineLocation id="MethodLocation" baseLocation="MAIN_FILE" 
				owned="true"
				location="function(${className}::Run${instanceName$title}L(const TDesC*))">
				<template>
/**
 * Show the popup note for ${instanceName}
 * @param aOverrideText optional override text
 */
void ${className}::Run${instanceName$title}L( const TDesC* aOverrideText )
	{
	}
				</template>
			</defineLocation>
			<template location="MethodLocation">
${properties.type}* note = new ( ELeave ) ${properties.type}();
if ( aOverrideText == NULL )
	{
	HBufC* noteText = StringLoader::LoadLC( ${resourceName$upper} );
	note->ExecuteLD( *noteText );
	CleanupStack::PopAndDestroy( noteText );
	}
else
	{
	note->ExecuteLD( *aOverrideText );
	}
			</template>

			<template phase="MainSystemIncludes"><![CDATA[
#include <aknnotewrappers.h>
]]>			</template>
			<template phase="MainSystemIncludes"><![CDATA[
#include <barsread.h>
]]>			</template>
			<template phase="MainSystemIncludes"><![CDATA[
#include <stringloader.h>
]]>			</template>
			
		</sourceGen>
	</component>
	
</componentDefinition>
