Commit Graph

24 Commits

Author SHA1 Message Date
a7a0d3fe63 Refactor Tup, flatten output directories
Make no attempt to replicate the depot layout.
2019-10-28 11:32:29 +01:00
59ab4ef6bc Tupify
Implement a graph-based build system.
2019-10-03 21:25:36 +02:00
Norman Feske
7d55adf01c nit_fb: defer mode change to client response
The '_active_mode' must not be changed at any time except when the
client asks for the 'Framebuffer::mode'. Otherwise, the dimensions of
dataspace used by the client is not always consistent with the mode
information as gathered by the client.
2018-05-30 13:36:15 +02:00
Norman Feske
afcad2a968 os: new Input::Event representation
This commit changes the 'Input::Event' type to be more safe and to
deliver symbolic character information along with press events.

Issue #2761
Fixes #2786
2018-05-03 15:31:25 +02:00
Norman Feske
69ac68ca98 nit_fb: prevent enlarging mode when out of RAM
This patch adds a safety check to nit_fb to ensures that nit_fb never
runs out of RAM. Should the available RAM not suffice for resizing the
virtual framebuffer to a new mode, it keeps the current mode.
2018-02-15 10:22:10 +01:00
Norman Feske
cd7e3425ee nit_fb: allow screen-relative initial_width/height
This change enables the use of negative values for the 'initial_width'
and 'initial_height' attributes to specify values that are relative to
the screen size. This is consistent with the meaning of the 'width' and
'height' attributes.
2018-02-14 20:41:04 +01:00
Josef Söntgen
fe6f616cf1 nit_fb: add attribute for initial dimensions
The 'initial_width' and 'initial_height' attributes were added to
accomodate the use-case to set the initial dimensions whenever 'nit_fb'
is used in a dynamic fashion, e.g, in combination with a window manager.
These attributes may not be mixed with the 'width' and 'height'
attributes, which are mostly used when a static size configuration is
desired.
2018-02-09 13:34:16 +01:00
Christian Helmuth
2b711f59ed nit_fb: fix resizing on framebuffer-mode change
Respect relative width/height configuration if the underlying
framebuffer dimensions change.
2018-01-17 12:14:40 +01:00
Norman Feske
eba9c15746 Follow practices suggested by "Effective C++"
The patch adjust the code of the base, base-<kernel>, and os repository.
To adapt existing components to fix violations of the best practices
suggested by "Effective C++" as reported by the -Weffc++ compiler
argument. The changes follow the patterns outlined below:

* A class with virtual functions can no longer publicly inherit base
  classed without a vtable. The inherited object may either be moved
  to a member variable, or inherited privately. The latter would be
  used for classes that inherit 'List::Element' or 'Avl_node'. In order
  to enable the 'List' and 'Avl_tree' to access the meta data, the
  'List' must become a friend.

* Instead of adding a virtual destructor to abstract base classes,
  we inherit the new 'Interface' class, which contains a virtual
  destructor. This way, single-line abstract base classes can stay
  as compact as they are now. The 'Interface' utility resides in
  base/include/util/interface.h.

* With the new warnings enabled, all member variables must be explicitly
  initialized. Basic types may be initialized with '='. All other types
  are initialized with braces '{ ... }' or as class initializers. If
  basic types and non-basic types appear in a row, it is nice to only
  use the brace syntax (also for basic types) and align the braces.

* If a class contains pointers as members, it must now also provide a
  copy constructor and assignment operator. In the most cases, one
  would make them private, effectively disallowing the objects to be
  copied. Unfortunately, this warning cannot be fixed be inheriting
  our existing 'Noncopyable' class (the compiler fails to detect that
  the inheriting class cannot be copied and still gives the error).
  For now, we have to manually add declarations for both the copy
  constructor and assignment operator as private class members. Those
  declarations should be prepended with a comment like this:

        /*
         * Noncopyable
         */
        Thread(Thread const &);
        Thread &operator = (Thread const &);

  In the future, we should revisit these places and try to replace
  the pointers with references. In the presence of at least one
  reference member, the compiler would no longer implicitly generate
  a copy constructor. So we could remove the manual declaration.

