mirror of
https://github.com/genodelabs/genode.git
synced 2025-06-18 23:28:29 +00:00
framebuffer_session: alpha as Mode attribute
Propagate the want of an alpha channel as attribute of Framebuffer::Mode instead of passing this property as a separate bool argument. This clears the way for adding useful accessors for pixel/alpha/input surfaces to the Mode type as a subsequent step. Issue #5351
This commit is contained in:
committed by
Christian Helmuth
parent
336d481726
commit
e738162bde
@ -239,10 +239,10 @@ class Framebuffer::Session_component : public Genode::Rpc_object<Session>
|
||||
|
||||
public:
|
||||
|
||||
Session_component(Genode::Env &env, Window_content &window_content)
|
||||
Session_component(Env &env, Window_content &window_content)
|
||||
: _timer(env), _window_content(window_content) { }
|
||||
|
||||
Genode::Dataspace_capability dataspace() override
|
||||
Dataspace_capability dataspace() override
|
||||
{
|
||||
_window_content.realloc_framebuffer();
|
||||
return _window_content.fb_ds_cap();
|
||||
@ -250,13 +250,15 @@ class Framebuffer::Session_component : public Genode::Rpc_object<Session>
|
||||
|
||||
Mode mode() const override
|
||||
{
|
||||
return Mode { .area = _window_content.mode_size() };
|
||||
return { .area = _window_content.mode_size(), .alpha = false };
|
||||
}
|
||||
|
||||
void mode_sigh(Genode::Signal_context_capability sigh) override {
|
||||
_window_content.mode_sigh(sigh); }
|
||||
void mode_sigh(Signal_context_capability sigh) override
|
||||
{
|
||||
_window_content.mode_sigh(sigh);
|
||||
}
|
||||
|
||||
void sync_sigh(Genode::Signal_context_capability sigh) override
|
||||
void sync_sigh(Signal_context_capability sigh) override
|
||||
{
|
||||
_timer.sigh(sigh);
|
||||
_timer.trigger_periodic(10*1000);
|
||||
|
@ -366,7 +366,7 @@ struct Nitlog::Main
|
||||
|
||||
void _init_gui_buffer()
|
||||
{
|
||||
_gui.buffer(Framebuffer::Mode { .area = { _win_w, _win_h } }, false);
|
||||
_gui.buffer({ .area = { _win_w, _win_h }, .alpha = false });
|
||||
}
|
||||
|
||||
bool const _gui_buffer_initialized = (_init_gui_buffer(), true);
|
||||
|
Reference in New Issue
Block a user