summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorSlávek Banko <[email protected]>2012-11-04 01:39:04 +0100
committerSlávek Banko <[email protected]>2012-11-04 01:39:04 +0100
commit824f886dae4c985f2d703bc9991eed4fc0558b1c (patch)
treee4b403d14b69fb852b72538ff6733cd8bfe3cac2 /src
parent5f33750491674ffffc4dd9065cc6baa3762497f3 (diff)
downloadkmplayer-824f886dae4c985f2d703bc9991eed4fc0558b1c.tar.gz
kmplayer-824f886dae4c985f2d703bc9991eed4fc0558b1c.zip
Fix support for xine 1.2 libraries
Diffstat (limited to 'src')
-rw-r--r--src/xineplayer.cpp56
1 files changed, 29 insertions, 27 deletions
diff --git a/src/xineplayer.cpp b/src/xineplayer.cpp
index 884b3ed..5dad3f2 100644
--- a/src/xineplayer.cpp
+++ b/src/xineplayer.cpp
@@ -528,7 +528,7 @@ void KXinePlayer::play (int repeat) {
xine_event_create_listener_thread (event_queue, event_listener, NULL);
if (mrl == "cdda:/") {
int nr;
- char ** mrls = xine_get_autoplay_mrls (xine, "CD", &nr);
+ const char * const* mrls = xine_get_autoplay_mrls (xine, "CD", &nr);
running = 1;
for (int i = 0; i < nr; i++) {
TQString m (mrls[i]);
@@ -859,10 +859,10 @@ protected:
case XK_p: // previous
mutex.lock ();
if (stream) {
- xine_event_t xine_event = {
- XINE_EVENT_INPUT_PREVIOUS,
- stream, 0L, 0, { 0, 0 }
- };
+ xine_event_t xine_event;
+ memset(&xine_event, 0, sizeof(xine_event));
+ xine_event.type = XINE_EVENT_INPUT_PREVIOUS;
+ xine_event.stream = stream;
xine_event_send (stream, &xine_event);
}
mutex.unlock ();
@@ -871,10 +871,10 @@ protected:
case XK_n: // next
mutex.lock ();
if (stream) {
- xine_event_t xine_event = {
- XINE_EVENT_INPUT_NEXT,
- stream, 0L, 0, { 0, 0 }
- };
+ xine_event_t xine_event;
+ memset(&xine_event, 0, sizeof(xine_event));
+ xine_event.type = XINE_EVENT_INPUT_NEXT;
+ xine_event.stream = stream;
xine_event_send (stream, &xine_event);
}
mutex.unlock ();
@@ -883,10 +883,10 @@ protected:
case XK_u: // up menu
mutex.lock ();
if (stream) {
- xine_event_t xine_event = {
- XINE_EVENT_INPUT_MENU1,
- stream, 0L, 0, { 0, 0 }
- };
+ xine_event_t xine_event;
+ memset(&xine_event, 0, sizeof(xine_event));
+ xine_event.type = XINE_EVENT_INPUT_MENU1;
+ xine_event.stream = stream;
xine_event_send (stream, &xine_event);
}
mutex.unlock ();
@@ -895,10 +895,10 @@ protected:
case XK_r: // root menu
mutex.lock ();
if (stream) {
- xine_event_t xine_event = {
- XINE_EVENT_INPUT_MENU3,
- stream, 0L, 0, { 0, 0 }
- };
+ xine_event_t xine_event;
+ memset(&xine_event, 0, sizeof(xine_event));
+ xine_event.type = XINE_EVENT_INPUT_MENU3;
+ xine_event.stream = stream;
xine_event_send (stream, &xine_event);
}
mutex.unlock ();
@@ -973,11 +973,12 @@ protected:
data.x = rect.x;
data.y = rect.y;
data.button = 0;
- xine_event_t xine_event = {
- XINE_EVENT_INPUT_MOUSE_MOVE,
- stream, &data, sizeof (xine_input_data_t),
- { 0 , 0 }
- };
+ xine_event_t xine_event;
+ memset(&xine_event, 0, sizeof(xine_event));
+ xine_event.type = XINE_EVENT_INPUT_MOUSE_MOVE;
+ xine_event.stream = stream;
+ xine_event.data = &data;
+ xine_event.data_length = sizeof (xine_input_data_t);
mutex.lock ();
xine_event_send (stream, &xine_event);
mutex.unlock ();
@@ -1007,11 +1008,12 @@ protected:
data.x = rect.x;
data.y = rect.y;
data.button = 1;
- xine_event_t xine_event = {
- XINE_EVENT_INPUT_MOUSE_BUTTON,
- stream, &data, sizeof (xine_input_data_t),
- { 0, 0 }
- };
+ xine_event_t xine_event;
+ memset(&xine_event, 0, sizeof(xine_event));
+ xine_event.type = XINE_EVENT_INPUT_MOUSE_BUTTON;
+ xine_event.stream = stream;
+ xine_event.data = &data;
+ xine_event.data_length = sizeof (xine_input_data_t);
mutex.lock ();
xine_event_send (stream, &xine_event);
mutex.unlock ();