Issue #465
2018-01-17 12:14:35 +01:00
Norman Feske
f3988a27d4 nit_fb: support 'origin' attribute
This patch makes the specification of screen coordinates more flexible.
First, the 'origin' attribute allows one to refer to either of the four
screen corners without knowing the screen size. Second, the 'width'
and 'height' values now accept negative values, which are relative to
the screen size.
2017-11-06 13:57:18 +01:00
Norman Feske
29b8d609c9 Adjust file headers to refer to the AGPLv3 2017-02-28 12:59:29 +01:00
Norman Feske
aee90ed453 Adapt components to new Event::CHARACTER type
Issue #2264
2017-02-27 15:37:49 +01:00
Christian Prochaska
dbb56a8068 nit_fb: API transition (fix 'deprecated' warnings)
Issue #1987
2017-01-20 16:46:56 +01:00
Christian Helmuth
53271d8c5f Use default component stack size where appropriate 2016-11-30 13:38:06 +01:00
Alexander Boettcher
844174918b nit_fb: get to front if nit_fb got input focus
Issue #2143
2016-11-08 15:26:29 +01:00
Emery Hemingway
71f0757a30 transition Input infrastructure to new base API
* Supply Env to Input::Session_component
* Attach input event dataspace at Input::Client
* Process input events by lambda rather than pointer
* Supply Env and a label to Input::Connection

* Wm serves valid input_session to decorator
* Per-source signal handling at input_merger
* Base API update for dummy_input_drv, test_input
* Input API update for launcher, menu_view, terminal,
  mupdf, sdl, seoul, virtualbox

Ref #1987
2016-10-21 12:39:29 +02:00
Emery Hemingway
f92be575ae nit_fb: change to component API
Issue #1987
2016-08-10 11:07:46 +02:00
Norman Feske
2936cbebfd loader,nit_fb,wm: work-around for NOVA's cap revokes 2016-02-09 16:56:50 +01:00
Alexander Boettcher
c745f9b48c nitpicker: forward touch events
Issue #1444
2015-03-19 08:57:19 +01:00
Norman Feske
6a4f232d60 nit_fb: fix translation of absolute motion events 2014-08-26 11:00:35 +02:00
Norman Feske
905ca7bf3f nit_fb: use server API, make resizeable
This patch reimplements the nit_fb server using the server API and
thereby enables the dynamic resizing the of the framebuffer.

Note that the new implementation does not feature the ability to perform
a periodic refresh via the 'refresh_rate' configuration argument. This
feature was removed because the refresh policy can (and should) always
be implemented on the client side.
2014-08-15 10:19:48 +02:00
Norman Feske
91e01411a4 nitpicker: Reworked session interface
This patch changes nitpicker's session interface to use session-local
view handles instead of view capabilities. This enables the batching
of multiple view operations into one atomic update.
2014-08-11 15:55:32 +02:00
Norman Feske
0ed68a56b7 Use signals for delivering input events
This patch changes both the Input::Session interface and the skeleton
for the server-side implementation of this interface
('input/component.h').

The Input::Session interface offers a new 'sigh' function, which can be
called be the client to register a signal handler. The signal handler
gets notified on the arrival of new input. This alleviates the need to
poll for input events at the client side.

The server-side skeleton for implementing input services underwent a
redesign to make it more modular and robust. I.e., there are no
global functions needed at the server side and the event-queue
enable/disable mechanism is implemented at a central place (in the root
component) rather than inside each driver.

Fixes #46
2014-06-06 14:54:07 +02:00
Norman Feske
ca971bbfd8 Move repositories to 'repos/' subdirectory
This patch changes the top-level directory layout as a preparatory
step for improving the tools for managing 3rd-party source codes.
The rationale is described in the issue referenced below.

Issue #1082
2014-05-14 16:08:00 +02:00