aboutsummaryrefslogtreecommitdiffstats
path: root/src/wm_client.cpp
diff options
context:
space:
mode:
authorKazumasa Mitsunari <knimitz@witz-inc.co.jp>2018-09-07 14:09:19 +0900
committerKazumasa Mitsunari <knimitz@witz-inc.co.jp>2018-09-07 14:09:19 +0900
commita13afdbe2af9815f4b4c2073d30a0ebc40a296b7 (patch)
tree62640eeeb4d7bb74ba0fe35ab3cb64628286fe31 /src/wm_client.cpp
parent1b1051702003391f958f4bf68c5dfe88676d56d4 (diff)
addSurface to client
Change-Id: I2f09a94893699fc73bc82ac2caad5a9e282405b3 Signed-off-by: Kazumasa Mitsunari <knimitz@witz-inc.co.jp>
Diffstat (limited to 'src/wm_client.cpp')
-rw-r--r--src/wm_client.cpp15
1 files changed, 14 insertions, 1 deletions
diff --git a/src/wm_client.cpp b/src/wm_client.cpp
index 0f78f9f..500c60e 100644
--- a/src/wm_client.cpp
+++ b/src/wm_client.cpp
@@ -17,6 +17,7 @@
#include <json-c/json.h>
#include "wm_client.hpp"
#include "util.hpp"
+#include <ilm/ilm_control.h>
#define INVALID_SURFACE_ID 0
@@ -155,7 +156,7 @@ void WMClient::appendRole(const string& role)
* @param unsigned[in] surface
* @return true
*/
-bool WMClient::addSurface(const string &role, unsigned surface)
+/* bool WMClient::addSurface(const string &role, unsigned surface)
{
HMI_DEBUG("Add role %s with surface %d", role.c_str(), surface);
if (0 != this->role2surface.count(role))
@@ -164,6 +165,18 @@ bool WMClient::addSurface(const string &role, unsigned surface)
}
this->role2surface[role] = surface;
return true;
+} */
+
+bool WMClient::addSurface(unsigned surface)
+{
+ this->surface = surface;
+ ilmErrorTypes err = ilm_layerAddSurface(this->layer, surface);
+
+ if(err == ILM_SUCCESS)
+ {
+ err = ilm_commitChanges();
+ }
+ return (err == ILM_SUCCESS) ? true : false;
}
bool WMClient::removeSurfaceIfExist(unsigned surface)