~ubuntu-branches/ubuntu/quantal/libkexiv2/quantal

« back to all changes in this revision

Viewing changes to libkexiv2/kexiv2_p.cpp

  • Committer: Package Import Robot
  • Author(s): Philip Muškovac
  • Date: 2012-05-26 14:27:02 UTC
  • mfrom: (1.1.12)
  • Revision ID: package-import@ubuntu.com-20120526142702-duh6ecr459d92ni9
Tags: 4:4.8.80-0ubuntu1
* New upstream beta release
  - replace libkexiv2-10 with libkexiv2-11 for new ABI version
  - refresh libkexiv2-11.symbols

Show diffs side-by-side

added added

removed removed

Lines of Context:
7
7
 * @date   2007-09-03
8
8
 * @brief  Exiv2 library interface for KDE
9
9
 *
10
 
 * @author Copyright (C) 2006-2011 by Gilles Caulier
 
10
 * @author Copyright (C) 2006-2012 by Gilles Caulier
11
11
 *         <a href="mailto:caulier dot gilles at gmail dot com">caulier dot gilles at gmail dot com</a>
12
 
 * @author Copyright (C) 2006-2011 by Marcel Wiesweg
 
12
 * @author Copyright (C) 2006-2012 by Marcel Wiesweg
13
13
 *         <a href="mailto:marcel dot wiesweg at gmx dot de">marcel dot wiesweg at gmx dot de</a>
14
14
 *
15
15
 * This program is free software; you can redistribute it
27
27
 
28
28
#include "kexiv2_p.h"
29
29
 
30
 
// C ANSI includes.
 
30
// C ANSI includes
31
31
 
32
32
extern "C"
33
33
{
39
39
{
40
40
 
41
41
KExiv2::KExiv2Priv::KExiv2Priv()
42
 
                  : data(new KExiv2Data::KExiv2DataPriv)
 
42
    : data(new KExiv2Data::KExiv2DataPriv)
43
43
{
44
44
    writeRawFiles         = false;
45
45
    updateFileTimeStamp   = false;
54
54
{
55
55
}
56
56
 
 
57
void KExiv2::KExiv2Priv::copyPrivateData(const KExiv2Priv* const  other)
 
58
{
 
59
    data                  = other->data;
 
60
    filePath              = other->filePath;
 
61
    writeRawFiles         = other->writeRawFiles;
 
62
    updateFileTimeStamp   = other->updateFileTimeStamp;
 
63
    useXMPSidecar4Reading = other->useXMPSidecar4Reading;
 
64
    metadataWritingMode   = other->metadataWritingMode;
 
65
}
 
66
 
57
67
bool KExiv2::KExiv2Priv::saveToXMPSidecar(const QFileInfo& finfo) const
58
68
{
59
69
    QString filePath = KExiv2::sidecarFilePathForFile(finfo.filePath());
410
420
    return i;
411
421
}
412
422
 
 
423
#ifdef _XMP_SUPPORT_
 
424
void KExiv2::KExiv2Priv::mergeXmpData(const Exiv2::XmpData& src, Exiv2::XmpData& dest)
 
425
{
 
426
    for (Exiv2::XmpData::const_iterator it = src.begin(); it != src.end(); ++it)
 
427
    {
 
428
        Exiv2::XmpData::iterator destIt = dest.findKey(Exiv2::XmpKey(it->key()));
 
429
        if (destIt == dest.end())
 
430
        {
 
431
            dest.add(*it);
 
432
        }
 
433
        else
 
434
        {
 
435
            *destIt = *it;
 
436
        }
 
437
    }
 
438
}
 
439
#endif
 
440
 
413
441
}  // NameSpace KExiv2Iface