phonebookui/Phonebook2/UIControls/src/TPbk2AddressSelectParams.cpp
changeset 0 e686773b3f54
equal deleted inserted replaced
-1:000000000000 0:e686773b3f54
       
     1 /*
       
     2 * Copyright (c) 2005-2007 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  Phonebook 2 address selection parameters.
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #include <TPbk2AddressSelectParams.h>
       
    20 
       
    21 // Phonebook 2
       
    22 #include <MPbk2ContactNameFormatter.h>
       
    23 #include <CPbk2FieldPropertyArray.h>
       
    24 
       
    25 // Virtual Phonebook
       
    26 #include <MVPbkStoreContactField.h>
       
    27 #include <MVPbkStoreContact.h>
       
    28 #include <CVPbkFieldTypeSelector.h>
       
    29 #include <MVPbkStoreContactFieldCollection.h>
       
    30 #include <CVPbkContactManager.h>
       
    31 
       
    32 
       
    33 // --------------------------------------------------------------------------
       
    34 // TPbk2AddressSelectParams::TPbk2AddressSelectParams
       
    35 // --------------------------------------------------------------------------
       
    36 //
       
    37 EXPORT_C TPbk2AddressSelectParams::TPbk2AddressSelectParams
       
    38         ( MVPbkStoreContact& aContact,
       
    39           const CVPbkContactManager& aContactManager,
       
    40           MPbk2ContactNameFormatter& aNameFormatter,
       
    41           const CPbk2FieldPropertyArray& aFieldPropertyArray,
       
    42           TResourceReader& aReader, TInt aTitleResId ) :
       
    43             iContact( aContact ),
       
    44             iContactManager( aContactManager ),
       
    45             iNameFormatter( aNameFormatter ),
       
    46             iFieldPropertyArray( aFieldPropertyArray ),
       
    47             iResReader( aReader ),
       
    48             iTitleResId( aTitleResId ),
       
    49             iFocusedField( NULL ),
       
    50             iDefaultPriorities( NULL ),
       
    51             iUseDefaultDirectly( EFalse ),
       
    52             iQueryAlways( EFalse ),
       
    53             iIncludeContactNameInPrompt( ETrue ),
       
    54             iSuppressWarnings( EFalse ),
       
    55             iCommMethod( VPbkFieldTypeSelectorFactory::EEmptySelector )
       
    56     {
       
    57     }
       
    58 
       
    59 // --------------------------------------------------------------------------
       
    60 // TPbk2AddressSelectParams::SetFocusedField
       
    61 // --------------------------------------------------------------------------
       
    62 //
       
    63 EXPORT_C void TPbk2AddressSelectParams::SetFocusedField
       
    64         ( const MVPbkStoreContactField* aFocusedField )
       
    65     {
       
    66     iFocusedField = aFocusedField;
       
    67     }
       
    68 
       
    69 // --------------------------------------------------------------------------
       
    70 // TPbk2AddressSelectParams::SetDefaultPriorities
       
    71 // --------------------------------------------------------------------------
       
    72 //
       
    73 EXPORT_C void TPbk2AddressSelectParams::SetDefaultPriorities
       
    74         ( const RVPbkContactFieldDefaultPriorities& aDefaultPriorities )
       
    75     {
       
    76     iDefaultPriorities = &aDefaultPriorities;
       
    77     }
       
    78 
       
    79 // --------------------------------------------------------------------------
       
    80 // TPbk2AddressSelectParams::SetUseDefaultDirectly
       
    81 // --------------------------------------------------------------------------
       
    82 //
       
    83 EXPORT_C void TPbk2AddressSelectParams::SetUseDefaultDirectly
       
    84         ( TBool aUseDefaultDirectly )
       
    85     {
       
    86     iUseDefaultDirectly = aUseDefaultDirectly;
       
    87     }
       
    88 
       
    89 // --------------------------------------------------------------------------
       
    90 // TPbk2AddressSelectParams::SetQueryAlways
       
    91 // --------------------------------------------------------------------------
       
    92 //
       
    93 EXPORT_C void TPbk2AddressSelectParams::SetQueryAlways
       
    94         ( TBool aQueryAlways )
       
    95     {
       
    96     iQueryAlways = aQueryAlways;
       
    97     }
       
    98 
       
    99 // --------------------------------------------------------------------------
       
   100 // TPbk2AddressSelectParams::SetQueryAlways
       
   101 // --------------------------------------------------------------------------
       
   102 //
       
   103 EXPORT_C void TPbk2AddressSelectParams::SetTitleToIncludeContactName
       
   104         ( TBool aIncludeContactName )
       
   105     {
       
   106     iIncludeContactNameInPrompt = aIncludeContactName;
       
   107     }
       
   108 
       
   109 // --------------------------------------------------------------------------
       
   110 // TPbk2AddressSelectParams::SetSuppressWarnings
       
   111 // --------------------------------------------------------------------------
       
   112 //
       
   113 EXPORT_C void TPbk2AddressSelectParams::SetSuppressWarnings
       
   114         ( TBool aSuppressWarnings )
       
   115     {
       
   116     iSuppressWarnings = aSuppressWarnings;
       
   117     }
       
   118 
       
   119 // End of File