genode/libports/src/app/qt5/qt_avplay/framebuffer_session_component.h
Norman Feske 6525ec5951 Simplify Framebuffer::Session interface
This patch removes the 'Framebuffer::Session::release()' function from
the interface to make the mode-change protocol consistent with the way
the Rom_session interface handles ROM-module changes. That is, the
client acknowledges the release of its current dataspace by requesting a
new dataspace via the 'Framebuffer::Session::dataspace()' function.

Fixes #1057
2014-03-14 13:17:35 +01:00

57 lines
1.3 KiB
C++

/*
* \brief Framebuffer session component
* \author Christian Prochaska
* \date 2012-04-02
*/
/*
* Copyright (C) 2012-2013 Genode Labs GmbH
*
* This file is part of the Genode OS framework, which is distributed
* under the terms of the GNU General Public License version 2.
*/
#ifndef _FRAMEBUFFER_SESSION_COMPONENT_H_
#define _FRAMEBUFFER_SESSION_COMPONENT_H_
/* Genode includes */
#include <base/rpc_server.h>
#include <framebuffer_session/client.h>
#include <nitpicker_session/connection.h>
/* Qt4 includes */
#include <qnitpickerviewwidget/qnitpickerviewwidget.h>
namespace Framebuffer {
class Session_component : public Genode::Rpc_object<Session>
{
private:
Nitpicker::Connection _nitpicker;
Session_client _framebuffer;
int _limited_size(int requested_size, int max_size);
public:
/**
* Constructor
*/
Session_component(const char *args,
QNitpickerViewWidget &nitpicker_view_widget,
int max_width = 0,
int max_height = 0);
Genode::Dataspace_capability dataspace();
Mode mode() const;
void mode_sigh(Genode::Signal_context_capability sigh_cap);
void refresh(int x, int y, int w, int h);
};
}
#endif /* _FRAMEBUFFER_SESSION_COMPONENT_H_ */