1914 Commits

Author SHA1 Message Date
Norman Feske
016d63703d depot: update recipe hashes 2025-04-10 14:55:59 +02:00
Norman Feske
4c01ba1663 sculpt: version 25.04
Issue #5501
2025-04-10 14:55:59 +02:00
Norman Feske
1ef80e86e2 base: introduce Local_rm for local Region_map
The new 'Local_rm' type offers a narrow interface for the interaction
with the component-local address space, managing the lifetime of
attachments by using the 'Allocation' API.

Fixes #5516
2025-04-10 14:55:57 +02:00
Christian Helmuth
8c4bd7d9da gui_fader: restore previous dither-matrix indexing
The dither matrix is not perfectly random but provides a kind of
pseudo-random pattern that fits the original dithering approach with
global coordinate based indexing. If the matrix is offset by one line
each 16 pixels the pattern becomes visible as alternating light and dark
columns.

Follow-up commit to "gui_fader: precompute dithered 16x16 tile".

Issue #5501
2025-04-10 14:55:21 +02:00
Norman Feske
84eb264786 util/attempt.h: mark 'Attempt' types as nodiscard
This catches bugs early on. E.g., when leaving an 'Allocation'
unused, it gets immediately deallocated, which is most probably not
intended. For regular 'Attempt' objects, this change encourages
the proper propagation of errors, or at least the logging of unexpected
conditions.

Fixes #5513
2025-04-10 14:55:21 +02:00
Norman Feske
e380d0da95 base: use 'Allocation' interface for mem alloc
This patch converts the memory-allocator interfaces ('Allocator',
'Range_allocator') and their implementations ('Heap', 'Sliced heap',
'Slab', 'Allocator_avl', 'Synced_allocator') to the new 'Allocation'
utility. The new interface resides at base/memory.h whereas the
traditional allocators implement the new interface.

Down the road, the traditional allocators can successively be decoupled
from the traditional 'Allocator' and 'Range_allocator' interfaces.

Issue #5502
Issue #5245
2025-04-10 14:55:21 +02:00
Norman Feske
fee2f354dc util/attempt.h: introduce 'Ok' type
This type alleviates the need to re-introduce custom '*_ok' types
whenever a result can be an error but no value.
2025-04-10 14:55:20 +02:00
Christian Helmuth
dea2ed1e41 dialog: adaptation to root dir via session label
This is a follow-up fix for "file-system session: root dir via session
label".

Issue #5445
2025-04-10 14:27:21 +02:00
Christian Helmuth
0736db0863 Revert "sculpt: consider screen pos for pointer tracking"
Absolute motion events already carry global coordinates (fader
session).

This reverts commit 3dc05a0a89f00e40d194e7d895b525b405f57f7e.

Issue #5501
2025-04-10 14:26:47 +02:00
Christian Helmuth
2354a6bddb Remove stale raw/download_coreplus recipe
Issue #5492
2025-04-10 14:24:31 +02:00
Norman Feske
ff83de2bbc base: decouple 'Pd_session' from 'Ram_allocator'
With this patch, the 'Pd_session' interface no longer implements the
'Ram_allocator' interface, which allows us to change the
'Genode::Ram_allocator' semantics (as a subsequent step) without
affecting core's PD service.

The patch also replaces the client-local implementation of
'Pd_session_client::dataspace_size' by the proper RPC call 'ram_size' to
core, which mitigates the potential risk of de-referencing a dataspace
cap of an untrusted origin. E.g., in scenarios where the monitor
component requests the size of a dataspace allocated by the debugging
target.

Since 'ram_size' is an RPC call, it cannot be const. Hence, the
'Ram_alloctor::dataspace_size' has become non-const.

The new 'Pd_ram_allocator' implements the 'Ram_allocator' interface by
using a PD session.

Issue #5502
2025-04-10 14:24:31 +02:00
Norman Feske
af3e8725ca Rename 'Constrained_ram_*' to 'Accounted_ram_*'
Fixes #5495
2025-04-10 14:24:11 +02:00
Norman Feske
37ec1db5ea Remove unused vfs_replay component
Fixes #5493
2025-04-10 14:24:11 +02:00
Johannes Schlatow
bdac10cb05 sculpt_manager: improve hover-seq coordination
When a single TOUCH and TOUCH_RELEASE event are submitted
simultaneously, the input sequence number is incremented twice. In
consequence, menu view will never generate a hover report for the
intermediate sequence number. However, this is the report that the
sculpt manager is waiting for to correlate it with the TOUCH event.

