gssettingsuis/Gs/GSCallPlugin/src/GSCallPluginContainer.cpp
author Pat Downey <patd@symbian.org>
Wed, 01 Sep 2010 12:20:44 +0100
branchRCL_3
changeset 54 7e0eff37aedb
permissions -rw-r--r--
Revert incorrect RCL_3 drop: Revision: 201033 Kit: 201035
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
54
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
     1
/*
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
     2
* Copyright (c) 2002-2007 Nokia Corporation and/or its subsidiary(-ies).
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
     3
* All rights reserved.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
     4
* This component and the accompanying materials are made available
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
     5
* under the terms of "Eclipse Public License v1.0"
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
     6
* which accompanies this distribution, and is available
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
     7
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
     8
*
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
     9
* Initial Contributors:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    10
* Nokia Corporation - initial contribution.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    11
*
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    12
* Contributors:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    13
*
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    14
* Description:  Container for the Call folder
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    15
*
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    16
*/
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    17
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    18
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    19
// INCLUDE FILES
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    20
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    21
#include "GSCallPluginContainer.h"  //for CGSCallPluginContainer
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    22
#include "GsLogger.h"               //for logging traces
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    23
#include "gssettingid.h"            //for constants
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    24
#include "GSCallPluginModel.h"      //plug-in model
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    25
#include "GSCallPlugin.h"
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    26
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    27
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    28
#include <aknlists.h>               //for CAknSettingStyleListBox
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    29
#include <PsetCli.h>                //for CPsetCli
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    30
#include <PsetSAObserver.h>         //for CPsetSAObserver
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    31
#include <PsetCSP.h>                //for CSP features
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    32
#include <gscallpluginrsc.rsg>      //for resource IDs
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    33
#include <csxhelp/cp.hlp.hrh>
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    34
#include <featmgr.h>
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    35
#include <bldvariant.hrh>
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    36
#include <gslistbox.h>              //for listbox clases
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    37
#include <aknViewAppUi.h>
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    38
#include <eikappui.h>
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    39
#include <gsfwviewuids.h>
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    40
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    41
//LOCAL CONSTANTS
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    42
_LIT( KGSNameOfClass, "CGSCallPluginContainer" );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    43
_LIT(KGSReplaceListControlChars, "\n\t\x2029");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    44
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    45
// ========================= MEMBER FUNCTIONS ================================
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    46
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    47
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    48
// Symbian OS two phased constructor
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    49
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    50
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    51
void CGSCallPluginContainer::ConstructL( const TRect& aRect )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    52
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    53
    __GSLOGSTRING("[CGSCallPluginContainer]--> CGSCallPluginContainer::ConstructL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    54
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    55
    __GSLOGSTRING("[CGSCallPluginContainer] Creating model...");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    56
    iModel = CGSCallPluginModel::NewL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    57
    __GSLOGSTRING("[CGSCallPluginContainer] Model created.");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    58
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    59
    iListBox = new ( ELeave ) CAknSettingStyleListBox;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    60
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    61
    __GSLOGSTRING("[CGSCallPluginContainer]--> ConstructL - Model created");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    62
    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    63
    iSsSettings = new (ELeave) RSSSettings;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    64
    User::LeaveIfError( iSsSettings->Open() );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    65
    __GSLOGSTRING("[CGSCallPluginContainer]--> ConstructL - SSSettings created & opened");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    66
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    67
    BaseConstructL( aRect,
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    68
                    R_GS_CALL_VIEW_TITLE,
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    69
                    R_CALL_LBX );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    70
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    71
    __GSLOGSTRING("[CGSCallPluginContainer] <--CGSCallPluginContainer::ConstructL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    72
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    73
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    74
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    75
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    76
// Destructor
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    77
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    78
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    79
CGSCallPluginContainer::~CGSCallPluginContainer()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    80
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    81
    if ( iSsSettings )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    82
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    83
        iSsSettings->Close();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    84
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    85
    delete iSsSettings;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    86
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    87
        delete iClirItems;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    88
        delete iCWItems;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    89
        delete iPCTItems;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    90
        delete iDndItems;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    91
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    92
    if ( iStillImgValues )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    93
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    94
        delete iStillImgValues;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    95
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    96
    if ( iChangeModeItems &&
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    97
         FeatureManager::FeatureSupported ( KFeatureIdJapanPrefixChange ) )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    98
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
    99
        delete iChangeModeItems;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   100
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   101
    if ( iCallDurationItems )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   102
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   103
        delete iCallDurationItems;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   104
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   105
    if ( iLongPressCallKeyItems )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   106
    	{
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   107
    	delete iLongPressCallKeyItems;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   108
    	}
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   109
    if ( iListboxItemArray )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   110
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   111
        delete iListboxItemArray;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   112
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   113
    if ( iOwnImageVtCallItems )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   114
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   115
        delete iOwnImageVtCallItems;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   116
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   117
    if ( iModel )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   118
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   119
        delete iModel;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   120
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   121
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   122
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   123
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   124
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   125
// Creates list box
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   126
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   127
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   128
void CGSCallPluginContainer::ConstructListBoxL( TInt aResLbxId )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   129
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   130
    __GSLOGSTRING("[CGSCallPluginContainer]--> CGSCallPluginContainer::ConstructListBoxL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   131
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   132
    iListBox->ConstructL( this, EAknListBoxSelectionList );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   133
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   134
    iListboxItemArray = CGSListBoxItemTextArray::NewL( aResLbxId,
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   135
        *iListBox, *iCoeEnv );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   136
    iListBox->Model()->SetItemTextArray( iListboxItemArray );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   137
    iListBox->Model()->SetOwnershipType( ELbmDoesNotOwnItemArray );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   138
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   139
    iStillImgValues =  iCoeEnv->ReadDesC16ArrayResourceL(
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   140
        R_GS_STILL_IMAGE_SETTING_PAGE_LBX );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   141
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   142
    if ( iModel->VoIPSupported() )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   143
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   144
        iClirItems = iCoeEnv->ReadDesC16ArrayResourceL(
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   145
                             R_IC_CLIR_SETTING_PAGE_LBX );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   146
        iCWItems = iCoeEnv->ReadDesC16ArrayResourceL(
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   147
                             R_IC_WAITING_SETTING_PAGE_LBX );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   148
        iPCTItems = iCoeEnv->ReadDesC16ArrayResourceL(
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   149
                             R_IC_PREFERRED_CALL_TYPE_SETTING_PAGE_LBX );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   150
        iDndItems = iCoeEnv->ReadDesC16ArrayResourceL(
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   151
                             R_IC_DND_SETTING_PAGE_LBX );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   152
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   153
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   154
    if ( FeatureManager::FeatureSupported( KFeatureIdJapanPrefixChange ) )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   155
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   156
        iChangeModeItems = iCoeEnv->ReadDesC16ArrayResourceL(
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   157
            R_GS_REPLACE_PREFIX_SETTING_PAGE_LBX );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   158
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   159
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   160
    iCallDurationItems = iCoeEnv->ReadDesC16ArrayResourceL(
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   161
            R_GS_SHOW_CALL_DURATION_SETTING_PAGE_LBX );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   162
    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   163
    iLongPressCallKeyItems = iCoeEnv->ReadDesC16ArrayResourceL(
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   164
            R_GS_LONG_PRESS_CALL_SETTING_PAGE_LBX );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   165
            
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   166
    iOwnImageVtCallItems = iCoeEnv->ReadDesC16ArrayResourceL(
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   167
            R_GS_OWN_IMAGE_VT_CALL_SETTING_PAGE_LBX );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   168
            
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   169
    CreateListBoxItemsL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   170
    __GSLOGSTRING("[CGSCallPluginContainer] <--CGSCallPluginContainer::ConstructListBoxL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   171
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   172
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   173
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   174
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   175
// Creates List box items
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   176
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   177
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   178
void CGSCallPluginContainer::CreateListBoxItemsL()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   179
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   180
    __GSLOGSTRING("[CGSCallPluginContainer]--> CGSCallPluginContainer::CreateListBoxItemsL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   181
// do not get check CSP if not using WINS
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   182
#ifndef __WINS__
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   183
    //Set CSP on, if it is not already
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   184
    if ( !iModel->GetCSPStatus() )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   185
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   186
        iModel->SetCSPActiveL( ETrue );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   187
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   188
#endif //__WINS__
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   189
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   190
    //create slide settings items
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   191
    if ( iModel->SlideSettingsShownL() )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   192
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   193
        MakeSlideSettingsItem( EGSOpeningSlideAnswerCallItemId );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   194
        MakeSlideSettingsItem( EGSClosingSlideEndCallItemId );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   195
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   196
    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   197
    //Create own number sending, call waiting soft-reject items and ccbs
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   198
    MakeONSItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   199
    MakeCWItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   200
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   201
    if ( iModel->VoIPSupported() )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   202
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   203
        MakeICClirItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   204
        MakeICWaitingItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   205
#ifndef RD_VOIP_REL_2_2 
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   206
        MakeICPreferredCallTypeItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   207
#endif // !RD_VOIP_REL_2_2
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   208
        MakeDndItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   209
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   210
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   211
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   212
    MakeSoftRejectTxtItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   213
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   214
    if ( FeatureManager::FeatureSupported(
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   215
                                 KFeatureIdCsVideoTelephony ) )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   216
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   217
        MakeStillImageItemL(); //Still Image item
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   218
        MakeOwnImageVtCallItemL(); //VT call own image mute item
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   219
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   220
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   221
    if ( FeatureManager::FeatureSupported( KFeatureIdJapanPrefixChange ) )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   222
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   223
        MakeReplacePrefixItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   224
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   225
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   226
    // Create on/off settings
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   227
    MakeCallItemL( KGSSettIdSummaryAfterCall );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   228
    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   229
    //Create line in use
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   230
    TInt als = ESSSettingsAlsNotSupported;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   231
    TInt alsError = iSsSettings->Get( ESSSettingsAls, als );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   232
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   233
    if ( als != ESSSettingsAlsNotSupported && alsError == KErrNone )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   234
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   235
        MakePLUItemL( als );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   236
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   237
        //Create Line blocking
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   238
        TInt alsBlock = ESSSettingsAlsBlockingNotSupported;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   239
        alsError = iSsSettings->Get( ESSSettingsAlsBlocking, alsBlock );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   240
        if ( alsBlock != ESSSettingsAlsBlockingNotSupported &&
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   241
             alsError == KErrNone )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   242
            {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   243
            MakePLBItemL( alsBlock );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   244
            }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   245
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   246
    MakeCallDurationItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   247
    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   248
  #ifdef RD_VT_LONG_SEND_KEY
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   249
    MakeLongPressCallKeyItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   250
  #endif
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   251
    __GSLOGSTRING("[CGSCallPluginContainer] <--CGSCallPluginContainer::CreateListBoxItemsL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   252
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   253
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   254
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   255
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   256
// Updates list box with a changed item
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   257
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   258
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   259
void CGSCallPluginContainer::UpdateListBoxL( TInt aFeatureId, TInt aNewValue )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   260
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   261
    __GSLOGSTRING("[CGSCallPluginContainer]--> CGSCallPluginContainer::UpdateListBoxL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   262
    switch( aFeatureId )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   263
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   264
        case EGSOpeningSlideAnswerCallItemId:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   265
        case EGSClosingSlideEndCallItemId:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   266
            if ( iModel->SlideSettingsShownL() )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   267
                {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   268
                MakeSlideSettingsItem( aFeatureId );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   269
                }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   270
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   271
        case EGSCliItemId:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   272
            MakeONSItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   273
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   274
//        case EGSCCBSItemId:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   275
        case EGSCallWaitingItemId:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   276
            return; //CW and CCBS does not have a value => no need to update
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   277
        case EGSICSendIntCallIdItemId:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   278
            if ( iModel->VoIPSupported() )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   279
                {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   280
              MakeICClirItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   281
                }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   282
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   283
        case EGSICWaitingItemId:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   284
            if ( iModel->VoIPSupported() )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   285
                {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   286
              MakeICWaitingItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   287
                }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   288
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   289
        case EGSICPreferredTelephonyId:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   290
            if ( iModel->VoIPSupported() )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   291
                {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   292
              MakeICPreferredCallTypeItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   293
                }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   294
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   295
        case EGSDndItemId:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   296
            if ( iModel->VoIPSupported() )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   297
                {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   298
              MakeDndItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   299
                }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   300
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   301
        case EGSSummaryAfterCallItemId:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   302
            MakeCallItemL( KGSSettIdSummaryAfterCall );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   303
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   304
        case EGSALSBlockItemId:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   305
            MakePLBItemL( aNewValue );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   306
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   307
        case EGSLineChangeItemId:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   308
            MakePLUItemL( aNewValue );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   309
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   310
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   311
        case EGSSoftRejectTextItemId:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   312
            MakeSoftRejectTxtItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   313
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   314
        case EGSStillImageItemId:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   315
            if ( FeatureManager::FeatureSupported(
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   316
                                 KFeatureIdCsVideoTelephony ) )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   317
                {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   318
                MakeStillImageItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   319
                }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   320
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   321
        case EGSReplacePrefixItemId:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   322
            if ( FeatureManager::FeatureSupported( KFeatureIdJapanPrefixChange ) )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   323
                {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   324
                MakeReplacePrefixItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   325
                }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   326
                break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   327
        case EGSShowCallDurationItemId:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   328
            MakeCallDurationItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   329
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   330
        case EGSLongPressCallKeyItemId:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   331
		#ifdef RD_VT_LONG_SEND_KEY 
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   332
   			MakeLongPressCallKeyItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   333
		#endif
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   334
    		break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   335
        case EGSOwnImageVtCallItemId:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   336
            if ( FeatureManager::FeatureSupported(
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   337
                                 KFeatureIdCsVideoTelephony ) )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   338
                {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   339
                MakeOwnImageVtCallItemL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   340
                }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   341
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   342
        default:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   343
            Panic( KGSNameOfClass, EInvalidIndex );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   344
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   345
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   346
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   347
    //iListBox->HandleItemAdditionL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   348
    iListBox->DrawDeferred();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   349
    __GSLOGSTRING("[CGSCallPluginContainer] <--CGSCallPluginContainer::UpdateListBoxL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   350
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   351
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   352
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   353
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   354
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   355
// Creates StillImage list item.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   356
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   357
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   358
void CGSCallPluginContainer::MakeStillImageItemL()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   359
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   360
    __GSLOGSTRING("[CGSCallPluginContainer]--> CGSCallPluginContainer::MakeStillImageItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   361
    HBufC* dynamicText = HBufC::NewLC( KGSBufSize128 );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   362
    TPtr ptrBuffer ( dynamicText->Des() );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   363
    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   364
    TInt dialogSelection = EGSVtStillImageNotInUse;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   365
    if ( iModel->VTStillImageL() )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   366
        dialogSelection = EGSVtStillImageInUse;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   367
    ptrBuffer = (*iStillImgValues)[ dialogSelection ];
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   368
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   369
    // Finally, set the dynamic text
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   370
    iListboxItemArray->SetDynamicTextL( EGSStillImageItemId, ptrBuffer );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   371
    CleanupStack::PopAndDestroy( dynamicText );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   372
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   373
    // And add to listbox
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   374
    iListboxItemArray->SetItemVisibilityL( EGSStillImageItemId,
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   375
        CGSListBoxItemTextArray::EVisible );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   376
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   377
    __GSLOGSTRING("[CGSCallPluginContainer] <--CGSCallPluginContainer::MakeStillImageItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   378
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   379
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   380
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   381
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   382
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   383
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   384
// Creates OwnNumberSending list item.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   385
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   386
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   387
void CGSCallPluginContainer::MakeONSItemL()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   388
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   389
    __GSLOGSTRING("[CGSCallPluginContainer]--> CGSCallPluginContainer::MakeONSItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   390
    HBufC16* dynamicText = NULL;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   391
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   392
    TInt clir = ESSSettingsClirNetworkDefault;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   393
    //to allow emulator usage without phone, do not retrieve values.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   394
    TInt err = iSsSettings->Get( ESSSettingsClir, clir );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   395
    __GSLOGSTRING2("[CGSCallPluginContainer]    MakeONSItemL: clir: %d, Error: %d", clir, err);
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   396
    if ( err != KErrNone )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   397
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   398
        return;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   399
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   400
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   401
    switch( clir )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   402
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   403
        case ESSSettingsClirExplicitSuppress:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   404
            dynamicText = StringLoader::LoadL( R_CLI_SENDING_ON );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   405
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   406
        case ESSSettingsClirExplicitInvoke:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   407
            dynamicText = StringLoader::LoadL( R_CLI_SENDING_OFF );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   408
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   409
        default:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   410
            if ( iModel->RestrictedSendCallerIdSupportedL() )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   411
                {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   412
                //set initially to ON if restricted CLIR is supported
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   413
                dynamicText = StringLoader::LoadL( R_CLI_SENDING_ON );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   414
                TInt err = iSsSettings->Set( 
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   415
                    ESSSettingsClir, ESSSettingsClirExplicitSuppress );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   416
                if ( err != KErrNone )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   417
                    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   418
                    delete dynamicText;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   419
                    return;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   420
                    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   421
                }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   422
            else
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   423
                {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   424
                dynamicText = StringLoader::LoadL( R_CLI_SENDING_DEFAULT );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   425
                }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   426
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   427
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   428
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   429
    // Finally, set the dynamic text
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   430
    iListboxItemArray->SetDynamicTextL( EGSCliItemId, *dynamicText );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   431
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   432
    // And add to listbox
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   433
    iListboxItemArray->SetItemVisibilityL( EGSCliItemId,
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   434
        CGSListBoxItemTextArray::EVisible );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   435
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   436
    delete dynamicText;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   437
    dynamicText = NULL;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   438
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   439
    __GSLOGSTRING("[CGSCallPluginContainer] <--CGSCallPluginContainer::MakeONSItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   440
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   441
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   442
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   443
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   444
// Creates CallWaiting list item.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   445
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   446
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   447
void CGSCallPluginContainer::MakeCWItemL()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   448
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   449
    __GSLOGSTRING("[CGSCallPluginContainer]--> CGSCallPluginContainer::MakeCWItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   450
#ifndef __WINS__
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   451
    //Create call waiting
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   452
    if ( iModel->IsSettingSupported( EGSCSPCallWaiting ) )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   453
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   454
#endif //__WINS__
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   455
    iListboxItemArray->SetItemVisibilityL( EGSCallWaitingItemId,
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   456
        CGSListBoxItemTextArray::EVisible );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   457
#ifndef __WINS__
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   458
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   459
#endif //__WINS__
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   460
    __GSLOGSTRING("[CGSCallPluginContainer] <--CGSCallPluginContainer::MakeCWItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   461
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   462
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   463
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   464
// CGSCallPluginContainer::MakeICClirItemL()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   465
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   466
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   467
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   468
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   469
void CGSCallPluginContainer::MakeICClirItemL()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   470
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   471
    __GSLOGSTRING("[CGSCallPluginContainer]--> CGSCallPluginContainer::MakeICClirItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   472
    TInt value( KErrNone );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   473
    iModel->GetVoIPCallSettingValue( EGSVoIPSendIntCallId, value );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   474
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   475
    HBufC* dynamicText = HBufC::NewLC( KGSBufSize128 );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   476
    TPtr ptrBuffer ( dynamicText->Des() );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   477
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   478
    ptrBuffer = ( *iClirItems )[ value ];
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   479
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   480
    // Finally, set the dynamic text
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   481
    iListboxItemArray->SetDynamicTextL( EGSICSendIntCallIdItemId, ptrBuffer );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   482
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   483
    iListboxItemArray->SetItemVisibilityL( EGSICSendIntCallIdItemId, 
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   484
      CGSListBoxItemTextArray::EVisible );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   485
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   486
    CleanupStack::PopAndDestroy( dynamicText );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   487
    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   488
    __GSLOGSTRING("[CGSCallPluginContainer] <--CGSCallPluginContainer::MakeICClirItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   489
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   490
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   491
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   492
// CGSCallPluginContainer::MakeICWaitingItemL()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   493
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   494
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   495
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   496
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   497
void CGSCallPluginContainer::MakeICWaitingItemL()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   498
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   499
    __GSLOGSTRING("[CGSCallPluginContainer]--> CGSCallPluginContainer::MakeICWaitingItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   500
    TInt value( KErrNone );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   501
    iModel->GetVoIPCallSettingValue( EGSVoIPCW, value );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   502
    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   503
    // Swap items because of different order.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   504
    if ( value == EGSCSCallWaitingOff )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   505
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   506
        value = EGSCSCallWaitingOn;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   507
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   508
    else
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   509
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   510
        value = EGSCSCallWaitingOff;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   511
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   512
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   513
    HBufC* dynamicText = HBufC::NewLC( KGSBufSize128 );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   514
    TPtr ptrBuffer ( dynamicText->Des() );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   515
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   516
    ptrBuffer = ( *iCWItems )[ value ];
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   517
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   518
    // Finally, set the dynamic text
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   519
    iListboxItemArray->SetDynamicTextL( EGSICWaitingItemId, ptrBuffer );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   520
    iListboxItemArray->SetItemVisibilityL( EGSICWaitingItemId, 
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   521
        CGSListBoxItemTextArray::EVisible );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   522
    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   523
    CleanupStack::PopAndDestroy( dynamicText );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   524
    __GSLOGSTRING("[CGSCallPluginContainer] <--CGSCallPluginContainer::MakeICWaitingItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   525
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   526
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   527
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   528
// CGSCallPluginContainer::MakeICPreferredCallTypeItemL()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   529
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   530
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   531
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   532
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   533
void CGSCallPluginContainer::MakeICPreferredCallTypeItemL()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   534
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   535
    __GSLOGSTRING("[CGSCallPluginContainer]--> CGSCallPluginContainer::MakeICPreferredCallTypeItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   536
    TInt value( KErrNone );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   537
    iModel->GetVoIPCallSettingValue( EGSVoIPPreType, value );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   538
    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   539
    HBufC* dynamicText = HBufC::NewLC( KGSBufSize128 );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   540
    TPtr ptrBuffer ( dynamicText->Des() );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   541
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   542
    ptrBuffer = ( *iPCTItems )[ value ];
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   543
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   544
    // Finally, set the dynamic text
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   545
    iListboxItemArray->SetDynamicTextL( EGSICPreferredTelephonyId, ptrBuffer );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   546
    CleanupStack::PopAndDestroy( dynamicText );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   547
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   548
    iListboxItemArray->SetItemVisibilityL( EGSICPreferredTelephonyId,
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   549
      CGSListBoxItemTextArray::EVisible );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   550
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   551
  __GSLOGSTRING("[CGSCallPluginContainer] <--CGSCallPluginContainer::MakeICPreferredCallTypeItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   552
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   553
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   554
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   555
// CGSCallPluginContainer::MakeDndItemL()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   556
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   557
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   558
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   559
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   560
void CGSCallPluginContainer::MakeDndItemL()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   561
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   562
    __GSLOGSTRING("[CGSCallPluginContainer]--> CGSCallPluginContainer::MakeDndItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   563
    TInt value( KErrNone );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   564
    iModel->GetVoIPCallSettingValue( EGSVoIPDnd, value );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   565
    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   566
    // Swap items because of different order.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   567
    if ( value == EGSCSCallDndOff )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   568
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   569
        value = EGSCSCallDndOn;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   570
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   571
    else
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   572
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   573
        value = EGSCSCallDndOff;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   574
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   575
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   576
    HBufC* dynamicText = HBufC::NewLC( KGSBufSize128 );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   577
    TPtr ptrBuffer ( dynamicText->Des() );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   578
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   579
    ptrBuffer = ( *iDndItems )[ value ];
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   580
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   581
    // Finally, set the dynamic text
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   582
    iListboxItemArray->SetDynamicTextL( EGSDndItemId, ptrBuffer );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   583
    CleanupStack::PopAndDestroy( dynamicText );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   584
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   585
    iListboxItemArray->SetItemVisibilityL( EGSDndItemId,
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   586
      CGSListBoxItemTextArray::EVisible );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   587
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   588
    __GSLOGSTRING("[CGSCallPluginContainer] <--CGSCallPluginContainer::MakeDndItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   589
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   590
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   591
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   592
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   593
// Creates PhoneLineInUse list item.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   594
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   595
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   596
void CGSCallPluginContainer::MakePLUItemL( TInt& aAlsValue )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   597
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   598
    __GSLOGSTRING("[CGSCallPluginContainer]--> CGSCallPluginContainer::MakePLUItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   599
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   600
    if ( aAlsValue == ESSSettingsAlsNotSupported )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   601
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   602
        iListboxItemArray->SetItemVisibilityL( EGSLineChangeItemId,
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   603
                           CGSListBoxItemTextArray::EInvisible );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   604
        
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   605
        __GSLOGSTRING("[CGSCallPluginContainer] <--MakePLUItemL:AlsNotSupported");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   606
        return;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   607
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   608
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   609
    HBufC* dynamicText = NULL;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   610
    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   611
    if ( aAlsValue == ESSSettingsAlsAlternate )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   612
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   613
        dynamicText = StringLoader::LoadL( R_ALS_LINE2 );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   614
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   615
    else
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   616
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   617
        dynamicText = StringLoader::LoadL( R_ALS_LINE1 );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   618
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   619
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   620
    // for A&H number conversion
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   621
    TPtr bufPtr = dynamicText->Des();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   622
    AknTextUtils::DisplayTextLanguageSpecificNumberConversion( bufPtr );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   623
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   624
    iListboxItemArray->SetDynamicTextL( EGSLineChangeItemId, *dynamicText );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   625
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   626
    // Add to listbox
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   627
    iListboxItemArray->SetItemVisibilityL( EGSLineChangeItemId,
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   628
        CGSListBoxItemTextArray::EVisible );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   629
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   630
    delete dynamicText;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   631
    dynamicText = NULL;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   632
    __GSLOGSTRING("[CGSCallPluginContainer] <--CGSCallPluginContainer::MakePLUItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   633
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   634
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   635
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   636
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   637
// Creates PhoneLineBlocking list item. No item is created, if service is not
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   638
// supported.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   639
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   640
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   641
void CGSCallPluginContainer::MakePLBItemL( TInt& aAlsBlockValue )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   642
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   643
    __GSLOGSTRING("[CGSCallPluginContainer]--> CGSCallPluginContainer::MakePLBItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   644
    HBufC* dynamicText = NULL;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   645
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   646
    if ( aAlsBlockValue == ESSSettingsAlsBlockingOn )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   647
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   648
        dynamicText = StringLoader::LoadL( R_ALS_LINE_BLOCKING_ON );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   649
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   650
    else
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   651
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   652
        dynamicText = StringLoader::LoadL( R_ALS_LINE_BLOCKING_OFF );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   653
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   654
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   655
    iListboxItemArray->SetDynamicTextL( EGSALSBlockItemId, *dynamicText );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   656
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   657
    // Add to listbox
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   658
    iListboxItemArray->SetItemVisibilityL( EGSALSBlockItemId,
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   659
        CGSListBoxItemTextArray::EVisible );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   660
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   661
    delete dynamicText;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   662
    dynamicText = NULL;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   663
    __GSLOGSTRING("[CGSCallPluginContainer] <--CGSCallPluginContainer::MakePLBItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   664
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   665
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   666
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   667
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   668
// Creates Speed Dialing, Anykey Answer, Summary After Call
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   669
// and Automatic redial items.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   670
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   671
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   672
void CGSCallPluginContainer::MakeCallItemL( TInt aIndex )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   673
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   674
    __GSLOGSTRING("[CGSCallPluginContainer]--> CGSCallPluginContainer::MakeCallItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   675
    HBufC* settingOn  = NULL;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   676
    HBufC* settingOff = NULL;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   677
    TInt value = KGSSettingOff; //default is OFF for all
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   678
    TInt settingItem = 0;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   679
    TBool ok = ETrue;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   680
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   681
    TCallSettId keyName = EGSNotSet;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   682
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   683
    switch ( aIndex )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   684
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   685
        case KGSSettIdSummaryAfterCall:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   686
            keyName = EGSSummaryAfterCall;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   687
            settingItem = EGSSummaryAfterCallItemId;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   688
            settingOn = StringLoader::LoadLC( R_CALL_TERMINATION_NOTE_ON );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   689
            settingOff = StringLoader::LoadLC( R_CALL_TERMINATION_NOTE_OFF );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   690
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   691
        default:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   692
            Panic( KGSNameOfClass, EInvalidIndex );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   693
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   694
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   695
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   696
    if( ok ) //if everything is ok so far
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   697
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   698
        iModel->GetCallSettingValue( keyName, value );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   699
        __GSLOGSTRING1("[CGSCallPluginContainer]    MakeCallItemL: value: %d", value);
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   700
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   701
        // Finally, set the dynamic text
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   702
        if ( value == KGSSettingOn )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   703
            {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   704
            iListboxItemArray->SetDynamicTextL( settingItem, settingOn->Des() );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   705
            }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   706
        else
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   707
            {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   708
            iListboxItemArray->SetDynamicTextL( settingItem, settingOff->Des() );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   709
            }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   710
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   711
        CleanupStack::PopAndDestroy( 2 ); //settingOn, settingOff
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   712
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   713
        // And add to listbox
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   714
        iListboxItemArray->SetItemVisibilityL( settingItem,
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   715
            CGSListBoxItemTextArray::EVisible );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   716
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   717
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   718
    __GSLOGSTRING("[CGSCallPluginContainer] <--CGSCallPluginContainer::MakeCallItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   719
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   720
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   721
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   722
// CGSCallPluginContainer::GetHelpContext(TCoeHelpContext& aContext) const
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   723
// Gets Help
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   724
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   725
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   726
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   727
void CGSCallPluginContainer::GetHelpContext(TCoeHelpContext& aContext) const
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   728
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   729
    __GSLOGSTRING("[CGSCallPluginContainer]--> CGSCallPluginContainer::GetHelpContext");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   730
    aContext.iMajor = KUidGS;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   731
    aContext.iContext = KSCP_HLP_CALL;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   732
    __GSLOGSTRING("[CGSCallPluginContainer] <--CGSCallPluginContainer::GetHelpContext");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   733
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   734
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   735
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   736
// Creates Call Completion When Busy Subscriber item.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   737
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   738
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   739
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   740
/*
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   741
void CGSCallPluginContainer::MakeCCBSItemL()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   742
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   743
    if ( FeatureManager::FeatureSupported( KFeatureIdPhoneCcbs ) )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   744
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   745
        iListboxItemArray->SetItemVisibilityL( EGSCCBSItemId,
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   746
            CGSListBoxItemTextArray::EVisible );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   747
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   748
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   749
*/
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   750
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   751
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   752
// CGSCallPluginContainer::CurrentFeatureId()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   753
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   754
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   755
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   756
TInt CGSCallPluginContainer::CurrentFeatureId( ) const
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   757
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   758
    return iListboxItemArray->CurrentFeature( );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   759
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   760
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   761
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   762
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   763
// Creates Soft reject text item.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   764
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   765
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   766
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   767
void CGSCallPluginContainer::MakeSoftRejectTxtItemL()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   768
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   769
    __GSLOGSTRING("[CGSCallPluginContainer]--> CGSCallPluginContainer::MakeSoftRejectTxtItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   770
    HBufC* dynamicText = HBufC::NewLC( KGSSMSTxtEditorLength );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   771
    TPtr string( dynamicText->Des() );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   772
    string.Zero();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   773
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   774
    GetSoftRejectTextL( string );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   775
    if ( string.Length() == 0 )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   776
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   777
        string = KGSEmptySpace;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   778
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   779
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   780
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   781
    AknTextUtils::ReplaceCharacters( string, KGSReplaceListControlChars, 
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   782
                                                                  TChar(' ') );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   783
                                                                  
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   784
    iListboxItemArray->SetDynamicTextL( EGSSoftRejectTextItemId, string );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   785
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   786
    CleanupStack::PopAndDestroy( dynamicText );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   787
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   788
    iListboxItemArray->SetItemVisibilityL( EGSSoftRejectTextItemId,
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   789
        CGSListBoxItemTextArray::EVisible );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   790
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   791
    __GSLOGSTRING("[CGSCallPluginContainer] <--CGSCallPluginContainer::MakeSoftRejectTxtItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   792
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   793
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   794
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   795
// Gets the value to the Soft Reject Txt.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   796
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   797
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   798
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   799
void CGSCallPluginContainer::GetSoftRejectTextL( TDes& aSoftRejectTxt )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   800
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   801
    __GSLOGSTRING("[CGSCallPluginContainer]--> CGSCallPluginContainer::GetSoftRejectTextL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   802
    TInt value = KGSSettingOff;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   803
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   804
    TCallSettId keyName = EGSSoftRejectDefault;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   805
    iModel->GetCallSettingValue( keyName, value );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   806
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   807
    if ( value == KGSSettingOff )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   808
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   809
        HBufC* defaultText = ReadFromResourceL( R_SOFT_REJECT_DEFAULT_TXT );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   810
        CleanupStack::PushL( defaultText );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   811
        aSoftRejectTxt = *defaultText;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   812
        CleanupStack::PopAndDestroy(); //defaultText
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   813
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   814
    else
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   815
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   816
        TGSSMSTextEditor softRejectTxt;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   817
        iModel->GetSoftRejectText( softRejectTxt );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   818
        aSoftRejectTxt = softRejectTxt;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   819
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   820
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   821
    __GSLOGSTRING("[CGSCallPluginContainer] <--CGSCallPluginContainer::GetSoftRejectTextL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   822
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   823
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   824
// ---------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   825
// CGSCallPluginContainer::ReadFromResourceL
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   826
// ---------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   827
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   828
HBufC* CGSCallPluginContainer::ReadFromResourceL(
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   829
        TInt aResourceId )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   830
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   831
    __GSLOGSTRING("[CGSCallPluginContainer]--> CGSCallPluginContainer::ReadFromResourceL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   832
    // Find the resource file
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   833
    RConeResourceLoader loader( *iCoeEnv );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   834
    TParse parse;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   835
    parse.Set( KGSSoftRejectResource, &KDC_RESOURCE_FILES_DIR, NULL );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   836
    TFileName fileName( parse.FullName() );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   837
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   838
    // Get language of resource file
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   839
    BaflUtils::NearestLanguageFile( iCoeEnv->FsSession(), fileName );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   840
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   841
    // Open resource file
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   842
    TInt err = loader.Open( fileName );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   843
    if ( err == KErrNotFound )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   844
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   845
        return NULL;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   846
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   847
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   848
    CleanupClosePushL( loader );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   849
    HBufC* result = StringLoader::LoadL( aResourceId );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   850
    CleanupStack::PopAndDestroy(); //loader & it is closed also.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   851
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   852
    __GSLOGSTRING("[CGSCallPluginContainer] <--CGSCallPluginContainer::ReadFromResourceL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   853
    return result;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   854
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   855
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   856
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   857
// Creates Replace Prefix list box item.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   858
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   859
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   860
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   861
void CGSCallPluginContainer::MakeReplacePrefixItemL()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   862
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   863
    __GSLOGSTRING("[CGSCallPluginContainer]--> MakeReplacePrefixItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   864
    HBufC* dynamicText = HBufC::NewLC( KGSBufSize128 );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   865
    TPtr ptrBuffer ( dynamicText->Des() );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   866
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   867
    const TInt changeMode = iModel->PrefixChangeModeL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   868
    ptrBuffer = ( *iChangeModeItems )[ changeMode ];
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   869
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   870
    // Finally, set the dynamic text
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   871
    iListboxItemArray->SetDynamicTextL( EGSReplacePrefixItemId, ptrBuffer );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   872
    CleanupStack::PopAndDestroy( dynamicText );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   873
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   874
    // And add to listbox
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   875
    iListboxItemArray->SetItemVisibilityL( EGSReplacePrefixItemId,
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   876
        CGSListBoxItemTextArray::EVisible );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   877
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   878
    __GSLOGSTRING("[CGSCallPluginContainer] <--MakeReplacePrefixItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   879
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   880
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   881
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   882
// Creates Show Call Duration list box item.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   883
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   884
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   885
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   886
void CGSCallPluginContainer::MakeCallDurationItemL()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   887
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   888
    __GSLOGSTRING("[CGSCallPluginContainer]--> MakeCallDurationItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   889
    HBufC* dynamicText = HBufC::NewLC( KGSBufSize128 );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   890
    TPtr ptrBuffer ( dynamicText->Des() );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   891
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   892
    const TInt duration = iModel->CallDurationL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   893
    ptrBuffer = ( *iCallDurationItems )[ duration ];
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   894
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   895
    // Finally, set the dynamic text
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   896
    iListboxItemArray->SetDynamicTextL( EGSShowCallDurationItemId, ptrBuffer );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   897
    CleanupStack::PopAndDestroy( dynamicText );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   898
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   899
    // And add to listbox
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   900
    iListboxItemArray->SetItemVisibilityL( EGSShowCallDurationItemId,
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   901
        CGSListBoxItemTextArray::EVisible );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   902
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   903
    __GSLOGSTRING("[CGSCallPluginContainer] <--MakeCallDurationItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   904
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   905
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   906
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   907
// Creates Long Press Call Key list box items.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   908
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   909
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   910
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   911
void CGSCallPluginContainer::MakeLongPressCallKeyItemL()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   912
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   913
    __GSLOGSTRING("[CGSCallPluginContainer]--> MakeLongPressCallKeyItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   914
    HBufC* dynamicText = HBufC::NewLC( KGSBufSize128 );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   915
    TPtr ptrBuffer ( dynamicText->Des() );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   916
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   917
    TInt statusLongPressCallKey = iModel->LongPressCallKeyL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   918
	// Here we again decrement by 1 so that values resemble appropriate title 
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   919
	// EGSLongPressCallKeyVoiceCall  ------> InActive in GS
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   920
	// EGSLongPressCallKeyVideoCall  ------> Video Call in GS
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   921
	// Refer to GSCallPlugin.hrh file for more info for the  description
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   922
	iModel->MapLongPressKeyCallKeyValue( statusLongPressCallKey );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   923
   	ptrBuffer = ( *iLongPressCallKeyItems )[ statusLongPressCallKey ];
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   924
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   925
    // Finally, set the dynamic text
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   926
    iListboxItemArray->SetDynamicTextL( EGSLongPressCallKeyItemId, ptrBuffer );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   927
    CleanupStack::PopAndDestroy( dynamicText );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   928
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   929
    // And add to listbox
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   930
    iListboxItemArray->SetItemVisibilityL( EGSLongPressCallKeyItemId,
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   931
        CGSListBoxItemTextArray::EVisible );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   932
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   933
    __GSLOGSTRING("[CGSCallPluginContainer] <--MakeLongPressCallKeyItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   934
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   935
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   936
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   937
// ----------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   938
// CGSCallPluginContainer::MakeOwnImageVtCallItemL
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   939
// 
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   940
// Own image mute status on video call
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   941
// ----------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   942
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   943
void CGSCallPluginContainer::MakeOwnImageVtCallItemL()
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   944
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   945
    __GSLOGSTRING("[CGSCallPluginContainer]--> MakeOwnImageVtCallItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   946
    HBufC* dynamicText = HBufC::NewLC( KGSBufSize128 );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   947
    TPtr ptrBuffer ( dynamicText->Des() );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   948
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   949
    TInt statusOwnImageVtCallKey = iModel->OwnImageVtCallStatusL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   950
   	ptrBuffer = ( *iOwnImageVtCallItems )[ statusOwnImageVtCallKey ];
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   951
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   952
    // Finally, set the dynamic text
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   953
    iListboxItemArray->SetDynamicTextL( EGSOwnImageVtCallItemId, ptrBuffer );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   954
    CleanupStack::PopAndDestroy( dynamicText );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   955
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   956
    // And add to listbox
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   957
    iListboxItemArray->SetItemVisibilityL( EGSOwnImageVtCallItemId,
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   958
        CGSListBoxItemTextArray::EVisible );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   959
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   960
    __GSLOGSTRING("[CGSCallPluginContainer] <--MakeOwnImageVtCallItemL");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   961
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   962
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   963
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   964
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   965
// Sets observer for MSK label updations.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   966
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   967
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   968
void CGSCallPluginContainer::SetMiddleSoftkeyObserver( 
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   969
    MGsFWMSKObserver* aObserver )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   970
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   971
    if ( !iMSKObserver && aObserver )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   972
        {        
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   973
        iMSKObserver = aObserver;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   974
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   975
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   976
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   977
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   978
// CGSCallPluginContainer::OfferKeyEventL
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   979
// Called when a key is pressed.
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   980
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   981
TKeyResponse CGSCallPluginContainer::OfferKeyEventL(
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   982
    const TKeyEvent& aKeyEvent, 
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   983
    TEventCode aType )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   984
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   985
    switch ( aKeyEvent.iCode )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   986
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   987
        case EKeyUpArrow:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   988
        case EKeyDownArrow:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   989
            {            
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   990
            TKeyResponse listboxResp = 
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   991
                iListBox->OfferKeyEventL( aKeyEvent, aType );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   992
            if ( iMSKObserver )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   993
                {                
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   994
                iMSKObserver->CheckMiddleSoftkeyLabelL();
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   995
                }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   996
            return listboxResp;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   997
            }        
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   998
        case EKeyLeftArrow:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
   999
        case EKeyRightArrow:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1000
            // Listbox takes all events even if it doesn't use them
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1001
            return EKeyWasNotConsumed;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1002
        default:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1003
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1004
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1005
    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1006
    return iListBox->OfferKeyEventL( aKeyEvent, aType ); 
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1007
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1008
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1009
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1010
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1011
// CGSCallPluginContainer::MakeSlideSettingsItem
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1012
// Create a slide settings item ( "Opening slide to answer call" or "Closing slide to end call" ) 
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1013
//
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1014
// ---------------------------------------------------------------------------
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1015
void CGSCallPluginContainer::MakeSlideSettingsItem( TInt aItemId )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1016
    {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1017
    __GSLOGSTRING("[CGSCallPluginContainer]--> CGSCallPluginContainer::MakeSlideSettingsItem");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1018
    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1019
    HBufC* settingValue = NULL;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1020
    TInt   value(0);
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1021
    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1022
    switch ( aItemId )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1023
        {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1024
        case EGSOpeningSlideAnswerCallItemId:           
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1025
            iModel->GetCallSettingValue( EGSOpeningSlideAnswerCall,value );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1026
            if ( EGSOpeningSlideAnswerCallOn == value )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1027
                {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1028
                settingValue = StringLoader::LoadLC
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1029
                    ( R_CP_SETTING_OPENING_SLIDE_ANSWER );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1030
                }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1031
            else
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1032
                {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1033
                settingValue = StringLoader::LoadLC
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1034
                    ( R_CP_SETTING_OPENING_SLIDE_NOT_ANSWER );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1035
                }                                    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1036
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1037
        case EGSClosingSlideEndCallItemId:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1038
            iModel->GetCallSettingValue( EGSClosingSlideEndCall,value );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1039
            if ( EGSClosingSlideEndCallOn == value )
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1040
                {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1041
                settingValue = StringLoader::LoadLC
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1042
                    ( R_CP_SETTING_CLOSING_SLIDE_END );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1043
                }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1044
            else 
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1045
                {
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1046
                settingValue = StringLoader::LoadLC
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1047
                    ( R_CP_SETTING_CLOSING_SLIDE_NOT_END );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1048
                }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1049
            break;
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1050
        default:
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1051
            Panic( KGSNameOfClass, EInvalidIndex );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1052
        }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1053
    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1054
    iListboxItemArray->SetDynamicTextL( aItemId,settingValue->Des() );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1055
    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1056
    CleanupStack::PopAndDestroy( settingValue );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1057
    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1058
    // And add to listbox
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1059
    iListboxItemArray->SetItemVisibilityL
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1060
        ( aItemId,CGSListBoxItemTextArray::EVisible );
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1061
    
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1062
    __GSLOGSTRING("[CGSCallPluginContainer] <--CGSCallPluginContainer::MakeSlideSettingsItem");
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1063
    }
7e0eff37aedb Revert incorrect RCL_3 drop:
Pat Downey <patd@symbian.org>
parents:
diff changeset
  1064
//End of File