diff --git a/repos/base/include/util/list_model.h b/repos/base/include/util/list_model.h index da849b8fdf..96af8f93bc 100644 --- a/repos/base/include/util/list_model.h +++ b/repos/base/include/util/list_model.h @@ -143,15 +143,15 @@ class Genode::List_model : Noncopyable } /** - * Apply functor 'fn' to the first element of the list model + * Call functor 'fn' with the first element of the list model * - * Using this method combined with the 'Element::next' method, the list - * model can be traversed manually. This is handy in situations where - * the list-model elements are visited via recursive function calls + * Using this method combined with 'Element::next', the list model + * can be traversed manually. This is handy in situations where the + * list-model elements are visited via recursive function calls * instead of a 'for_each' loop. */ template - void apply_first(FN const &fn) const + void with_first(FN const &fn) const { if (Element const *e = _elements.first()) fn(static_cast(*e)); diff --git a/repos/os/include/decorator/window_stack.h b/repos/os/include/decorator/window_stack.h index be4609d2ce..636b3de00b 100644 --- a/repos/os/include/decorator/window_stack.h +++ b/repos/os/include/decorator/window_stack.h @@ -79,7 +79,7 @@ class Decorator::Window_stack : public Window_base::Draw_behind_fn Dirty_rect result = _dirty_rect; _dirty_rect.flush([&] (Rect const &rect) { - _windows.apply_first([&] (Window_base const &first) { + _windows.with_first([&] (Window_base const &first) { _draw_rec(canvas, &first, rect); }); }); return result;