fix
This commit is contained in:
		
							parent
							
								
									6f6e5c99e9
								
							
						
					
					
						commit
						926a465040
					
				@ -247,6 +247,37 @@ async function playChannelInShaka(channel, windowId) {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
    instance.channel = channel;
 | 
					    instance.channel = channel;
 | 
				
			||||||
    
 | 
					    
 | 
				
			||||||
 | 
					    const newTitle = channel.name || 'Advanced DRM Player';
 | 
				
			||||||
 | 
					    const titleElement = instance.container.querySelector('.player-window-title');
 | 
				
			||||||
 | 
					    if (titleElement) {
 | 
				
			||||||
 | 
					        titleElement.textContent = newTitle;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    const taskbarItem = document.getElementById(`taskbar-item-${windowId}`);
 | 
				
			||||||
 | 
					    if (taskbarItem) {
 | 
				
			||||||
 | 
					        taskbarItem.title = newTitle;
 | 
				
			||||||
 | 
					        const taskbarText = taskbarItem.querySelector('.taskbar-item-text');
 | 
				
			||||||
 | 
					        if (taskbarText) {
 | 
				
			||||||
 | 
					            taskbarText.textContent = newTitle;
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        const iconContainer = taskbarItem.querySelector('.taskbar-item-icon-container');
 | 
				
			||||||
 | 
					        if (iconContainer) {
 | 
				
			||||||
 | 
					            const logoSrc = channel['tvg-logo'] || '';
 | 
				
			||||||
 | 
					            let iconHtml;
 | 
				
			||||||
 | 
					            if (logoSrc) {
 | 
				
			||||||
 | 
					                iconHtml = `<img src="${logoSrc}" class="taskbar-item-logo" alt="" onerror="this.style.display='none'; this.nextElementSibling.style.display='inline-flex';">
 | 
				
			||||||
 | 
					                            <span class="taskbar-item-logo-placeholder" style="display: none;">${newTitle.charAt(0)}</span>`;
 | 
				
			||||||
 | 
					            } else {
 | 
				
			||||||
 | 
					                iconHtml = `<span class="taskbar-item-logo-placeholder">${newTitle.charAt(0)}</span>`;
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
 | 
					            iconContainer.innerHTML = iconHtml;
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    if (document.title.includes("Advanced DRM Player")) {
 | 
				
			||||||
 | 
					       document.title = newTitle;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    const player = instance.player;
 | 
					    const player = instance.player;
 | 
				
			||||||
    const videoElement = instance.videoElement;
 | 
					    const videoElement = instance.videoElement;
 | 
				
			||||||
    videoElement.poster = channel['tvg-logo'] || '';
 | 
					    videoElement.poster = channel['tvg-logo'] || '';
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user