: id(appid),
layer(0),
is_source_set(false),
+ is_active(false),
+ main_role(role),
role2surface(0),
evname2afb_event(0)
{
WMClient::WMClient(const string &appid, unsigned layer, const string &role)
: id(appid),
layer(layer),
+ is_source_set(false),
+ is_active(false),
main_role(role),
role2surface(0),
evname2afb_event(0)
return this->main_role;
}
+void WMClient::setRole(const string& role)
+{
+ this->main_role = role;
+}
+
unsigned WMClient::layerID() const
{
return this->layer;
}
+void WMClient::setLayerID(unsigned id)
+{
+ this->layer = id;
+}
+
unsigned WMClient::surfaceID() const
{
return this->surface;
this->surface = surface;
}
+void WMClient::activate()
+{
+ if(!this->isActive())
+ this->emitActive(true); // emit when state is changed
+ this->is_active = true;
+}
+
+void WMClient::deactivate()
+{
+ if(this->isActive())
+ this->emitActive(false); // emit when state is changed
+ this->is_active = false;
+}
+
/**
* Add surface to the client
*
}
if(allow_send)
{
- this->area = area;
json_object* j = json_object_new_object();
json_object_object_add(j, kKeyRole, json_object_new_string(this->role().c_str()));
json_object_object_add(j, kKeyDrawingName, json_object_new_string(this->role().c_str()));
}
if(allow_send)
{
- this->area = area;
json_object* j = json_object_new_object();
json_object_object_add(j, kKeyRole, json_object_new_string(this->role().c_str()));
json_object_object_add(j, kKeyDrawingName, json_object_new_string(this->role().c_str()));
HMI_NOTICE("trace");
if(afb_event_is_valid(this->evname2afb_event[kSyncDraw]))
{
- this->area = area;
json_object *j_rect = json_object_new_object();
json_object_object_add(j_rect, kKeyX, json_object_new_int(r.x));
json_object_object_add(j_rect, kKeyY, json_object_new_int(r.y));