diff options
author | Kazumasa Mitsunari <knimitz@witz-inc.co.jp> | 2018-08-27 19:15:30 +0900 |
---|---|---|
committer | Kazumasa Mitsunari <knimitz@witz-inc.co.jp> | 2018-08-27 19:17:24 +0900 |
commit | e5295c77d4c436212265edeca7f9a4818a5133e6 (patch) | |
tree | 79b38046d79add27328816d97be94baff6e303c5 /src/wm_client.cpp | |
parent | a5106227c3c9ddbe2b07fbc2ecfc4e2ae1e4de74 (diff) |
Update wm_client and applist
Change-Id: I76a58f431b894f2db1a8864f620c48311807befc
Signed-off-by: Kazumasa Mitsunari <knimitz@witz-inc.co.jp>
Diffstat (limited to 'src/wm_client.cpp')
-rw-r--r-- | src/wm_client.cpp | 33 |
1 files changed, 20 insertions, 13 deletions
diff --git a/src/wm_client.cpp b/src/wm_client.cpp index 4aecbf4..7245549 100644 --- a/src/wm_client.cpp +++ b/src/wm_client.cpp @@ -71,6 +71,23 @@ WMClient::WMClient(const string &appid, const string &role) } } +WMClient::WMClient(const string &appid, unsigned layer, + const string& layer_name, unsigned surface, const string &role) + : id(appid), layer(layer), wm_layer_name(layer_name), + role2surface(0) +{ + role2surface[role] = surface; + for (auto x : kWMEvents) + { +#if GTEST_ENABLED + string ev = x; +#else + afb_event ev = afb_daemon_make_event(x.c_str()); +#endif + evname2afb_event[x] = ev; + } +} + string WMClient::appID() const { return this->id; @@ -114,23 +131,13 @@ const string& WMClient::getWMLayerName() void WMClient::setRole(const string& role) { + this->role_list.clear(); this->role_list.push_back(role); } -/** - * Set layerID the client belongs to - * - * This function set layerID the client belongs to. - * But this function may not used because the layer should be fixed at constructor. - * So this function will be used to change layer by some reasons. - * - * @param unsigned[in] layerID - * @return None - * @attention WMClient can't have multiple layer - */ -void WMClient::registerLayer(unsigned layer) +void WMClient::appendRole(const string& role) { - this->layer = layer; + this->role_list.push_back(role); } /** |