Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

cleanup - removed unreferenced functions, moved dangling variable dec…

…laration
  • Loading branch information...
commit 2c485ca125688fbd30e739511ba87eca5c3dae05 1 parent 8de9ffd
@asylumfunk authored
View
2  addons/webinterface.default/addon.xml
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<addon
id="webinterface.default"
- version="2.0.4"
+ version="2.0.5"
@asylumfunk Owner

bump

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
name="Default"
provider-name="Team XBMC">
<requires>
View
2  addons/webinterface.default/index.html
@@ -69,6 +69,6 @@
<div id="nowPlayingPlaylist" style="display: none;"></div>
</div>
</div>
- <script type="text/javascript" src="js/xbmc.launcher.js?v=2.0.3"></script>
+ <script type="text/javascript" src="js/xbmc.launcher.js?v=2.0.5"></script>
@asylumfunk Owner

double-bump (to match addon.xml)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
</body>
</html>
View
33 addons/webinterface.default/js/Core.js
@@ -19,7 +19,7 @@
*/
/* Global Paths */
-
+var commsErrorTimeout;
@asylumfunk Owner

This was dangling further down in the file. JS interprets it this way (vars declared immediately) anyway, plus the code is now more obvious.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
var JSON_RPC = 'jsonrpc';
var DEFAULT_ALBUM_COVER = 'images/DefaultAlbumCover.png';
var DEFAULT_VIDEO_COVER = 'images/DefaultVideo.png';
@@ -50,32 +50,6 @@ function durationToString(duration) {
return result;
}
-function timeToString(duration, showMilliseconds) {
@asylumfunk Owner

This was never referenced.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
- if (!duration) {
- return '00:00';
- }
- milliseconds = duration.milliseconds
- var result = '';
- if (duration.hours) {
- result += (duration.hours < 10 ? '0' + duration.hours : duration.hours) + ':';
- }
- result += (duration.minutes < 10 ? '0' + duration.minutes : duration.minutes) + ':' + (duration.seconds < 10 ? '0' + duration.seconds : duration.seconds);
- if (showMilliseconds) {
- result += '.';
- if (duration.milliseconds < 1000) {
- result += '.';
- if (duration.milliseconds < 100) {
- result += '0';
- if (duration.milliseconds < 10) {
- result += '0';
- }
- }
- }
- result += duration.milliseconds;
- }
- return result;
-}
-
function timeToDuration(time) {
return time.hours * 3600 + time.minutes * 60 + time.seconds;
}
@@ -84,8 +58,6 @@ function applyDeviceFixes() {
document.addEventListener('touchmove', function(e){ e.preventDefault(); });
}
-var commsErrorTimeout;
-
@asylumfunk Owner

see above

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
function displayCommunicationError(m) {
clearTimeout(commsErrorTimeout);
var message = m || 'Connection to server lost';
@@ -117,6 +89,3 @@ function getCookie(name) {
return null;
}
-function deleteCookie(name) {
@asylumfunk Owner

This was never referenced.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
- setCookie(name,"",-1);
-}
View
2  addons/webinterface.default/js/xbmc.launcher.js
@@ -24,7 +24,7 @@
var i,
script,
debug = false, /* Set to true to disable cached javascript */
- version = (debug ? Math.random() : '2.0.3'),
+ version = (debug ? Math.random() : '2.0.5'),
@asylumfunk Owner

double-bump (to match addon.xml)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
scripts = [
"js/jquery-1.5.2.min.js",
"js/jquery.lazyload.js",
@asylumfunk

double-bump (to match addon.xml)

@asylumfunk

This was dangling further down in the file. JS interprets it this way (vars declared immediately) anyway, plus the code is now more obvious.

@asylumfunk

This was never referenced.

@asylumfunk

This was never referenced.

@asylumfunk

double-bump (to match addon.xml)

Please sign in to comment.
Something went wrong with that request. Please try again.