--- /dev/null
+/*
+ * Copyright (c) 2017 Samsung Electronics Co., Ltd.
+ *
+ * Licensed under the Flora License, Version 1.1 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://floralicense.org/license/
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __WIDGET_VIEWER_EVAS_H
+#define __WIDGET_VIEWER_EVAS_H
+
+#include <tizen_type.h>
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+
+/**
+ * @file widget_viewer_evas_extension.h
+ */
+
+/**
+ * @addtogroup CAPI_WIDGET_VIEWER_EVAS_MODULE
+ * @{
+ */
+
+/**
+ * @brief Sets delayed resuming time.
+ * @details The resuming event for widget applications will be postponed
+ * @since_tizen 4.0
+ * @param[in] time The time for being postponed, in milliseconds
+ * The time should be between 0 and 10000
+ * @return @c 0 on success,
+ * otherwise a negative error value
+ * @retval #WIDGET_ERROR_NONE If success
+ * @retval #WIDGET_ERROR_INVALID_PARAMETER Invalid argument
+ * @remark Delayed resuming will work only if the option is set by widget_viewer_evas_set_option()
+ * @see widget_viewer_evas_set_option()
+ * @see #WIDGET_VIEWER_EVAS_DELAYED_RESUME
+ * */
+int widget_viewer_evas_set_delayed_resuming_time(int time);
+
+/**
+ * @}
+ */
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif
+
+/* End of a file */
static void __flush_event_queue(struct widget_info *info);
static void __destroy_widget_info(gpointer data);
+static int __default_delayed_resuming_time = 100;
+static bool __is_delayed_resuming_mode;
static inline bool __is_widget_feature_enabled(void)
{
screen_connector_toolkit_evas_stop_visibility_notify();
else
screen_connector_toolkit_evas_start_visibility_notify();
+ } else if (type == WIDGET_VIEWER_EVAS_DELAYED_RESUME) {
+ if (value) {
+ __is_delayed_resuming_mode = true;
+ screen_connector_toolkit_evas_set_delayed_resuming_time(__default_delayed_resuming_time);
+ } else {
+ __is_delayed_resuming_mode = false;
+ screen_connector_toolkit_evas_set_delayed_resuming_time(0);
+ }
}
return WIDGET_ERROR_NONE;
return (const char *)info->instance_id;
}
+EAPI int widget_viewer_evas_set_delayed_resuming_time(int time)
+{
+ if (time < 0 || time > 10000)
+ return WIDGET_ERROR_INVALID_PARAMETER;
+
+ __default_delayed_resuming_time = time;
+ if (__is_delayed_resuming_mode)
+ screen_connector_toolkit_evas_set_delayed_resuming_time(time);
+
+ return WIDGET_ERROR_NONE;
+}
+
/* End of a file */