this is usefull for later implementations in spinner and fileselector.
A event for this was not added because the result is only really usefull
after a focus operation has been successfull.
Differential Revision: https://phab.enlightenment.org/D7102
Summary:
This commit removes some clashes (i.e. names as classes and namespaces
at the same time). It'll avoid nested items that are either forbidden
(C#) or problematic (Python) in some languages.
Reviewers: segfaultxavi, bu5hm4n, felipealmeida
Reviewed By: segfaultxavi
Subscribers: cedric, #reviewers, #committers
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D7260
Summary:
Check if the Eo to be replaced is NULL before calling efl_unref.
The documentation implies that the replaced object can be NULL, so this
check avoids unnecessary function calls and warning logs.
Add an EINA_SAFETY check in order to properly print an error message
when the function is used with an NULL storage pointer.
The documentation specifies that the first parameter can not be NULL.
So printing an error message should be better than silently returning.
Add a boolean return to the function that signalizes if the content of
the storage was changed. It is NOT an success/error flag, it is just a
simple helper to quickly test for a change in content.
This feature was inspired by eina_stringshare_replace that is used in
similar ways around the code.
Change the documentation to match the changes and to be more specific
about what is expected and how the arguments are treated.
Reviewers: raster, bu5hm4n, cedric, felipealmeida
Reviewed By: bu5hm4n
Subscribers: #reviewers, #committers, larryolj
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D7256
We weren't setting a C++ version for build previously, which would
result in compiler specific default being used, most likely C++11
with GNU extensions on modern compilers and C++03 with GNU exts
on old compilers. This is bad because it potentially breaks build
on older toolchains that don't default to a modern C++.
Now we enable pure C++11 without GNU exts; this resulted in some
of the build breaking because of use of typeof() GNU C/C++ ext
in tests code, so fix that to use standard decltype() from C++11.
@fix
cnp mode type was a mess. thankfully it was a bit simpler than it
seemed. cleaned up code to deal with it sanely and keep it a single
type as intended byt he api too.
so gcc likes to warn even if the truncation is intended. there are
verious ways around this, but in this case it's really just writing
your own ... which is pretty simple.
there is just too much warning noise for efl.
using strncpy with strlen of the string you append is pointless.
again... strcpy will do - but use memcpy to be exact and pre-compute
sizing etc. only once. fixes warnings.
warnings now are being super picky with:
../src/modules/evas/engines/software_x11/evas_xlib_buffer.c: In
function ‘evas_software_xlib_x_output_buffer_new’:
../src/modules/evas/engines/software_x11/evas_xlib_buffer.c:306:56:
warning: cast between incompatible function types from ‘void
(*)(Display *, XErrorEvent *)’ {aka ‘void (*)(struct _XDisplay *,
struct <anonymous> *)’} to ‘int (*)(Display *, XErrorEvent *)’ {aka
‘int (*)(struct _XDisplay *, struct <anonymous> *)’}
[-Wcast-function-type]
ph = XSetErrorHandler((XErrorHandler)
can we really match a struct <anonymous> somehow? i don't think so...
so... void to the rescue.