controlpanelui/src/cpplugins/keytouchfdbkplugin/src/cpkeyscreenmodel.cpp
branchRCL_3
changeset 35 5f281e37a2f5
parent 34 90fe62538f66
child 46 ed95320285d0
equal deleted inserted replaced
34:90fe62538f66 35:5f281e37a2f5
     1 /*
       
     2  * Copyright (c) 2009 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 #include "cpkeyscreenmodel.h"
       
    20 #include <qglobal.h>
       
    21 
       
    22 #ifdef Q_OS_SYMBIAN
       
    23 #include "cpkeyscreenmodel_p.h"
       
    24 #endif
       
    25 
       
    26 
       
    27 CpKeyScreenModel::CpKeyScreenModel()
       
    28 {
       
    29 #ifdef Q_OS_SYMBIAN
       
    30     ptr = new CpKeyScreenModelPrivate();
       
    31 #endif
       
    32 }
       
    33 
       
    34 CpKeyScreenModel::~CpKeyScreenModel()
       
    35 {
       
    36 #ifdef Q_OS_SYMBIAN
       
    37     delete ptr;
       
    38     ptr = 0;
       
    39 #endif
       
    40 }
       
    41 
       
    42 bool CpKeyScreenModel::isKeyguardSupported()
       
    43 {
       
    44 #ifdef Q_OS_SYMBIAN
       
    45     return ptr->isKeyguardSupported();
       
    46 #else
       
    47     return 0;
       
    48 #endif
       
    49 }
       
    50 
       
    51 int CpKeyScreenModel::keyguard()
       
    52 {
       
    53 #ifdef Q_OS_SYMBIAN
       
    54     return ptr->keyguard();
       
    55 #else
       
    56     return 0;
       
    57 #endif
       
    58 }
       
    59 
       
    60 void CpKeyScreenModel::setKeyguard(int value)
       
    61 {
       
    62 #ifdef Q_OS_SYMBIAN
       
    63     ptr->setKeyguard(value);
       
    64 #else
       
    65     Q_UNUSED(value);
       
    66 #endif
       
    67 }
       
    68 
       
    69 bool CpKeyScreenModel::isRotateSupported()
       
    70 {
       
    71 #ifdef Q_OS_SYMBIAN
       
    72     return ptr->isRotateSupported();
       
    73 #else
       
    74     return false;
       
    75 #endif
       
    76 }
       
    77 
       
    78 bool CpKeyScreenModel::rotate()
       
    79 {
       
    80 #ifdef Q_OS_SYMBIAN
       
    81     return ptr->rotate();
       
    82 #else
       
    83     return 0;
       
    84 #endif
       
    85 }
       
    86 
       
    87 void CpKeyScreenModel::setRotate(bool value)
       
    88 {
       
    89 #ifdef Q_OS_SYMBIAN
       
    90     ptr->setRotate(value);
       
    91 #else
       
    92     Q_UNUSED(value);
       
    93 #endif
       
    94 }
       
    95 
       
    96 bool CpKeyScreenModel::isBrightnessSupported()
       
    97 {
       
    98 #ifdef Q_OS_SYMBIAN
       
    99     return ptr->isBrightnessSupported();
       
   100 #else
       
   101     return false;
       
   102 #endif
       
   103 }
       
   104 
       
   105 int CpKeyScreenModel::brightness()
       
   106 {
       
   107 #ifdef Q_OS_SYMBIAN
       
   108     return ptr->brightness();
       
   109 #else
       
   110     return 0;
       
   111 #endif    
       
   112 }
       
   113 
       
   114 void CpKeyScreenModel::setBrightness(int value)
       
   115 {
       
   116 #ifdef Q_OS_SYMBIAN
       
   117     ptr->setBrightness(value);
       
   118 #else
       
   119     Q_UNUSED(value);
       
   120 #endif
       
   121 }
       
   122 
       
   123 bool CpKeyScreenModel::isCallibrationSupported()
       
   124 {
       
   125 #ifdef Q_OS_SYMBIAN
       
   126     return ptr->isCallibrationSupported();
       
   127 #else
       
   128     return true;
       
   129 #endif
       
   130 }
       
   131 
       
   132 // End of the file