|
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 * test application for qt control panel public apis. |
|
16 */ |
|
17 |
|
18 #include "mycpdataformbuttonentryviewitem.h" |
|
19 |
|
20 /*! |
|
21 \class MyCpDataFormButtonEntryViewItem |
|
22 \brief The MyCpDataFormButtonEntryViewItem class is designed for the unit testing for the protected member functions in CpDataFormButtonEntryViewItem class. |
|
23 */ |
|
24 |
|
25 /*! |
|
26 * Default constructor |
|
27 */ |
|
28 MyCpDataFormButtonEntryViewItem::MyCpDataFormButtonEntryViewItem(QGraphicsItem *parent) : CpDataFormButtonEntryViewItem(parent) |
|
29 { |
|
30 |
|
31 } |
|
32 |
|
33 /*! |
|
34 * Copy constructor |
|
35 */ |
|
36 MyCpDataFormButtonEntryViewItem::MyCpDataFormButtonEntryViewItem(const MyCpDataFormButtonEntryViewItem& other) : |
|
37 CpDataFormButtonEntryViewItem(other) |
|
38 { |
|
39 |
|
40 } |
|
41 |
|
42 /*! |
|
43 * This is designed for testing of the copy assignment operator = in class CpDataFormButtonEntryViewItem, |
|
44 * that operator was declared as protected. |
|
45 * the detection of self assignment was removed to enable the detection in base class implementation executed. |
|
46 */ |
|
47 MyCpDataFormButtonEntryViewItem& MyCpDataFormButtonEntryViewItem::operator=(const MyCpDataFormButtonEntryViewItem& other) |
|
48 { |
|
49 // if (&other == this) |
|
50 // { |
|
51 // return *this; |
|
52 // } |
|
53 |
|
54 CpDataFormButtonEntryViewItem::operator=(other); |
|
55 |
|
56 return *this; |
|
57 } |
|
58 |
|
59 /*! |
|
60 * this is also for protected member functions testing, call base class implematation directly. |
|
61 */ |
|
62 HbWidget * MyCpDataFormButtonEntryViewItem::createCustomWidget() |
|
63 { |
|
64 return CpDataFormButtonEntryViewItem::createCustomWidget(); |
|
65 } |
|
66 |
|
67 |