|
@@ -23736,20 +23736,26 @@ window.Modernizr = function(n, e, t) {
|
|
|
var currentLocation = this.model.heroLocations[this.director.currentItem[0]]
|
|
|
var rotTime
|
|
|
if(currentLocation.rotTime == void 0 || currentLocation.rotTime == ''){
|
|
|
- var restChildCount = currentLocation.heroLocations ? (currentLocation.heroLocations.length-this.director.currentItem[1]-1) : 0
|
|
|
- var hasMusic = currentLocation && currentLocation.musicInfo && currentLocation.musicInfo.music
|
|
|
- if(hasMusic){
|
|
|
- var audioObj = SoundManager.list.find(e=>e.name == 'tour')
|
|
|
- var current = audioObj.audio.currentTime * 1e3 // || 0 //g_tourAudio ? 1e3 * g_tourAudio.currentTime : 0
|
|
|
- rotTime = currentLocation.musicInfo.time - current
|
|
|
- if(restChildCount){//如果当前folder中还有剩下的item,平分一下时间
|
|
|
- rotTime = (rotTime-timeEachItem*restChildCount) / (restChildCount+1);
|
|
|
- }
|
|
|
- }else{
|
|
|
- rotTime = defaultRotTime
|
|
|
- }
|
|
|
- rotTime = Math.max(0, rotTime)
|
|
|
- Log("rotTime "+rotTime +" at item "+this.director.currentItem + (hasMusic ? (",musicCurrentTime:"+current+'音乐总长:'+currentLocation.musicInfo.time) : ''),"#E8E")
|
|
|
+ // 周恩光加 使用片段时长覆盖音乐时长
|
|
|
+ rotTime = currentLocation.heroLocations[this.director.currentItem[1]-1].rotTime * 1000
|
|
|
+ if(!rotTime) {
|
|
|
+ var restChildCount = currentLocation.heroLocations ? (currentLocation.heroLocations.length-this.director.currentItem[1]-1) : 0
|
|
|
+ var hasMusic = currentLocation && currentLocation.musicInfo && currentLocation.musicInfo.music
|
|
|
+ if(hasMusic){
|
|
|
+ var audioObj = SoundManager.list.find(e=>e.name == 'tour')
|
|
|
+ var current = audioObj.audio.currentTime * 1e3 // || 0 //g_tourAudio ? 1e3 * g_tourAudio.currentTime : 0
|
|
|
+ rotTime = currentLocation.musicInfo.time - current
|
|
|
+ if(restChildCount){//如果当前folder中还有剩下的item,平分一下时间
|
|
|
+ rotTime = (rotTime-timeEachItem*restChildCount) / (restChildCount+1);
|
|
|
+ }
|
|
|
+ }else{
|
|
|
+ rotTime = defaultRotTime
|
|
|
+ }
|
|
|
+ rotTime = Math.max(0, rotTime)
|
|
|
+ Log("rotTime "+rotTime +" at item "+this.director.currentItem + (hasMusic ? (",musicCurrentTime:"+current+'音乐总长:'+currentLocation.musicInfo.time) : ''),"#E8E")
|
|
|
+ } else {
|
|
|
+ Log("rotTime "+rotTime +" at item "+this.director.currentItem,"#E8E")
|
|
|
+ }
|
|
|
}else{
|
|
|
rotTime = currentLocation.rotTime * 1000
|
|
|
Log("rotTime "+rotTime +" at item "+this.director.currentItem,"#E8E")
|