Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update Music Player Support to 0.3.0.0
- Loading branch information
Showing
19 changed files
with
289 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
Binary file not shown.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
42 changes: 42 additions & 0 deletions
42
plugin/Music Player Support/bin/widget/cover demo/cover.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
var DATA_URL = "http://nvg-data/"; | ||
var ID_ODATASOURCE = "A60D2B8A-DCD9-4753-9E3F-C9F2B686F34B"; | ||
var ID_DATA_CAD = "26DDF5CF-528B-46b4-B184-19ED771D495D"; | ||
var ID_CAD_TITLE = 3; | ||
var ID_CAD_COVER = 7; | ||
|
||
var UPDATE_INTERVAL = 1000; // 1s | ||
|
||
var title = ""; | ||
|
||
function updateItem(sid, did, vid, isCover) | ||
{ | ||
$.ajax({ | ||
type: "get", | ||
dataType: "json", | ||
url: DATA_URL + sid + "/" + did + "/" + vid + "/query", | ||
success: function (ret) { | ||
if (isCover) { | ||
if (ret.data.value != " ") | ||
document.getElementById("cover").src = ret.data.value + "?time=" + new Date().getTime(); | ||
else | ||
document.getElementById("cover").src = "unknown.png"; | ||
} | ||
else | ||
if (ret.data.value != title) { | ||
title = ret.data.value; | ||
document.getElementById("cover").src = ""; | ||
updateItem(ID_ODATASOURCE, ID_DATA_CAD, ID_CAD_COVER, true); | ||
} | ||
} | ||
}); | ||
} | ||
|
||
function refreshValues() | ||
{ | ||
updateItem(ID_ODATASOURCE, ID_DATA_CAD, ID_CAD_TITLE, false); | ||
} | ||
|
||
$(function () { | ||
refreshValues(); | ||
setInterval("refreshValues()", UPDATE_INTERVAL); | ||
}); |
123 changes: 123 additions & 0 deletions
123
plugin/Music Player Support/bin/widget/cover demo/index.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,123 @@ | ||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> | ||
<html xmlns="http://www.w3.org/1999/xhtml"> | ||
<head> | ||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> | ||
<title>Cover Demo</title> | ||
<script language="javascript" type="text/javascript" src="jquery.min.js"></script> | ||
<script language="javascript" type="text/javascript" src="cover.js"></script> | ||
<style> | ||
.grid { | ||
position: absolute; | ||
} | ||
|
||
.l-t { | ||
height: 10px; | ||
width: 10px; | ||
top: 0px; | ||
left: 0px; | ||
background-image: url("left-top.png"); | ||
} | ||
|
||
.t { | ||
height: 10px; | ||
width: auto; | ||
top: 0px; | ||
left: 10px; | ||
right: 10px; | ||
background-image: url("top.png"); | ||
} | ||
|
||
.r-t { | ||
height: 10px; | ||
width: 10px; | ||
top: 0px; | ||
right: 0px; | ||
background-image: url("right-top.png"); | ||
} | ||
|
||
.l { | ||
height: auto; | ||
width: 10px; | ||
top: 10px; | ||
left: 0px; | ||
bottom: 10px; | ||
background-image: url("left.png"); | ||
} | ||
|
||
.r { | ||
height: auto; | ||
width: 10px; | ||
top: 10px; | ||
bottom: 10px; | ||
right: 0px; | ||
background-image: url("right.png"); | ||
} | ||
|
||
.l-b { | ||
height: 10px; | ||
width: 10px; | ||
left: 0px; | ||
bottom: 0px; | ||
background-image: url("left-bottom.png"); | ||
} | ||
|
||
.b { | ||
height: 10px; | ||
width: auto; | ||
left: 10px; | ||
bottom: 0px; | ||
right: 10px; | ||
background-image: url("bottom.png"); | ||
} | ||
|
||
.r-b { | ||
height: 10px; | ||
width: 10px; | ||
bottom: 0px; | ||
right: 0px; | ||
background-image: url("right-bottom.png"); | ||
} | ||
|
||
.bg { | ||
width: auto; | ||
height: auto; | ||
top: 10px; | ||
left: 10px; | ||
bottom: 10px; | ||
right: 10px; | ||
background-image: url("bg.png"); | ||
} | ||
|
||
.cover { | ||
margin: auto; | ||
position: absolute; | ||
top: 0; | ||
left: 0; | ||
bottom: 0; | ||
right: 0; | ||
max-height: 100%; | ||
max-width: 100%; | ||
} | ||
</style> | ||
</head> | ||
|
||
<body> | ||
<div> | ||
<div class="grid l-t"></div> | ||
<div class="grid t"></div> | ||
<div class="grid r-t"></div> | ||
</div> | ||
<div> | ||
<div class="grid l"></div> | ||
<div class="grid bg"> | ||
<img class="cover" id="cover" src="" onerror='this.src="unknown.png"'/> | ||
</div> | ||
<div class="grid r"></div> | ||
</div> | ||
<div> | ||
<div class="grid l-b"></div> | ||
<div class="grid b"></div> | ||
<div class="grid r-b"></div> | ||
</div> | ||
</body> | ||
</html> |
4 changes: 4 additions & 0 deletions
4
plugin/Music Player Support/bin/widget/cover demo/jquery.min.js
Large diffs are not rendered by default.
Oops, something went wrong.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
94 changes: 94 additions & 0 deletions
94
plugin/Music Player Support/bin/widget/cover demo/style.css
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
|
||
.item { | ||
font-family: 微软雅黑; | ||
width: auto; | ||
min-height: 24px; | ||
color: #FFF; | ||
background: rgba(0,0,0,0.5); | ||
padding: 0 4px 0 4px; | ||
line-height: 140%; | ||
overflow: hidden; | ||
white-space: nowrap; | ||
} | ||
|
||
.square { | ||
float: left; | ||
height: 50px; | ||
width: 44px; | ||
text-align: center; | ||
line-height: 300%; | ||
background: rgba(99,99,99,0.5); | ||
} | ||
|
||
.line { | ||
margin-bottom: 2px; | ||
} | ||
|
||
.v-layout { | ||
width: auto; | ||
margin-left: 54px; | ||
} | ||
|
||
|
||
.progress { | ||
height: 16px; | ||
margin-top: 4px; | ||
color: #333; | ||
background: #EEE; | ||
border-right: 2px solid #999; | ||
text-align: center; | ||
line-height: 100%; | ||
} | ||
|
||
.head .left { | ||
margin-right: 54px; | ||
} | ||
|
||
.head .right { | ||
float: right; | ||
width: 44px; | ||
} | ||
|
||
.main .left { | ||
float: left; | ||
width: 44px; | ||
} | ||
|
||
.main .right { | ||
width: auto; | ||
} | ||
|
||
.extra .left { | ||
margin-right: 22px; | ||
overflow: auto; | ||
white-space: normal; | ||
} | ||
|
||
.extra .right { | ||
float: right; | ||
width: 20px; | ||
padding: 0px; | ||
text-align: center; | ||
cursor: default; | ||
} | ||
|
||
.extra .right:hover { | ||
background: rgba(99,99,99,0.5); | ||
} | ||
|
||
#note textarea { | ||
margin: 1px -4px 1px -3px; | ||
width: 100%; | ||
height: 100%; | ||
resize: none; | ||
overflow-y: hidden; | ||
} | ||
|
||
#note pre { | ||
margin: 0px; | ||
word-wrap: break-word; | ||
} | ||
|
||
.clear { | ||
clear: both; | ||
} |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters