xzw 3 år sedan
förälder
incheckning
205fa8da30
1 ändrade filer med 15 tillägg och 6 borttagningar
  1. 15 6
      js/edit.js

+ 15 - 6
js/edit.js

@@ -1568,11 +1568,13 @@ Hotpoint.prototype.initListSelect = function(){//热点样式图列表
                 }else{
                     this.updateGifPanel({on: !!this.photoList.chosenItem[0].animateInfo  })    
                 }
-                
-                //$('#gifEdit').removeClass('hide');
+                 
+                $('#gifEdit').removeClass('hide');
                 
             }else{
+                !o.dontApplyToHot && this.editSpot.changeTexType("photo",   'clear' )  
                 this.updateGifPanel({on:false})
+                $('#gifEdit').addClass('hide');
                 div.addClass('hide')
             }
             
@@ -1592,10 +1594,11 @@ Hotpoint.prototype.initListSelect = function(){//热点样式图列表
                 
                 if (e.target.classList.contains("del")) { //删除图片 
                      
-                    if($li.hasClass('selected')){//(肯定)是当前spot的 
+                    /* if($li.hasClass('selected')){//(肯定)是当前spot的 
                         that.editSpot.changeTexType('photo', 'clear')  
                     }                    
-                    $li[0]._media = null
+                    $li[0]._media = null */
+                    
                     this.photoList.removeItem($li)  
                 } else {
                     //添加图片 
@@ -1683,6 +1686,9 @@ Hotpoint.prototype.initListSelect = function(){//热点样式图列表
             }else{
                 //div.addClass('hide')
                 div.text('')
+                if(!o.dontApplyToHot){ 
+                    this.editSpot.changeTexType("video" ,   'clear'    )  
+                }
             }
              
            
@@ -2077,6 +2083,7 @@ Hotpoint.prototype.initListSelect = function(){//热点样式图列表
             var name = o.name || o.$li.attr('index')
             for(let i in this.texLists){ this.texLists[i].listDom.parent().addClass("hide")} 
             this.texLists[name].listDom.parent().removeClass("hide")
+            
             if(name == 'photo'){
                 $('#gifEdit').removeClass('hide')
             }else{ 
@@ -2166,7 +2173,8 @@ Hotpoint.prototype.changeType = function(type){
         }
       
         list.selectFromOutSide(list.chosenIndex)
-         
+        
+        
     }
     this.useSuitableRatio({setScaleAuto:true})  
     hot.info.actionType = CloneObject(settings.hotClickEvent[type]);//给一个默认 图和视频不打开热点
@@ -5785,7 +5793,8 @@ class ListBox{//下拉列表
     removeItem($dom){
         $dom.remove()
         if(this.chosenItem && this.chosenItem[0] == $dom[0]){
-            this.chosenItem = this.chosenIndex = null
+            this.selectFromOutSide(null)
+            //this.chosenItem = this.chosenIndex = null
         }
         if(this.options.delFun){
             this.options.delFun($dom)