e_client: skip base output resolution set when screen size is same with configured... 73/215373/1 accepted/tizen/unified/20191015.013221 submit/tizen/20191007.101823
authorJunseok, Kim <juns.kim@samsung.com>
Mon, 7 Oct 2019 11:37:24 +0000 (20:37 +0900)
committerJunseok, Kim <juns.kim@samsung.com>
Mon, 7 Oct 2019 11:37:24 +0000 (20:37 +0900)
Change-Id: Ide9d9ad02ef2c064640fa01e1e105be65deeec4b

src/bin/e_client.c

index 626ac03c8ac8d8b63ea8ea266ce850f217258b5b..b18ad89fdd7072de1acf35e024774d27baae887b 100644 (file)
@@ -7484,28 +7484,24 @@ e_client_base_output_resolution_update(E_Client *ec)
 
   if (!ec->netwm.pid)
     {
-       _e_client_base_output_resolution_set(ec, configured_width, configured_height);
        ELOGF("POL_APPINFO", "NO PID... USE configured_output_resolution(%d,%d) pid:%d", ec,
              configured_width, configured_height, ec->netwm.pid);
-       return EINA_TRUE;
+       goto use_configured;
     }
 
    epai = e_policy_appinfo_find_with_pid(ec->netwm.pid);
    if (!epai)
      {
-        _e_client_base_output_resolution_set(ec, configured_width, configured_height);
         ELOGF("POL_APPINFO", "NO APPINFO... USE configured_output_resolution(%d,%d) pid:%d", ec,
               configured_width, configured_height, ec->netwm.pid);
-        return EINA_TRUE;
+        goto use_configured;
      }
 
    if (!e_policy_appinfo_base_output_resolution_get(epai, &width, &height))
      {
-        /* set the base_output_resolution of the e_client as a default */
-        _e_client_base_output_resolution_set(ec, configured_width, configured_height);
         ELOGF("POL_APPINFO", "NO BASE SCREEN RESOLUTION... USE configured_output_resolution(%d,%d) pid:%d", ec,
               configured_width, configured_height, ec->netwm.pid);
-        return EINA_TRUE;
+        goto use_configured;
       }
 
    if ((width == 0) && (height == 0))
@@ -7526,6 +7522,20 @@ e_client_base_output_resolution_update(E_Client *ec)
    ELOGF("POL_APPINFO", "USE base_output_resolution(%d,%d) pid:%d", ec, width, height, ec->netwm.pid);
 
    return EINA_TRUE;
+
+use_configured:
+
+   if ((ec->desk->geom.w == configured_width) && (ec->desk->geom.h == configured_height))
+     {
+        ELOGF("POL_APPINFO", "SKIP use configured_output_resolution (same with desk size:(%d,%d), pid:%d)", ec, configured_width, configured_height, ec->netwm.pid);
+     }
+   else
+     {
+        /* set the base_output_resolution of the e_client as a default */
+        _e_client_base_output_resolution_set(ec, configured_width, configured_height);
+     }
+
+   return EINA_TRUE;
 }
 
 E_API void