|
1 /* |
|
2 * Copyright (c) 2010 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: Implementation of HbToolButton |
|
15 * |
|
16 */ |
|
17 |
|
18 // Version : %version: 1 % |
|
19 |
|
20 |
|
21 |
|
22 #include <qgraphicswidget> |
|
23 |
|
24 #include <hbaction.h> |
|
25 #include <hbframedrawer.h> |
|
26 |
|
27 #include "mpxvideo_debug.h" |
|
28 #include "hbtoolbutton.h" |
|
29 |
|
30 // ------------------------------------------------------------------------------------------------- |
|
31 // HbToolButton::HbToolButton |
|
32 // ------------------------------------------------------------------------------------------------- |
|
33 // |
|
34 HbToolButton::HbToolButton( HbAction *action ) |
|
35 { |
|
36 MPX_ENTER_EXIT(_L("HbToolButton::HbToolButton()")); |
|
37 |
|
38 mAction = action; |
|
39 } |
|
40 |
|
41 // ------------------------------------------------------------------------------------------------- |
|
42 // HbToolButton::~HbToolButton |
|
43 // ------------------------------------------------------------------------------------------------- |
|
44 // |
|
45 HbToolButton::~HbToolButton() |
|
46 { |
|
47 MPX_DEBUG(_L("HbToolButton::HbToolButton") ); |
|
48 } |
|
49 |
|
50 // ------------------------------------------------------------------------------------------------- |
|
51 // HbToolButton::isEnabled |
|
52 // ------------------------------------------------------------------------------------------------- |
|
53 // |
|
54 bool HbToolButton::isEnabled() |
|
55 { |
|
56 MPX_DEBUG(_L("HbToolButton::isEnabled") ); |
|
57 |
|
58 return mAction->isEnabled(); |
|
59 } |
|
60 |
|
61 // ------------------------------------------------------------------------------------------------- |
|
62 // HbToolButton::press |
|
63 // ------------------------------------------------------------------------------------------------- |
|
64 // |
|
65 void HbToolButton::press() |
|
66 { |
|
67 MPX_DEBUG(_L("HbToolButton::press") ); |
|
68 |
|
69 emit pressed(); |
|
70 } |
|
71 |
|
72 // ------------------------------------------------------------------------------------------------- |
|
73 // HbToolButton::release |
|
74 // ------------------------------------------------------------------------------------------------- |
|
75 // |
|
76 void HbToolButton::release() |
|
77 { |
|
78 MPX_DEBUG(_L("HbToolButton::release") ); |
|
79 |
|
80 emit released(); |
|
81 } |
|
82 |
|
83 // End of file |