9#if defined(SK_BUILD_FOR_WIN)
45 int fileno = _fileno((FILE*)
f);
56 BY_HANDLE_FILE_INFORMATION
info;
57 if (0 == GetFileInformationByHandle(
file, &
info)) {
60 id->fVolume =
info.dwVolumeSerialNumber;
70 && aID.fLsbSize == bID.fLsbSize
71 && aID.fMsbSize == bID.fMsbSize
72 && aID.fVolume == bID.fVolume;
77 SkAutoNullKernelHandle(
const HANDLE handle) : fHandle(handle) { }
78 ~SkAutoNullKernelHandle() { CloseHandle(fHandle); }
79 operator HANDLE()
const {
return fHandle; }
80 bool isValid()
const {
return SkToBool(fHandle); }
84typedef SkAutoNullKernelHandle SkAutoWinMMap;
87 UnmapViewOfFile(
addr);
96 LARGE_INTEGER fileSize;
97 if (0 == GetFileSizeEx(
file, &fileSize)) {
101 if (!SkTFitsIn<size_t>(fileSize.QuadPart)) {
105 SkAutoWinMMap mmap(CreateFileMapping(
file,
nullptr, PAGE_READONLY, 0, 0,
nullptr));
106 if (!mmap.isValid()) {
112 void*
addr = MapViewOfFile(mmap, FILE_MAP_READ, 0, 0, 0);
113 if (
nullptr ==
addr) {
118 *
length =
static_cast<size_t>(fileSize.QuadPart);
123 return _fileno((FILE*)
f);
143 memset(&overlapped, 0,
sizeof(overlapped));
144 ULARGE_INTEGER winOffset;
145 winOffset.QuadPart =
offset;
146 overlapped.Offset = winOffset.LowPart;
147 overlapped.OffsetHigh = winOffset.HighPart;
149 if (!SkTFitsIn<DWORD>(
count)) {
172static uint16_t* concat_to_16(
const char src[],
const char suffix[]) {
177 for (
i = 0;
i <
len;
i++) {
181 if (
i > 0 &&
dst[
i-1] !=
'/') {
208 ::FindClose(
self.fHandle);
210 self.~SkOSFileIterData();
216 ::FindClose(
self.fHandle);
219 if (
nullptr ==
path) {
227static bool is_magic_dir(
const uint16_t
dir[]) {
229 return dir[0] ==
'.' && (
dir[1] == 0 || (
dir[1] ==
'.' &&
dir[2] == 0));
233 WIN32_FIND_DATAW
data;
235 if (
nullptr == dataPtr) {
236 if (::FindNextFileW(handle, &
data))
244 if ((dataPtr->dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) &&
245 !is_magic_dir((uint16_t*)dataPtr->cFileName))
250 if (!(dataPtr->dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)) {
254 if (!::FindNextFileW(handle, dataPtr)) {
260 const uint16_t* utf16name = (
const uint16_t*)dataPtr->cFileName;
261 const uint16_t* ptr = utf16name;
262 while (*ptr != 0) { ++ptr; }
270 WIN32_FIND_DATAW
data;
271 WIN32_FIND_DATAW* dataPtr =
nullptr;
273 if (
self.fHandle == 0) {
274 if (
self.fPath16 ==
nullptr || *
self.fPath16 == 0) {
278 self.fHandle = ::FindFirstFileW((LPCWSTR)
self.fPath16, &
data);
static void info(const char *fmt,...) SK_PRINTF_LIKE(1
SK_API void sk_free(void *)
static void * sk_malloc_throw(size_t size)
size_t sk_qread(FILE *, void *buffer, size_t count, size_t offset)
void sk_fmunmap(const void *addr, size_t length)
bool sk_exists(const char *path, SkFILE_Flags=(SkFILE_Flags) 0)
bool sk_fidentical(FILE *a, FILE *b)
void * sk_fdmmap(int fd, size_t *length)
void * sk_fmmap(FILE *f, size_t *length)
static bool sk_ino(FILE *a, SkFILEID *id)
SkString SkStringFromUTF16(const uint16_t *src, size_t count)
static constexpr bool SkToBool(const T &x)
SK_SPI void reset(const char path[], const char suffix[]=nullptr)
SK_SPI bool next(SkString *name, bool getDir=false)
static const size_t kStorageSize
FlutterSemanticsFlag flags
static float max(float r, float g, float b)
void ReadFile(uint8_t **data, intptr_t *file_len, void *stream)
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir path
DEF_SWITCHES_START aot vmservice shared library name
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir Path to the cache directory This is different from the persistent_cache_path in embedder which is used for Skia shader cache icu native lib Path to the library file that exports the ICU data vm service The hostname IP address on which the Dart VM Service should be served If not defaults to or::depending on whether ipv6 is specified vm service A custom Dart VM Service port The default is to pick a randomly available open port disable vm Disable the Dart VM Service The Dart VM Service is never available in release mode disable vm service Disable mDNS Dart VM Service publication Bind to the IPv6 localhost address for the Dart VM Service Ignored if vm service host is set endless trace Enable an endless trace buffer The default is a ring buffer This is useful when very old events need to viewed For during application launch Memory usage will continue to grow indefinitely however Start app with an specific route defined on the framework flutter assets dir
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir Path to the cache directory This is different from the persistent_cache_path in embedder which is used for Skia shader cache icu native lib Path to the library file that exports the ICU data vm service The hostname IP address on which the Dart VM Service should be served If not defaults to or::depending on whether ipv6 is specified vm service A custom Dart VM Service port The default is to pick a randomly available open port disable vm Disable the Dart VM Service The Dart VM Service is never available in release mode disable vm service Disable mDNS Dart VM Service publication Bind to the IPv6 localhost address for the Dart VM Service Ignored if vm service host is set endless trace buffer
it will be possible to load the file into Perfetto s trace viewer disable asset Prevents usage of any non test fonts unless they were explicitly Loaded via prefetched default font Indicates whether the embedding started a prefetch of the default font manager before creating the engine run In non interactive mode
def getDir(rootdir, target)
std::shared_ptr< const fml::Mapping > data
#define INVALID_HANDLE_VALUE
WINBASEAPI _Check_return_ _Post_equals_last_error_ DWORD WINAPI GetLastError(VOID)
struct _OVERLAPPED OVERLAPPED
unsigned __int64 ULONGLONG