<commit_before>! Copyright (C) 2010 <NAME>
! See http://factorcode.org/license.txt for BSD license

USING: accessors alien.c-types alien.data alien.strings
alien.syntax classes.struct destructors kernel
io.encodings.utf16n io.files.trash libc math sequences system
windows.types ;

IN: io.files.trash.windows

<PRIVATE

LIBRARY: shell32

TYPEDEF: WORD FILEOP_FLAGS

PACKED-STRUCT: SHFILEOPSTRUCTW
    { hwnd HWND }
    { wFunc UINT }
    { pFrom LPCWSTR* }
    { pTo LPCWSTR* }
    { fFlags FILEOP_FLAGS }
    { fAnyOperationsAborted BOOL }
    { hNameMappings LPVOID }
    { lpszProgressTitle LPCWSTR } ;

FUNCTION: int SHFileOperationW ( SHFILEOPSTRUCTW* lpFileOp )

CONSTANT: FO_MOVE 0x0001
CONSTANT: FO_COPY 0x0002
CONSTANT: FO_DELETE 0x0003
CONSTANT: FO_RENAME 0x0004

CONSTANT: FOF_MULTIDESTFILES 0x0001
CONSTANT: FOF_CONFIRMMOUSE 0x0002
CONSTANT: FOF_SILENT 0x0004
CONSTANT: FOF_RENAMEONCOLLISION 0x0008<commit_msg>io.files.trash.windows: cleanup using.<commit_after>! Copyright (C) 2010 <NAME>
! See http://factorcode.org/license.txt for BSD license

USING: accessors alien.c-types alien.data alien.strings
alien.syntax classes.struct destructors io.files.trash kernel
libc math sequences system windows.types ;

IN: io.files.trash.windows

<PRIVATE

LIBRARY: shell32

TYPEDEF: WORD FILEOP_FLAGS

PACKED-STRUCT: SHFILEOPSTRUCTW
    { hwnd HWND }
    { wFunc UINT }
    { pFrom LPCWSTR* }
    { pTo LPCWSTR* }
    { fFlags FILEOP_FLAGS }
    { fAnyOperationsAborted BOOL }
    { hNameMappings LPVOID }
    { lpszProgressTitle LPCWSTR } ;

FUNCTION: int SHFileOperationW ( SHFILEOPSTRUCTW* lpFileOp )

CONSTANT: FO_MOVE 0x0001
CONSTANT: FO_COPY 0x0002
CONSTANT: FO_DELETE 0x0003
CONSTANT: FO_RENAME 0x0004

CONSTANT: FOF_MULTIDESTFILES 0x0001
CONSTANT: FOF_CONFIRMMOUSE 0x0002
CONSTANT: FOF_SILENT 0x0004
CONSTANT: FOF_RENAMEONCOLLISION 0x0008
{'fraction_non_alphanumeric': 0.07517577068685775, 'fraction_numerical': 0.05083829096809086, 'mean_word_length': 4.640243902439025, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4253269', 'n_tokens_mistral': 766, 'n_tokens_neox': 690, 'n_words': 162}