gnomemm r1280 - in gstreamermm/trunk: . examples/ogg_player_gtkmm



Author: jaalburqu
Date: Thu Jan 10 23:15:33 2008
New Revision: 1280
URL: http://svn.gnome.org/viewvc/gnomemm?rev=1280&view=rev

Log:
2008-01-10  Josà Alburquerque  <jaalburqu svn gnome org>

	* examples/ogg_player_gtkmm/PlayerWindow.cc: moved cast of Gst::Query
	in PlayerWindow::on_forward() method to occur after
	mainPipeline->query() call to avoid immutable warnings on the Query's
	structure


Modified:
   gstreamermm/trunk/ChangeLog
   gstreamermm/trunk/examples/ogg_player_gtkmm/PlayerWindow.cc

Modified: gstreamermm/trunk/examples/ogg_player_gtkmm/PlayerWindow.cc
==============================================================================
--- gstreamermm/trunk/examples/ogg_player_gtkmm/PlayerWindow.cc	(original)
+++ gstreamermm/trunk/examples/ogg_player_gtkmm/PlayerWindow.cc	Thu Jan 10 23:15:33 2008
@@ -227,14 +227,13 @@
     gint64 pos;
     Gst::Format fmt = Gst::FORMAT_TIME;
 
-    Glib::RefPtr<Gst::Query> query =
-            Gst::QueryPosition::create(fmt);
+    Glib::RefPtr<Gst::Query> query = Gst::QueryPosition::create(fmt);
 
-    Glib::RefPtr<Gst::QueryPosition> posQuery =
-        Glib::RefPtr<Gst::QueryPosition>::cast_dynamic(query);
-
-    if (mainPipeline->query(posQuery))
+    if (mainPipeline->query(query))
     {
+        Glib::RefPtr<Gst::QueryPosition> posQuery =
+            Glib::RefPtr<Gst::QueryPosition>::cast_dynamic(query);
+
         posQuery->parse(fmt, pos);
 
         gint64 newPos = ((pos + skipAmount) < duration) ? (pos + skipAmount) :



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]