diff options
Diffstat (limited to 'src/eom.c')
-rwxr-xr-x | src/eom.c | 24 |
1 files changed, 22 insertions, 2 deletions
@@ -980,6 +980,7 @@ eom_unset_attribute_changed_cb (eom_attribute_changed_cb callback) API int eom_set_output_attribute (eom_output_id output_id, eom_output_attribute_e attr) { + eom_output_info *output_info = NULL; bool ret = false; GValueArray *msg_array; GValueArray *ret_array; @@ -992,6 +993,14 @@ eom_set_output_attribute (eom_output_id output_id, eom_output_attribute_e attr) _eom_mutex_lock (); + output_info = _eom_find_output_info (output_id); + if (!output_info) + { + set_last_result (EOM_ERROR_NO_SUCH_DEVICE); + _eom_mutex_unlock (); + return EOM_ERROR_NO_SUCH_DEVICE; + } + pid = getpid(); INFO ("output_id: %d, pid: %d, mode: %d\n", output_id, pid, attr); @@ -1194,6 +1203,8 @@ eom_get_output_physical_size (eom_output_id output_id, int *phy_width, int *phy_ API int eom_set_output_window (eom_output_id output_id, Evas_Object *win) { +#ifdef HAVE_X11 + eom_output_info *output_info = NULL; bool ret = false; GValueArray *msg_array; GValueArray *ret_array; @@ -1206,6 +1217,14 @@ eom_set_output_window (eom_output_id output_id, Evas_Object *win) _eom_mutex_lock (); + output_info = _eom_find_output_info (output_id); + if (!output_info) + { + set_last_result (EOM_ERROR_NO_SUCH_DEVICE); + _eom_mutex_unlock (); + return EOM_ERROR_NO_SUCH_DEVICE; + } + pid = getpid(); xwin = elm_win_xwindow_get (win); @@ -1244,10 +1263,11 @@ eom_set_output_window (eom_output_id output_id, Evas_Object *win) return EOM_ERROR_NONE; } - INFO ("SetWindow: failed\n"); _eom_mutex_unlock (); - return EOM_ERROR_MESSAGE_OPERATION_FAILURE; +#else + return EOM_ERROR_NONE; +#endif } |