$ show mhogomchungu/media-downloader
Media Downloader is a cross-platform Qt/C++ desktop application that serves as a graphical frontend for multiple command-line download tools (yt-dlp, gallery-dl, aria2c, wget, etc.). It provides a tabbed interface for single URL downloads, batch processing, playlist and subscription management, and a library browser for managing downloaded files. The application manages the lifecycle of external engine executables, including automatic download and updates, and supports proxy configuration, themes, translations (17+ languages), system tray integration, and extensive download options (format selection, subtitles, chapters, etc.). The architecture follows a plugin-like pattern where each backend engine is wrapped in a polymorphic class derived from a base engine, with JSON configuration files defining executables and options. The code shows strong engineering discipline with clear separation of utilities, engine wrappers, and UI components, though some files (e.g., batchdownloader.cpp) are very large.
The LLM identified 2 files worth highlighting for reuse:
Implements enforced single-instance behavior using QLocalServer/QLocalSocket and a lock file. The code is fully encapsulated, platform-independent (uses Qt abstractions), and can be extracted as-is into any Qt application that needs to prevent multiple instances. Demonstrates non-obvious knowledge of inter-process communication with fallback to lock file if server creation fails.
A reusable cross-platform directory listing utility with sorting (by name, date, size) and platform-specific implementations (Windows wchar_t path handling, POSIX dirent, and generic QDirIterator). The header declareations are minimal and self-contained; the implementation logic is isolated from the rest of the application. Could be extracted into a file manager or any tool requiring directory browsing with custom sort.