B2G/gecko/browser/components/migration/src/IEProfileMigrator.js
/**
   * Converts a FILETIME struct (2 DWORDS), to a SYSTEMTIME struct.
   *
   * @param aTimeHi
   *        Least significant DWORD.
   * @param aTimeLo
   *        Most significant DWORD.
   * @return a Date object representing the converted datetime.
   */
Converts a FILETIME struct (2 DWORDS), to a SYSTEMTIME struct.
@param aTimeHi
Least significant DWORD.
@param aTimeLo
Most significant DWORD.
@return a Date object representing the converted datetime.
Converts a FILETIME struct ( 2 DWORDS ) to a SYSTEMTIME struct . @param aTimeHi Least significant DWORD . @param aTimeLo Most significant DWORD . @return a Date object representing the converted datetime .
function CH_fileTimeToDate(aTimeHi, aTimeLo) {
    let fileTime = this._structs.FILETIME();
    fileTime.dwLowDateTime = aTimeLo;
    fileTime.dwHighDateTime = aTimeHi;
    let systemTime = this._structs.SYSTEMTIME();
    let result = this._functions.FileTimeToSystemTime(fileTime.address(),
                                                      systemTime.address());
    if (result == 0)
      throw new Error(ctypes.winLastError);
    return new Date(systemTime.wYear,
                    systemTime.wMonth - 1,
                    systemTime.wDay,
                    systemTime.wHour,
                    systemTime.wMinute,
                    systemTime.wSecond,
                    systemTime.wMilliseconds);
  }
function CH_fileTimeToDate ( aTimeHi , aTimeLo ) { let fileTime = this . _structs . FILETIME ( ) ; fileTime . dwLowDateTime = aTimeLo ; fileTime . dwHighDateTime = aTimeHi ; let systemTime = this . _structs . SYSTEMTIME ( ) ; let result = this . _functions . FileTimeToSystemTime ( fileTime . address ( ) , systemTime . address ( ) ) ; if ( result == 0 ) throw new Error ( ctypes . winLastError ) ; return new Date ( systemTime . wYear , systemTime . wMonth - 1 , systemTime . wDay , systemTime . wHour , systemTime . wMinute , systemTime . wSecond , systemTime . wMilliseconds ) ; }
Converts a FILETIME struct (2 DWORDS), to a SYSTEMTIME struct.
Converts a FILETIME struct ( 2 DWORDS ) to a SYSTEMTIME struct .