From 18683f22aa30973e84c94e884371f5f10a9d80c6 Mon Sep 17 00:00:00 2001 From: Karl 'vollmerk' Vollmer Date: Thu, 30 Apr 2009 15:36:34 +0000 Subject: fix lack of ui response on deleting track right after appending to saved playlist --- lib/class/ajax.class.php | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) (limited to 'lib/class/ajax.class.php') diff --git a/lib/class/ajax.class.php b/lib/class/ajax.class.php index a9a9f3ba..bac642f8 100644 --- a/lib/class/ajax.class.php +++ b/lib/class/ajax.class.php @@ -26,6 +26,8 @@ */ class Ajax { + private static $include_override; + /** * constructor * This is what is called when the class is loaded @@ -157,6 +159,16 @@ class Ajax { } // run + /** + * set_include_override + * This sets the cinlduing div override, used only one place kind of a hack + */ + public static function set_include_override($value) { + + self::$include_override = make_bool($value); + + } // set_include_override + /** * start_container * This checks to see if we're AJAX'in if we aren't then it echos out the @@ -164,7 +176,7 @@ class Ajax { */ public static function start_container($name) { - if (AJAX_INCLUDE == '1') { return true; } + if (AJAX_INCLUDE == '1' AND !self::$include_override) { return true; } echo '
'; @@ -176,10 +188,12 @@ class Ajax { */ public static function end_container() { - if (AJAX_INCLUDE == '1') { return true; } + if (AJAX_INCLUDE == '1' AND !self::$include_override) { return true; } echo "
"; + self::$include_override = false; + } // end_container } // end Ajax class -- cgit