5.3 release

This commit is contained in:
Trevor Squillario 2014-12-20 17:18:56 -05:00
parent fab90cbabd
commit dea8b9ffd9
12 changed files with 75 additions and 433 deletions

View file

@ -1,8 +1,14 @@
[
{
"date": "12/20/2014", "version": "4.3",
"changes": [
{ "text": "- I'm feeling really good about this one!"}
]
},
{
"date": "12/7/2014", "version": "4.2.5",
"changes": [
{ "text": "- Better mobile support!"}
{ "text": "- Better mobile support (CSS Media Queries)"}
]
},
{

View file

@ -108,6 +108,18 @@
setTimeout(function () { if (submenu_active === false) $('div.submenu').stop().fadeOut(); }, 10000);
}
};
$scope.$watchCollection('queue', function(newItem, oldItem) {
if (oldItem.length != newItem.length) {
$rootScope.showQueue();
}
/*
for (var index in newCol) {
var item = newCol[index];
item.order = parseInt(index) + 1;
}
*/
});
$rootScope.showQueue = function () {
$('#SideBar').css('display', 'block');
$('#right-component').removeClass('lgcolumn_expanded');
@ -123,6 +135,13 @@
$rootScope.hideQueue();
}
};
$scope.toggleQueue = function () {
if ($('#SideBar').css('display') == 'none') {
$rootScope.showQueue();
} else {
$rootScope.hideQueue();
}
};
$rootScope.showArtists = function () {
$('#left-component').css('display', '');
$('#right-component').removeClass('lgcolumn_expandedleft');

View file

@ -49,7 +49,7 @@
<div class="clear"></div>
</div><!-- end #content -->
<div id="SideBar" ng-if="queue.length > 0">
<div id="SideBar">
<div class="headeractions">
<a class="buttonimg" title="Shuffle Queue" ng-click="queueShuffle()"><img src="images/fork_gd_11x12.png"></a>
<a class="buttonimg" id="action_Empty" title="Delete Queue" ng-click="queueEmpty()"><img src="images/trash_fill_gd_12x12.png"></a>
@ -150,10 +150,8 @@
<script src="bower_components/underscore/underscore.js"></script>
<script src="bower_components/angular-underscore/angular-underscore.js"></script>
<!-- endbower -->
<!--<script src="vendor/jquery-split-pane.js"></script>-->
<script src="vendor/jquery.base64.js"></script>
<script src="vendor/jquery.dateFormat-1.0.js"></script>
<script src="vendor/UnityShim.js"></script>
<!-- endbuild -->
<!-- our scripts -->
<!-- build:js(app) scripts/scripts.min.js -->

View file

@ -46,6 +46,7 @@ span.apiversion
{
background: none;
border-right: 1px solid #1D1D1D;
border-top 1px solid #1D1D1D;
}
ul.tablist li {
background: #232323;

View file

@ -1,10 +1,13 @@
@media only screen and (max-width: 400px) {
.smcolumn {
width: 75%;
background: rgba(255, 255, 255, 0.8);
border-bottom; none;
min-width: 292px;
@media only screen and (max-width: 1200px) {
#SideBar {
display: none;
width: 100%;
}
.lgcolumn {
margin-right: 0 !important;
}
}
@media only screen and (max-width: 840px) {
#nav {
border-bottom: 1px solid #D5D5D5;
height: 39px;
@ -23,14 +26,9 @@
margin-bottom: -82px;
}
.subactions {
margin: 11px 5px 0 0;
margin-top: 6px;
float: left;
}
#BreadCrumb {
margin: 5px;
}
}
@media only screen and (max-width: 840px) {
.lgcolumn {
margin-left: 0;
}
@ -85,12 +83,27 @@
#SettingsForm {
}
}
@media only screen and (max-width: 1200px) {
#SideBar {
display: none;
width: 100%;
@media only screen and (max-width: 600px) {
.smcolumn {
width: 75%;
background: rgba(255, 255, 255, 0.8);
border-bottom; none;
min-width: 292px;
top: 120px;
margin-bottom: -122px;
}
.lgcolumn {
margin-right: 0 !important;
.lgsection {
top: 120px;
margin-bottom: -122px;
}
#SideBar {
top: 120px;
margin-bottom: -122px;
}
#BreadCrumb {
margin: 5px;
}
#search {
margin: 11px 5px 0px 5px;
}
}

