typedef struct wmClientCtxt
{
std::string name;
- wmClientCtxt(const char *appName)
+ std::string role;
+ wmClientCtxt(const char *appName, const char* appRole)
{
name = appName;
+ role = role;
}
} wmClientCtxt;
}
HMI_DEBUG("wm", "remove app %s", ctxt->name.c_str());
// Lookup surfaceID and remove it because App is dead.
- auto pSid = g_afb_instance->app.id_alloc.lookup(ctxt->name.c_str());
+ auto pSid = g_afb_instance->app.id_alloc.lookup(ctxt->role.c_str());
if (pSid)
{
auto sid = *pSid;
if (isFirstReq)
{
- wmClientCtxt *ctxt = new wmClientCtxt(a_drawing_name);
+ wmClientCtxt *ctxt = new wmClientCtxt(afb_req_get_application_id(req), a_drawing_name);
HMI_DEBUG("wm", "create session for %s", ctxt->name.c_str());
afb_req_session_set_LOA(req, 1);
afb_req_context_set(req, ctxt, cbRemoveClientCtxt);