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: Layout plugin for all the widgets present in |
|
15 * conversation view. |
|
16 * |
|
17 */ |
|
18 |
|
19 #include "conversationviewplugin.h" |
|
20 |
|
21 // INCLUDES |
|
22 #include <hbstyle.h> |
|
23 #include <hbiconitem.h> |
|
24 #include <hbtextitem.h> |
|
25 #include <QDir> |
|
26 #include <hbwidget.h> |
|
27 #include <hbinstance.h> |
|
28 |
|
29 #include "debugtraces.h" |
|
30 |
|
31 // Constants |
|
32 #define PRIMITIVECOUNT 1; |
|
33 |
|
34 //--------------------------------------------------------------- |
|
35 // ConversationViewPlugin::primitiveCount |
|
36 // @see header file |
|
37 //--------------------------------------------------------------- |
|
38 int ConversationViewPlugin::primitiveCount() const |
|
39 { |
|
40 #ifdef _DEBUG_TRACES_ |
|
41 qDebug() << "ConversationViewPlugin::primitiveCount"; |
|
42 #endif |
|
43 |
|
44 |
|
45 return PRIMITIVECOUNT; |
|
46 } |
|
47 |
|
48 //--------------------------------------------------------------- |
|
49 // ConversationViewPlugin::createPrimitive |
|
50 // @see header file |
|
51 //--------------------------------------------------------------- |
|
52 QGraphicsItem* ConversationViewPlugin::createPrimitive( |
|
53 HbStyle::Primitive primitive, QGraphicsItem *parent) const |
|
54 { |
|
55 Q_UNUSED(primitive) |
|
56 Q_UNUSED(parent) |
|
57 return NULL; |
|
58 } |
|
59 |
|
60 //--------------------------------------------------------------- |
|
61 // ConversationViewPlugin::updatePrimitive |
|
62 // @see header file |
|
63 //--------------------------------------------------------------- |
|
64 void ConversationViewPlugin::updatePrimitive(QGraphicsItem *item, |
|
65 HbStyle::Primitive primitive, const QStyleOption *option) const |
|
66 { |
|
67 Q_UNUSED(item) |
|
68 Q_UNUSED(primitive) |
|
69 Q_UNUSED(option) |
|
70 } |
|
71 |
|
72 //--------------------------------------------------------------- |
|
73 // ConversationViewPlugin::layoutPath |
|
74 // @see header file |
|
75 //--------------------------------------------------------------- |
|
76 QString ConversationViewPlugin::layoutPath() const |
|
77 { |
|
78 QString path; |
|
79 |
|
80 path = QString(":/"); |
|
81 |
|
82 #ifdef _DEBUG_TRACES_ |
|
83 qDebug() << "layout plugin resources:" << path; |
|
84 #endif |
|
85 return path; |
|
86 } |
|
87 |
|
88 Q_EXPORT_PLUGIN2(conversationviewplugin, ConversationViewPlugin) |
|
89 |
|
90 // EOF |
|