/*
* Copyright (c) 2005-2007 Nokia Corporation and/or its subsidiary(-ies).
* All rights reserved.
* This component and the accompanying materials are made available
* under the terms of "Eclipse Public License v1.0"
* which accompanies this distribution, and is available
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
*
* Initial Contributors:
* Nokia Corporation - initial contribution.
*
* Contributors:
*
* Description:  Phonebook 2 store property definition resource structures.
*
*/


#ifndef PBK2STOREPROPERTY_RH
#define PBK2STOREPROPERTY_RH

/**
 * Phonebook 2 store view definition.
 */
STRUCT PHONEBOOK2_STORE_VIEW
    {
    /// Version number
    BYTE version = 0;

    /// Type of the view in the main composite view
    /// @see TPbk2ContactViewType
    BYTE viewType;

    /// Location of the view in the main composite view
    /// @see TPbk2ContactViewLocation
    BYTE viewLocation;

    /// Virtual Phonebook view definition of the view
    /// @see VPBK_CONTACT_VIEW
    STRUCT viewDefinition;

    /// Specifies the icon that is displayed in the front of the contact
    /// in names list. One of the Phonebook 2 icons or id defined
    /// in an UI extension.
    /// @see PHONEBOOK2_ICON_ID
    STRUCT iconId;
    }

/**
 * Phonebook 2 store property definition.
 */
STRUCT PHONEBOOK2_STORE_PROPERTY
    {
    /// Version number
    BYTE version = 0;

    /// URI of the store
    LTEXT storeUri;

    /// Name of the store
    LTEXT storeName;

    /// Flags for the UI
    /// @see Pbk2StoreProperty.hrh
    LONG flags = 0;

    /// View definitions for the store
    /// @see PHONEBOOK2_STORE_VIEW
    STRUCT views[];

    /// A set of item types (bits) for displaying
    /// Phonebook 2 memory information.
    /// @see Pbk2StoreProperty.hrh
    LONG memoryInfoItemTypes = 0;

    /// A link to a PHONEBOOK2_FIELD_PROPERTY_ARRAY resource.
    /// The array is for overwriting core Phonebook 2 field properties.
    /// This information is used by the presentation layer to get information
    /// about field labels, icons etc. These properties are not appended
    /// to the Phonebook 2 field property array.
    /// Use case example: it is needed to have a different label for the
    /// name field if the contact locates in the storeUri.
    LLINK fieldPropertyModifications = 0;

    /// Array of localized text string items
    /// @see PHONEBOOK2_LOCALIZED_TEXT
    STRUCT localizedResourceStrings[];
    }

/**
 * Phonebook 2 localized context sensitive text.
 */
STRUCT PHONEBOOK2_LOCALIZED_TEXT
    {
    /// The id of the context this string is used from
    WORD context;

    /// Localized string
    LTEXT text;
    }

/**
 * Phonebook 2 store property array.
 */
STRUCT PHONEBOOK2_STORE_PROPERTY_ARRAY
    {
    /// Array of store property items
    /// @see PHONEBOOK2_STORE_PROPERTY
    STRUCT items[];
    }

#endif // PBK2STOREPROPERTY_RH

// End of File