Only incrementing the input sequence number when the state changed from
not clicked to clicked exposes another corner case: When the last event
unfocused a dialog (e.g. the popup dialog) and when the current event
touches the dialog, the seq event is not delivered to the dialog because it
is not focused. Therefore, the seq event should be submitted after submitting
the TOUCH event.

genodelabs/genode#5491
2025-04-10 14:24:11 +02:00
Norman Feske
6edbfbf7c3 gems: don't copy Xml_node
Issue #5411
2025-04-10 14:24:11 +02:00
Norman Feske
636eb7b53f os: don't copy Xml_node
As this patch changes 'Vfs::File_system_factory::create', the
VFS plugins must be adapted, now taking 'Xml_node const &' as
argument.

Issue #5411
2025-04-10 14:18:41 +02:00
Norman Feske
7aefaff646 os/buffered_xml.h: don't copy Xml_node
The public 'xml' const member replaces 'with_xml_node()' and the 'xml()'
accessor.

Issue #5411
2025-04-10 14:14:07 +02:00
Christian Helmuth
5cfe44ab72 Check stable output in file_vault_client test
Just output the date (not hours and minutes) in ls as RTC is fixed to
2018-01-01 00:01.

Issue #4371
2025-04-10 14:13:26 +02:00
Johannes Schlatow
9e2e592283 sculpt_manager: touch control of popup dialog
When trying to control the popup dialog with touch events, the dialog
was immediately closed (on any touch). This was a consequence of
evaluating the dialog's hover state without waiting for the
corresponding hover report. For regular motiong events, the hover report
is updated when the pointer moves. For touch events, however, the
hover report is only updated when the touch occurs. We therefore need to
wait for the hover report that corresponds to the touch event before
deciding about closing the popup dialog.

Since menu_view's hover report is not updated for clicks/touches outside any
dialog, we are now using nitpicker's hover report, which also got
augmented by the sequence number in order to be correlated with the
click/touch event.

Fixes #5485
2025-04-10 14:13:26 +02:00
Norman Feske
5b9a9f4d9e sculpt: update panel width on screen-size change
As the panel dialog's min width is propagated via the menu-view config,
we need to re-generate the runtime config whenever the leitzentrale's
size changes. Otherwise the update merely happens as a side effect of
dynamically adjusting the font size, which does not happen with the
fixed config/fonts file.

Issue #5370
2025-04-10 14:13:26 +02:00
Norman Feske
a6ae7c7c58 sculpt: consider screen pos for pointer tracking
When inferring the global pointer position from input events referring
to the leitzentrale, we must take the leitzentrale's panorama position
into account. Otherwise, the hovered display cannot always be reliably
determined.

Issue #5370
2025-04-10 14:13:26 +02:00
Alexander Boettcher
eb443e751f sculpt: support disabling connector manually
via config/fb

Fix #5478
2025-04-10 14:13:26 +02:00
Roman Iten
f4d5e480e3 gems: use 'assert'-proc in run scripts
Issue #5432
2025-04-10 14:12:21 +02:00
Christian Helmuth
2d89b53b0c depot: update recipe hashes 2025-02-27 12:53:40 +01:00
Stefan Kalkowski
b1d53fd4c8 sculpt: add F&S i.MX 8MP Armstone 2025-02-24 16:39:56 +01:00
Norman Feske
2c8beb462f file-system session: root dir via session label
This patch changes the way of how the client-selected sub directory is
communicated to the server. The former opaque session argument is now
passed as last label element, which allows for the flexible tweaking
of this argument by init's session-routing and label-rewriting
mechansims. In particular, it alleviates the need for creating chroot
component instances.

This change requires the following four adaptations at the
configuration level:

- Each file-system session request must now carry a path starting
  with / as last session arguments. Hence, <vfs> <fs> nodes that
  feature a 'label' attributes must extend the attribute value
  with " -> /". For <fs> nodes with no label attribute, "/" is
  used as last label argument by default.

- For matching session-routing rules at init's configuration,
  the matching of full labels should be replaced by 'label_prefix'
  matches, excluding the last (path) argument.

- Wherever a label of a file-system session is rewritten by using
  init's 'label' attribute of a <parent> or <child> target node,
  the new attribute 'identity' should be used instead. This replaces
  the identity part of the label while preserving the client's
  directory argument.

