Bugfix: when the uri is a "file://" uri, just play it directly
(upstream svn revision r476)
This commit is contained in:
parent
4e1f1e2718
commit
b8bd3aec24
@ -1,9 +1,9 @@
|
||||
# $OpenBSD: Makefile,v 1.24 2011/09/12 08:27:38 dcoppa Exp $
|
||||
# $OpenBSD: Makefile,v 1.25 2011/09/21 14:19:16 dcoppa Exp $
|
||||
|
||||
COMMENT = gnome-mplayer browser media plugin
|
||||
V = 1.0.4
|
||||
DISTNAME = gecko-mediaplayer-${V}
|
||||
REVISION = 1
|
||||
REVISION = 2
|
||||
CATEGORIES = www
|
||||
|
||||
MAINTAINER = David Coppa <dcoppa@openbsd.org>
|
||||
|
@ -1,11 +1,29 @@
|
||||
$OpenBSD: patch-src_plugin_cpp,v 1.7 2011/09/12 08:27:38 dcoppa Exp $
|
||||
$OpenBSD: patch-src_plugin_cpp,v 1.8 2011/09/21 14:19:16 dcoppa Exp $
|
||||
|
||||
When the uri is a "file://" uri, just play it directly
|
||||
(upstream svn revision r476)
|
||||
|
||||
Fix apple.com/trailers (upstream svn revisions r468 and r470)
|
||||
|
||||
Fix return value for the CURLGetURLNotify function (upstream svn r473)
|
||||
|
||||
--- src/plugin.cpp.orig Mon Jun 20 17:00:33 2011
|
||||
+++ src/plugin.cpp Mon Sep 12 10:18:11 2011
|
||||
@@ -1320,7 +1320,7 @@ int progress_callback(void *clientp, double dltotal, d
|
||||
--- src/plugin.cpp.orig Wed Sep 21 15:46:40 2011
|
||||
+++ src/plugin.cpp Wed Sep 21 15:46:55 2011
|
||||
@@ -887,8 +887,11 @@ int32 CPlugin::Write(NPStream * stream, int32 offset,
|
||||
return -1;
|
||||
}
|
||||
|
||||
- if (strstr((char *) buffer, "ICY 200 OK") != NULL || strstr((char *) buffer, "Content-length:") != NULL // If item is a block of jpeg images, just stream it
|
||||
- || strstr((char *) buffer, "<HTML>") != NULL || item->streaming == TRUE) {
|
||||
+ if (strstr((char *) buffer, "ICY 200 OK") != NULL
|
||||
+ || strstr((char *) buffer, "Content-length:") != NULL
|
||||
+ || strstr((char *) buffer, "<HTML>") != NULL || item->streaming == TRUE
|
||||
+ || strstr(item->src, "file://") != NULL) {
|
||||
+ // If item is a block of jpeg images, just stream it
|
||||
// || stream->lastmodified == 0) { this is not valid for many sites
|
||||
|
||||
// printf("BUFFER='%s'\n", buffer);
|
||||
@@ -1320,7 +1323,7 @@ int progress_callback(void *clientp, double dltotal, d
|
||||
ListItem *item = (ListItem *) clientp;
|
||||
gdouble percent, rate;
|
||||
gchar *text;
|
||||
@ -14,7 +32,7 @@ Fix return value for the CURLGetURLNotify function (upstream svn r473)
|
||||
gint id;
|
||||
gboolean ready;
|
||||
gboolean newwindow;
|
||||
@@ -1364,8 +1364,6 @@ int progress_callback(void *clientp, double dltotal, d
|
||||
@@ -1364,8 +1367,6 @@ int progress_callback(void *clientp, double dltotal, d
|
||||
rate);
|
||||
}
|
||||
send_signal_with_string(plugin, item, "SetProgressText", text);
|
||||
@ -23,7 +41,7 @@ Fix return value for the CURLGetURLNotify function (upstream svn r473)
|
||||
if (plugin->post_dom_events && plugin->id != NULL) {
|
||||
postDOMEvent(plugin->mInstance, plugin->id, "qt_progress");
|
||||
postDOMEvent(plugin->mInstance, plugin->id, "qt_durationchange");
|
||||
@@ -1391,7 +1389,6 @@ int progress_callback(void *clientp, double dltotal, d
|
||||
@@ -1391,7 +1392,6 @@ int progress_callback(void *clientp, double dltotal, d
|
||||
if (ok_to_play == FALSE) {
|
||||
if (item->bitrate == 0 && item->bitrate_requests < 5
|
||||
&& ((gint) (percent * 100) > item->bitrate_requests)) {
|
||||
@ -31,7 +49,7 @@ Fix return value for the CURLGetURLNotify function (upstream svn r473)
|
||||
item->bitrate_requests++;
|
||||
}
|
||||
if (item->bitrate > 0) {
|
||||
@@ -1418,6 +1415,7 @@ int progress_callback(void *clientp, double dltotal, d
|
||||
@@ -1418,6 +1418,7 @@ int progress_callback(void *clientp, double dltotal, d
|
||||
if (!item->streaming) {
|
||||
printf("in progress_callback\n");
|
||||
plugin->playlist = list_parse_qt(plugin->playlist, item);
|
||||
@ -39,7 +57,7 @@ Fix return value for the CURLGetURLNotify function (upstream svn r473)
|
||||
plugin->playlist = list_parse_asx(plugin->playlist, item);
|
||||
plugin->playlist = list_parse_qml(plugin->playlist, item);
|
||||
plugin->playlist = list_parse_ram(plugin->playlist, item);
|
||||
@@ -1493,13 +1491,14 @@ gpointer CURLGetURLNotify(gpointer data)
|
||||
@@ -1493,13 +1494,14 @@ gpointer CURLGetURLNotify(gpointer data)
|
||||
|
||||
}
|
||||
fclose(local);
|
||||
@ -56,7 +74,7 @@ Fix return value for the CURLGetURLNotify function (upstream svn r473)
|
||||
id = item->controlid;
|
||||
path = g_strdup(item->path);
|
||||
ready = item->playerready;
|
||||
@@ -1509,13 +1508,14 @@ gpointer CURLGetURLNotify(gpointer data)
|
||||
@@ -1509,13 +1511,14 @@ gpointer CURLGetURLNotify(gpointer data)
|
||||
if (!item->streaming) {
|
||||
printf("in CURLGetURLNotify\n");
|
||||
plugin->playlist = list_parse_qt(plugin->playlist, item);
|
||||
@ -72,7 +90,7 @@ Fix return value for the CURLGetURLNotify function (upstream svn r473)
|
||||
if (item->play) {
|
||||
send_signal_with_integer(plugin, item, "SetGUIState", PLAYING);
|
||||
open_location(plugin, item, TRUE);
|
||||
@@ -1549,6 +1549,7 @@ gpointer CURLGetURLNotify(gpointer data)
|
||||
@@ -1549,6 +1552,7 @@ gpointer CURLGetURLNotify(gpointer data)
|
||||
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user