10 Commits

Author SHA1 Message Date
Maksim Totmin
a2d92b75e0 Fix Add Files flow: manual source files now persist across scans
- Add self.library_source_files list to store manually added file paths
- _on_library_add_files now adds to library_source_files instead of
  calling _scan_library() (which would clear the list)
- _refresh_source_ui merges scanned sources + library_source_files
  with dedup by path. All items get proper UserRole data.
- _on_library_remove_selected now removes from library_source_files too
- Previously added files would be lost on every scan because
  _scan_library() called .clear() on the source list
2026-05-31 15:15:07 +07:00
Maksim Totmin
ea5f9d038b Fix library remove: delete files from disk, not just from UI
- _on_library_remove_selected now removes files from disk with confirmation
- Shows count, file names, sizes, and total size in dialog
- Cleans up empty parent directories after deletion
- Re-scans library after deletion to refresh the UI
2026-05-31 15:04:20 +07:00
Maksim Totmin
c68bc3a09a Add GTK theme integration for Linux desktop environments
- Add _setup_linux_theming() called before QApplication creation
- Auto-detect libqgtk3.so plugin from common Qt6 plugin paths
- Sets QT_QPA_PLATFORMTHEME=gtk3 so Qt follows system GTK theme
- Falls back to qt6ct if gtk3 plugin not found
- Falls back to Fusion style if no platform theme available
- Respects user-set QT_QPA_PLATFORMTHEME (never overrides)
2026-05-31 15:01:17 +07:00
Maksim Totmin
56a88cf420 Fix QThread lifecycle crash: 'Destroyed while thread is still running'
- Add _cleanup_worker() helper: calls wait() then deleteLater() before
  dropping the Python reference. This ensures the C++ thread is fully
  cleaned up before the QObject is destroyed.
- Replace all 'self.worker_thread = None' with _cleanup_worker()
- Add running thread guards to all handlers: prevent starting a new
  WorkerThread while one is already running
- Add timeout to wait() calls (3000ms) to avoid hanging on close
- WorkerThread.stop() now calls self.wait() to ensure clean shutdown
2026-05-31 14:58:13 +07:00
Maksim Totmin
4c41cba428 Rewrite Library tab as persistent mediатека, split iPod tab for device management
- Rename Convert → Library, Transfer → iPod
- Library tab scans Output Directory on startup and shows all m4a/mp3
  files with metadata (artist, title, duration, size)
- Library tab has two sections: 'Ready to Transfer' and 'Source Files'
  (FLAC/WAV/OGG waiting for conversion)
- Move 'Transfer to iPod' button from Transfer tab to Library tab
- iPod tab is now device-only: mount/eject, view tracks, remove, scan orphans
- No more RAM-only converted_tracks list — library is always from disk
- Auto-scan on startup, after conversion, after download, on directory change
2026-05-31 14:52:55 +07:00
Maksim Totmin
33c8534eb4 Add Transfer tab: Mount/Eject UI, track management, orphaned file scanning
- Add Mount/Eject buttons with device status display
- Auto-mount device on refresh
- Load and display tracks from iPod SQLite database
- Delete selected tracks from iPod with confirmation
- Scan for orphaned files (audio files without DB entries)
- Bulk delete orphaned files to reclaim space
- Show track count and free/total space
2026-05-31 14:39:18 +07:00
Maksim Totmin
47bfdf0011 Add track management: view and delete tracks on iPod from Transfer tab
- Add get_all_tracks() to load all tracks with file paths via tag matching
- Add delete_track() to remove tracks from SQLite DB and delete physical files
- Add _cleanup_orphaned_entries() to remove orphaned artist/album records
- Add track count label and 'Remove Selected' button to Transfer tab
- Load existing tracks on device detection
- Confirmation dialog before deleting tracks
- Reload track list after successful transfer
2026-05-31 12:37:13 +07:00
Maksim Totmin
1b4c092a04 Add metadata extraction from local audio files for proper tag preservation
- Add extract_tags() to metadata_handler.py: reads tags from FLAC, MP3, OGG, M4A
- Support ID3v2 (MP3), Vorbis comments (FLAC/OGG), MP4 tags (M4A)
- Extract cover art from METADATA_BLOCK_PICTURE (FLAC), APIC (MP3), covr (M4A)
- Update _run_convert to use extract_tags instead of guessing from filename
- Fix tag reading in ipod_nano7_db.get_audio_info() using EasyID3 for MP3
2026-05-31 12:26:53 +07:00
Maksim Totmin
761f896ea8 Add iPod Nano 7 SQLite database support for proper track transfer
- Create ipod_nano7_db.py module for Nano 7 SQLite DB management (Library.itdb)
- Fix case-insensitive iPod label detection in device detection
- Add /run/media to mount point search paths for Arch Linux
- Support already-mounted devices without requiring ifuse
- Add local file selection in Convert tab (FLAC, WAV, OGG, etc.)
- Transfer now properly registers tracks in iPod database so they appear in UI
2026-05-31 12:07:17 +07:00
Antonio Lorusso
9dcb1228ca initial app 2025-03-12 01:01:43 +01:00