omads/omadsappui/ui/src/NSmlDSSyncContainer.cpp
branchRCL_3
changeset 52 4f0867e42d62
parent 0 dab8a81a92de
equal deleted inserted replaced
51:8e7494275d3a 52:4f0867e42d62
       
     1 /*
       
     2 * Copyright (c) 2002-2005 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:  
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 // INCLUDE FILES
       
    21 #include "NSmlDSSyncContainer.h"
       
    22 
       
    23 #include <AknUtils.h>
       
    24 
       
    25 
       
    26 
       
    27 // ============================ MEMBER FUNCTIONS ===============================
       
    28 
       
    29 
       
    30 
       
    31 // -----------------------------------------------------------------------------
       
    32 // CNSmlDSSyncContainer::ConstructL
       
    33 //
       
    34 // -----------------------------------------------------------------------------
       
    35 //
       
    36 void CNSmlDSSyncContainer::ConstructL(const TRect& aRect)
       
    37     {
       
    38     CreateWindowL();
       
    39     SetRect(aRect);
       
    40     ActivateL();
       
    41     }
       
    42 
       
    43 
       
    44 // -----------------------------------------------------------------------------
       
    45 // CNSmlDSSyncContainer::~CNSmlDSSyncContainer
       
    46 //
       
    47 // -----------------------------------------------------------------------------
       
    48 //
       
    49 CNSmlDSSyncContainer::~CNSmlDSSyncContainer()
       
    50     {
       
    51     }
       
    52 
       
    53 
       
    54 // -----------------------------------------------------------------------------
       
    55 // CNSmlDSSyncContainer::SizeChanged
       
    56 //
       
    57 // Called by framework when the view size is changed.
       
    58 // -----------------------------------------------------------------------------
       
    59 //
       
    60 void CNSmlDSSyncContainer::SizeChanged()
       
    61     {
       
    62     }
       
    63 
       
    64 
       
    65 // -----------------------------------------------------------------------------
       
    66 // CNSmlDSSyncContainer::CountComponentControls
       
    67 //
       
    68 // Returns number of controls inside this container.
       
    69 // -----------------------------------------------------------------------------
       
    70 //
       
    71 TInt CNSmlDSSyncContainer::CountComponentControls() const
       
    72     {
       
    73     return 0;
       
    74     }
       
    75 
       
    76 
       
    77 // -----------------------------------------------------------------------------
       
    78 // CNSmlDSSyncContainer::ComponentControl
       
    79 //
       
    80 // -----------------------------------------------------------------------------
       
    81 //
       
    82 CCoeControl* CNSmlDSSyncContainer::ComponentControl(TInt /*aIndex*/) const
       
    83     {
       
    84     return NULL;
       
    85     }
       
    86 
       
    87 
       
    88 // -----------------------------------------------------------------------------
       
    89 // CNSmlDSSyncContainer::Draw
       
    90 //
       
    91 // -----------------------------------------------------------------------------
       
    92 //
       
    93 void CNSmlDSSyncContainer::Draw(const TRect& aRect) const
       
    94     {
       
    95     CWindowGc& gc = SystemGc();
       
    96     gc.SetPenStyle(CGraphicsContext::ENullPen);
       
    97     gc.SetBrushColor(KRgbGray);
       
    98     gc.SetBrushStyle(CGraphicsContext::ESolidBrush);
       
    99     gc.DrawRect(aRect);
       
   100     }
       
   101 
       
   102 
       
   103 // -----------------------------------------------------------------------------
       
   104 // CNSmlDSSyncContainer::HandleControlEventL
       
   105 //
       
   106 // -----------------------------------------------------------------------------
       
   107 //
       
   108 void CNSmlDSSyncContainer::HandleControlEventL(CCoeControl* /*aControl*/,TCoeEvent /*aEventType*/)
       
   109     {
       
   110     }
       
   111 
       
   112 
       
   113 // -----------------------------------------------------------------------------
       
   114 // CNSmlDSSyncContainer::HandleResourceChange
       
   115 //
       
   116 // -----------------------------------------------------------------------------
       
   117 //
       
   118 void CNSmlDSSyncContainer::HandleResourceChange(TInt aType)
       
   119     {
       
   120     if (aType == KEikDynamicLayoutVariantSwitch) //Handle change in layout orientation
       
   121         {
       
   122         TRect mainPaneRect;
       
   123         AknLayoutUtils::LayoutMetricsRect(AknLayoutUtils::EMainPane, mainPaneRect);
       
   124         SetRect(mainPaneRect);
       
   125 		DrawNow();
       
   126 		return;
       
   127 		}
       
   128 
       
   129     CCoeControl::HandleResourceChange(aType);
       
   130     }
       
   131 
       
   132 
       
   133 // End of File