|
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: Offers message creation and sending services. |
|
15 * |
|
16 */ |
|
17 |
|
18 #include <hbaction.h> |
|
19 #include <hbdevicedialog.h> |
|
20 #include <qtdebug> |
|
21 #include <xqservicerequest.h> |
|
22 #include "testshareuiview.h" |
|
23 #include "shareui.h" |
|
24 |
|
25 TestShareUiView::TestShareUiView(HbMainWindow* parent) |
|
26 { |
|
27 // TODO Auto-generated constructor stub |
|
28 |
|
29 } |
|
30 |
|
31 TestShareUiView::~TestShareUiView() |
|
32 { |
|
33 // TODO Auto-generated destructor stub |
|
34 delete mDialog; |
|
35 } |
|
36 |
|
37 bool TestShareUiView::init() |
|
38 { |
|
39 // initialize |
|
40 qDebug() << "[DeviceView] " << "init()"; |
|
41 mToolBar = toolBar(); |
|
42 |
|
43 // clear actions |
|
44 mToolBar->clearActions(); |
|
45 |
|
46 // add the actions now |
|
47 // when you press this, a device dialog should pop up. |
|
48 HbAction* openCvAction = new HbAction( HbIcon(""), tr("Launch Share Ui"), this); |
|
49 mToolBar->addAction(openCvAction); |
|
50 connect(openCvAction, SIGNAL(triggered()), this, SLOT(openCvPop())); |
|
51 |
|
52 return true; |
|
53 } |
|
54 |
|
55 void TestShareUiView::openCvPop() |
|
56 { |
|
57 qDebug() << "[DeviceView] " << "openCvPop() "; |
|
58 mDialog = new ShareUi(); |
|
59 QStringList fileList; |
|
60 fileList << QString("c:\\Sunset.jpg"); |
|
61 mDialog->send(fileList,true); |
|
62 } |
|
63 |