The pragma GCC diagnostic doesn't work properly on gcc >= 4.7.1
Seems to be related to this bug:
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55881
Thus, we have to avoid the actionslider macros :-/.
Since Elementary 1.7.x uses a different accessor than 1.8+ to get
to the underlying smart data, added a configure check for the
elementary version (HAVE_ELM_1_7) in order to select which accessor
needs to be used.
Signed-off-by: U. Artie Eoff <ullysses.a.eoff@intel.com>
[
AC_DEFINE(HAVE_EFL, 1, [Support for EFL Tests])
have_efl="yes"
+ PKG_CHECK_MODULES([ELM_1_7],
+ [
+ elementary >= 1.7.0
+ elementary < 1.7.99
+ ],
+ [
+ AC_DEFINE(HAVE_ELM_1_7, 1, [Support for ELM 1.7.x])
+ have_elm_1_7="yes"
+ ],
+ [have_elm_1_7="no"]
+ )
],
[have_efl="no"]
)
Geometry getButtonGeometry() const
{
-#pragma GCC diagnostic ignored "-fpermissive"
- ELM_ACTIONSLIDER_DATA_GET(*this, sd);
-#pragma GCC diagnostic error "-fpermissive"
-
+ #if defined(HAVE_ELM_1_7)
+ Elm_Actionslider_Smart_Data *sd = static_cast<Elm_Actionslider_Smart_Data*>(
+ evas_object_smart_data_get(o));
+ #else
+ Elm_Actionslider_Smart_Data *sd = static_cast<Elm_Actionslider_Smart_Data*>(
+ eo_data_scope_get(*this, ELM_OBJ_ACTIONSLIDER_CLASS));
+ #endif
EvasObject o(sd->drag_button_base, false);
return o.getGeometry();
}