Code

mpdclient: automatically re-enter idle mode, eliminate mpdclient_put_connection()
[ncmpc.git] / src / mpdclient.h
index 371d42935ecff3374fe9646162b4274c0eb98fc6..bac33383ab1bc33ccb34a614b5091fda8080f2cf 100644 (file)
@@ -23,13 +23,19 @@ struct mpdclient {
 
        /**
         * Tracks idle events.  It is automatically called by
-        * mpdclient_get_connection() and mpdclient_put_connection().
+        * mpdclient_get_connection().
         */
        struct mpd_glib_source *source;
 
        struct mpd_status *status;
        const struct mpd_song *song;
 
+       /**
+        * The GLib source id which re-enters MPD idle mode before the
+        * next main loop interation.
+        */
+       unsigned enter_idle_source_id;
+
        /**
         * This attribute is incremented whenever the connection changes
         * (i.e. on disconnection and (re-)connection).
@@ -139,9 +145,6 @@ mpdclient_update(struct mpdclient *c);
 struct mpd_connection *
 mpdclient_get_connection(struct mpdclient *c);
 
-void
-mpdclient_put_connection(struct mpdclient *c);
-
 /*** MPD Commands  **********************************************************/
 
 bool