~ubuntu-branches/ubuntu/trusty/content-hub/trusty-proposed

« back to all changes in this revision

Viewing changes to import/Ubuntu/Content/qmlimportexporthandler.cpp

  • Committer: Package Import Robot
  • Author(s): Ubuntu daily release, Ken VanDine, Ubuntu daily release
  • Date: 2014-03-21 00:46:57 UTC
  • mfrom: (1.1.19)
  • Revision ID: package-import@ubuntu.com-20140321004657-5w0p7mj1qn9lrrj3
Tags: 0.0+14.04.20140321-0ubuntu1
[ Ken VanDine ]
* Adds support for multiple handler types: source, destination and
  share. Enforce single transfer per peer, if a second transfer
  request is made from a peer that already has an unfinished transfer,
  cancel the previous one. This is needed as long as apps are required
  to be single instance.
* If the transfer isn't persistent, attempt to hardlink instead of
  copying. If the link fails, fallback to a copy.
* If the default source is set to anything other than a click appId
  triplet, fallback to the legacy APP_ID. Changed default source for
  contacts to the legacy APP_ID for address-book-app

[ Ubuntu daily release ]
* New rebuild forced

Show diffs side-by-side

added added

removed removed

Lines of Context:
15
15
 */
16
16
 
17
17
#include "qmlimportexporthandler.h"
 
18
#include "../../../src/com/ubuntu/content/debug.h"
18
19
 
19
20
#include <com/ubuntu/content/transfer.h>
20
21
 
21
 
#include <QDebug>
22
 
 
23
22
namespace cuc = com::ubuntu::content;
24
23
 
25
24
/*!
29
28
QmlImportExportHandler::QmlImportExportHandler(QObject *parent)
30
29
    : cuc::ImportExportHandler(parent)
31
30
{
32
 
    qDebug() << Q_FUNC_INFO;
 
31
    TRACE() << Q_FUNC_INFO;
33
32
}
34
33
 
35
34
/*!
37
36
 */
38
37
void QmlImportExportHandler::handle_import(com::ubuntu::content::Transfer *transfer)
39
38
{
40
 
    qDebug() << Q_FUNC_INFO;
 
39
    TRACE() << Q_FUNC_INFO;
41
40
    Q_EMIT importRequested(transfer);
42
41
}
43
42
 
46
45
 */
47
46
void QmlImportExportHandler::handle_export(com::ubuntu::content::Transfer *transfer)
48
47
{
49
 
    qDebug() << Q_FUNC_INFO;
 
48
    TRACE() << Q_FUNC_INFO;
50
49
    Q_EMIT exportRequested(transfer);
51
50
}
52
51
 
 
52
/*!
 
53
 * \reimp
 
54
 */
 
55
void QmlImportExportHandler::handle_share(com::ubuntu::content::Transfer *transfer)
 
56
{
 
57
    TRACE() << Q_FUNC_INFO;
 
58
    Q_EMIT shareRequested(transfer);
 
59
}