source/lib/VBListPanel.js
// Return true if the updated entry differs from the previous entry

Return true if the updated entry differs from the previous entry
Return true if the updated entry differs from the previous entry
updateSnEntry(snEntry, device) {
    const oldIpAddr       = snEntry.ipAddr
    const oldFriendlyName = snEntry.friendlyName
    const oldModelName    = snEntry.modelName
    const oldModelNumber  = snEntry.modelNumber
    if (snEntry.ipAddr !== device.ipAddr) {
      snEntry.ipAddr = device.ipAddr
      snEntry.ip32 = ipAddrTo32(device.ipAddr)
    }
    if (snEntry.friendlyName === '') {
      snEntry.friendlyName = device.friendlyName
    }
    if (device.modelName !== '') {
      snEntry.modelName = device.modelName
    }
    if (device.modelNumber !== '') {
      snEntry.modelNumber = device.modelNumber
    }
    return !( snEntry.ipAddr       === oldIpAddr        &&
              snEntry.friendlyName === oldFriendlyName  &&
              snEntry.modelName    === oldModelName     &&
              snEntry.modelNumber  === oldModelNumber )
  }
updateSnEntry ( snEntry , device ) { const oldIpAddr = snEntry . ipAddr const oldFriendlyName = snEntry . friendlyName const oldModelName = snEntry . modelName const oldModelNumber = snEntry . modelNumber if ( snEntry . ipAddr !== device . ipAddr ) { snEntry . ipAddr = device . ipAddr snEntry . ip32 = ipAddrTo32 ( device . ipAddr ) } if ( snEntry . friendlyName === '' ) { snEntry . friendlyName = device . friendlyName } if ( device . modelName !== '' ) { snEntry . modelName = device . modelName } if ( device . modelNumber !== '' ) { snEntry . modelNumber = device . modelNumber } return ! ( snEntry . ipAddr === oldIpAddr && snEntry . friendlyName === oldFriendlyName && snEntry . modelName === oldModelName && snEntry . modelNumber === oldModelNumber ) }
Return true if the updated entry differs from the previous entry
Return true if the updated entry differs from the previous entry
// If the IP address has changed, calculate the 32-bit ip value
 // Don't update the friendly name unless it was previously blank,
 // because the user could have updated the friendly name manually
 // Don't update the table with blank values for model name/number,
 // which would happen if an SSDP Notify was received,
 // but no response could be obtained
 // Return true if any field has changed in value (SN does not change)
