add experimental support for setting user.ui via #?k=v&l=w

This commit is contained in:
rolux 2012-10-31 13:27:33 +00:00
parent d658da92c8
commit 429dd37701

View file

@ -8,7 +8,7 @@ pandora.URL = (function() {
function getState() {
Ox.Log('', 'GET STATE, UI', pandora.user.ui)
Ox.Log('URL', 'getState:, UI', pandora.user.ui)
if (pandora.user.ui.page) {
return {page: pandora.user.ui.page};
@ -132,6 +132,16 @@ pandora.URL = (function() {
}
}
if (state.hash && state.hash.query) {
state.hash.query.forEach(function(kv) {
try {
set[kv.key] = JSON.parse(kv.value);
} catch(e) {
set[kv.key] = kv.value;
}
});
}
Ox.Request.cancel();
$('video').each(function() {
$(this).trigger('stop');