[longomatch] Make sure we use the EosHandler and not an EventHandler for EOS.
- From: Andoni Morales Alastruey <amorales src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [longomatch] Make sure we use the EosHandler and not an EventHandler for EOS.
- Date: Wed, 24 Sep 2014 20:31:18 +0000 (UTC)
commit 489885f6f0148be15fbeb6a2c31f4031f9b98e33
Author: Julien Moutte <julien fluendo com>
Date: Thu Sep 18 16:12:06 2014 +0200
Make sure we use the EosHandler and not an EventHandler for EOS.
LongoMatch.Core/Interfaces/Multimedia/IPlayer.cs | 2 +-
LongoMatch.GUI.Multimedia/Gui/PlayerBin.cs | 2 +-
LongoMatch.Multimedia/Player/GstPlayer.cs | 8 +++++++-
3 files changed, 9 insertions(+), 3 deletions(-)
---
diff --git a/LongoMatch.Core/Interfaces/Multimedia/IPlayer.cs
b/LongoMatch.Core/Interfaces/Multimedia/IPlayer.cs
index 9c30550..a77e764 100644
--- a/LongoMatch.Core/Interfaces/Multimedia/IPlayer.cs
+++ b/LongoMatch.Core/Interfaces/Multimedia/IPlayer.cs
@@ -30,7 +30,7 @@ namespace LongoMatch.Core.Interfaces.Multimedia
{
// Events
event ErrorHandler Error;
- event System.EventHandler Eos;
+ event EosHandler Eos;
event StateChangeHandler StateChange;
event ReadyToSeekHandler ReadyToSeek;
diff --git a/LongoMatch.GUI.Multimedia/Gui/PlayerBin.cs b/LongoMatch.GUI.Multimedia/Gui/PlayerBin.cs
index eeae1a2..5b8dfdc 100644
--- a/LongoMatch.GUI.Multimedia/Gui/PlayerBin.cs
+++ b/LongoMatch.GUI.Multimedia/Gui/PlayerBin.cs
@@ -724,7 +724,7 @@ namespace LongoMatch.Gui
Pause ();
}
- void OnEndOfStream (object o, EventArgs args)
+ void OnEndOfStream ()
{
Application.Invoke (delegate {
player.Seek (new Time (0), true);
diff --git a/LongoMatch.Multimedia/Player/GstPlayer.cs b/LongoMatch.Multimedia/Player/GstPlayer.cs
index ef55626..02fdb39 100644
--- a/LongoMatch.Multimedia/Player/GstPlayer.cs
+++ b/LongoMatch.Multimedia/Player/GstPlayer.cs
@@ -34,6 +34,7 @@ namespace LongoMatch.Video.Player
public event StateChangeHandler StateChange;
public event TickHandler Tick;
public event ReadyToSeekHandler ReadyToSeek;
+ public event EosHandler Eos;
[DllImport("libcesarplayer.dll")]
static extern IntPtr lgm_video_player_get_type ();
@@ -132,6 +133,11 @@ namespace LongoMatch.Video.Player
if (ReadyToSeek != null)
ReadyToSeek ();
};
+
+ this.GlibEos += (sender, e) => {
+ if (Eos != null)
+ Eos ();
+ };
}
#pragma warning disable 0169
@@ -267,7 +273,7 @@ namespace LongoMatch.Video.Player
}
[GLib.Signal("eos")]
- public event System.EventHandler Eos {
+ public event System.EventHandler GlibEos {
add {
GLib.Signal sig = GLib.Signal.Lookup (this, "eos");
sig.AddDelegate (value);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]