qplatformclipboard.cpp

Absolute File Name:/home/qt/qt5_coco/qt5/qtbase/src/gui/kernel/qplatformclipboard.cpp
Switch to Source codePreprocessed file
LineSourceCount
1-
2-
3-
4-
5-
6-
7class QClipboardData-
8{-
9public:-
10 QClipboardData();-
11 ~QClipboardData();-
12-
13 void setSource(QMimeData* s)-
14 {-
15 if (s == src
s == srcDescription
TRUEnever evaluated
FALSEnever evaluated
)
0
16 return;
never executed: return;
0
17 delete src;-
18 src = s;-
19 }
never executed: end of block
0
20 QMimeData* source()-
21 { return
never executed: return src;
src;
never executed: return src;
}
0
22-
23private:-
24 QMimeData* src;-
25};-
26-
27QClipboardData::QClipboardData()-
28{-
29 src = 0;-
30}
never executed: end of block
0
31-
32QClipboardData::~QClipboardData()-
33{-
34 delete src;-
35}
never executed: end of block
0
36-
37namespace { namespace Q_QGS_q_clipboardData { typedef QClipboardData Type; QBasicAtomicInt guard = { QtGlobalStatic::Uninitialized }; __attribute__((visibility("hidden"))) inline Type *innerFunction() { struct HolderBase { ~HolderBase() noexcept { if (guard.load() == QtGlobalStatic::Initialized
guard.load() =...c::InitializedDescription
TRUEnever evaluated
FALSEnever evaluated
) guard.store(QtGlobalStatic::Destroyed);
never executed: guard.store(QtGlobalStatic::Destroyed);
}
never executed: end of block
}; static struct Holder : public HolderBase { Type value; Holder() noexcept(noexcept(Type ())) : value () { guard.store(QtGlobalStatic::Initialized); } } holder; return
never executed: return &holder.value;
&holder.value;
never executed: return &holder.value;
} } } static QGlobalStatic<QClipboardData, Q_QGS_q_clipboardData::innerFunction, Q_QGS_q_clipboardData::guard> q_clipboardData;;
0
38QPlatformClipboard::~QPlatformClipboard()-
39{-
40-
41}-
42-
43QMimeData *QPlatformClipboard::mimeData(QClipboard::Mode mode)-
44{-
45-
46 (void)mode;;-
47 return
never executed: return q_clipboardData()->source();
q_clipboardData()->source();
never executed: return q_clipboardData()->source();
0
48}-
49-
50void QPlatformClipboard::setMimeData(QMimeData *data, QClipboard::Mode mode)-
51{-
52-
53 (void)mode;;-
54 q_clipboardData()->setSource(data);-
55-
56 emitChanged(mode);-
57}
never executed: end of block
0
58-
59bool QPlatformClipboard::supportsMode(QClipboard::Mode mode) const-
60{-
61 return
never executed: return mode == QClipboard::Clipboard;
mode == QClipboard::Clipboard;
never executed: return mode == QClipboard::Clipboard;
0
62}-
63-
64bool QPlatformClipboard::ownsMode(QClipboard::Mode mode) const-
65{-
66 (void)mode;;-
67 return
never executed: return false;
false;
never executed: return false;
0
68}-
69-
70void QPlatformClipboard::emitChanged(QClipboard::Mode mode)-
71{-
72 if (!QGuiApplicationPrivate::is_app_closing
!QGuiApplicati...is_app_closingDescription
TRUEnever evaluated
FALSEnever evaluated
)
0
73 QGuiApplication::clipboard()->emitChanged(mode);
never executed: QGuiApplication::clipboard()->emitChanged(mode);
0
74}
never executed: end of block
0
75-
76-
Switch to Source codePreprocessed file

Generated by Squish Coco Non-Commercial 4.3.0-BETA-master-30-08-2018-4cb69e9