diff options
author | Thibault Saunier <tsaunier@igalia.com> | 2018-03-13 10:06:58 -0300 |
---|---|---|
committer | Thibault Saunier <tsaunier@igalia.com> | 2018-03-13 10:16:12 -0300 |
commit | bbe45ebd918d479d634699a07cf98c9e721bb721 (patch) | |
tree | 8089c5941583900beff7aebd375ebb5c665a47ac /samples | |
parent | 94f4d85af3995fcc800c1cebecc73bad75931bfc (diff) |
message: Name all constructors
And fix examples.
Fixes https://bugzilla.gnome.org/show_bug.cgi?id=793274
Diffstat (limited to 'samples')
-rw-r--r-- | samples/BasicTutorial13.cs | 6 | ||||
-rw-r--r-- | samples/BasicTutorial5.cs | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/samples/BasicTutorial13.cs b/samples/BasicTutorial13.cs index 485f666..1fcda15 100644 --- a/samples/BasicTutorial13.cs +++ b/samples/BasicTutorial13.cs @@ -27,9 +27,9 @@ namespace GstreamerSharp Event seekEvent; // Create the seek event if (Rate > 0) { - seekEvent = new Event (Rate, Format.Time, SeekFlags.Flush | SeekFlags.Accurate, SeekType.Set, position, SeekType.None, 0); + seekEvent = Event.NewSeek (Rate, Format.Time, SeekFlags.Flush | SeekFlags.Accurate, SeekType.Set, position, SeekType.None, 0); } else { - seekEvent = new Event (Rate, Format.Time, SeekFlags.Flush | SeekFlags.Accurate, SeekType.Set, 0, SeekType.Set, position); + seekEvent = Event.NewSeek (Rate, Format.Time, SeekFlags.Flush | SeekFlags.Accurate, SeekType.Set, 0, SeekType.Set, position); } if (VideoSink == null) { @@ -71,7 +71,7 @@ namespace GstreamerSharp // If we have not done so, obtain the sink through which we will send the step events VideoSink = (Element)Pipeline ["video-sink"]; } - var evnt = new Event (Format.Buffers, 1, Rate, true, false); + var evnt = Event.NewStep (Format.Buffers, 1, Rate, true, false); VideoSink.SendEvent (evnt); Console.WriteLine ("Stepping one frame"); diff --git a/samples/BasicTutorial5.cs b/samples/BasicTutorial5.cs index b82564d..ce32080 100644 --- a/samples/BasicTutorial5.cs +++ b/samples/BasicTutorial5.cs @@ -181,7 +181,7 @@ namespace GstreamerSharp static void HandleTags (object sender, GLib.SignalArgs args) { // We are possibly in the Gstreamer working thread, so we notify the main thread of this event through a message in the bus var s = new Structure ("tags-changed"); - Playbin.PostMessage (new Message (Playbin, s)); + Playbin.PostMessage (Message.NewApplication (Playbin, s)); } // This function is called when an error message is posted on the bus |