1 /* |
1 /* |
2 * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). |
2 * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). |
3 * All rights reserved. |
3 * All rights reserved. |
4 * This component and the accompanying materials are made available |
4 * This component and the accompanying materials are made available |
5 * under the terms of "Eclipse Public License v1.0" |
5 * under the terms of "Eclipse Public License v1.0" |
6 * which accompanies this distribution, and is available |
6 * which accompanies this distribution, and is available |
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
8 * |
8 * |
9 * Initial Contributors: |
9 * Initial Contributors: |
10 * Nokia Corporation - initial contribution. |
10 * Nokia Corporation - initial contribution. |
11 * |
11 * |
12 * Contributors: |
12 * Contributors: |
13 * |
13 * |
14 * Description: This is custom widget for details view in photos for displaying the description of image . |
14 * Description: This is custom widget for details view in photos for displaying the description of image . |
15 * |
15 * |
16 */ |
16 */ |
17 |
17 |
18 #ifndef GlXDETAILSDESCEDIT_H |
18 #ifndef GlXDETAILSDESCEDIT_H |
19 #define GlXDETAILSDESCEDIT_H |
19 #define GlXDETAILSDESCEDIT_H |
20 |
20 |
21 #include <hbtextedit.h> |
21 #include <hblineedit.h> |
22 |
22 |
23 #ifdef BUILD_DETAILSCUSTOM |
23 #ifdef BUILD_DETAILSCUSTOM |
24 #define MY_EXPORT Q_DECL_EXPORT |
24 #define MY_EXPORT Q_DECL_EXPORT |
25 #else |
25 #else |
26 #define MY_EXPORT Q_DECL_IMPORT |
26 #define MY_EXPORT Q_DECL_IMPORT |
27 #endif |
27 #endif |
28 |
28 |
29 class HbEditorInterface; |
29 class MY_EXPORT GlxDetailsTextEdit: public HbLineEdit |
30 class MY_EXPORT GlxDetailsTextEdit : public HbTextEdit |
30 { |
31 { |
31 Q_OBJECT |
32 Q_OBJECT |
32 |
33 |
|
34 public: |
33 public: |
35 GlxDetailsTextEdit(QGraphicsItem *parent = NULL); |
34 GlxDetailsTextEdit(QGraphicsItem *parent = NULL); |
36 ~GlxDetailsTextEdit(); |
35 ~GlxDetailsTextEdit(); |
37 void setItemText( const QString &text ); |
36 void setItemText(const QString &text); |
38 |
37 void setTextItemReadOnly(bool value); |
|
38 |
39 protected: |
39 protected: |
40 void focusInEvent (QFocusEvent *event) ; |
40 void gestureEvent(QGestureEvent* event); |
41 void focusOutEvent (QFocusEvent *event) ; |
|
42 |
41 |
43 |
|
44 signals : |
42 signals : |
45 void labelPressed(); |
43 void editorTapped(); |
|
44 |
46 private: |
45 private: |
47 HbEditorInterface *mDesc; |
46 //flag to set if the editor should emit signal or not for edit. |
|
47 bool mEditorReadOnly; |
|
48 |
48 }; |
49 }; |
49 |
50 |
50 #endif // GlXDETAILSDESCEDIT_H |
51 #endif // GlXDETAILSDESCEDIT_H |