e_mod_main_wl : remove unnecessary function call in a loop 43/174543/1
authorSung-Jin Park <sj76.park@samsung.com>
Tue, 3 Apr 2018 01:41:53 +0000 (10:41 +0900)
committerSung-Jin Park <sj76.park@samsung.com>
Tue, 3 Apr 2018 01:41:53 +0000 (10:41 +0900)
Change-Id: Iae2a12a2f5aa2e001022d8d18f78e771e1f4e1d6
Signed-off-by: Sung-Jin Park <sj76.park@samsung.com>
src/e_mod_main_wl.c

index 90a58e8..efa2c0b 100644 (file)
@@ -1319,6 +1319,7 @@ _e_keyrouter_query_tizen_key_table(void)
    E_Keyrouter_Tizen_HWKey *data;
    int res;
    struct xkb_rule_names names={0,};
+   Eina_Bool use_keymap_cache = e_comp_wl_input_keymap_cache_file_use_get();
 
    /* TODO: Make struct in HardKeys to pointer.
                   If a key is defined, allocate memory to pointer,
@@ -1344,7 +1345,7 @@ _e_keyrouter_query_tizen_key_table(void)
         krt->HardKeys[data->keycode].no_privcheck = data->no_privcheck ? EINA_TRUE : EINA_FALSE;
         krt->HardKeys[data->keycode].repeat = data->repeat ? EINA_TRUE : EINA_FALSE;
 
-        if (e_comp_wl_input_keymap_cache_file_use_get() == EINA_FALSE)
+        if (use_keymap_cache == EINA_FALSE)
           {
              if (krt->HardKeys[data->keycode].repeat == EINA_FALSE)
                {
@@ -1357,7 +1358,7 @@ _e_keyrouter_query_tizen_key_table(void)
           }
      }
 
-   if (e_comp_wl_input_keymap_cache_file_use_get() == EINA_FALSE)
+   if (use_keymap_cache == EINA_FALSE)
      {
         KLINF("Server create a new cache file: %s", e_comp_wl_input_keymap_path_get(names));
         res = unlink(e_comp_wl_input_keymap_path_get(names));