e_client: added skip base_output_resolution_set conditions. 93/208393/3
authorJunseok, Kim <juns.kim@samsung.com>
Mon, 24 Jun 2019 03:52:17 +0000 (12:52 +0900)
committerJunseok, Kim <juns.kim@samsung.com>
Mon, 24 Jun 2019 09:26:08 +0000 (18:26 +0900)
if the window size is same with base output resolution, then it's no need to set base output resolution.
And, if size from appinfo is zero(means the client want maximum size), then it's also no need to set base output resolution.

Change-Id: I71542adf7fee3096a3eb2bc9a4baa9f715ee130e
Signed-off-by: Junseok, Kim <juns.kim@samsung.com>
src/bin/e_client.c

index 22e0de96aadb5a319b9b87b0a45c7b297b09b86c..0295a2e401959433c43449d4b01f4adacb4e2799 100644 (file)
@@ -7192,15 +7192,12 @@ e_client_image_save(E_Client *ec, const char *dir, const char *name, E_Capture_C
 static void
 _e_client_base_output_resolution_set(E_Client *ec, int width, int height)
 {
+   if (!ec) return;
    ec->base_output_resolution.use = 1;
    ec->base_output_resolution.w = width;
    ec->base_output_resolution.h = height;
-
-   if ((ec->desk->geom.w != width) || (ec->desk->geom.h != height))
-     {
-        ec->base_output_resolution.transform = e_util_transform_new();
-        e_client_transform_core_add(ec, ec->base_output_resolution.transform);
-     }
+   ec->base_output_resolution.transform = e_util_transform_new();
+   e_client_transform_core_add(ec, ec->base_output_resolution.transform);
 }
 
 E_API void
@@ -7260,6 +7257,18 @@ e_client_base_output_resolution_update(E_Client *ec)
         return EINA_TRUE;
       }
 
+   if ((width == 0) && (height == 0))
+     {
+        ELOGF("POL_APPINFO", "SKIP SET BASE SCREEN RESOLUTION... base_output_resolution size:(%d,%d) pid:%d", ec, width, height, ec->netwm.pid);
+        return EINA_TRUE;
+     }
+
+   if ((ec->desk->geom.w == width) && (ec->desk->geom.h == height))
+     {
+        ELOGF("POL_APPINFO", "SKIP SET BASE SCREEN RESOLUTION... base_output_resolution is same with desk size:(%d,%d), pid:%d", ec, width, height, ec->netwm.pid);
+        return EINA_TRUE;
+     }
+
    /* set the base_output_resolution of the e_client */
    _e_client_base_output_resolution_set(ec, width, height);