1
Description: Fix compilation with valac-0.12.
2
Cherry picked from upstream commits f189986 and 5cab283
3
Author: Nicolas Delvaux <nicolas.delvaux@gmx.com>
7
Last-Update: 2011-04-10
9
--- totem-plugin-arte-0.9.2.orig/url-extractor.vala
10
+++ totem-plugin-arte-0.9.2/url-extractor.vala
15
-errordomain ExtractionError
16
+public errordomain ExtractionError
20
@@ -66,7 +66,7 @@ public class StreamUrlExtractor : GLib.O
23
var regex = new Regex (regexp);
24
- regex.match(msg.response_body.flatten ().data, 0, out match);
25
+ regex.match((string) msg.response_body.flatten ().data, 0, out match);
27
} catch (RegexError e) {
28
GLib.warning ("%s", e.message);
29
--- totem-plugin-arte-0.9.2.orig/cache.vala
30
+++ totem-plugin-arte-0.9.2/cache.vala
31
@@ -83,8 +83,7 @@ public class Cache : GLib.Object
33
var file_stream = file.create (FileCreateFlags.REPLACE_DESTINATION, null);
34
var data_stream = new DataOutputStream (file_stream);
35
- data_stream.write (msg.response_body.data,
36
- (ssize_t) msg.response_body.length, null);
37
+ data_stream.write (msg.response_body.data);
40
GLib.error ("%s", e.message);
41
@@ -138,8 +137,7 @@ public class Cache : GLib.Object
45
- var img_stream = new MemoryInputStream.from_data (msg.response_body.data,
46
- (ssize_t) msg.response_body.length, null);
47
+ var img_stream = new MemoryInputStream.from_data (msg.response_body.data, null);
50
/* original size: 720px × 406px */
51
--- totem-plugin-arte-0.9.2.orig/arteplus7.vala
52
+++ totem-plugin-arte-0.9.2/arteplus7.vala
53
@@ -155,7 +155,7 @@ public abstract class ArteParser : GLib.
55
var context = new MarkupParseContext (parser,
56
MarkupParseFlags.TREAT_CDATA_AS_TEXT, this, null);
57
- context.parse (msg.response_body.flatten ().data,
58
+ context.parse ((string) msg.response_body.flatten ().data,
59
(ssize_t) msg.response_body.length);
62
@@ -187,7 +187,7 @@ public class ArteRSSParser : ArteParser
63
"http://videos.arte.tv/de/do_delegate/videos/arte7/index-3188666,view,rss.xml";
66
- private override void open_tag (MarkupParseContext ctx,
67
+ protected override void open_tag (MarkupParseContext ctx,
69
string[] attribute_names,
70
string[] attribute_values) throws MarkupError
71
@@ -202,7 +202,7 @@ public class ArteRSSParser : ArteParser
75
- private override void close_tag (MarkupParseContext ctx,
76
+ protected override void close_tag (MarkupParseContext ctx,
77
string elem) throws MarkupError
80
@@ -218,7 +218,7 @@ public class ArteRSSParser : ArteParser
84
- private override void process_text (MarkupParseContext ctx,
85
+ protected override void process_text (MarkupParseContext ctx,
87
size_t text_len) throws MarkupError
89
@@ -270,7 +270,7 @@ public class ArteXMLParser : ArteParser
90
xml_de = xml_tmpl.printf ("de", "de", page);
93
- private override void open_tag (MarkupParseContext ctx,
94
+ protected override void open_tag (MarkupParseContext ctx,
96
string[] attribute_names,
97
string[] attribute_values) throws MarkupError
98
@@ -285,7 +285,7 @@ public class ArteXMLParser : ArteParser
102
- private override void close_tag (MarkupParseContext ctx,
103
+ protected override void close_tag (MarkupParseContext ctx,
104
string elem) throws MarkupError
107
@@ -301,7 +301,7 @@ public class ArteXMLParser : ArteParser
111
- private override void process_text (MarkupParseContext ctx,
112
+ protected override void process_text (MarkupParseContext ctx,
114
size_t text_len) throws MarkupError
116
@@ -396,11 +396,11 @@ class ArtePlugin : Totem.Plugin
117
/* add a search entry with a refresh and a cleanup icon */
118
search_entry = new Gtk.Entry ();
119
search_entry.set_icon_from_stock (Gtk.EntryIconPosition.PRIMARY,
120
- Gtk.STOCK_REFRESH);
121
+ Gtk.Stock.REFRESH);
122
search_entry.set_icon_tooltip_text (Gtk.EntryIconPosition.PRIMARY,
124
search_entry.set_icon_from_stock (Gtk.EntryIconPosition.SECONDARY,
127
search_entry.set_icon_tooltip_text (Gtk.EntryIconPosition.SECONDARY,
128
_("Clear the search text"));
129
search_entry.set_icon_sensitive (Gtk.EntryIconPosition.SECONDARY, false);
130
@@ -493,7 +493,7 @@ class ArtePlugin : Totem.Plugin
132
var dialog = new Dialog.with_buttons (_("Arte+7 Plugin Properties"),
133
null, Gtk.DialogFlags.MODAL | Gtk.DialogFlags.DESTROY_WITH_PARENT,
134
- Gtk.STOCK_CLOSE, Gtk.ResponseType.CLOSE, null);
135
+ Gtk.Stock.CLOSE, Gtk.ResponseType.CLOSE, null);
136
dialog.has_separator = false;
137
dialog.resizable = false;
138
dialog.border_width = 5;