summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xdocs/CHANGELOG2
-rw-r--r--lib/class/xmldata.class.php2
-rw-r--r--server/stream.ajax.php16
3 files changed, 18 insertions, 2 deletions
diff --git a/docs/CHANGELOG b/docs/CHANGELOG
index 88f361a2..789fd718 100755
--- a/docs/CHANGELOG
+++ b/docs/CHANGELOG
@@ -4,6 +4,8 @@
--------------------------------------------------------------------------
v.3.4
+ - Fixed lack of refresh of controls when switching between localplay
+ and other play methods
- Add Debug page with current configuration and php state information
as well as links to generate new config file and reset database
charset
diff --git a/lib/class/xmldata.class.php b/lib/class/xmldata.class.php
index 7f2e33f6..caeee032 100644
--- a/lib/class/xmldata.class.php
+++ b/lib/class/xmldata.class.php
@@ -1,7 +1,7 @@
<?php
/*
- Copyright 2001 - 2007 Ampache.org
+ Copyright Ampache.org
All Rights Reserved
This program is free software; you can redistribute it and/or
diff --git a/server/stream.ajax.php b/server/stream.ajax.php
index a7e7203f..53437205 100644
--- a/server/stream.ajax.php
+++ b/server/stream.ajax.php
@@ -41,18 +41,32 @@ switch ($_REQUEST['action']) {
$results['rfc3514'] = '0x1';
break 2;
}
+ $new = $_POST['type'];
break;
case 'xspf_player':
+ $new = $_POST['type'];
// Rien a faire
break;
default:
+ $new = 'stream';
$results['rfc3514'] = '0x1';
break 2;
} // end switch
+ $current = Config::get('play_type');
+
// Go ahead and update their preference
- Preference::update('play_type',$GLOBALS['user']->id,$_POST['type']);
+ if (Preference::update('play_type',$GLOBALS['user']->id,$new)) {
+ Config::set('play_type',$new,'1');
+ }
+
+
+ if (($new == 'localplay' AND $current != 'localplay') OR ($current == 'localplay' AND $new != 'localplay')) {
+ $results['rightbar'] = ajax_include('rightbar.inc.php');
+ }
+
$results['rfc3514'] = '0x0';
+
break;
case 'basket':
// We need to set the basket up!