summaryrefslogtreecommitdiff
path: root/extra/phonon/libqzeitgeist08.patch
blob: 7a99101c41c3ef5089e860289e77ada3e0849347 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
--- phonon-4.5.1/phonon/mediaobject.cpp~	2011-10-29 13:04:16.499027830 +0000
+++ phonon-4.5.1/phonon/mediaobject.cpp	2011-10-29 13:09:49.222080364 +0000
@@ -38,12 +38,12 @@
 #include <QtCore/QUrl>
 
 #ifdef HAVE_QZEITGEIST
-#include <QtZeitgeist/DataModel/Event>
-#include <QtZeitgeist/Interpretation>
-#include <QtZeitgeist/Log>
-#include <QtZeitgeist/Manifestation>
-#include <QtZeitgeist/QtZeitgeist>
-#endif
+#include <QZeitgeist/DataModel/Event>
+#include <QZeitgeist/Interpretation>
+#include <QZeitgeist/Log>
+#include <QZeitgeist/Manifestation>
+#include <QZeitgeist/QZeitgeist>
+#endif  
 
 #include "phononnamespace_p.h"
 #include "platform_p.h"
@@ -330,7 +330,7 @@
                                          const QString &subject_mimetype)
 {
 #ifdef HAVE_QZEITGEIST
-    QtZeitgeist::DataModel::Subject subject;
+    QZeitgeist::DataModel::Subject subject;
     QString url = subject_uri.toString();
     QString path = url.left(url.lastIndexOf(QLatin1Char('/')));
     subject.setUri(url);
@@ -340,20 +340,20 @@
     subject.setOrigin(path);
     subject.setMimeType(subject_mimetype);
 
-    QtZeitgeist::DataModel::SubjectList subjects;
+    QZeitgeist::DataModel::SubjectList subjects;
     subjects << subject;
 
-    QtZeitgeist::DataModel::Event event;
+    QZeitgeist::DataModel::Event event;
     event.setTimestamp(subject_timestamp);
     event.setInterpretation(event_interpretation);
     event.setManifestation(event_manifestation);
     event.setActor(event_actor);
     event.setSubjects(subjects);
 
-    QtZeitgeist::DataModel::EventList events;
+    QZeitgeist::DataModel::EventList events;
     events << event;
 
-    QDBusPendingReply<QtZeitgeist::DataModel::EventIdList> reply =
+    QDBusPendingReply<QZeitgeist::DataModel::EventIdList> reply =
         log->insertEvents(events);
 #else
     Q_UNUSED(event_interpretation)
@@ -377,11 +377,11 @@
         QString eventInterpretation;
         switch (eventState) {
         case PlayingState:
-            eventInterpretation = QtZeitgeist::Interpretation::Event::ZGAccessEvent;
+            eventInterpretation = QZeitgeist::Interpretation::Event::ZGAccessEvent;
             break;
         case ErrorState:
         case StoppedState:
-            eventInterpretation = QtZeitgeist::Interpretation::Event::ZGLeaveEvent;
+            eventInterpretation = QZeitgeist::Interpretation::Event::ZGLeaveEvent;
             break;
         //These states are not signifigant events.
         case LoadingState:
@@ -409,10 +409,10 @@
         QString mime;
         QString subjectInterpretation;
         if (q->hasVideo()) {
-            subjectInterpretation = QtZeitgeist::Interpretation::Subject::NFOVideo;
+            subjectInterpretation = QZeitgeist::Interpretation::Subject::NFOVideo;
             mime = "video/raw";
         } else {
-            subjectInterpretation = QtZeitgeist::Interpretation::Subject::NFOAudio;
+            subjectInterpretation = QZeitgeist::Interpretation::Subject::NFOAudio;
             mime = "audio/raw";
         }
         pDebug() << "Zeitgeist mime type:" << mime;
@@ -425,20 +425,20 @@
         case MediaSource::Invalid:
             return;
         case MediaSource::Url:
-            subjectType = QtZeitgeist::Manifestation::Subject::NFORemoteDataObject;
+            subjectType = QZeitgeist::Manifestation::Subject::NFORemoteDataObject;
             break;
         case MediaSource::CaptureDevice:
         case MediaSource::Disc:
         case MediaSource::Stream:
-            subjectType = QtZeitgeist::Manifestation::Subject::NFOMediaStream;
+            subjectType = QZeitgeist::Manifestation::Subject::NFOMediaStream;
             break;
         case MediaSource::LocalFile:
-            subjectType = QtZeitgeist::Manifestation::Subject::NFOFileDataObject;
+            subjectType = QZeitgeist::Manifestation::Subject::NFOFileDataObject;
             break;
         }
 
         sendToZeitgeist(eventInterpretation,
-                        QtZeitgeist::Manifestation::Event::ZGUserActivity,
+                        QZeitgeist::Manifestation::Event::ZGUserActivity,
                         QLatin1Literal("app://" ) % Platform::applicationName() % QLatin1Literal(".desktop"),
                         QDateTime::currentDateTime(),
                         mediaSource.url(),
--- phonon-4.5.1/phonon/mediaobject_p.h~	2011-10-29 13:04:34.982530678 +0000
+++ phonon-4.5.1/phonon/mediaobject_p.h	2011-10-29 15:27:44.679123431 +0000
@@ -30,8 +30,8 @@
 #include "mediasource.h"
 #include <QtCore/QQueue>
 #ifdef HAVE_QZEITGEIST
-#include <QtZeitgeist/Log>
-#include <QtZeitgeist/QtZeitgeist>
+#include <QZeitgeist/Log>
+#include <QZeitgeist/QZeitgeist>
 #endif
 
 QT_BEGIN_NAMESPACE
@@ -114,8 +114,7 @@
 #endif //QT_NO_PHONON_ABSTRACTMEDIASTREAM
         {
 #ifdef HAVE_QZEITGEIST
-            QtZeitgeist::init();
-            log = new QtZeitgeist::Log(qObject());
+            log = new QZeitgeist::Log(qObject());
 #endif
         }
 
@@ -142,7 +141,7 @@
         MediaSource mediaSource;
         QQueue<MediaSource> sourceQueue;
 #ifdef HAVE_QZEITGEIST
-        QtZeitgeist::Log *log;
+        QZeitgeist::Log *log;
 #endif
 };
 }
--- phonon-4.5.1/phonon/CMakeLists.txt~	2011-10-29 15:30:07.640468718 +0000
+++ phonon-4.5.1/phonon/CMakeLists.txt	2011-10-29 15:30:26.643980831 +0000
@@ -21,7 +21,7 @@
 endif(GLIB2_FOUND AND PULSEAUDIO_FOUND)
 
 macro_optional_find_package(QZeitgeist)
-macro_log_feature(QZEITGEIST_FOUND "QtZeitgeist" "Qt bindings for Zeitgeist" "http://gitorious.org/kde-zeitgeist/libqzeitgeist/" FALSE)
+macro_log_feature(QZEITGEIST_FOUND "QZeitgeist" "Qt bindings for Zeitgeist" "http://gitorious.org/kde-zeitgeist/libqzeitgeist/" FALSE)
 if (QZEITGEIST_FOUND)
     add_definitions(-DHAVE_QZEITGEIST)
     include_directories(${QZEITGEIST_INCLUDE_DIR})