View file

@ -282,7 +282,7 @@ span.apiversion
}
#SideBar
{
/*display: none;*/
display: none;
min-height: 100%;
height: 100%;
overflow-y: auto;
@ -294,7 +294,7 @@ span.apiversion
top: 40px;
right: 0;
margin-bottom: -42px;
opacity: .95;
opacity: .98;
}
#SideBar .header
{
@ -811,7 +811,10 @@ ul.songlist .albumgrid .albumart img {
background: url(../images/albumdefault_160.jpg) no-repeat;
margin: 3px 0 0 18px;
padding: 0px;
box-shadow: 3px 4px 1px rgba(0, 0, 0, 0.2);
/* REMOVED: Slows scroll performance of albums;
-webkit-box-reflect: below 1px -webkit-gradient(linear, left top, left bottom, from(transparent), color-stop(80%, transparent), to(rgba(255,255,255,0.2)));
*/
}
ul.songlist li:hover .albumgrid .albumart img {
border: 4px solid #ccc;
@ -1088,9 +1091,10 @@ ul.songlist li:hover
.subactions
{
height: 30px;
width: 345px;
/* width: 660px; */
margin: 6px 125px 0 5px;
padding: 0 0 0 5px;
padding: 0;
float: right;
}
#globalactions

View file

@ -4,6 +4,12 @@
<div class="actions floatleft">
<a href="" class="button" id="action_RefreshArtists" title="Refresh List" ng-click="refreshArtists()"><img class="pad" src="images/reload_9x11.png" /></a>
<a href="" class="button" id="action_RescanLibrary" title="Rescan Library" ng-click="rescanLibrary()"><img class="pad" src="images/loop_alt1_gd_12x9.png" /></a>
<a href="" class="button" id="action_ToggleArtists" ng-click="toggleArtists()" title="Toggle Artists"><img src="images/arrow_right_gl_8x8.png" /></a>
</div>
<div id="search">
<input type="text" id="Search" name="Search" class="medium" title="Wildcards (*) supported" placeholder="Search..." ng-enter="search()"/>
<select id="SearchType" name="SearchType" ng-model="SearchType.id" ng-options="o.id as o.name for o in SearchTypes"></select>
<a href="" class="button" id="action_Search" title="Search" ng-click="search()"><img class="pad" src="images/magnifying_glass_alt_12x12.png" /></a>
</div>
<div class="subactions">
<div class="floatleft" ng-show="selectedPlaylist">
@ -73,9 +79,6 @@
</div>
</div>
<div id="left-component" class="smcolumn noselect" tabindex="0">
<div class="leftactions">
<a href="" class="button" id="action_ToggleArtists" ng-click="toggleArtists()" title="Toggle Artists"><img src="images/arrow_right_gl_8x8.png" /></a>
</div>
<ul class="tablist">
<li class="" ng-click="toggleIndex()"><a href="">Artists</a></li>
<li class="" ng-click="togglePlaylist()"><a href="">Playlists</a></li>
@ -87,11 +90,6 @@
<div id="AZIndex" ng-show="!settings.HideAZ" class="subactionsfixed">
<a href="" ng-click="toggleAZ()" stop-event="click">A-Z</a>
</div>
<div id="search">
<input type="text" id="Search" name="Search" class="medium" title="Wildcards (*) supported" placeholder="Search..." ng-enter="search()"/>
<select id="SearchType" name="SearchType" ng-model="SearchType.id" ng-options="o.id as o.name for o in SearchTypes"></select>
<a href="" class="button" id="action_Search" title="Search" ng-click="search()"><img class="pad" src="images/magnifying_glass_alt_12x12.png" /></a>
</div>
<div class="clear"></div>
<ul id="AutoAlbumContainer" class="simplelist mainlist noselect">
<li class="index" id="auto">Auto Albums</li>

View file

@ -1,62 +0,0 @@
/*
* Use this function to create a Unity Music Shim. To use it, simply call setSupports to tell unity
* which features you support, give it a callback for actions as documented below,
* and notify it when your player state changes.
*/
var UnityMusicShim = function() {
var UnityObj = {};
/*
* sendState requires an object with any of the following properties.
* Call this whenever your player state changes.
*
* - playing: Boolean whether or not you are currently playing music
* - title: String the title of the current song
* - artist: String the artist of the current song
* - albumArt: String a URL to the album art of the current song. This must be a publically accessible url
* - favorite: Boolean whether or not the current song is marked as a favorite
* - thumbsUp: Boolean whether or not the current song is marked as thumbs up
* - thumbsDown: Boolean whether or not the current song is marked as thumbs down
*/
UnityObj.sendState = function(state) {
var evt = document.createEvent("CustomEvent");
evt.initEvent("UnityStateEvent", true, true );
document.body.setAttribute('data-unity-state', JSON.stringify(state));
document.body.dispatchEvent(evt, state);
}
document.body.addEventListener('UnityActionEvent', function(e) {
var action = JSON.parse(document.body.getAttribute('data-unity-action'));
if (UnityObj._callbackObject) UnityObj._callbackObject[action]();
});
/*
* addCallbackObject requires an object with functions mapping to any features you support.
* - playpause: Toggle the paused state of your player.
* - next: Skip to the next song.
* - previous: Skip to the previous song.
* - thumbsUp: Mark (or unmark) this song as thumbs up.
* - thumbsDown: Mark (or unmark) this song as thumbs up.
* - favorite: Mark (or unmark) this song as a favorite.
*/
UnityObj.setCallbackObject = function(cbObj) {
UnityObj._callbackObject = cbObj;
};
/*
* setSupports requires an object with any of the following features that your player supports.
* Pass true for anything you support, and omit any you don't.
*
* - playpause: Whether you support pausing the song. You must support this to use Unity
* - next: Whether you support skipping the current song.
* - previous: Whether you support going back to a previous song.
* - thumbsUp: Whether you support giving a song a thumbs up.
* - thumbsDown: Whether you support giving a song a thumbs down.
* - favorite: Whether you support marking song as a favorite.
*/
UnityObj.setSupports = function(supports) {
var evt = document.createEvent("CustomEvent");
evt.initEvent("UnitySupportsEvent", true, true );
document.body.setAttribute('data-unity-supports', JSON.stringify(supports));
document.body.dispatchEvent(evt, supports);
}
return UnityObj;
};

View file

@ -1,99 +0,0 @@
/*!
Split Pane v0.3
Copyright (c) 2012 Simon Hagström
Released under the MIT license
https://raw.github.com/shagstrom/split-pane/master/LICENSE
*/
.split-pane {
position: absolute;
width: 100%;
overflow: hidden;
}
.split-pane.fixed-top > .split-pane-component,
.split-pane.fixed-bottom > .split-pane-component,
.split-pane.horizontal-percent > .split-pane-component {
position: absolute;
left: 0;
width: 100%;
overflow: auto;
top: auto;
bottom: 0;
z-index: 1;
}
.split-pane.fixed-top > .split-pane-component:first-child,
.split-pane.fixed-bottom > .split-pane-component:first-child,
.split-pane.horizontal-percent > .split-pane-component:first-child {
top: 0;
bottom: auto;
}
.split-pane.fixed-top > .split-pane-divider,
.split-pane.fixed-bottom > .split-pane-divider,
.split-pane.horizontal-percent > .split-pane-divider {
position: absolute;
width: 100%;
left: 0;
cursor: ns-resize;
cursor: n-resize\9;
z-index: 2;
}
.split-pane.fixed-left > .split-pane-component,
.split-pane.fixed-right > .split-pane-component,
.split-pane.vertical-percent > .split-pane-component {
position: absolute;
top: 0;
height: 100%;
overflow: auto;
left: auto;
right: 0;
z-index: 1;
}
.split-pane.fixed-left > .split-pane-component:first-child,
.split-pane.fixed-right > .split-pane-component:first-child,
.split-pane.vertical-percent > .split-pane-component:first-child {
left: 0;
right: auto;
}
.split-pane.fixed-left > .split-pane-divider,
.split-pane.fixed-right > .split-pane-divider,
.split-pane.vertical-percent > .split-pane-divider {
position: absolute;
height: 100%;
top: 0;
cursor: ew-resize;
cursor: w-resize\9;
z-index: 2;
}
.split-pane-resize-shim {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
z-index: 10000;
display: none;
}
.split-pane.fixed-left > .split-pane-resize-shim,
.split-pane.fixed-right > .split-pane-resize-shim,
.split-pane.vertical-percent > .split-pane-resize-shim {
cursor: ew-resize;
cursor: w-resize\9;
}
.split-pane.fixed-top > .split-pane-resize-shim,
.split-pane.fixed-bottom > .split-pane-resize-shim,
.split-pane.horizontal-percent > .split-pane-resize-shim {
cursor: ns-resize;
cursor: n-resize\9;
}

View file

@ -1,236 +0,0 @@
/*!
Split Pane v0.3
Copyright (c) 2012 Simon Hagström
Released under the MIT license
https://raw.github.com/shagstrom/split-pane/master/LICENSE
*/
(function($) {
$.fn.splitPane = function() {
var $splitPanes = this;
$splitPanes.each(setMinHeightAndMinWidth);
$splitPanes.append('<div class="split-pane-resize-shim">');
$splitPanes.children('.split-pane-divider').bind('mousedown', mousedownHandler);
setTimeout(function() {
// Doing this later because of an issue with Chrome (v23.0.1271.64) returning split-pane width = 0
// and triggering multiple resize events when page is being opened from an <a target="_blank"> .
$splitPanes.bind('_splitpaneparentresize', parentresizeHandler);
$(window).trigger('resize');
}, 100);
};
var SPLITPANERESIZE_HANDLER = '_splitpaneparentresizeHandler';
/**
* A special event that will "capture" a resize event from the parent split-pane or window.
* The event will NOT propagate to grandchildren.
*/
jQuery.event.special._splitpaneparentresize = {
setup: function(data, namespaces) {
var element = this,
parent = $(this).parent().closest('.split-pane')[0] || window;
$(this).data(SPLITPANERESIZE_HANDLER, function(event) {
var target = event.target === document ? window : event.target;
if (target === parent) {
event.type = "_splitpaneparentresize";
jQuery.event.dispatch.apply(element, arguments);
} else {
event.stopPropagation();
}
});
$(parent).bind('resize', $(this).data(SPLITPANERESIZE_HANDLER));
},
teardown: function(namespaces) {
var parent = $(this).parent().closest('.split-pane')[0] || window;
$(parent).unbind('resize', $(this).data(SPLITPANERESIZE_HANDLER));
$(this).removeData(SPLITPANERESIZE_HANDLER);
}
};
function setMinHeightAndMinWidth() {
var $splitPane = $(this),
$firstComponent = $splitPane.children('.split-pane-component:first'),
$divider = $splitPane.children('.split-pane-divider'),
$lastComponent = $splitPane.children('.split-pane-component:last');
if ($splitPane.is('.fixed-top, .fixed-bottom, .horizontal-percent')) {
$splitPane.css('min-height', (minHeight($firstComponent) + minHeight($lastComponent) + $divider.height()) + 'px');
} else {
$splitPane.css('min-width', (minWidth($firstComponent) + minWidth($lastComponent) + $divider.width()) + 'px');
}
}
function mousedownHandler(event) {
event.preventDefault();
var $resizeShim = $(this).siblings('.split-pane-resize-shim').show(),
mousemove = createMousemove($(this).parent(), event.pageX, event.pageY);
$(document).mousemove(mousemove);
$(document).one('mouseup', function(event) {
$(document).unbind('mousemove', mousemove);
$resizeShim.hide();
});
}
function parentresizeHandler() {
var $splitPane = $(this),
$firstComponent = $splitPane.children('.split-pane-component:first'),
$divider = $splitPane.children('.split-pane-divider'),
$lastComponent = $splitPane.children('.split-pane-component:last');
if ($splitPane.is('.fixed-top')) {
var maxfirstComponentHeight = $splitPane.height() - minHeight($lastComponent) - $divider.height();
if ($firstComponent.height() > maxfirstComponentHeight) {
setTop($splitPane, $firstComponent, $divider, $lastComponent, maxfirstComponentHeight + 'px');
} else {
$splitPane.resize();
}
} else if ($splitPane.is('.fixed-bottom')) {
var maxLastComponentHeight = $splitPane.height() - minHeight($firstComponent) - $divider.height();
if ($lastComponent.height() > maxLastComponentHeight) {
setBottom($splitPane, $firstComponent, $divider, $lastComponent, maxLastComponentHeight + 'px')
} else {
$splitPane.resize();
}
} else if ($splitPane.is('.horizontal-percent')) {
var maxLastComponentHeight = $splitPane.height() - minHeight($firstComponent) - $divider.height();
if ($lastComponent.height() > maxLastComponentHeight) {
setBottom($splitPane, $firstComponent, $divider, $lastComponent, (maxLastComponentHeight / $splitPane.height() * 100) + '%');
} else {
var lastComponentMinHeight = minHeight($lastComponent);
if ($splitPane.height() - $firstComponent.height() - $divider.height() < lastComponentMinHeight) {
setBottom($splitPane, $firstComponent, $divider, $lastComponent, (lastComponentMinHeight / $splitPane.height() * 100) + '%');
} else {
$splitPane.resize();
}
}
} else if ($splitPane.is('.fixed-left')) {
var maxFirstComponentWidth = $splitPane.width() - minWidth($lastComponent) - $divider.width();
if ($firstComponent.width() > maxFirstComponentWidth) {
setLeft($splitPane, $firstComponent, $divider, $lastComponent, maxFirstComponentWidth + 'px');
} else {
$splitPane.resize();
}
} else if ($splitPane.is('.fixed-right')) {
var maxLastComponentWidth = $splitPane.width() - minWidth($firstComponent) - $divider.width();
if ($lastComponent.width() > maxLastComponentWidth) {
setRight($splitPane, $firstComponent, $divider, $lastComponent, maxLastComponentWidth + 'px')
} else {
$splitPane.resize();
}
} else if ($splitPane.is('.vertical-percent')) {
var maxLastComponentWidth = $splitPane.width() - minWidth($firstComponent) - $divider.width();
if ($lastComponent.width() > maxLastComponentWidth) {
setRight($splitPane, $firstComponent, $divider, $lastComponent, (maxLastComponentWidth / $splitPane.width() * 100) + '%');
} else {
var lastComponentMinWidth = minWidth($lastComponent);
if ($splitPane.width() - $firstComponent.width() - $divider.width() < lastComponentMinWidth) {
setRight($splitPane, $firstComponent, $divider, $lastComponent, (lastComponentMinWidth / $splitPane.width() * 100) + '%');
} else {
$splitPane.resize();
}
}
}
}
function createMousemove($splitPane, pageX, pageY) {
var $firstComponent = $splitPane.children('.split-pane-component:first'),
$divider = $splitPane.children('.split-pane-divider'),
$lastComponent = $splitPane.children('.split-pane-component:last');
if ($splitPane.is('.fixed-top')) {
var firstComponentMinHeight = minHeight($firstComponent),
maxFirstComponentHeight = $splitPane.height() - minHeight($lastComponent) - $divider.height(),
topOffset = $divider.position().top - pageY;
return function(event) {
event.preventDefault();
var top = Math.min(Math.max(firstComponentMinHeight, topOffset + event.pageY), maxFirstComponentHeight);
setTop($splitPane, $firstComponent, $divider, $lastComponent, top + 'px')
};
} else if ($splitPane.is('.fixed-bottom')) {
var lastComponentMinHeight = minHeight($lastComponent),
maxLastComponentHeight = $splitPane.height() - minHeight($firstComponent) - $divider.height(),
bottomOffset = $lastComponent.height() + pageY;
return function(event) {
event.preventDefault();
var bottom = Math.min(Math.max(lastComponentMinHeight, bottomOffset - event.pageY), maxLastComponentHeight);
setBottom($splitPane, $firstComponent, $divider, $lastComponent, bottom + 'px');
};
} else if ($splitPane.is('.horizontal-percent')) {
var splitPaneHeight = $splitPane.height(),
lastComponentMinHeight = minHeight($lastComponent),
maxLastComponentHeight = splitPaneHeight - minHeight($firstComponent) - $divider.height(),
bottomOffset = $lastComponent.height() + pageY;
return function(event) {
event.preventDefault();
var bottom = Math.min(Math.max(lastComponentMinHeight, bottomOffset - event.pageY), maxLastComponentHeight);
setBottom($splitPane, $firstComponent, $divider, $lastComponent, (bottom / splitPaneHeight * 100) + '%');
};
} else if ($splitPane.is('.fixed-left')) {
var firstComponentMinWidth = minWidth($firstComponent),
maxFirstComponentWidth = $splitPane.width() - minWidth($lastComponent) - $divider.width(),
leftOffset = $divider.position().left - pageX;
return function(event) {
event.preventDefault();
var left = Math.min(Math.max(firstComponentMinWidth, leftOffset + event.pageX), maxFirstComponentWidth);
setLeft($splitPane, $firstComponent, $divider, $lastComponent, left + 'px')
};
} else if ($splitPane.is('.fixed-right')) {
var lastComponentMinWidth = minWidth($lastComponent),
maxLastComponentWidth = $splitPane.width() - minWidth($firstComponent) - $divider.width(),
rightOffset = $lastComponent.width() + pageX;
return function(event) {
event.preventDefault();
var right = Math.min(Math.max(lastComponentMinWidth, rightOffset - event.pageX), maxLastComponentWidth);
setRight($splitPane, $firstComponent, $divider, $lastComponent, right + 'px');
};
} else if ($splitPane.is('.vertical-percent')) {
var splitPaneWidth = $splitPane.width(),
lastComponentMinWidth = minWidth($lastComponent),
maxLastComponentWidth = splitPaneWidth - minWidth($firstComponent) - $divider.width(),
rightOffset = $lastComponent.width() + pageX;
return function(event) {
event.preventDefault();
var right = Math.min(Math.max(lastComponentMinWidth, rightOffset - event.pageX), maxLastComponentWidth);
setRight($splitPane, $firstComponent, $divider, $lastComponent, (right / splitPaneWidth * 100) + '%');
};
}
}
function minHeight($element) {
return parseInt($element.css('min-height')) || 0;
}
function minWidth($element) {
return parseInt($element.css('min-width')) || 0;
}
function setTop($splitPane, $firstComponent, $divider, $lastComponent, top) {
$firstComponent.css('height', top);
$divider.css('top', top);
$lastComponent.css('top', top);
$splitPane.resize();
}
function setBottom($splitPane, $firstComponent, $divider, $lastComponent, bottom) {
$firstComponent.css('bottom', bottom);
$divider.css('bottom', bottom);
$lastComponent.css('height', bottom);
$splitPane.resize();
}
function setLeft($splitPane, $firstComponent, $divider, $lastComponent, left) {
$firstComponent.css('width', left);
$divider.css('left', left);
$lastComponent.css('left', left);
$splitPane.resize();
}
function setRight($splitPane, $firstComponent, $divider, $lastComponent, right) {
$firstComponent.css('right', right);
$divider.css('right', right);
$lastComponent.css('width', right);
$splitPane.resize();
}
})(jQuery);

View file

@ -1,6 +1,6 @@
{
"name": "jamstash",
"version": "4.2.5",
"version": "4.3",
"description": "HTML5 Audio Streamer for Subsonic, Archive.org browsing and streaming",
"authors": [
"tsquillario (https://github.com/tsquillario)",

View file

@ -1,6 +1,6 @@
{
"name": "jamstash",
"version": "4.2.5",
"version": "4.3",
"description": "HTML5 Audio Streamer for Subsonic, Archive.org browsing and streaming",
"author": "Trevor Squillario (https://github.com/tsquillario)",
"contributors": [