From: discomfitor Date: Wed, 28 Sep 2011 06:48:44 +0000 (+0000) Subject: From: Hyoyoung Chang X-Git-Tag: REL_F_I9500_20120323_1~17^2~1747 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9fb9115ce045c85b74bdc39621ff4089e78ae498;p=framework%2Fuifw%2Felementary.git From: Hyoyoung Chang Subject: [E-devel] [patch] elm_cnp_helper - add ATOM handling Date: Wed, 28 Sep 2011 15:42:20 +0900 blah blah blah, this fixes cnp compatibility with some apps good work hyoyoung git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/elementary@63639 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33 --- diff --git a/src/lib/elm_cnp_helper.c b/src/lib/elm_cnp_helper.c index 8769331..843772d 100644 --- a/src/lib/elm_cnp_helper.c +++ b/src/lib/elm_cnp_helper.c @@ -32,6 +32,8 @@ typedef int (*Notify_Handler_Cb) (Cnp_Selection *sel, Ecore_X_Event_Sele enum { CNP_ATOM_TARGETS = 0, + CNP_ATOM_ATOM, + CNP_ATOM_LISTING_ATOMS = CNP_ATOM_ATOM, CNP_ATOM_text_uri, CNP_ATOM_text_urilist, CNP_ATOM_text_x_vcard, @@ -170,6 +172,14 @@ static Cnp_Atom atoms[CNP_N_ATOMS] = { notify_handler_targets, 0 }, + [CNP_ATOM_ATOM] = { + "ATOM", + (Elm_Sel_Format) -1, // everything + targets_converter, + response_handler_targets, + notify_handler_targets, + 0 + }, [CNP_ATOM_XELM] = { "application/x-elementary-markup", ELM_SEL_FORMAT_MARKUP, @@ -672,7 +682,7 @@ notify_handler_targets(Cnp_Selection *sel, Ecore_X_Event_Selection_Notify *notif targets = notify->data; atomlist = (Ecore_X_Atom *)(targets->data.data); - for (j = 1; j < CNP_N_ATOMS; j++) + for (j = (CNP_ATOM_LISTING_ATOMS+1); j < CNP_N_ATOMS; j++) { cnp_debug("\t%s %d\n", atoms[j].name, atoms[j].atom); if (!(atoms[j].formats & sel->requestformat)) continue;