feat(ui): install the Flatpak files dropped or opened with PacManager

The window accepts a drop and the desktop entry's %U hands over the file
the user picked, so both gestures end up as the same request. The frame
asks the core which files it can install and never names a format itself;
dropped files queue up because the core runs one operation at a time, and
the search and log fields stop swallowing drops so a file dropped on them
reaches the window.

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <noreply@codebuff.com>
This commit is contained in:
BlackAngelTV committed 2026-09-27 19:39:46 +02:00
1 parent 1e751c7205
commit 20acfd00a4
5 files changed
+187

No files matched your search

+4
View File
@@ -32,6 +32,9 @@ BrowsePage::BrowsePage(AppCore* core, QWidget* parent) : Page(core, parent) {
searchRow->setSpacing(10);
m_searchBar = new QLineEdit();
// Drops belong to the window: a .flatpakref let go over the search field
// must install, not paste its path (see MainWindow::dragEnterEvent).
m_searchBar->setAcceptDrops(false);
m_searchBar->setPlaceholderText("Rechercher un paquet (ex : firefox)...");
m_searchBar->setMinimumHeight(40);
m_searchBar->addAction(ui::icon("search"), QLineEdit::LeadingPosition);
@@ -54,6 +57,7 @@ BrowsePage::BrowsePage(AppCore* core, QWidget* parent) : Page(core, parent) {
filterRow->setSpacing(10);
m_filterBar = new QLineEdit();
m_filterBar->setAcceptDrops(false); // drops go to the window (see above)
m_filterBar->setPlaceholderText("Filtrer par nom...");
m_filterBar->setMinimumHeight(36);
m_filterBar->addAction(ui::icon("filter"), QLineEdit::LeadingPosition);
+3
View File
@@ -28,6 +28,9 @@ LogsPage::LogsPage(AppCore* core, QWidget* parent) : Page(core, parent) {
filterRow->addWidget(m_source);
m_filter = new QLineEdit();
// Drops go to the window, which installs Flatpak files (see
// MainWindow::dragEnterEvent) rather than pasting a path here.
m_filter->setAcceptDrops(false);
m_filter->setPlaceholderText("Filtrer les logs (paquet, action, date)...");
m_filter->setMinimumHeight(36);
m_filter->setClearButtonEnabled(true);