Add shortcut to homescreen

Add shortcut with specified name and icon to homescreen
//    PRIVILEGE needed to be set in tizen-manifest.xml:
//    http://tizen.org/privilege/shortcut

#include <shortcut_manager.h>
#include <dlog.h> // for logging purposes


void
add_shortcut() {
	int ret = shortcut_add_to_home("Shortcut name", LAUNCH_BY_APP, NULL, "Icon image path", 1, NULL, NULL);
	if(ret == SHORTCUT_ERROR_NONE)
		LOGI("Shortcut added!");
}

Responses

0 Replies