[feature]: minimal setups for the IMX6ULL - #12
Merged
Conversation
Add desktop/ui/platform/embedded/ providing an IDisplayServerBackend implementation for the DirectRender role, used when CFDesktop renders directly to the framebuffer (Qt linuxfb/EGLFS) without a windowing system -- e.g. i.MX6ULL. - EmbeddedDisplayServerBackend: DirectRender role, primary-screen output, no-op window backend. - NullWindowBackend: empty IWindowBackend; reports no multi-window/GPU. - EmbeddedDisplaySizePolicy: frameless fullscreen for one framebuffer. - embedded_platform.cpp: native_impl / native_display_impl / native_shell_layer_impl (shell layer reuses WidgetShellLayer). - CMake: CFDESKTOP_EMBEDDED option selects embedded/ instead of linux_wsl/ (XCB) or windows/, so the ARM build needs no libxcb. Enables cross-compiling for armhf (arm-none-linux-gnueabihf, GCC 15.2, Qt 6.9.1 linuxfb) with -DCFDESKTOP_EMBEDDED=ON.
ConsoleHelper::size() could return a valid optional holding (0, 0) on consoles with no window size (e.g. an i.MX6ULL serial console). Callers only checked for nullopt, so the zero size reached the early welcome renderer, which built a std::string of static_cast<size_t>(-2) chars and threw std::length_error, aborting boot. Return nullopt for non-positive dimensions so callers fall back to fallback_size() (80x24). Confirmed: CFDesktop now boots to the shell on i.MX6ULL linuxfb.
Four issues blocked the AppLauncher start-menu on the i.MX6ULL linuxfb target (no compositor / window manager): 1. Qt::Popup auto-closes on deactivation: as a top-level popup it was dismissed shortly after show() because linuxfb cannot keep a second window active. Make it a frameless CHILD widget of the desktop so it renders inside the single desktop window -- no activation fight. 2. As a child widget it auto-shows when the desktop becomes visible, rendering the tiles at the default (0,0) on boot. Hide it in the ctor so it only appears on popup(). 3. popup() used setFixedSize + move separately, which could leave a never-shown child at (0,0) on first realization. Use setGeometry (atomic) and force the grid to activate. 4. The start button only ever called popup() (no close path), so a second click was a no-op. Make it a proper toggle (hide if showing, else popup). Confirmed on i.MX6ULL linuxfb: the start menu opens centered above the taskbar, stays open, and toggles cleanly on repeated Start clicks.
The default app list was a set of placeholder X11 apps (xdg-open, xterm, cfdesktop-settings, ...) that do not exist on the i.MX6ULL board, so clicking a launcher tile launched nothing. Make the list per-board configurable and add one real in-process app. - Load the app list from <bin>/../apps.json at startup; fall back to defaultApps() when the file is missing/empty. AppEntry fields are read from a JSON apps[] array, so a board customizes the launcher by dropping an apps.json -- no recompile. exec_command already supported args via QProcess::splitCommand, so apps.json just carries them. - Add a builtin About panel: a frameless child widget shown over the desktop when an entry with exec_command "builtin:about" is clicked, dismissed on a tap. CFDesktopEntity routes "builtin:*" entries in-process; everything else goes through AppLaunchService (QProcess). In-process suits the single-framebuffer linuxfb target, where an external GUI app would fight the desktop for /dev/fb0. Confirmed on i.MX6ULL linuxfb: the start menu lists the apps.json entries, About opens/closes, and external entries launch with arguments.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.