ladybird/Userland
Sam Atkins 23aec16e8b LibCore: Introduce a new directory iteration API
`Core::Directory::for_each_entry()` takes a callback which is passed the
DirectoryEntry and the parent Directory. It returns any error from
creating the iterator, iterating the entries, or returned from the
callback.

As a simple example, this:

```c++
Core::DirIterator piece_set_iterator { "/res/icons/chess/sets/",
        Core::DirIterator::SkipParentAndBaseDir };
while (piece_set_iterator.has_next())
    m_piece_sets.append(piece_set_iterator.next_path());
```

becomes this:

```c++
TRY(Core::Directory::for_each_entry("/res/icons/chess/sets/"sv,
        Core::DirIterator::SkipParentAndBaseDir,
        [&](auto const& entry, auto&) -> ErrorOr<IterationDecision> {
    TRY(m_piece_sets.try_append(entry.name));
    return IterationDecision::Continue;
}));
```
2023-03-05 20:23:42 +01:00
..
Applets Applets/Keymap: Repaint applet on demand only 2023-03-04 00:29:38 +01:00
Applications LibCore+Everywhere: Return an Error from DirIterator::error() 2023-03-05 20:23:42 +01:00
BuggieBox Userland: Add the BuggieBox program 2022-11-26 12:41:47 -07:00
Demos Userland: Fix remaining smart pointer const-correctness issues 2023-02-21 00:54:04 +01:00
DevTools LibCore+Everywhere: Return an Error from DirIterator::error() 2023-03-05 20:23:42 +01:00
DynamicLoader DynamicLoader: Disable stack protector in some files for aarch64 build 2023-02-15 22:53:19 +01:00
Games Userland: Use Font::pixel_size_rounded_up() instead of glyph_height() 2023-03-04 00:29:38 +01:00
Libraries LibCore: Introduce a new directory iteration API 2023-03-05 20:23:42 +01:00
Services LibCore+Everywhere: Return an Error from DirIterator::error() 2023-03-05 20:23:42 +01:00
Shell LibCore+Everywhere: Remove ArgsParser::add*(char const*&) 2023-03-01 10:47:19 +01:00
Utilities LibCore+Everywhere: Return an Error from DirIterator::error() 2023-03-05 20:23:42 +01:00
CMakeLists.txt Userland: Add the BuggieBox program 2022-11-26 12:41:47 -07:00