On 10/10/2012 11:17 AM, Enlightenment SVN wrote: > Log: > From: Michal Pakula vel Rutka <m.pak...@samsung.com> > Subject: [E-devel] [Patch] [Ecore] Allow to send SelectionNotify event > if there is no data from XGetWindowProperty. > > The issue I want to fix is that elementary clipboard does not return > paste callback if selection does not contain any data. > Currently when ecore_x_window_prop_property_get function is called > asking for AnyProperty it returns 0 if there is no data (number of > items stored equals 0). This causes ecore_x_event_handle_selection > _notify to exit before SelectionNotify event is added and eventually > elementary paste callback is not fired. > My patch removes this condition and changes behaviour of this function > by allowing to add SelectionNotify event even if data returned is empty. > > > > Author: raster > Date: 2012-10-10 02:17:21 -0700 (Wed, 10 Oct 2012) > New Revision: 77732 > Trac: http://trac.enlightenment.org/e/changeset/77732 >
> Modified: trunk/ecore/src/lib/ecore_x/xcb/ecore_xcb_selection.c > =================================================================== > --- trunk/ecore/src/lib/ecore_x/xcb/ecore_xcb_selection.c 2012-10-10 > 09:15:16 UTC (rev 77731) > +++ trunk/ecore/src/lib/ecore_x/xcb/ecore_xcb_selection.c 2012-10-10 > 09:17:21 UTC (rev 77732) > @@ -748,7 +748,7 @@ > sel = calloc(1, sizeof(Ecore_X_Selection_Data_Text)); > if (!sel) return NULL; > > - if (_data[size - 1]) > + if (data && data[size - 1]) > { > size++; > t = realloc(_data, size); > @@ -790,7 +790,7 @@ > > ECORE_XCB_SELECTION_DATA(sel)->free = > _ecore_xcb_selection_data_files_free; > > - if (_data[size - 1]) > + if (data && data[size - 1]) > { > size++; Sure this shouldn't still be _data? S. ------------------------------------------------------------------------------ Don't let slow site performance ruin your business. Deploy New Relic APM Deploy New Relic app performance management and know exactly what is happening inside your Ruby, Python, PHP, Java, and .NET app Try New Relic at no cost today and get our sweet Data Nerd shirt too! http://p.sf.net/sfu/newrelic-dev2dev _______________________________________________ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel