aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/window_manager.cpp6
-rw-r--r--src/wm_layer_control.cpp14
2 files changed, 19 insertions, 1 deletions
diff --git a/src/window_manager.cpp b/src/window_manager.cpp
index 31caebf..f209f12 100644
--- a/src/window_manager.cpp
+++ b/src/window_manager.cpp
@@ -227,6 +227,12 @@ result<int> WindowManager::api_request_surface(char const *appid, char const *dr
auto id = int(this->id_alloc.generate_id(role));
this->tmp_surface2app[id] = {s_appid, 0};
+ // Work Around
+ HMI_NOTICE("WORK AROUND: add surface on request surface");
+ auto client = g_app_list.lookUpClient(s_appid);
+ client->addSurface(id);
+ ///////////////
+
// Set role map of (new, old)
this->rolenew2old[role] = string(drawing_name);
diff --git a/src/wm_layer_control.cpp b/src/wm_layer_control.cpp
index 10e99b9..80dc0c9 100644
--- a/src/wm_layer_control.cpp
+++ b/src/wm_layer_control.cpp
@@ -554,7 +554,19 @@ WMError LayerControl::layoutChange(const WMAction& action)
auto rect = this->getAreaSize(action.area);
HMI_DEBUG("Set layout %d, %d, %d, %d",rect.x, rect.y, rect.w, rect.h);
- ilm_commitChanges();
+
+ // TO BE FIXED:
+ // Sometimes, ivi_wm_surface_size signal doesn't reach window manager,
+ // then, Window Manager can't set source size.
+ // This fixes it but it takes about 200ns(on R-Car M3) wastefully
+ ilmSurfaceProperties sp;
+ ilm_getPropertiesOfSurface(surface, &sp);
+ if(sp.origSourceHeight != sp.sourceHeight) {
+ HMI_SEQ_NOTICE(action.req_num, "WORK AROUND: set source size w:%d h%d", sp.origSourceWidth, sp.origSourceHeight);
+ ilm_surfaceSetSourceRectangle(surface, 0, 0, sp.origSourceWidth, sp.origSourceHeight);
+ ilm_commitChanges();
+ }
+
ilm_surfaceSetDestinationRectangle(surface, rect.x, rect.y, rect.w, rect.h);
ilm_commitChanges();
for(auto &wm_layer: this->wm_layers)