int noti_ex_item_checkbox_set_check_state(noti_ex_item_h handle, bool checked);
/**
- * @brief Gets the check state of a checkbox.
- * @since_tizen 5.5
- * @param[in] handle The notification_ex item handle
- * @param[out] checked The check state of a checkbox
- * @return #NOTI_EX_ERROR_NONE On success, other value on failure
- * @retval #NOTI_EX_ERROR_NONE Success
- * @retval #NOTI_EX_ERROR_INVALID_PARAMETER Invalid parameter, if the item type is not correct, this error is returned
- * @see #noti_ex_item_h
- * @see noti_ex_item_checkbox_create()
- * @par Sample code:
- * @code
-#include <notification_ex.h>
-
-{
- int ret;
- bool checked;
-
- ret = noti_ex_item_checkbox_is_checked(checkbox_item, &checked);
-}
- * @endcode
- */
-int noti_ex_item_checkbox_is_checked(noti_ex_item_h handle, bool *checked);
-
-/**
* @}
*/
return NOTI_EX_ERROR_NONE;
}
-extern "C" EXPORT_API int noti_ex_item_checkbox_is_checked(noti_ex_item_h handle,
- bool *checked) {
- if (handle == nullptr || checked == nullptr) {
- LOGE("Invalid parameter");
- return NOTI_EX_ERROR_INVALID_PARAMETER;
- }
- Handle* h = static_cast<Handle*>(handle);
- if (!h->IsValidType(AbstractItem::CheckBox)) {
- LOGE("Invalid handle type");
- return NOTI_EX_ERROR_INVALID_PARAMETER;
- }
- CheckBoxItem* p = static_cast<CheckBoxItem*>(h->Get());
- *checked = p->IsChecked();
-
- return NOTI_EX_ERROR_NONE;
-}
-
extern "C" EXPORT_API int noti_ex_item_checkbox_get_check_state(
noti_ex_item_h handle, bool *checked) {
if (handle == nullptr || checked == nullptr) {