- Analogously to the matching of session-routing rules, server-side
  policy-selection rules that formerly matched a concrete 'label'
  must be changed to match a 'label_prefix' instead.

As a good practice, 'label_prefix' values should end with " ->" if
possible, which clearly delimits the identity part of the label
used by the matching.

Issue #5445
2025-02-24 16:39:20 +01:00
Stefan Kalkowski
ba97a676ad depot: update skalk's expired public key 2025-02-24 16:39:20 +01:00
Norman Feske
2719b37107 run: use ram attribute in start nodes
Issue #5448
2025-02-24 16:39:20 +01:00
Norman Feske
fed21976ec sculpt: add missing ROM route to dialog.lib.so
This is a follow-up fix for "gems: ABI and depot recipe for dialog API".

Issue #5409
2025-02-24 16:39:20 +01:00
Norman Feske
30b3fa45f1 window_layouter: free-arrange mode
This patch adds the feature of moving and resizing windows by clicking
anywhere within a window while the global window-management key is held.
Depending on the position within the window, the click is interpreted as
click on the title (when clicking at inner 50% of the window, or as a
click on the border (when clicking at an area nearby the window
boundary).

This mode of interaction requires more flexibility of the handling of
key sequences. The formerly hard-wired handling of the drag and drop as
response to BTN_LEFT events does not suffice. Therefore, this patch
moves the driving of the drag-and-drop state to the config level by
introducing the actions "drag" and "drop"

Fixes #5403
2025-02-24 16:39:19 +01:00
Norman Feske
7fc060438a window_layouter: handle drag/drop as actions
This patch moves the formerly hard-wired drag-and-drop handling
to the configuration level by introducing the actions "drag" and "drop".

To aid the robust handling of release events matching their
corresponding press events, the patch refines the policy-matching of the
current combination of keys against the hierarchy of <press> and
<release> nodes. If no policy for a concrete combination exists, a
release event also considers the policy of its matching <press> node.
This way, the regular drag-and-drop rules can be expressed as

  <press key="BTN_LEFT" action="drag">
     <release key="BTN_LEFT" action="drop"/>
  </press>

This also works when releasing BTN_LEFT while pressing additional keys,
for which no policy exists.

With this change, the layouter supports the matching of multiple key
sequences instead of only one, thereby supporting multiple actions at
once and allowing for decoupling different user interactions in the
configuration.

Issue #5403
2025-02-24 16:39:19 +01:00
Norman Feske
6c7cbb2c5e pkg/window_layouter: rules format change -> 24.12
To accommodate multi-monitor window management, the window-layouter
rules must be extended. By renaming the rules file to a version number
reflecting the date of change (24.12), we prevent the loss of
window-layout state when switching back and forth between different
versions of the window-layouter.

The default rules contain now the definition of three displays
("primary", "secondary", and "ternary") and map 3 screens to each
display.

Issue #5390
2025-02-24 16:39:19 +01:00
Norman Feske
248c37784b window_layouter: "pick_up" and "place_down" action
The new 'action' attribute values can be used to realize the
keyboard-based assignement of windows to screens. The "pick_up" action
(on a key press) selects the focused window to be held at the current
position until the "place_down" action is issued (by a key release).
While the focused window is held, "screen" actions can be executed
taking the picked up window to the selected screen.

Issue #5390
2025-02-24 16:39:19 +01:00
Norman Feske
d9e49a5c03 window_layouter: restrict focus to visible windows
This patch restricts the focus switching via the keyboard (Super-Tab) to
windows located at visible screens.

Should the currently focused window become invible, switch the focus to the
most recently focused visible window.

Issue #5390
2025-02-24 16:39:19 +01:00
Norman Feske
dbcc21c109 window_layouter: modernized coding style
Replace the use of pointers and the copying of XML nodes by the 'with_'
pattern. Use plain struct where appropriate, replace constructors by { }
initialization. Use C++20 function template syntax. Replace accessors by
public constants where possible. Follow 'from_xml' convention. Follow
usual 'Action' interface naming.

Issue #5390
2025-02-24 16:39:19 +01:00
Norman Feske
ca1b22b0aa window_layouter: allow screen-change during drag
This patch enables the user to interactively change the assignment of
windows to screens. For screens visible side by side in a multi-monitor
setup, one can now move a window from one screen to another by dragging
the window title. When using screens as virtual desktops on one display,
a window can be moved to another screen by switching the screen (by
pressing a key matching a desired screen) while the window is dragged
with the mouse. So the user can drag the window between virtual desktops.

Issue #5390
2025-02-24 16:39:19 +01:00
Norman Feske
8496d5b02a window_layouter: drag windows between displays
This patch allows the user to drag windows from one target area (i.e.,
display) to another whereas the resizing of windows is restricted to
the window's original target area. The latter point is important to
ensure that the window's resize handles remain reachable at all times.

Issue #5390
2025-02-24 16:39:19 +01:00
Norman Feske
1638ee00c3 wm/decorator/layouter: window clipping
This patch changes the window-layout format to support the rectangular
clipping of windows at screen boundaries. The new <boundary> node defines
the clipping boundary for the windows listed within the node. Boundaries
are expected to be disjoint. In the example below, the "vbox" window is
placed partially outside the screen area of "screen_2".

<window_layout>
  <boundary name="screen_1" xpos="0" ypos="0" width="640" height="480">
    <window id="1" title="launchpad" xpos="10" ypos="140" width="400" height=">
  </boundary>
  <boundary name="screen_2" xpos="640" ypos="0" width="800" height="600">
    <window id="2" title="vbox"     xpos="520" ypos="52" width="800" height="600">
    <window id="3" title="terminal" xpos="650" ypos="72" width="500" height="400">
  </boundary>
</window_layout>

The layouter uses boundaries to restrict the visiblilty of windows to
their respective target areas.

Until now, Sculpt relied on the fact that the window-layout ROM had the
same structure as the resize-request ROM. With the addition of the
<boundary> nodes, this is no longer the case. Therefore, the Sculpt
manager generates a dedicated resize-request ROM now.

Issue #5390
2025-02-24 16:39:19 +01:00
Norman Feske
b3d99960e7 window_layouter: assignment of screens to displays
This patch enhances the window layouter with the notion of displays
and the assignment of screens to displays.

Issue #5390
2025-02-24 16:39:19 +01:00
Christian Helmuth
5076554f20 depot: update recipe hashes 2025-01-30 16:32:35 +01:00
Norman Feske
146f161383 gui_fader: precompute dithered 16x16 tile
This improves the performance of the Alpha_dither_painter in
the run/gui_fader scenario by about 3x.
2025-01-30 16:30:15 +01:00
Alexander Boettcher
f28f97773d sculpt: use rom_fs for fiasco and foc
Issue #5406
2025-01-30 16:30:14 +01:00
Norman Feske
414afba682 cpu_sampler: propagate Create_thread_error
The accounting of caps for the UTCB allocation on base-hw puts pressure
on the out-of-ram/caps handling of Create_thread_result in the CPU
sampler. This patch implements the formerly missing error handling.

Issue #5408
2025-01-30 16:30:14 +01:00
Norman Feske
916d036b58 sculpt_manager: use Callable
Issue #5420
2025-01-30 16:30:13 +01:00
Norman Feske
69e8e9f3f1 base: add util/callable.h
Fixes #5420
2025-01-30 16:30:13 +01:00
Norman Feske
1b0829e8a9 gems: ABI and depot recipe for dialog API
This exposes makes the dialog API usable for users of Goa. It turns the
former static dialog library to a shared object and accompanied symbols
file, and adds depot recipes for the library and API.

Issue #5409
2025-01-30 16:30:13 +01:00
Norman Feske
e27d0d36fa wm: revoke curr focus if new focus is undefined
This allows the window layouter to ensure that input entered after
switching to an empty screen won't be routed to the old focused but
no longer visible window.

Issue #5390
2025-01-30 16:24:36 +01:00
Stefan Kalkowski
ebb159d32d usb webcam: turn run-scripts into sculpt tests
Ref genodelabs/genode#5401
2024-12-11 12:20:31 +01:00
Christian Helmuth
cd6701c483 depot: update recipe hashes 2024-12-11 08:35:22 +01:00
Norman Feske
0749f8cbdf wm: free content view IDs if decorator disappears
This patch fixes the following error message printed by the wm upon the
restart of a decorator.

  Error: freeing non-empty slab block"
  Error: ID space not empty at destruction time

Fortunately, the error is not critical as the backing store is released
along with the session.
2024-12-10 14:12:24 +01:00