summaryrefslogtreecommitdiffstats
path: root/src/3rdparty
diff options
context:
space:
mode:
authorJanne Anttila <janne.anttila@digia.com>2010-02-04 13:57:44 (GMT)
committerJanne Anttila <janne.anttila@digia.com>2010-02-04 14:02:51 (GMT)
commit94abb3ee93aa09f79640e14fed89b286c57ce05c (patch)
tree2dbcfd5a0e40cd6233d638d5f8165fcccc1026d3 /src/3rdparty
parent98352b43fa2bce30bcea0965ad3d05109404d166 (diff)
downloadQt-94abb3ee93aa09f79640e14fed89b286c57ce05c.zip
Qt-94abb3ee93aa09f79640e14fed89b286c57ce05c.tar.gz
Qt-94abb3ee93aa09f79640e14fed89b286c57ce05c.tar.bz2
Initial support for S60 softkey icons.
The logic for resolving the icon size in landscape mode for S60 5.0 (5800XM) is somewhat fragile, but better way is not yet know. Also the 50% transparent mask what CBA implementation tries to create for pressed down CB Abuttons fails for some reason. When button is pressed down there are drawing artifacts in softkey images. These issues will be tried to resolve with later commits Task-number: QTBUG-7314 Review-By: Sami Merila
Diffstat (limited to 'src/3rdparty')
-rw-r--r--src/3rdparty/s60/eiksoftkeyimage.h112
1 files changed, 112 insertions, 0 deletions
diff --git a/src/3rdparty/s60/eiksoftkeyimage.h b/src/3rdparty/s60/eiksoftkeyimage.h
new file mode 100644
index 0000000..84f6108a
--- /dev/null
+++ b/src/3rdparty/s60/eiksoftkeyimage.h
@@ -0,0 +1,112 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** No Commercial Usage
+** This file contains pre-release code and may not be distributed.
+** You may use this file in accordance with the terms and conditions
+** contained in the Technology Preview License Agreement accompanying
+** this package.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** If you have questions regarding the use of this file, please contact
+** Nokia at qt-info@nokia.com.
+**
+**
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+/*
+* Copyright (c) 2002 Nokia Corporation and/or its subsidiary(-ies).
+* All rights reserved.
+* This component and the accompanying materials are made available
+* under the terms of "Eclipse Public License v1.0"
+* which accompanies this distribution, and is available
+* at the URL "http://www.eclipse.org/legal/epl-v10.html".
+*
+* Initial Contributors:
+* Nokia Corporation - initial contribution.
+*
+* Contributors:
+*
+* Description: Changes cba button's label to image.
+*
+*/
+
+#ifndef EIKSOFTKEYIMAGE_H
+#define EIKSOFTKEYIMAGE_H
+
+// FORWARD DECLARATIONS
+class CEikButtonGroupContainer;
+
+// CLASS DECLARATION
+
+/**
+* Changes cba button's label to image.
+*
+* @lib EIKCOCTL
+* @since 2.0
+*/
+class EikSoftkeyImage
+ {
+ public:
+
+ /**
+ * Set image to cba button by replacing label
+ * @since 2.0
+ * @param aButtonGroupContainer Button container
+ * @param aImage Image to button,
+ * Takes Images ownership
+ * @param aLeft Boolean: left or right button.
+ * If true, then change left,
+ * if false, change right
+ */
+ IMPORT_C static void SetImage(CEikButtonGroupContainer* aButtonGroupContainer, CEikImage& aImage, TBool aLeft);
+
+ /**
+ * Change to cba button image back to label
+ * @since 2.0
+ * @param aButtonGroupContainer Button container
+ * @param aLeft Boolean: left or right button.
+ * If true, then change left,
+ * if false, change right
+ */
+ IMPORT_C static void SetLabel(CEikButtonGroupContainer* aButtonGroupContainer, TBool aLeft);
+
+ private:
+
+ /**
+ * C++ default constructor.
+ */
+ EikSoftkeyImage() {};
+
+
+ };
+
+#endif // EIKSOFTKEYIMAGE_H
+
+// End of File
+