Merge branch 'master' into devs/hermet/lottie

This commit is contained in:
Hermet Park 2019-09-24 11:53:28 +09:00
commit f2012f3c6e
88 changed files with 721 additions and 662 deletions

16
.ci/build-example.sh Executable file
View File

@ -0,0 +1,16 @@
#!/bin/sh
set -e
if [ -d /usr/local/lib64 ] ; then
export PKG_CONFIG_PATH=/usr/local/lib64/pkgconfig
else
export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig
fi
cd .ci/example
#build the example
mkdir build
meson . build
ninja -C build all

23
.ci/ci-build-test.sh Executable file
View File

@ -0,0 +1,23 @@
#!/bin/sh
set -e
. .ci/travis.sh
travis_fold compile_test compile_test
if [ "$DISTRO" != "" ] ; then
if [ "$1" = "coverity" ] ; then
exit 0
fi
if [ "$1" = "mingw" ] ; then
exit 0
fi
if [ "$1" = "release-ready" ] ; then
exit 0
fi
docker exec --env EIO_MONITOR_POLL=1 $(cat $HOME/cid) .ci/build-example.sh
else
exit 0
#FIXME: we don't install efl_ui.pc on osx?
export PATH="$(brew --prefix gettext)/bin:$PATH"
.ci/build-example.sh
fi
travis_endfold compile_test

View File

@ -101,6 +101,6 @@ else
export PKG_CONFIG_PATH="/usr/local/opt/openssl/lib/pkgconfig:/usr/local/Cellar/libffi/$LIBFFI_VER/lib/pkgconfig"
export CC="ccache gcc"
travis_fold meson meson
mkdir build && meson build -Decore-imf-loaders-disabler=scim,ibus -Dx11=false -Davahi=false -Dbindings=luajit -Deeze=false -Dsystemd=false -Dnls=false -Dcocoa=true -Demotion-loaders-disabler=gstreamer,gstreamer1,libvlc,xine
mkdir build && meson build -Dopengl=full -Decore-imf-loaders-disabler=scim,ibus -Dx11=false -Davahi=false -Dbindings=luajit -Deeze=false -Dsystemd=false -Dnls=false -Dcocoa=true -Demotion-loaders-disabler=gstreamer,gstreamer1,libvlc,xine
travis_endfold meson
fi

13
.ci/example/meson.build Normal file
View File

@ -0,0 +1,13 @@
project(
'efl-example', 'c',
version : '0.0.1',
default_options: [ 'c_std=gnu99', 'warning_level=2' ],
meson_version : '>= 0.38.0')
eina = dependency('eina', version : '>=1.20.99')
efl = dependency('efl-ui', version : '>=1.20.99')
elm = dependency('elementary', version : '>=1.20.99')
inc = include_directories('.')
subdir('src')

11
.ci/example/src/main.c Normal file
View File

@ -0,0 +1,11 @@
#define EFL_BETA_API_SUPPORT 1
#define EFL_NOLEGACY_API_SUPPORT
#include <Efl_Ui.h>
EAPI_MAIN void
efl_main(void *data EINA_UNUSED, const Efl_Event *ev EINA_UNUSED)
{
return 0;
}
EFL_MAIN()

View File

@ -0,0 +1,12 @@
src = files([
'main.c',
])
deps = [eina, efl, elm]
executable('efl_example', src,
dependencies : deps,
include_directories : inc,
install : true
)

View File

@ -103,15 +103,11 @@ script:
if [[ "$TRAVIS_OS_NAME" == "linux" ]] && [[ "$CI_BUILD_TYPE" == "" ]]; then
.ci/ci-make-benchmark.sh "$CI_BUILD_TYPE"
fi
#- .ci/ci-make-install.sh "$CI_BUILD_TYPE"
- .ci/ci-make-install.sh "$CI_BUILD_TYPE"
- .ci/ci-make-check.sh "$CI_BUILD_TYPE"
- .ci/ci-make-distcheck.sh "$CI_BUILD_TYPE"
#- |
#if [[ "$DISTRO" == "" ]] && [[ "$TRAVIS_OS_NAME" != "linux" ]] ; then
#true
#elif [[ "$CI_BUILD_TYPE" != "release-ready" ]] ; then
#docker exec --env EIO_MONITOR_POLL=1 $(cat $HOME/cid) .ci/build-efl-app.sh
#fi
- |
- .ci/ci-build-test.sh "$CI_BUILD_TYPE"
before_cache:
- .ci/ci-ccache-stats.sh
- |

202
README
View File

@ -210,9 +210,9 @@ Ecore main-loop and event queue.
//BSD 2-Clause license//
This is a library to wrap/deal with Xlib as well as optionally XCB to
make dealing with X11 less painful and less footwork as well as being
glue to tie these into the Ecore main-loop and event queue.
This is a library to wrap/deal with Xlib make dealing with X11 less painful
and less footwork as well as being glue to tie these into the Ecore main-loop
and event queue.
@ -464,7 +464,7 @@ Required by default:
* libxcursor
* libxp
* libxi (2.2 or newer)
* libgl (opengl/glx or opengl-es2/egl)
* opengl(mesa etc.) (opengl/glx/full or opengl-es2/egl. full opengl only on osx - must be explicitly specified to be full to have support)
* giflib
* util-linux (limbount + libblkid)
* systemd / libudev
@ -473,18 +473,41 @@ Required by default:
* libspectre
* librsvg
Recommended requirements (highly recommended):
You might want webp support so disable fewer loaders and remove webp
from the disablers with:
* harfbuzz
* libwebp
* libunwind (where available)
-Devas-loaders-disabler=json
Enable these with configure options:
Wayland support:
--enable-xinput22 \
--enable-image-loader-webp \
--enable-harfbuzz \
--enable-multisense
You may also want wayland support when on Linux. This enables support
for EFL to trget wayland support for client applications. To do this
supply:
-Dwl=true
Framebuffer support:
This requires linux frame-buffer support, headers etc. This supports
basic frame-buffers like /dev/fb as well as input via /dev/input for
keyboards and mice in a basic way. Enable this with:
-Dfb=true
For more modern framebuffer support you may want drm/kms rendering
support so enable this. This is what you also want for wayland
compositor support in enlightenment as it will want to be able to
render to a moder framebuffer tarbet with atomic buffer swapping. To
do this provide:
-Ddrm=true
You may want to change the install prefix for EFL with:
--prefix=/path/to/prefix
The default prefix if not given is "/usr/local". Many people like to
use prefixes like /opt/e or /opt/efl or /home/USERNAME/software etc.
COMPILER FLAGS
--------------
@ -495,159 +518,24 @@ that to ensure ABI stability you should use the exact same CFLAGS /
CXXFLAGS for all the build of EFL and any applications/libraries that
depend on them.
Other possible recommendations:
* scim
Enable this with:
--enable-scim
Framebuffer support:
This requires linux frame-buffer support, headers etc. This supports
basic frame-buffers like /dev/fb as well as input via /dev/input for
keyboards and mice in a basic way. Enable this with:
--enable-fb
This also turns on support for touch-screens via tslib. Not everyone
has tslib, so you may want to disable it with:
--disable-tslib
You likely don't need static libraries most of the time so you can
disable them with:
--disable-static
You may want to change the install prefix for EFL with:
--prefix=/path/to/prefix
The default prefix if not given is "/usr/local". Many people like to
use prefixes like /opt/e or /opt/efl or /home/USERNAME/software etc.
You may want to enable valgrind support if you plan on doing debugging
with EFL or apps built on top of EFL. This requires an install of
valgrind first. You can enable this with:
--enable-valgrind
You may want to enable xine support in emotion, as this library
provides fairly solid support for a lot of codecs and DVD navigation
support and more. You can enable it with:
--enable-xine
Wayland is also supported fairly solidly in EFL 1.8. It is not
required by default due to it being new and not that widely spread.
You can enable Wayland support with:
--enable-wayland \
--enable-elput \
--enable-drm
For faster rendering when dithering down to lower-than 24/32bpp, you
can try:
--with-evas-dither-mask=small
But this will drop quality slightly, using a small 16x16 ordered
dither mask rather than the default 128x128. This should save a little
memory too in the binary size of Evas.
There are many other configure options that can be used, but in
general it is not a good idea to go enabling or disabling things
unless you wish to break things. The defaults are well tested, with
the above recommended options also being well tested. Go much further
and your mileage may vary wildly. Disabling features is a good way of
breaking EFL functionality, so it is not recommended. The defaults
breaking EFL functionality, so it is not recommended to mess with
these without understanding the implications. The defaults
have been carefully considered to provide full functionality so users
will not be missing anything.
VALGRIND DEPENDENCY
-------------------
EFL uses the concept of memory pools (mempool) and this will confuse
valgrind memcheck tool. By using memory pool, the memory is still
owned by EFL, then valgrind won't alert on memory leaks or use of
unused memory. EFL will use memcheck.h from valgrind to declare its
memory pools to valgrind, producing better debugging results.
However valgrind is only available to limited platforms, making it
hard for us to declare it a mandatory requirement. Based on
--with-profile={dev,debug} valgrind will be used if available or will
be issued a warning. You can force valgrind with --enable-valgrind, or
disable it and the warning with --disable-valgrind.
EFL does NOT link to valgrind libraries. Then there is NO runtime
dependency on valgrind.
BULLET PHYSICS DEPENDENCY
-------------------------
EFL comes with EPhysics (a physics wrapper library) enabled by
default. To build it the user must have BulletPhysics engine installed.
More information about BulletPhysics can be obtained in the upstream project
web site at http://bulletphysics.org
We have received many reports about BulletPhysics installation and distros
packages in bad shape, some without even a package. If your distro doesn't
ship a BulletPhysics package or you want to build it from source code follow
the instructions below:
**Required Packages:**
You should have cmake installed. Bullet comes with autotools and cmake build
systems, do not use the autotools alternative, it's unstable, bogus and hasn't
been maintained for quite some time.
**Download the tarball from:**
http://code.google.com/p/bullet/downloads/list
**NOTE:**
The current supported version is 2.80 or greater.
**Compiling and Installing:**
Uncompress it to (say) ~/bullet and:
cd ~/bullet/build
cmake .. -DBUILD_CPU_DEMOS=OFF -DBUILD_DEMOS=OFF -DBUILD_SHARED_LIBS=ON
make
sudo make install
sudo ldconfig
**Ubuntu Users:**
Alternatively Ubuntu users have the option to install the BulletPhysics from
our official EFL PPA:
https://launchpad.net/~efl/+archive/trunk
PROFILES
--------
EFL build is based on "profiles". It will default to "dev" for
unreleased software and "release" for official tarballs. One can
change it with --with-profile=NAME, where NAME is one of:
* **dev**: extra checks useful to test software.
* **debug**: superset of dev, with debug features and assert().
* **release**: optimizations and less checks so it runs faster.
CRYPTOGRAPHY
------------
EFL officially uses "openssl" library to do signature, cipher and related.
Alternatively one can use "gnutls" (some distros are strict about licenses
and want gnutls instead of openssl) or disable it. One can change it with
--with-crypto=NAME, where NAME is one of: "openssl", "gnutls" and "none".
EFL officially offers openssl or gnutls as cryptography backends. By
default it uses "openssl" to do signature, cipher and related. Alternatively
one can use "gnutls" (some distros are strict about licenses and want gnutls
instead of openssl) You can switch to gnutls with:
-Dcrypto=gnutls

View File

@ -190,7 +190,7 @@ collections {
#include "edc/efl/tags.edc"
#include "edc/efl/panel.edc"
#include "edc/efl/tooltip.edc"
#include "edc/efl/photocam.edc"
#include "edc/efl/image_zoomable.edc"
#include "edc/efl/progress.edc"
#include "edc/efl/border.edc"
#include "edc/efl/spin.edc"

View File

@ -20,11 +20,11 @@ group { "efl/bg";
color: 64 64 64 255;
}
}
part { name: "efl.rectangle"; type: SWALLOW;
part { name: "efl.rectangle"; type: SWALLOW; required;
description { state: "default" 0.0;
}
}
part { name: "efl.background"; type: SWALLOW;
part { name: "efl.background"; type: SWALLOW; required;
clip_to: "clipper";
description { state: "default" 0.0;
fixed: 1 1;
@ -38,9 +38,9 @@ group { "efl/bg";
fill.smooth: 0;
}
}
part { name: "efl.content"; type: SWALLOW;
part { name: "efl.content"; type: SWALLOW; required;
description { state: "default" 0.0;
}
}
}
}
}

View File

@ -493,7 +493,7 @@ group { name: "efl/button:anchor";
color: 255 255 255 64;
}
}
swallow { "efl.background"; nomouse;
swallow { "efl.background"; nomouse; required;
desc { "default";
rel1.to: "base";
rel2.to: "base";
@ -504,7 +504,7 @@ group { name: "efl/button:anchor";
visible: 1;
}
}
swallow { "efl.content"; nomouse;
swallow { "efl.content"; nomouse; required;
clip_to: "icon_clip";
desc { "default";
fixed: 1 0;

View File

@ -97,7 +97,7 @@ group { "efl/datepicker";
align: 1.0 1.0;
}
}
swallow { "efl.field0";
swallow { "efl.field0"; required;
mouse;
scale;
desc { "default";
@ -125,7 +125,7 @@ group { "efl/datepicker";
align: 0.0 0.5;
}
}
swallow { "efl.field1";
swallow { "efl.field1"; required;
mouse;
scale;
desc { "default";
@ -156,7 +156,7 @@ group { "efl/datepicker";
align: 1.0 0.5;
}
}
swallow { "efl.field2";
swallow { "efl.field2"; required;
mouse;
scale;
desc { "default";
@ -215,7 +215,7 @@ group { "efl/datepicker/spin_button";
vis;
}
}
swallow { "efl.inc_button";
swallow { "efl.inc_button"; required;
scale;
desc { "default";
align: 0.5 0.0;
@ -224,7 +224,7 @@ group { "efl/datepicker/spin_button";
fixed: 1 1;
}
}
swallow { "efl.dec_button";
swallow { "efl.dec_button"; required;
scale;
desc { "default";
align: 0.5 1.0;
@ -233,7 +233,7 @@ group { "efl/datepicker/spin_button";
fixed: 1 1;
}
}
swallow { "efl.entry";
swallow { "efl.entry"; required;
clip: "clip";
desc { "default";
fixed: 1 1;
@ -246,7 +246,7 @@ group { "efl/datepicker/spin_button";
vis;
}
}
swallow { "efl.text_button";
swallow { "efl.text_button"; required;
scale;
desc { "default";
rel.to_x: "base";

View File

@ -1,4 +1,4 @@
group { name: "efl/photocam";
group { name: "efl/image_zoomable";
inherit: "efl/scroller";
images.image: "knob_round_busy.png" COMP;
images.image: "glow_round_corners.png" COMP;

View File

@ -1,7 +1,9 @@
/**
* A macro for defining the programms that are needed to redirect the mouse events of a part to the implementation of Efl.Ui.Clickable.
* A macro for defining the programms that are needed to redirect the mouse
* events of a part to the implementation of Efl.Ui.Clickable.
*
* The Widget using this has to call the method bind_to_theme of Efl.Ui.Clickable_Util in order to redirect the here called signals to real events that can be used in code.
* The Widget using this has to call the method bind_to_theme of Efl.Ui.Clickable_Util
* in order to redirect the here called signals to real events that can be used in code.
* The resulting events on the widget will be from the Efl.Ui.Clickable class.
*/

View File

@ -15,12 +15,12 @@ group { "efl/popup";
image.normal: "rounded_square.png";
}
}
swallow { "efl.background";
swallow { "efl.background"; required;
desc { "default";
rel.to: "bg";
}
}
swallow { "efl.content";
swallow { "efl.content"; required;
desc { "default";
rel.to: "base";
}
@ -29,8 +29,6 @@ group { "efl/popup";
}
group { "efl/alert_popup";
alias: "efl/scroll_alert_popup";
alias: "efl/text_alert_popup";
images.image: "rounded_square.png" COMP;
parts {
alias: "title" "efl.text.title";
@ -41,7 +39,7 @@ group { "efl/alert_popup";
image.normal: "rounded_square.png";
}
}
swallow { "efl.background";
swallow { "efl.background"; required;
desc { "default";
rel.to: "bg";
}
@ -67,7 +65,7 @@ group { "efl/alert_popup";
min: 0 20;
}
}
textblock { "efl.text.title";
textblock { "efl.text.title"; required;
scale;
desc { "default";
fixed: 1 1;
@ -82,7 +80,7 @@ group { "efl/alert_popup";
vis;
}
}
swallow { "efl.buttons";
swallow { "efl.buttons"; required;
desc { "default";
fixed: 0 1;
rel.to: "base";
@ -95,7 +93,7 @@ group { "efl/alert_popup";
min: 0 30;
}
}
swallow { "efl.content";
swallow { "efl.content"; required;
desc { "default";
rel1.to_x: "base";
rel1.to_y: "title_bg";
@ -123,8 +121,6 @@ group { "efl/alert_popup";
group { "efl/popup/backwall";
alias: "efl/alert_popup/backwall";
alias: "efl/scroll_alert_popup/backwall";
alias: "efl/text_alert_popup/backwall";
parts {
rect { "base";
desc { "default";
@ -135,7 +131,7 @@ group { "efl/popup/backwall";
hid;
}
}
swallow { "efl.content";
swallow { "efl.content"; required;
desc { "default";
rel.to: "base";
hid;
@ -174,17 +170,13 @@ group { "efl/popup/backwall";
}
group { "efl/alert_popup/button_layout1";
alias: "efl/scroll_alert_popup/button_layout1";
alias: "efl/text_alert_popup/button_layout1";
parts {
swallow { "efl.button1";
swallow { "efl.button1"; required;
}
}
}
group { "efl/alert_popup/button_layout2";
alias: "efl/scroll_alert_popup/button_layout2";
alias: "efl/text_alert_popup/button_layout2";
parts {
spacer { "div1";
desc { "default";
@ -193,13 +185,13 @@ group { "efl/alert_popup/button_layout2";
min: 5 5;
}
}
swallow { "efl.button1";
swallow { "efl.button1"; required;
desc { "default";
rel2.to_x: "div1";
rel2.relative: 0.0 1.0;
}
}
swallow { "efl.button2";
swallow { "efl.button2"; required;
desc { "default";
rel1.to_x: "div1";
rel1.relative: 1.0 0.0;
@ -209,8 +201,6 @@ group { "efl/alert_popup/button_layout2";
}
group { "efl/alert_popup/button_layout3";
alias: "efl/scroll_alert_popup/button_layout3";
alias: "efl/text_alert_popup/button_layout3";
parts {
spacer { "div1";
desc { "default";
@ -226,13 +216,13 @@ group { "efl/alert_popup/button_layout3";
min: 5 5;
}
}
swallow { "efl.button1";
swallow { "efl.button1"; required;
desc { "default";
rel2.to_x: "div1";
rel2.relative: 0.0 1.0;
}
}
swallow { "efl.button2";
swallow { "efl.button2"; required;
desc { "default";
rel1.to_x: "div1";
rel2.to_x: "div2";
@ -240,7 +230,7 @@ group { "efl/alert_popup/button_layout3";
rel2.relative: 0.0 1.0;
}
}
swallow { "efl.button3";
swallow { "efl.button3"; required;
desc { "default";
rel1.to_x: "div2";
rel1.relative: 1.0 0.0;
@ -251,45 +241,12 @@ group { "efl/alert_popup/button_layout3";
group { "efl/alert_popup/left_button";
inherit: "efl/button";
alias: "efl/scroll_alert_popup/left_button";
alias: "efl/text_alert_popup/left_button";
}
group { "efl/alert_popup/right_button";
inherit: "efl/button";
alias: "efl/scroll_alert_popup/right_button";
alias: "efl/text_alert_popup/right_button";
}
group { "efl/alert_popup/button";
inherit: "efl/button";
alias: "efl/scroll_alert_popup/button";
alias: "efl/text_alert_popup/button";
}
group { "efl/scroll_alert_popup/scroller";
inherit: "efl/scroller";
alias: "efl/text_alert_popup/scroller";
parts {
swallow { "efl.content";
desc { "default";
rel1.offset: 0 0;
rel2.offset: 0 0;
}
}
spacer { "inset";
desc { "default";
hid;
}
}
spacer { "shadow";
desc { "default";
hid;
}
}
}
}
group { "efl/text_alert_popup/text";
inherit: "efl/text";
}

View File

@ -170,7 +170,7 @@ group { name: "efl/scroller";
fixed: 1 1;
}
}
part { name: "efl.dragable.vbar"; type: RECT;
part { name: "efl.dragable.vbar"; type: RECT; required;
clip_to: "sb_vbar";
scale: 1;
dragable.x: 0 0 0;
@ -451,7 +451,7 @@ group { name: "efl/scroller";
fixed: 1 1;
}
}
part { name: "efl.dragable.hbar"; type: RECT;
part { name: "efl.dragable.hbar"; type: RECT; required;
clip_to: "sb_hbar";
scale: 1;
dragable.x: 1 1 0;
@ -687,7 +687,7 @@ group { name: "efl/scroller";
rel2.to: "efl.background";
}
}
part { name: "efl.background"; type: SWALLOW;
part { name: "efl.background"; type: SWALLOW; required;
clip_to: "clipper";
description { state: "default" 0.0;
rel1.offset: 1 1;
@ -697,7 +697,7 @@ group { name: "efl/scroller";
rel2.to_y: "sb_hbar";
}
}
part { name: "efl.content"; type: SWALLOW;
part { name: "efl.content"; type: SWALLOW; required;
clip_to: "clipper";
description { state: "default" 0.0;
rel1.offset: 1 1;
@ -730,7 +730,7 @@ group { name: "efl/scroller";
color: 255 255 255 128;
}
}
part { name: "efl.overlay"; type: SWALLOW;
part { name: "efl.overlay"; type: SWALLOW; required;
clip_to: "clipper";
description { state: "default" 0.0;
rel1.to: "efl.content";
@ -1285,12 +1285,12 @@ group { name: "efl/scroller:popup/no_inset_shadow";
group { name: "efl/scroller/contents";
parts {
part { name: "efl.content";
part { name: "efl.content"; required;
type: SWALLOW;
description { state: "default" 0.0;
}
}
part { name: "efl.content_r";
part { name: "efl.content_r"; required;
type: SWALLOW;
description { state: "default" 0.0;
fixed: 1 1;
@ -1304,7 +1304,7 @@ group { name: "efl/scroller/contents";
}
}
}
part { name: "efl.content_b";
part { name: "efl.content_b"; required;
type: SWALLOW;
description { state: "default" 0.0;
fixed: 1 1;
@ -1318,7 +1318,7 @@ group { name: "efl/scroller/contents";
}
}
}
part { name: "efl.content_rb";
part { name: "efl.content_rb"; required;
type: SWALLOW;
description { state: "default" 0.0;
fixed: 1 1;

View File

@ -36,7 +36,7 @@ group { "efl/spin_button/horizontal";
vis;
}
}
swallow { "efl.entry";
swallow { "efl.entry"; required;
clip: "clip";
desc { "default";
fixed: 1 1;
@ -49,7 +49,7 @@ group { "efl/spin_button/horizontal";
vis;
}
}
swallow { "efl.dec_button";
swallow { "efl.dec_button"; required;
scale;
desc { "default";
fixed: 1 0;
@ -58,7 +58,7 @@ group { "efl/spin_button/horizontal";
aspect: 1.0 1.0; aspect_preference: VERTICAL;
}
}
swallow { "efl.inc_button";
swallow { "efl.inc_button"; required;
scale;
desc { "default";
fixed: 1 0;
@ -67,7 +67,7 @@ group { "efl/spin_button/horizontal";
aspect: 1.0 1.0; aspect_preference: VERTICAL;
}
}
swallow { "efl.text_button";
swallow { "efl.text_button"; required;
scale;
desc { "default";
vis;
@ -158,7 +158,7 @@ group { "efl/spin_button/vertical";
min: 40 150;
}
}
swallow { "efl.inc_button";
swallow { "efl.inc_button"; required;
scale;
desc { "default";
rel.to: "inset";
@ -168,7 +168,7 @@ group { "efl/spin_button/vertical";
fixed: 1 1;
}
}
swallow { "efl.dec_button";
swallow { "efl.dec_button"; required;
scale;
desc { "default";
rel.to: "inset";
@ -178,7 +178,7 @@ group { "efl/spin_button/vertical";
fixed: 1 1;
}
}
swallow { "efl.text_button";
swallow { "efl.text_button"; required;
scale;
desc { "default";
rel.to_x: "inset";

View File

@ -5,7 +5,7 @@ group { "efl/tab_pager";
desc { "default";
}
}
swallow { "efl.tab_root";
swallow { "efl.tab_root"; required;
scale;
desc { "default";
rel.to: "base";
@ -15,7 +15,7 @@ group { "efl/tab_pager";
fixed: 0 1;
}
}
swallow { "efl.page_root";
swallow { "efl.page_root"; required;
scale;
desc { "default";
rel1.to: "efl.tab_root";
@ -23,7 +23,7 @@ group { "efl/tab_pager";
rel1.relative: 0 1;
}
}
swallow { "efl.event";
swallow { "efl.event"; required;
scale;
repeat_events: 1;
desc { "default";

View File

@ -105,7 +105,7 @@ group { "efl/timepicker";
align: 1.0 1.0;
}
}
swallow { "efl.field0";
swallow { "efl.field0"; required;
mouse;
scale;
desc { "default";
@ -197,7 +197,7 @@ group { "efl/timepicker";
max: 0 0;
}
}
swallow { "efl.field1";
swallow { "efl.field1"; required;
mouse;
scale;
desc { "default";
@ -289,7 +289,7 @@ group { "efl/timepicker";
max: 0 0;
}
}
swallow { "efl.field2";
swallow { "efl.field2"; required;
mouse;
scale;
desc { "default";

View File

@ -182,8 +182,8 @@ doc_target += custom_target('doxygen',
)
compress_target = custom_target('package_doc_tar',
command: [tar, '-C', meson.build_root(), '-cf', 'efl-'+meson.version()+'.tar', 'html', 'man'],
output: 'efl-'+meson.version()+'.tar',
command: [tar, '-C', meson.build_root(), '-cf', 'efl-'+meson.project_version()+'.tar', 'html', 'man'],
output: 'efl-'+meson.project_version()+'.tar',
depends: doc_target,
build_by_default: false
)

View File

@ -67,7 +67,7 @@ option('eeze',
option('opengl',
type : 'combo',
choices : ['full', 'es-egl', 'none'],
value : 'full',
value : 'es-egl',
description : 'Type of OpenGL support in efl'
)
@ -170,7 +170,7 @@ option('xinput22',
option('tslib',
type : 'boolean',
value : true,
value : false,
description : 'Framebuffer (/dev/fb / fbcon) touchscreen tslib support in efl'
)

View File

@ -701,9 +701,13 @@ _programs_parse(Evas_Object *ed)
}
edje_edit_string_free(description);
description = NULL;
edje_edit_string_free(sig);
sig = NULL;
edje_edit_string_free(source);
source = NULL;
free(apiname);
apiname = NULL;
}
edje_edit_string_list_free(programs);

View File

@ -860,7 +860,7 @@ add_tests:
ADD_TEST(NULL, "Images", "Photocam", test_photocam);
ADD_TEST(NULL, "Images", "Photocam Remote", test_photocam_remote);
ADD_TEST(NULL, "Images", "Photocam Icon", test_photocam_icon);
ADD_TEST(NULL, "Images", "Image Zoomable animation", test_image_zoomable_animated);
ADD_TEST_EO(NULL, "Images", "Image Zoomable animation", test_image_zoomable_animated);
ADD_TEST(NULL, "Images", "Photo", test_photo);
ADD_TEST(NULL, "Images", "Thumb", test_thumb);
ADD_TEST(NULL, "Images", "Image", test_image);

View File

@ -115,6 +115,10 @@ test_check(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_inf
evas_object_show(ck);
evas_object_show(ic);
ck = elm_check_add(win);
elm_box_pack_end(bx, ck);
evas_object_show(ck);
ck = elm_check_add(win);
elm_box_pack_end(bx, ck);
elm_object_text_set(ck, "text is visible when check state is true.");

View File

@ -62,8 +62,8 @@ struct alias_definition_generator
<< scope_tab << "public static implicit operator " << alias_type << "(" << alias_name << " value)\n"
<< scope_tab << "{\n"
<< scope_tab << scope_tab << "return value.payload;\n"
<< scope_tab << "}\n\n"
<< "}\n\n"
<< scope_tab << "}\n"
<< "}\n"
).generate(sink, alias, context))
return false;

View File

@ -23,7 +23,7 @@ struct documentation_generator
int scope_size = 0;
documentation_generator(int scope_size)
documentation_generator(int scope_size = 0)
: scope_size(scope_size) {}
@ -595,9 +595,8 @@ struct documentation_generator
else
ref = "<see cref=\"" + ref + "\" />";
if (!as_generator(
scope_tab << "/// <param name=\"" << constructor_parameter_name(ctor) << "\">" << summary << " See " << ref << "</param>\n"
).generate(sink, param, context))
if (!as_generator(scope_tab(scope_size) << "/// <param name=\"" << constructor_parameter_name(ctor) << "\">" << summary << " See " << ref << "</param>\n")
.generate(sink, param, context))
return false;
}
return true;

View File

@ -45,7 +45,7 @@ struct enum_definition_generator
return false;
}
if(!as_generator("}\n\n").generate(sink, attributes::unused, context)) return false;
if(!as_generator("}\n").generate(sink, attributes::unused, context)) return false;
if(!name_helpers::close_namespaces(sink, enum_.namespaces, context))
return false;

View File

@ -255,7 +255,7 @@ struct event_argument_wrapper_generator
<< scope_tab << "/// <summary>Actual event payload.</summary>\n"
<< scope_tab << "/// <value>" << documentation_string << "</value>\n"
<< scope_tab << "public " << type << " arg { get; set; }\n"
<< "}\n"
<< "}\n\n"
).generate(sink, std::make_tuple(evt.documentation.summary, *etype), context);
}
} const event_argument_wrapper {};
@ -279,9 +279,8 @@ struct event_declaration_generator
if (evt.type.is_engaged())
wrapper_args_type = "<" + name_helpers::managed_event_args_name(evt) + ">";
if (!as_generator(
documentation(1)
).generate(sink, evt, context)) return false;
if (!as_generator(documentation(1))
.generate(sink, evt, context)) return false;
if (evt.type.is_engaged())
if (!as_generator(
scope_tab << "/// <value><see cref=\"" << name_helpers::managed_event_args_name(evt) << "\"/></value>\n"
@ -427,7 +426,7 @@ struct event_definition_generator
<< scope_tab << scope_tab << scope_tab << "return;\n"
<< scope_tab << scope_tab << "}\n\n"
<< event_native_call
<< scope_tab << "}\n"
<< scope_tab << "}\n\n"
).generate(sink, nullptr, context))
return false;
@ -479,7 +478,7 @@ struct event_definition_generator
<< scope_tab << scope_tab << scope_tab << scope_tab << "RemoveNativeEventHandler(" << library_name << ", key, value);\n"
<< scope_tab << scope_tab << scope_tab << "}\n" // End of lock block
<< scope_tab << scope_tab << "}\n"
<< scope_tab << "}\n"
<< scope_tab << "}\n\n"
).generate(sink, attributes::unused, context);
}
};

View File

@ -27,11 +27,11 @@ struct function_declaration_generator
if(f.scope != attributes::member_scope::scope_public)
return true;
if(!as_generator(documentation).generate(sink, f, context))
if(!as_generator(documentation(1)).generate(sink, f, context))
return false;
return as_generator
(eolian_mono::type(true) << " " << string << "(" << (parameter % ", ") << ");\n")
(scope_tab << eolian_mono::type(true) << " " << string << "(" << (parameter % ", ") << ");\n\n")
.generate(sink, std::make_tuple(f.return_type, name_helpers::managed_method_name(f), f.parameters), context);
}
};

View File

@ -119,7 +119,7 @@ struct native_function_definition_generator
<< indent << scope_tab << "var ws = Efl.Eo.Globals.GetWrapperSupervisor(obj);\n"
<< indent << scope_tab << "if (ws != null)\n"
<< indent << scope_tab << "{\n"
<< eolian_mono::native_function_definition_preamble()
<< indent << scope_tab << scope_tab << eolian_mono::native_function_definition_preamble() << "\n"
<< indent << scope_tab << scope_tab << "try\n"
<< indent << scope_tab << scope_tab << "{\n"
<< indent << scope_tab << scope_tab << scope_tab << (return_type != "void" ? "_ret_var = " : "")
@ -131,7 +131,7 @@ struct native_function_definition_generator
<< indent << scope_tab << scope_tab << scope_tab << "Eina.Log.Warning($\"Callback error: {e.ToString()}\");\n"
<< indent << scope_tab << scope_tab << scope_tab << "Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);\n"
<< indent << scope_tab << scope_tab << "}\n\n"
<< eolian_mono::native_function_definition_epilogue(*klass) << "\n"
<< indent << eolian_mono::native_function_definition_epilogue(*klass) << "\n"
<< indent << scope_tab << "}\n"
<< indent << scope_tab << "else\n"
<< indent << scope_tab << "{\n"
@ -204,14 +204,14 @@ struct function_definition_generator
if(!as_generator
(scope_tab << eolian_mono::function_scope_get(f) << ((do_super && !f.is_static) ? "virtual " : "") << (f.is_static ? "static " : "") << return_type << " " << string << "(" << (parameter % ", ")
<< ") {\n "
<< eolian_mono::function_definition_preamble()
<< ") {\n"
<< scope_tab(2) << eolian_mono::function_definition_preamble()
<< klass_full_native_inherit_name(f.klass) << "." << string << "_ptr.Value.Delegate("
<< self
<< ((!f.is_static && (f.parameters.size() > 0)) ? "," : "")
<< (argument_invocation % ", ") << ");\n"
<< eolian_mono::function_definition_epilogue()
<< " }\n")
<< scope_tab(2) << eolian_mono::function_definition_epilogue()
<< scope_tab(1) << "}\n\n")
.generate(sink, std::make_tuple(name_helpers::managed_method_name(f), f.parameters, f, f.c_name, f.parameters, f), context))
return false;
@ -268,11 +268,11 @@ struct property_extension_method_definition_generator
if (property.setter.is_engaged())
{
attributes::type_def prop_type = property.setter->parameters[0].type;
if (!as_generator("public static Efl.BindableProperty<" << type(true) << "> " << managed_name << "<T>(this Efl.Ui.ItemFactory<T> fac, Efl.Csharp.ExtensionTag<"
<< name_helpers::klass_full_concrete_or_interface_name(cls)
<< ", T>magic = null) where T : " << name_helpers::klass_full_concrete_or_interface_name(cls) << " {\n"
if (!as_generator(scope_tab << "public static Efl.BindableProperty<" << type(true) << "> " << managed_name << "<T>(this Efl.Ui.ItemFactory<T> fac, Efl.Csharp.ExtensionTag<"
<< name_helpers::klass_full_concrete_or_interface_name(cls)
<< ", T>magic = null) where T : " << name_helpers::klass_full_concrete_or_interface_name(cls) << " {\n"
<< scope_tab << scope_tab << "return new Efl.BindableProperty<" << type(true) << ">(\"" << property.name << "\", fac);\n"
<< scope_tab << "}\n"
<< scope_tab << "}\n\n"
).generate(sink, std::make_tuple(prop_type, prop_type), context))
return false;
}
@ -285,11 +285,11 @@ struct property_extension_method_definition_generator
if (property.setter.is_engaged())
{
attributes::type_def prop_type = property.setter->parameters[0].type;
if (!as_generator("public static Efl.BindableProperty<" << type(true) << "> " << managed_name << "<T>(this Efl.BindablePart<T> part, Efl.Csharp.ExtensionTag<"
<< name_helpers::klass_full_concrete_or_interface_name(cls)
<< ", T>magic = null) where T : " << name_helpers::klass_full_concrete_or_interface_name(cls) << " {\n"
if (!as_generator(scope_tab << "public static Efl.BindableProperty<" << type(true) << "> " << managed_name << "<T>(this Efl.BindablePart<T> part, Efl.Csharp.ExtensionTag<"
<< name_helpers::klass_full_concrete_or_interface_name(cls)
<< ", T>magic = null) where T : " << name_helpers::klass_full_concrete_or_interface_name(cls) << " {\n"
<< scope_tab << scope_tab << "return new Efl.BindableProperty<" << type(true) << ">(part.PartName, \"" << property.name << "\", part.Binder);\n"
<< scope_tab << "}\n"
<< scope_tab << "}\n\n"
).generate(sink, std::make_tuple(prop_type, prop_type), context))
return false;
}
@ -522,7 +522,7 @@ struct property_wrapper_definition_generator
return false;
}
if (!as_generator(scope_tab << "}\n").generate(sink, attributes::unused, context))
if (!as_generator(scope_tab << "}\n\n").generate(sink, attributes::unused, context))
return false;
return true;

View File

@ -34,14 +34,14 @@ struct native_function_definition_preamble_generator
return false;
if (!as_generator(
*(scope_tab << scope_tab << native_convert_in_variable)
<< *(scope_tab << scope_tab << native_convert_out_variable)
<< *(scope_tab << scope_tab << native_convert_function_pointer)
<< scope_tab << scope_tab << scope_tab << native_convert_return_variable
*(native_convert_in_variable)
<< *(native_convert_out_variable)
<< *(native_convert_function_pointer)
<< native_convert_return_variable
).generate(sink, std::make_tuple(f.parameters, f.parameters, f.parameters, f.return_type), context))
return false;
return as_generator("\n").generate(sink, attributes::unused, context);
return as_generator("").generate(sink, attributes::unused, context);
}
};
@ -57,11 +57,11 @@ struct function_definition_preamble_generator
return false;
if (!as_generator(
*(scope_tab << scope_tab << convert_in_variable)
<< *(scope_tab << scope_tab << convert_out_variable)
<< *(scope_tab << scope_tab << convert_function_pointer)
<< scope_tab << scope_tab << convert_return_variable
).generate(sink, std::make_tuple(f.parameters, f.parameters, f.parameters, f.return_type), context))
*(convert_in_variable)
<< *(convert_out_variable)
<< *(convert_function_pointer)
<< convert_return_variable
).generate(sink, std::make_tuple(f.parameters, f.parameters, f.parameters, f.return_type), context))
return false;
return true;
@ -82,9 +82,9 @@ struct native_function_definition_epilogue_generator
return false;
if (!as_generator(
*(scope_tab << scope_tab << native_convert_out_assign(*klass))
<< *(scope_tab << scope_tab << native_convert_in_ptr_assign)
<< scope_tab << scope_tab << native_convert_return(*klass)
*(native_convert_out_assign(*klass))
<< *(native_convert_in_ptr_assign)
<< scope_tab(2) << native_convert_return(*klass)
).generate(sink, std::make_tuple(f.parameters, f.parameters, f.return_type), context))
return false;
@ -99,10 +99,10 @@ struct function_definition_epilogue_generator
bool generate(OutputIterator sink, attributes::function_def const& f, Context const& context) const
{
if (!as_generator(
scope_tab << scope_tab << "Eina.Error.RaiseIfUnhandledException();\n"
<< *(scope_tab << scope_tab << convert_out_assign)
<< *(scope_tab << scope_tab << convert_in_ptr_assign)
<< scope_tab << scope_tab << convert_return
"Eina.Error.RaiseIfUnhandledException();\n"
<< *(convert_out_assign)
<< *(convert_in_ptr_assign)
<< scope_tab(2) << convert_return << "\n"
).generate(sink, std::make_tuple(f.parameters, f.parameters, f.return_type), context))
return false;

View File

@ -127,10 +127,10 @@ struct klass
if(!as_generator("\n{\n").generate(sink, attributes::unused, iface_cxt))
return false;
if(!as_generator(*(scope_tab << function_declaration)).generate(sink, cls.functions, iface_cxt))
if(!as_generator(*(function_declaration)).generate(sink, cls.functions, iface_cxt))
return false;
if(!as_generator(*(scope_tab << async_function_declaration)).generate(sink, cls.functions, iface_cxt))
if(!as_generator(*(async_function_declaration)).generate(sink, cls.functions, iface_cxt))
return false;
if(!as_generator(*(event_declaration)).generate(sink, cls.events, iface_cxt))
@ -147,7 +147,7 @@ struct klass
return false;
// End of interface declaration
if(!as_generator("}\n").generate(sink, attributes::unused, iface_cxt)) return false;
if(!as_generator("}\n\n").generate(sink, attributes::unused, iface_cxt)) return false;
}
// Events arguments go in the top namespace to avoid the Concrete suffix clutter in interface events.
@ -213,7 +213,7 @@ struct klass
(
scope_tab << "[System.Runtime.InteropServices.DllImport(" << context_find_tag<library_context>(concrete_cxt).actual_library_name(cls.filename)
<< ")] internal static extern System.IntPtr\n"
<< scope_tab << scope_tab << name_helpers::klass_get_name(cls) << "();\n"
<< scope_tab << scope_tab << name_helpers::klass_get_name(cls) << "();\n\n"
<< scope_tab << "/// <summary>Initializes a new instance of the <see cref=\"" << interface_name << "\"/> class.\n"
<< scope_tab << "/// Internal usage: This is used when interacting with C code and should not be used directly.</summary>\n"
<< scope_tab << "/// <param name=\"wh\">The native pointer to be wrapped.</param>\n"
@ -262,7 +262,7 @@ struct klass
scope_tab << "private static IntPtr GetEflClassStatic()\n"
<< scope_tab << "{\n"
<< scope_tab << scope_tab << "return " << name_helpers::klass_get_full_name(cls) << "();\n"
<< scope_tab << "}\n"
<< scope_tab << "}\n\n"
).generate(sink, attributes::unused, concrete_cxt))
return false;
@ -342,7 +342,7 @@ struct klass
scope_tab << "private static IntPtr GetEflClassStatic()\n"
<< scope_tab << "{\n"
<< scope_tab << scope_tab << "return " << name_helpers::klass_get_full_name(cls) << "();\n"
<< scope_tab << "}\n"
<< scope_tab << "}\n\n"
).generate(sink, attributes::unused, inherit_cxt))
return false;
@ -370,8 +370,8 @@ struct klass
<< "#pragma warning disable CS1591\n" // Disabling warnings as DocFx will hide these classes
<<"public static class " << (string % "_") << name_helpers::klass_inherit_name(cls)
<< "_ExtensionMethods {\n"
<< *((scope_tab << property_extension_method_definition(cls)) << "\n")
<< *((scope_tab << part_extension_method_definition(cls)) << "\n")
<< *(property_extension_method_definition(cls))
<< *(part_extension_method_definition(cls))
<< "}\n"
<< "#pragma warning restore CS1591\n"
<< "#endif\n")
@ -416,7 +416,7 @@ struct klass
{
if(!as_generator(
indent << scope_tab << "private static Efl.Eo.NativeModule Module = new Efl.Eo.NativeModule("
<< indent << context_find_tag<library_context>(context).actual_library_name(cls.filename) << ");\n"
<< context_find_tag<library_context>(context).actual_library_name(cls.filename) << ");\n\n"
).generate(sink, attributes::unused, inative_cxt))
return false;
}
@ -466,7 +466,7 @@ struct klass
if(!as_generator(
indent << scope_tab << scope_tab << "return descs;\n"
<< indent << scope_tab << "}\n"
<< indent << scope_tab << "}\n\n"
).generate(sink, attributes::unused, inative_cxt))
return false;
@ -532,7 +532,7 @@ struct klass
if(!as_generator(
scope_tab << "[System.Runtime.InteropServices.DllImport(" << context_find_tag<library_context>(context).actual_library_name(cls.filename)
<< ")] internal static extern System.IntPtr\n"
<< scope_tab << scope_tab << name_helpers::klass_get_name(cls) << "();\n"
<< scope_tab << scope_tab << name_helpers::klass_get_name(cls) << "();\n\n"
).generate(sink, attributes::unused, context))
return false;
@ -607,7 +607,7 @@ struct klass
return true;
// Self events
if (!as_generator(*(event_definition(cls, cls))).generate(sink, cls.events, context))
if (!as_generator(*(event_definition(cls, cls)) << "\n").generate(sink, cls.events, context))
return false;
// Inherited events

View File

@ -508,7 +508,7 @@ bool open_namespaces(OutputIterator sink, std::vector<std::string> namespaces, C
template<typename OutputIterator, typename Context>
bool close_namespaces(OutputIterator sink, std::vector<std::string> const& namespaces, Context const& context)
{
auto close_namespace = (lit("}") % "\n\n" ) << "\n\n";
auto close_namespace = (lit("}") % "\n" ) << "\n\n";
return as_generator(close_namespace).generate(sink, namespaces, context);
}

View File

@ -1071,7 +1071,7 @@ struct convert_return_generator
else if (helpers::need_struct_conversion(regular))
{
return as_generator(
"return _ret_var;\n"
"return _ret_var;"
).generate(sink, nullptr, context);
}
else if (ret_type.c_type == "Eina_Binbuf *" || ret_type.c_type == "const Eina_Binbuf *")
@ -1119,7 +1119,7 @@ struct convert_return_generator
}
else if (ret_type.c_type != "void")
{
return as_generator("return _ret_var;\n").generate(sink, ret_type, context);
return as_generator("return _ret_var;").generate(sink, ret_type, context);
}
return true;
}
@ -1289,13 +1289,13 @@ struct native_convert_return_generator
if (ret_type.is_ptr && helpers::need_pointer_conversion(regular) && !helpers::need_struct_conversion_in_return(ret_type, attributes::parameter_direction::unknown) )
{
return as_generator(
"return Eina.PrimitiveConversion.ManagedToPointerAlloc(_ret_var);\n"
"return Eina.PrimitiveConversion.ManagedToPointerAlloc(_ret_var);"
).generate(sink, attributes::unused, context);
}
else if (helpers::need_struct_conversion(regular))
{
return as_generator(
"return _ret_var;\n"
"return _ret_var;"
).generate(sink, nullptr, context);
}
else if (ret_type.c_type == "const char *")
@ -1308,12 +1308,12 @@ struct native_convert_return_generator
return false;
}
return as_generator(
"return _ret_var;\n"
"return _ret_var;"
).generate(sink, attributes::unused, context);
}
else
{
return as_generator("return _ret_var;\n"
return as_generator("return _ret_var;"
).generate(sink, attributes::unused, context);
}
}
@ -1326,12 +1326,12 @@ struct native_convert_return_generator
return false;
}
return as_generator(
"return _ret_var;\n"
"return _ret_var;"
).generate(sink, attributes::unused, context);
}
else
{
return as_generator("return _ret_var;\n")
return as_generator("return _ret_var;")
.generate(sink, attributes::unused, context);
}
}
@ -1341,7 +1341,7 @@ struct native_convert_return_generator
.generate(sink, attributes::unused, context))
return false;
return as_generator("return _ret_var.Handle;\n")
return as_generator("return _ret_var.Handle;")
.generate(sink, attributes::unused, context);
}
else if (ret_type.c_type == "Eina_Hash *" || ret_type.c_type == "const Eina_Hash *")
@ -1359,7 +1359,7 @@ struct native_convert_return_generator
.generate(sink, attributes::unused, context))
return false;
return as_generator("return _ret_var.Handle;\n")
return as_generator("return _ret_var.Handle;")
.generate(sink, attributes::unused, context);
}
else if (ret_type.c_type == "Eina_Array *" || ret_type.c_type == "const Eina_Array *"
@ -1386,11 +1386,11 @@ struct native_convert_return_generator
return false;
}
return as_generator("return _ret_var.Handle;\n")
return as_generator("return _ret_var.Handle;")
.generate(sink, attributes::unused, context);
}
else if (ret_type.c_type != "void")
return as_generator("return _ret_var;\n").generate(sink, ret_type, context);
return as_generator("return _ret_var;").generate(sink, ret_type, context);
return true;
}

View File

@ -60,7 +60,7 @@ struct part_extension_method_definition_generator
<< ", T> x=null) where T : " << name_helpers::klass_full_concrete_or_interface_name(cls) << "\n"
<< scope_tab << "{\n"
<< scope_tab << scope_tab << "return new " << bindableClass << "<" << part_klass_name << ">(\"" << part.name << "\" ,fac);\n"
<< scope_tab << "}\n"
<< scope_tab << "}\n\n"
).generate(sink, attributes::unused, context))
return false;

View File

@ -370,12 +370,12 @@ struct struct_internal_definition_generator
}
if (!as_generator(indent << scope_tab << scope_tab << "return _external_struct;\n"
<< indent << scope_tab << "}\n\n").generate(sink, nullptr, context))
<< indent << scope_tab << "}\n").generate(sink, nullptr, context))
return false;
// close internal class
if(!as_generator(indent << "}\n\n"
<< indent << "#pragma warning restore CS1591\n\n"
if(!as_generator(indent << "}\n"
<< indent << "#pragma warning restore CS1591\n"
).generate(sink, attributes::unused, context)) return false;
return true;

View File

@ -42,7 +42,7 @@ struct field_argument_docs_generator
template<typename OutputIterator, typename Context>
bool generate(OutputIterator sink, attributes::struct_field_def const& field, Context const& context) const
{
if (!as_generator("/// <param name=\"" << string << "\">" << documentation_string << "</param>")
if (!as_generator(current_indentation(context) << "/// <param name=\"" << string << "\">" << documentation_string << "</param>")
.generate(sink, std::make_tuple(name_helpers::to_field_name(field.name), field.documentation.summary), context))
return false;
return true;

View File

@ -101,11 +101,12 @@ struct _inlist_iterator
: _list(list), _node(node) {}
/**
* @brief Copy constructor. Creates a copy of the given iterator.
* @brief Create a const iterator from this one.
* @param other Other iterator.
*/
_inlist_iterator(_inlist_iterator<typename std::remove_const<T>::type> const& other)
: _list(other._list), _node(other._node) {}
operator _inlist_iterator<T const>() {
return _inlist_iterator<T const>{_list, _node};
}
/**
* @brief Move the iterator to the next position in the list.

View File

@ -46,9 +46,9 @@ struct _ptr_array_iterator
{
}
_ptr_array_iterator(_ptr_array_iterator<typename remove_cv<value_type>::type> const& other)
: _ptr(other._ptr)
operator _ptr_array_iterator<T const>()
{
return _ptr_array_iterator<T const>{_ptr};
}
_ptr_array_iterator<T>& operator++()
{

View File

@ -62,9 +62,9 @@ struct _ptr_list_iterator : _ptr_list_iterator_base
: _ptr_list_iterator_base(list, node)
{
}
_ptr_list_iterator(_ptr_list_iterator<value_type> const& other)
: _ptr_list_iterator_base(static_cast<_ptr_list_iterator_base const&>(other))
operator _ptr_list_iterator<T const>()
{
return _ptr_list_iterator<T const>{_list, _node};
}
_ptr_list_iterator<T>& operator++()

View File

@ -164,7 +164,7 @@ static Eina_Bool have_main_loop_thread = 0;
static Eina_Trash *_ecore_thread_worker_trash = NULL;
static int _ecore_thread_worker_count = 0;
static void *_ecore_thread_worker(void *);
static void *_ecore_thread_worker(void *, Eina_Thread);
static Ecore_Pthread_Worker *_ecore_thread_worker_new(void);
static PH(get_main_loop_thread) (void)
@ -468,8 +468,9 @@ _ecore_direct_worker_cleanup(void *data)
}
static void *
_ecore_direct_worker(Ecore_Pthread_Worker *work)
_ecore_direct_worker(void *data, Eina_Thread t EINA_UNUSED)
{
Ecore_Pthread_Worker *work = data;
eina_thread_cancellable_set(EINA_FALSE, NULL);
eina_thread_name_set(eina_thread_self(), "Ethread-feedback");
work->self = PHS();
@ -497,7 +498,7 @@ _ecore_thread_worker_cleanup(void *data EINA_UNUSED)
}
static void *
_ecore_thread_worker(void *data EINA_UNUSED)
_ecore_thread_worker(void *data EINA_UNUSED, Eina_Thread t EINA_UNUSED)
{
eina_thread_cancellable_set(EINA_FALSE, NULL);
EINA_THREAD_CLEANUP_PUSH(_ecore_thread_worker_cleanup, NULL);

View File

@ -106,7 +106,6 @@ typedef Efl_Gfx_Path_Command_Type Efl_Gfx_Path_Command;
#include "interfaces/efl_ui_draggable.eo.h"
#include "interfaces/efl_ui_scrollable.eo.h"
#include "interfaces/efl_ui_scrollbar.eo.h"
#include "interfaces/efl_ui_scrollable_interactive.eo.h"
#include "interfaces/efl_ui_text_selectable.eo.h"
#include "interfaces/efl_ui_container_selectable.eo.h"
#include "interfaces/efl_ui_zoom.eo.h"

View File

@ -11,6 +11,7 @@
#define EFL_VERSION_MAJOR @EFL_VERSION_MAJOR@
#define EFL_VERSION_MINOR @EFL_VERSION_MINOR@
#define EFL_VERSION_MICRO @EFL_VERSION_MICRO@
#define EFL_BUILD_ID "@EFL_BUILD_ID@"
#endif

View File

@ -1377,6 +1377,13 @@ _next_command(char *path, char *cmd, double *arr, int *count)
path++;
*count = _number_count(*cmd);
}
else
{
if (*cmd == 'm')
*cmd = 'l';
else if (*cmd == 'M')
*cmd = 'L';
}
if ( *count == 7)
{
// special case for arc command

View File

@ -74,7 +74,6 @@
#include "interfaces/efl_ui_draggable.eo.c"
#include "interfaces/efl_ui_scrollable.eo.c"
#include "interfaces/efl_ui_scrollable_interactive.eo.c"
#include "interfaces/efl_ui_scrollbar.eo.c"
#include "interfaces/efl_ui_container_selectable.eo.c"
#include "interfaces/efl_ui_text_selectable.eo.c"

View File

@ -36,29 +36,35 @@ interface Efl.Pack_Linear extends Efl.Pack
return: bool; [[$false if $subobj could not be packed.]]
}
pack_before {
[[Prepend an object before an existing sub-object.
[[Prepend an object before the $existing sub-object.
When this container is deleted, it will request deletion of the
given $subobj. Use @Efl.Pack.unpack to remove $subobj from this
container without deleting it.
If $existing is $NULL this method behaves like @.pack_begin.
]]
params {
@in subobj: Efl.Gfx.Entity; [[Object to pack before $existing.]]
@in existing: const(Efl.Gfx.Entity); [[Existing reference sub-object.]]
@in existing: const(Efl.Gfx.Entity); [[Existing reference sub-object. Must already belong to the container
or be $NULL.]]
}
return: bool; [[$false if $existing could not be found or $subobj
could not be packed.]]
}
pack_after {
[[Append an object after an existing sub-object.
[[Append an object after the $existing sub-object.
When this container is deleted, it will request deletion of the
given $subobj. Use @Efl.Pack.unpack to remove $subobj from this
container without deleting it.
If $existing is $NULL this method behaves like @.pack_end.
]]
params {
@in subobj: Efl.Gfx.Entity; [[Object to pack after $existing.]]
@in existing: const(Efl.Gfx.Entity); [[Existing reference sub-object.]]
@in existing: const(Efl.Gfx.Entity); [[Existing reference sub-object. Must already belong to the container
or be $NULL.]]
}
return: bool; [[$false if $existing could not be found or $subobj
could not be packed.]]

View File

@ -1,7 +1,172 @@
import eina_types;
import efl_ui_layout_orientable;
interface @beta Efl.Ui.Scrollable
{
[[Efl UI scrollable interface]]
event_prefix: efl_ui;
methods {
@property content_pos {
[[The content position]]
set {
}
get {
}
values {
pos: Eina.Position2D; [[The position is virtual value, (0, 0) starting at the top-left.]]
}
}
@property content_size {
[[The content size]]
get {
}
values {
size: Eina.Size2D; [[The content size in pixels.]]
}
}
@property viewport_geometry {
[[The viewport geometry]]
get {
}
values {
rect: Eina.Rect; [[It is absolute geometry.]]
}
}
@property bounce_enabled {
[[Bouncing behavior
When scrolling, the scroller may "bounce" when reaching the edge of the
content object. This is a visual way to indicate the end has been reached.
This is enabled by default for both axes. This API will determine if it's enabled
for the given axis with the boolean parameters for each one.]]
set {
}
get {
}
values {
horiz: bool; [[Horizontal bounce policy.]]
vert: bool; [[Vertical bounce policy.]]
}
}
@property scroll_freeze {
[[Freeze property
This function will freeze scrolling movement (by input of a user).
Unlike @.movement_block, this function freezes bidirectionally.
If you want to freeze in only one direction,
see @.movement_block.set.
]]
get {
}
set {
}
values {
freeze: bool; [[$true if freeze, $false otherwise]]
}
}
@property scroll_hold {
[[Hold property
When hold turns on, it only scrolls by holding action.
]]
get {
}
set {
}
values {
hold: bool; [[$true if hold, $false otherwise]]
}
}
@property looping {
[[Controls an infinite loop for a scroller.]]
set {
}
get {
}
values {
loop_h: bool; [[The scrolling horizontal loop]]
loop_v: bool; [[The Scrolling vertical loop]]
}
}
@property movement_block {
[[Blocking of scrolling (per axis).
This function will block scrolling movement (by input of a user) in
a given direction. You can disable movements in the X axis, the Y
axis or both.
The default value is @Efl.Ui.Layout_Orientation.default meaning that movements are
allowed in both directions.
]]
set {
}
get {
}
values {
block: Efl.Ui.Layout_Orientation(Efl.Ui.Layout_Orientation.default); [[Which axis (or axes) to block]]
}
}
@property gravity {
[[Control scrolling gravity on the scrollable
The gravity defines how the scroller will adjust its view
when the size of the scroller contents increases.
The scroller will adjust the view to glue itself as follows:
$[x=0.0] to stay where it is relative to the left edge of the content.
$[x=1.0] to stay where it is relative to the right edge of the content.
$[y=0.0] to stay where it is relative to the top edge of the content.
$[y=1.0] to stay where it is relative to the bottom edge of the content.
]]
set {
}
get {
}
values {
x: double(0.0); [[Horizontal scrolling gravity.]]
y: double(0.0); [[Vertical scrolling gravity.]]
}
}
@property match_content {
[[Prevent the scrollable from being smaller than the minimum size of the content.
By default the scroller will be as small as its design allows,
irrespective of its content. This will make the scroller minimum size the
right size horizontally and/or vertically to perfectly fit its content in
that direction.]]
set {
}
values {
w: bool; [[Whether to limit the minimum horizontal size]]
h: bool; [[Whether to limit the minimum vertical size]]
}
}
@property step_size {
[[Control the step size
Use this call to set step size.
This value is used when scroller scroll by arrow key event.]]
set {
}
get {
}
values {
step: Eina.Position2D; [[The step size in pixels]]
}
}
scroll {
[[Show a specific virtual region within the scroller content object.
This will ensure all (or part if it does not fit) of the designated
region in the virtual content object (0, 0 starting at the top-left of the
virtual content object) is shown within the scroller. This allows the scroller to "smoothly slide"
to this location (if configuration in general calls for transitions). It
may not jump immediately to the new location and make take a while and
show other content along the way.
]]
params {
@in rect: Eina.Rect; [[The position where to scroll. and The size user want to see]]
@in animation: bool; [[Whether to scroll with animation or not]]
}
}
}
events {
scroll,started: void; [[Called when scroll operation starts]]
scroll,changed: void; [[Called when scrolling]]

View File

@ -1,169 +0,0 @@
import eina_types;
import efl_ui_layout_orientable;
interface @beta Efl.Ui.Scrollable_Interactive extends Efl.Ui.Scrollable
{
c_prefix: efl_ui_scrollable;
methods {
@property content_pos {
[[The content position]]
set {
}
get {
}
values {
pos: Eina.Position2D; [[The position is virtual value, (0, 0) starting at the top-left.]]
}
}
@property content_size {
[[The content size]]
get {
}
values {
size: Eina.Size2D; [[The content size in pixels.]]
}
}
@property viewport_geometry {
[[The viewport geometry]]
get {
}
values {
rect: Eina.Rect; [[It is absolute geometry.]]
}
}
@property bounce_enabled {
[[Bouncing behavior
When scrolling, the scroller may "bounce" when reaching the edge of the
content object. This is a visual way to indicate the end has been reached.
This is enabled by default for both axes. This API will determine if it's enabled
for the given axis with the boolean parameters for each one.]]
set {
}
get {
}
values {
horiz: bool; [[Horizontal bounce policy.]]
vert: bool; [[Vertical bounce policy.]]
}
}
@property scroll_freeze {
[[Freeze property
This function will freeze scrolling movement (by input of a user).
Unlike @.movement_block, this function freezes bidirectionally.
If you want to freeze in only one direction,
see @.movement_block.set.
]]
get {
}
set {
}
values {
freeze: bool; [[$true if freeze, $false otherwise]]
}
}
@property scroll_hold {
[[Hold property
When hold turns on, it only scrolls by holding action.
]]
get {
}
set {
}
values {
hold: bool; [[$true if hold, $false otherwise]]
}
}
@property looping {
[[Controls an infinite loop for a scroller.]]
set {
}
get {
}
values {
loop_h: bool; [[The scrolling horizontal loop]]
loop_v: bool; [[The Scrolling vertical loop]]
}
}
@property movement_block {
[[Blocking of scrolling (per axis).
This function will block scrolling movement (by input of a user) in
a given direction. You can disable movements in the X axis, the Y
axis or both.
The default value is @Efl.Ui.Layout_Orientation.default meaning that movements are
allowed in both directions.
]]
set {
}
get {
}
values {
block: Efl.Ui.Layout_Orientation(Efl.Ui.Layout_Orientation.default); [[Which axis (or axes) to block]]
}
}
@property gravity {
[[Control scrolling gravity on the scrollable
The gravity defines how the scroller will adjust its view
when the size of the scroller contents increases.
The scroller will adjust the view to glue itself as follows:
$[x=0.0] to stay where it is relative to the left edge of the content.
$[x=1.0] to stay where it is relative to the right edge of the content.
$[y=0.0] to stay where it is relative to the top edge of the content.
$[y=1.0] to stay where it is relative to the bottom edge of the content.
]]
set {
}
get {
}
values {
x: double(0.0); [[Horizontal scrolling gravity.]]
y: double(0.0); [[Vertical scrolling gravity.]]
}
}
@property match_content {
[[Prevent the scrollable from being smaller than the minimum size of the content.
By default the scroller will be as small as its design allows,
irrespective of its content. This will make the scroller minimum size the
right size horizontally and/or vertically to perfectly fit its content in
that direction.]]
set {
}
values {
w: bool; [[Whether to limit the minimum horizontal size]]
h: bool; [[Whether to limit the minimum vertical size]]
}
}
@property step_size {
[[Control the step size
Use this call to set step size.
This value is used when scroller scroll by arrow key event.]]
set {
}
get {
}
values {
step: Eina.Position2D; [[The step size in pixels]]
}
}
scroll {
[[Show a specific virtual region within the scroller content object.
This will ensure all (or part if it does not fit) of the designated
region in the virtual content object (0, 0 starting at the top-left of the
virtual content object) is shown within the scroller. This allows the scroller to "smoothly slide"
to this location (if configuration in general calls for transitions). It
may not jump immediately to the new location and make take a while and
show other content along the way.
]]
params {
@in rect: Eina.Rect; [[The position where to scroll. and The size user want to see]]
@in animation: bool; [[Whether to scroll with animation or not]]
}
}
}
}

View File

@ -9,7 +9,6 @@ pub_legacy_eo_files = [
'efl_input_device.eo',
'efl_ui_draggable.eo',
'efl_ui_scrollable.eo',
'efl_ui_scrollable_interactive.eo',
'efl_ui_scrollbar.eo',
'efl_ui_container_selectable.eo',
'efl_ui_text_selectable.eo',

View File

@ -95,15 +95,16 @@ eina_array_count(const Eina_Array *array)
static inline Eina_Bool
eina_array_find(const Eina_Array *array, const void *data, unsigned int *out_idx)
{
unsigned int i;
if (!array) return EINA_FALSE;
unsigned int i = 0;
for (; i < array->count; i++)
for (i = 0; i < array->count; i++)
{
if (array->data[i] == data)
{
if (out_idx) *out_idx = i;
return EINA_TRUE;
}
}

View File

@ -1538,7 +1538,7 @@ eina_log_init(void)
#endif
#ifdef HAVE_SYSTEMD
if (getenv("NOTIFY_SOCKET"))
if (getenv("NOTIFY_SOCKET") && !getenv("EFL_RUN_IN_TREE"))
_print_cb = eina_log_print_cb_journald;
#endif
@ -1562,10 +1562,6 @@ eina_log_init(void)
// Global log level
if ((level = getenv(EINA_LOG_ENV_LEVEL)))
_log_level = atoi(level);
#ifdef HAVE_SYSTEMD
else if (getenv("NOTIFY_SOCKET") && (_print_cb == eina_log_print_cb_journald))
_log_level = EINA_LOG_LEVEL_INFO;
#endif
// Register UNKNOWN domain, the default logger
EINA_LOG_DOMAIN_GLOBAL = eina_log_domain_register("", NULL);

View File

@ -180,6 +180,7 @@ _efl_ui_caching_factory_efl_ui_factory_create(Eo *obj,
Efl_Ui_Caching_Factory_Data *pd,
Eina_Iterator *models, Efl_Gfx_Entity *parent)
{
Efl_Ui_Caching_Factory_Request *r;
Efl_Ui_Caching_Factory_Group_Request *gr;
Efl_Gfx_Entity *w = NULL;
Efl_Model *model;
@ -187,7 +188,6 @@ _efl_ui_caching_factory_efl_ui_factory_create(Eo *obj,
if (pd->cache && pd->style && !pd->klass)
{
Efl_Ui_Caching_Factory_Request *r;
Eina_Future **all;
int count = 0;
@ -199,11 +199,7 @@ _efl_ui_caching_factory_efl_ui_factory_create(Eo *obj,
r->factory = efl_ref(obj);
all = calloc(1, sizeof (Eina_Future *));
if (!all)
{
free(r);
return efl_loop_future_rejected(obj, ENOMEM);
}
if (!all) goto alloc_array_error;
EINA_ITERATOR_FOREACH(models, model)
{
@ -213,11 +209,7 @@ _efl_ui_caching_factory_efl_ui_factory_create(Eo *obj,
.data = r);
all = realloc(all, (count + 1) * sizeof (Eina_Future *));
if (!all)
{
free(r);
return efl_loop_future_rejected(obj, ENOMEM);
}
if (!all) goto alloc_array_error;
}
eina_iterator_free(models);
@ -274,6 +266,13 @@ _efl_ui_caching_factory_efl_ui_factory_create(Eo *obj,
.success_type = EINA_VALUE_TYPE_ARRAY,
.data = gr,
.free = _efl_ui_caching_factory_group_cleanup);
alloc_array_error:
efl_unref(r->parent);
efl_unref(r->factory);
free(r);
eina_iterator_free(models);
return efl_loop_future_rejected(obj, ENOMEM);
}
static void

View File

@ -470,7 +470,7 @@ _efl_ui_collection_efl_ui_layout_orientable_orientation_get(const Eo *obj EINA_U
}
EOLIAN static void
_efl_ui_collection_efl_ui_scrollable_interactive_match_content_set(Eo *obj EINA_UNUSED, Efl_Ui_Collection_Data *pd, Eina_Bool w, Eina_Bool h)
_efl_ui_collection_efl_ui_scrollable_match_content_set(Eo *obj EINA_UNUSED, Efl_Ui_Collection_Data *pd, Eina_Bool w, Eina_Bool h)
{
if (pd->match_content.w == w && pd->match_content.h == h)
return;
@ -821,7 +821,8 @@ EOLIAN static Eina_Bool
_efl_ui_collection_efl_pack_linear_pack_before(Eo *obj, Efl_Ui_Collection_Data *pd, Efl_Gfx_Entity *subobj, const Efl_Gfx_Entity *existing)
{
Eina_List *subobj_list = eina_list_data_find_list(pd->items, existing);
EINA_SAFETY_ON_NULL_RETURN_VAL(subobj_list, EINA_FALSE);
if (existing)
EINA_SAFETY_ON_NULL_RETURN_VAL(subobj_list, EINA_FALSE);
if (!register_item(obj, pd, subobj))
return EINA_FALSE;
@ -835,7 +836,8 @@ EOLIAN static Eina_Bool
_efl_ui_collection_efl_pack_linear_pack_after(Eo *obj, Efl_Ui_Collection_Data *pd, Efl_Gfx_Entity *subobj, const Efl_Gfx_Entity *existing)
{
Eina_List *subobj_list = eina_list_data_find_list(pd->items, existing);
EINA_SAFETY_ON_NULL_RETURN_VAL(subobj_list, EINA_FALSE);
if (existing)
EINA_SAFETY_ON_NULL_RETURN_VAL(subobj_list, EINA_FALSE);
if (!register_item(obj, pd, subobj))
return EINA_FALSE;

View File

@ -5,7 +5,7 @@ class @beta Efl.Ui.Collection extends Efl.Ui.Layout_Base implements
Efl.Ui.Focus.Manager_Sub,
Efl.Ui.Widget_Focus_Manager
composites
Efl.Ui.Scrollable_Interactive,
Efl.Ui.Scrollable,
Efl.Ui.Scrollbar,
Efl.Ui.Focus.Manager
{
@ -77,7 +77,7 @@ class @beta Efl.Ui.Collection extends Efl.Ui.Layout_Base implements
Efl.Pack_Linear.pack_unpack_at;
Efl.Pack_Linear.pack_index_get;
Efl.Pack_Linear.pack_content_get;
Efl.Ui.Scrollable_Interactive.match_content { set; }
Efl.Ui.Scrollable.match_content { set; }
Efl.Ui.Widget_Focus_Manager.focus_manager_create;
Efl.Ui.Widget.focus_state_apply;
Efl.Ui.Focus.Manager.move;

View File

@ -81,10 +81,11 @@ _efl_ui_exact_model_slot_compress(unsigned int index, Eina_List *compressed, uns
_efl_ui_exact_model_list_find(list_index, compressed, &l);
tbuf = eina_binbuf_manage_new((unsigned char *) buffer, EFL_UI_EXACT_MODEL_CONTENT_LENGTH, EINA_TRUE);
if (!tbuf) return compressed;
cbuf = emile_compress(tbuf, EMILE_LZ4, EMILE_COMPRESSOR_FAST);
eina_binbuf_free(tbuf);
if (!tbuf || !cbuf) return compressed;
if (!cbuf) return compressed;
// Make sure the list has all the buffer up to the needed one filled with valid data
if (list_index)
@ -95,10 +96,19 @@ _efl_ui_exact_model_slot_compress(unsigned int index, Eina_List *compressed, uns
unsigned char *zmem;
zmem = calloc(EFL_UI_EXACT_MODEL_CONTENT, sizeof (unsigned int));
if (!zmem) return compressed;
if (!zmem)
{
if (cbuf) eina_binbuf_free(cbuf);
return compressed;
}
tbuf = eina_binbuf_manage_new(zmem, EFL_UI_EXACT_MODEL_CONTENT_LENGTH, EINA_TRUE);
if (!tbuf) return compressed;
if (!tbuf)
{
if (cbuf) eina_binbuf_free(cbuf);
if (zmem) free(zmem);
return compressed;
}
z = emile_compress(tbuf, EMILE_LZ4, EMILE_COMPRESSOR_FAST);

View File

@ -29,11 +29,22 @@ _set_a_without_b(Eina_List *a, Eina_List *b)
return a_out;
}
static void
_invalidate_cb(void *data, const Efl_Event *ev)
{
MY_DATA(data, pd);
EINA_SAFETY_ON_NULL_RETURN(pd);
pd->current_border = eina_list_remove(pd->current_border, ev->object);
}
static void
_register(Efl_Ui_Focus_Manager *obj, Efl_Ui_Focus_Manager *par_m, Efl_Ui_Focus_Object *node, Efl_Ui_Focus_Object *logical)
{
if (par_m)
efl_ui_focus_manager_calc_register(par_m, node, logical, obj);
efl_event_callback_add(node, EFL_EVENT_INVALIDATE, _invalidate_cb, obj);
}
static void
@ -41,6 +52,7 @@ _unregister(Efl_Ui_Focus_Manager *obj EINA_UNUSED, Efl_Ui_Focus_Manager *par_m,
{
if (par_m)
efl_ui_focus_manager_calc_unregister(par_m, node);
efl_event_callback_del(node, EFL_EVENT_INVALIDATE, _invalidate_cb, obj);
}
static void

View File

@ -149,10 +149,19 @@ _efl_ui_group_item_efl_pack_linear_pack_before(Eo *obj, Efl_Ui_Group_Item_Data *
EINA_SAFETY_ON_TRUE_RETURN_VAL(subobj == obj, EINA_FALSE);
Eo *container = efl_ui_item_container_get(obj);
EINA_SAFETY_ON_NULL_RETURN_VAL(container, EINA_FALSE);
int group_index = efl_pack_index_get(container, obj);
//FIXME, maybe we should check if existing is really part of this group
_register_item(obj, pd, subobj);
HANDLE_REG_CALL(efl_pack_before(container, subobj, existing));
if (existing)
{
HANDLE_REG_CALL(efl_pack_before(container, subobj, existing));
}
else
{
HANDLE_REG_CALL(efl_pack_at(container, subobj, group_index + 1));
}
}
EOLIAN static Eina_Bool
@ -161,10 +170,18 @@ _efl_ui_group_item_efl_pack_linear_pack_after(Eo *obj, Efl_Ui_Group_Item_Data *p
EINA_SAFETY_ON_TRUE_RETURN_VAL(subobj == obj, EINA_FALSE);
Eo *container = efl_ui_item_container_get(obj);
EINA_SAFETY_ON_NULL_RETURN_VAL(container, EINA_FALSE);
int group_index = efl_pack_index_get(container, obj);
//FIXME, maybe we should check if existing is really part of this group
_register_item(obj, pd, subobj);
HANDLE_REG_CALL(efl_pack_after(container, subobj, existing));
if (existing)
{
HANDLE_REG_CALL(efl_pack_after(container, subobj, existing));
}
else
{
HANDLE_REG_CALL(efl_pack_at(container, subobj, group_index + eina_list_count(pd->registered_items)));
}
}
EOLIAN static Eina_Bool

View File

@ -2703,7 +2703,7 @@ _efl_ui_image_zoomable_image_region_set(Eo *obj, Efl_Ui_Image_Zoomable_Data *sd,
}
EOLIAN static void
_efl_ui_image_zoomable_efl_ui_scrollable_interactive_scroll(Eo *obj, Efl_Ui_Image_Zoomable_Data *sd, Eina_Rect rc, Eina_Bool animation)
_efl_ui_image_zoomable_efl_ui_scrollable_scroll(Eo *obj, Efl_Ui_Image_Zoomable_Data *sd, Eina_Rect rc, Eina_Bool animation)
{
int rx, ry, rw, rh;

View File

@ -3,7 +3,7 @@ struct @extern Elm.Photocam.Error; [[Photocam error information.]]
struct @extern Elm.Photocam.Progress; [[Photocam progress information.]]
class @beta Efl.Ui.Image_Zoomable extends Efl.Ui.Image implements Efl.Ui.Zoom
composites Efl.Ui.Scrollable_Interactive, Efl.Ui.Scrollbar
composites Efl.Ui.Scrollable, Efl.Ui.Scrollbar
{
[[Elementary Image Zoomable class]]
methods {
@ -52,7 +52,7 @@ class @beta Efl.Ui.Image_Zoomable extends Efl.Ui.Image implements Efl.Ui.Zoom
Efl.Ui.Widget.theme_apply;
Efl.Ui.Focus.Object.on_focus_update;
Efl.Ui.Widget.widget_input_event_handler;
Efl.Ui.Scrollable_Interactive.scroll;
Efl.Ui.Scrollable.scroll;
Efl.Access.Widget.Action.elm_actions { get; }
Efl.File.load;
Efl.File.unload;

View File

@ -1801,7 +1801,6 @@ _elm_layout_efl_canvas_group_change(Eo *obj, Elm_Layout_Data *ld)
{
Efl_Ui_Layout_Data *sd;
if (!efl_finalized_get(obj)) return;
sd = efl_data_scope_safe_get(obj, EFL_UI_LAYOUT_BASE_CLASS);
EINA_SAFETY_ON_NULL_RETURN(sd);
if (sd->frozen) return;
@ -1835,26 +1834,25 @@ EOLIAN static int
_efl_ui_layout_base_efl_layout_calc_calc_freeze(Eo *obj, Efl_Ui_Layout_Data *sd)
{
ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd, 0);
if ((sd->frozen)++ != 0) return sd->frozen;
edje_object_freeze(wd->resize_obj);
return 1;
sd->frozen = EINA_TRUE;
return edje_object_freeze(wd->resize_obj);
}
EOLIAN static int
_efl_ui_layout_base_efl_layout_calc_calc_thaw(Eo *obj, Efl_Ui_Layout_Data *sd)
{
int ret;
ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd, 0);
if (--(sd->frozen) != 0) return sd->frozen;
ret = edje_object_thaw(wd->resize_obj);
edje_object_thaw(wd->resize_obj);
if (!ret)
{
sd->frozen = EINA_FALSE;
efl_canvas_group_change(obj);
}
efl_canvas_group_change(obj);
return 0;
return ret;
}
EOLIAN void

View File

@ -13,7 +13,7 @@ class @beta Efl.Ui.List_View extends Efl.Ui.Layout_Base implements
Efl.Ui.Container_Selectable, Efl.Ui.List_View_Model,
Efl.Ui.Widget_Focus_Manager
composites
Efl.Ui.Scrollable_Interactive, Efl.Ui.Scrollbar
Efl.Ui.Scrollable, Efl.Ui.Scrollbar
{
methods {
@property homogeneous {

View File

@ -18,7 +18,7 @@ struct @beta Efl.Ui.Panel_Scroll_Info
class @beta Efl.Ui.Panel extends Efl.Ui.Layout_Base
implements Efl.Ui.Focus.Layer, Efl.Content,
Efl.Access.Widget.Action
composites Efl.Ui.Scrollable_Interactive
composites Efl.Ui.Scrollable
{
[[Elementary panel class]]
methods {

View File

@ -448,6 +448,8 @@ _reposition_content(Eo *obj EINA_UNUSED, Efl_Ui_Position_Manager_Grid_Data *pd)
if (pd->max_min_size.w <= 0 || pd->max_min_size.h <= 0) return;
if (!eina_inarray_count(pd->group_cache)) return;
_size_cache_require(obj, pd);
//space size contains the amount of space that is outside the viewport (either to the top or to the left)
space_size.w = (MAX(pd->last_viewport_size.w - pd->viewport.w, 0))*pd->scroll_position.x;
space_size.h = (MAX(pd->last_viewport_size.h - pd->viewport.h, 0))*pd->scroll_position.y;

View File

@ -417,6 +417,8 @@ _efl_ui_position_manager_list_efl_ui_position_manager_entity_position_single_ite
if (!pd->size) return EINA_RECT(0,0,0,0);
cache_require(obj, pd);
//space size contains the amount of space that is outside the viewport (either to the top or to the left)
space_size.w = (MAX(pd->abs_size.w - pd->viewport.w, 0))*pd->scroll_position.x;
space_size.h = (MAX(pd->abs_size.h - pd->viewport.h, 0))*pd->scroll_position.y;

View File

@ -253,13 +253,13 @@ _efl_ui_scroll_manager_edge_right(Efl_Ui_Scroll_Manager_Data *sd)
}
EOLIAN static Eina_Size2D
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_content_size_get(const Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd)
_efl_ui_scroll_manager_efl_ui_scrollable_content_size_get(const Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd)
{
return efl_ui_pan_content_size_get(sd->pan_obj);
}
EOLIAN static Eina_Rect
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_viewport_geometry_get(const Eo *obj EINA_UNUSED,
_efl_ui_scroll_manager_efl_ui_scrollable_viewport_geometry_get(const Eo *obj EINA_UNUSED,
Efl_Ui_Scroll_Manager_Data *sd)
{
if (!sd->pan_obj) return EINA_RECT(0, 0, 0, 0);
@ -268,21 +268,21 @@ _efl_ui_scroll_manager_efl_ui_scrollable_interactive_viewport_geometry_get(const
}
EOLIAN static void
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_match_content_set(Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Eina_Bool w, Eina_Bool h)
_efl_ui_scroll_manager_efl_ui_scrollable_match_content_set(Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Eina_Bool w, Eina_Bool h)
{
sd->match_content_w = !!w;
sd->match_content_h = !!h;
}
EOLIAN static void
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_step_size_set(Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Eina_Position2D step)
_efl_ui_scroll_manager_efl_ui_scrollable_step_size_set(Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Eina_Position2D step)
{
sd->step.x = step.x * elm_config_scale_get();
sd->step.y = step.y * elm_config_scale_get();
}
EOLIAN static Eina_Position2D
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_step_size_get(const Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd)
_efl_ui_scroll_manager_efl_ui_scrollable_step_size_get(const Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd)
{
return EINA_POSITION2D(sd->step.x, sd->step.y);
}
@ -408,7 +408,7 @@ _efl_ui_scroll_manager_bounce_eval(Efl_Ui_Scroll_Manager_Data *sd)
}
EOLIAN static Eina_Position2D
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_content_pos_get(const Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd)
_efl_ui_scroll_manager_efl_ui_scrollable_content_pos_get(const Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd)
{
if (!sd->pan_obj) return EINA_POSITION2D(0, 0);
@ -416,7 +416,7 @@ _efl_ui_scroll_manager_efl_ui_scrollable_interactive_content_pos_get(const Eo *o
}
EOLIAN static void
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_content_pos_set(Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Eina_Position2D pos)
_efl_ui_scroll_manager_efl_ui_scrollable_content_pos_set(Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Eina_Position2D pos)
{
Evas_Coord x = pos.x, y = pos.y;
Eina_Position2D min = {0, 0}, max = {0, 0}, cur = {0, 0};
@ -2309,25 +2309,25 @@ _efl_ui_scroll_manager_pan_set(Eo *obj, Efl_Ui_Scroll_Manager_Data *sd, Eo *pan)
}
EOLIAN static Eina_Bool
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_scroll_hold_get(const Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd)
_efl_ui_scroll_manager_efl_ui_scrollable_scroll_hold_get(const Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd)
{
return sd->hold;
}
EOLIAN static void
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_scroll_hold_set(Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Eina_Bool hold)
_efl_ui_scroll_manager_efl_ui_scrollable_scroll_hold_set(Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Eina_Bool hold)
{
sd->hold = hold;
}
EOLIAN static Eina_Bool
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_scroll_freeze_get(const Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd)
_efl_ui_scroll_manager_efl_ui_scrollable_scroll_freeze_get(const Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd)
{
return sd->freeze;
}
EOLIAN static void
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_scroll_freeze_set(Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Eina_Bool freeze)
_efl_ui_scroll_manager_efl_ui_scrollable_scroll_freeze_set(Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Eina_Bool freeze)
{
sd->freeze = freeze;
if (sd->freeze)
@ -2339,21 +2339,21 @@ _efl_ui_scroll_manager_efl_ui_scrollable_interactive_scroll_freeze_set(Eo *obj E
}
EOLIAN static void
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_bounce_enabled_set(Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Eina_Bool horiz, Eina_Bool vert)
_efl_ui_scroll_manager_efl_ui_scrollable_bounce_enabled_set(Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Eina_Bool horiz, Eina_Bool vert)
{
sd->bounce_horiz = !!horiz;
sd->bounce_vert = !!vert;
}
EOLIAN static void
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_bounce_enabled_get(const Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Eina_Bool *horiz, Eina_Bool *vert)
_efl_ui_scroll_manager_efl_ui_scrollable_bounce_enabled_get(const Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Eina_Bool *horiz, Eina_Bool *vert)
{
if (horiz) *horiz = sd->bounce_horiz;
if (vert) *vert = sd->bounce_vert;
}
EOLIAN static void
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_scroll(Eo *obj, Efl_Ui_Scroll_Manager_Data *sd, Eina_Rect rect, Eina_Bool animation)
_efl_ui_scroll_manager_efl_ui_scrollable_scroll(Eo *obj, Efl_Ui_Scroll_Manager_Data *sd, Eina_Rect rect, Eina_Bool animation)
{
_scroll_manager_animators_drop(obj);
if (animation)
@ -2381,7 +2381,7 @@ _efl_ui_scroll_manager_efl_ui_scrollable_interactive_scroll(Eo *obj, Efl_Ui_Scro
}
EOLIAN static void
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_gravity_set(Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, double x, double y)
_efl_ui_scroll_manager_efl_ui_scrollable_gravity_set(Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, double x, double y)
{
sd->gravity_x = x;
sd->gravity_y = y;
@ -2391,26 +2391,26 @@ _efl_ui_scroll_manager_efl_ui_scrollable_interactive_gravity_set(Eo *obj EINA_UN
}
EOLIAN static void
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_gravity_get(const Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, double *x, double *y)
_efl_ui_scroll_manager_efl_ui_scrollable_gravity_get(const Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, double *x, double *y)
{
if (x) *x = sd->gravity_x;
if (y) *y = sd->gravity_y;
}
EOLIAN static void
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_movement_block_set(Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Efl_Ui_Layout_Orientation block)
_efl_ui_scroll_manager_efl_ui_scrollable_movement_block_set(Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Efl_Ui_Layout_Orientation block)
{
sd->block = block;
}
EOLIAN static Efl_Ui_Layout_Orientation
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_movement_block_get(const Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd)
_efl_ui_scroll_manager_efl_ui_scrollable_movement_block_get(const Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd)
{
return sd->block;
}
EOLIAN static void
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_looping_set(Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Eina_Bool loop_h, Eina_Bool loop_v)
_efl_ui_scroll_manager_efl_ui_scrollable_looping_set(Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Eina_Bool loop_h, Eina_Bool loop_v)
{
if (sd->loop_h == loop_h && sd->loop_v == loop_v) return;
@ -2419,7 +2419,7 @@ _efl_ui_scroll_manager_efl_ui_scrollable_interactive_looping_set(Eo *obj EINA_UN
}
EOLIAN static void
_efl_ui_scroll_manager_efl_ui_scrollable_interactive_looping_get(const Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Eina_Bool *loop_h, Eina_Bool *loop_v)
_efl_ui_scroll_manager_efl_ui_scrollable_looping_get(const Eo *obj EINA_UNUSED, Efl_Ui_Scroll_Manager_Data *sd, Eina_Bool *loop_h, Eina_Bool *loop_v)
{
*loop_h = sd->loop_h;
*loop_v = sd->loop_v;

View File

@ -1,6 +1,6 @@
class @beta Efl.Ui.Scroll.Manager extends Efl.Object implements
Efl.Ui.I18n,
Efl.Ui.Scrollable_Interactive,
Efl.Ui.Scrollable,
Efl.Ui.Scrollbar
{
[[Efl ui scroll manager class]]
@ -25,21 +25,21 @@ class @beta Efl.Ui.Scroll.Manager extends Efl.Object implements
Efl.Object.constructor;
Efl.Object.destructor;
Efl.Ui.I18n.mirrored { set; }
Efl.Ui.Scrollable_Interactive.content_pos { set; get; }
Efl.Ui.Scrollable_Interactive.content_size{ get; }
Efl.Ui.Scrollable_Interactive.viewport_geometry{ get; }
Efl.Ui.Scrollable_Interactive.bounce_enabled { set; get; }
Efl.Ui.Scrollable_Interactive.scroll_freeze { get; set; }
Efl.Ui.Scrollable_Interactive.scroll_hold { get; set; }
Efl.Ui.Scrollable_Interactive.looping { get; set; }
Efl.Ui.Scrollable_Interactive.movement_block { get; set; }
Efl.Ui.Scrollable_Interactive.gravity { get; set; }
Efl.Ui.Scrollable_Interactive.match_content { set; }
Efl.Ui.Scrollable_Interactive.step_size { set; get; }
Efl.Ui.Scrollable.content_pos { set; get; }
Efl.Ui.Scrollable.content_size{ get; }
Efl.Ui.Scrollable.viewport_geometry{ get; }
Efl.Ui.Scrollable.bounce_enabled { set; get; }
Efl.Ui.Scrollable.scroll_freeze { get; set; }
Efl.Ui.Scrollable.scroll_hold { get; set; }
Efl.Ui.Scrollable.looping { get; set; }
Efl.Ui.Scrollable.movement_block { get; set; }
Efl.Ui.Scrollable.gravity { get; set; }
Efl.Ui.Scrollable.match_content { set; }
Efl.Ui.Scrollable.step_size { set; get; }
Efl.Ui.Scrollbar.bar_mode { get; set; }
Efl.Ui.Scrollbar.bar_size { get; }
Efl.Ui.Scrollbar.bar_position { get; set; }
Efl.Ui.Scrollbar.bar_visibility_update;
Efl.Ui.Scrollable_Interactive.scroll;
Efl.Ui.Scrollable.scroll;
}
}

View File

@ -361,7 +361,7 @@ _efl_ui_scroller_efl_ui_widget_theme_apply(Eo *obj, Efl_Ui_Scroller_Data *sd)
}
EOLIAN static void
_efl_ui_scroller_efl_ui_scrollable_interactive_match_content_set(Eo *obj EINA_UNUSED,
_efl_ui_scroller_efl_ui_scrollable_match_content_set(Eo *obj EINA_UNUSED,
Efl_Ui_Scroller_Data *sd,
Eina_Bool match_content_w,
Eina_Bool match_content_h)

View File

@ -3,10 +3,21 @@ class @beta Efl.Ui.Scroller extends Efl.Ui.Layout_Base implements
Efl.Ui.Widget_Focus_Manager,
Efl.Content
composites
Efl.Ui.Scrollable_Interactive,
Efl.Ui.Scrollable,
Efl.Ui.Scrollbar
{
[[Efl ui scroller class]]
[[Widget container that allows objects bigger than itself to be put inside it, and provides
scrolling functionality so the whole content is visible.
Some widgets have scrolling capabilities (like @Efl.Ui.List) that allow big content
to be shown inside a small viewport, using the well-known scrollbar objects.
Some other widgets (like @Efl.Ui.Box, for example) cannot scroll by themselves and
therefore would not be fully visible when placed inside a viewport smaller than them.
The @Efl.Ui.Scroller is a helper class that provides scrolling capabilities for widgets
which don't have them. In the above example, simply putting the @Efl.Ui.Box inside a
@Efl.Ui.Scroller (using @Efl.Content.content.set) would give it the ability to scroll.
]]
implements {
Efl.Object.constructor;
Efl.Object.finalize;
@ -18,6 +29,6 @@ class @beta Efl.Ui.Scroller extends Efl.Ui.Layout_Base implements
Efl.Ui.Widget.focus_state_apply;
Efl.Ui.Widget.widget_input_event_handler;
Efl.Ui.Widget_Focus_Manager.focus_manager_create;
Efl.Ui.Scrollable_Interactive.match_content { set; }
Efl.Ui.Scrollable.match_content { set; }
}
}

View File

@ -2429,6 +2429,7 @@ _wl_general_converter(char *target, Sel_Manager_Selection *sel, void *data, int
memcpy(tmp, data, size);
if (data_ret) *data_ret = tmp;
if (size_ret) *size_ret = size;
if (!data_ret) free(tmp);
}
}
else

View File

@ -317,7 +317,8 @@ _efl_ui_spotlight_container_efl_pack_linear_pack_before(Eo *obj EINA_UNUSED,
const Efl_Gfx_Entity *existing)
{
int index = eina_list_data_idx(pd->content_list, (void *)existing);
EINA_SAFETY_ON_FALSE_RETURN_VAL(index >= 0, EINA_FALSE);
if (existing)
EINA_SAFETY_ON_FALSE_RETURN_VAL(index >= 0, EINA_FALSE);
if (!_register_child(obj, pd, subobj)) return EINA_FALSE;
pd->content_list = eina_list_prepend_relative(pd->content_list, subobj, existing);
@ -332,7 +333,8 @@ _efl_ui_spotlight_container_efl_pack_linear_pack_after(Eo *obj EINA_UNUSED,
const Efl_Gfx_Entity *existing)
{
int index = eina_list_data_idx(pd->content_list, (void *)existing);
EINA_SAFETY_ON_FALSE_RETURN_VAL(index >= 0, EINA_FALSE);
if (existing)
EINA_SAFETY_ON_FALSE_RETURN_VAL(index >= 0, EINA_FALSE);
if (!_register_child(obj, pd, subobj)) return EINA_FALSE;
pd->content_list = eina_list_append_relative(pd->content_list, subobj, existing);

View File

@ -188,7 +188,8 @@ _efl_ui_tab_bar_efl_pack_linear_pack_end(Eo *obj, Efl_Ui_Tab_Bar_Data *pd, Efl_G
EOLIAN static Eina_Bool
_efl_ui_tab_bar_efl_pack_linear_pack_before(Eo *obj, Efl_Ui_Tab_Bar_Data *pd, Efl_Gfx_Entity *subobj, const Efl_Gfx_Entity *existing)
{
EINA_SAFETY_ON_FALSE_RETURN_VAL(efl_pack_index_get(pd->bx, existing) >= 0, EINA_FALSE);
if (existing)
EINA_SAFETY_ON_FALSE_RETURN_VAL(efl_pack_index_get(pd->bx, existing) >= 0, EINA_FALSE);
EINA_SAFETY_ON_FALSE_RETURN_VAL(_register_item(obj, pd, subobj), EINA_FALSE);
return efl_pack_before(pd->bx, subobj, existing);
}
@ -196,7 +197,8 @@ _efl_ui_tab_bar_efl_pack_linear_pack_before(Eo *obj, Efl_Ui_Tab_Bar_Data *pd, Ef
EOLIAN static Eina_Bool
_efl_ui_tab_bar_efl_pack_linear_pack_after(Eo *obj, Efl_Ui_Tab_Bar_Data *pd, Efl_Gfx_Entity *subobj, const Efl_Gfx_Entity *existing)
{
EINA_SAFETY_ON_FALSE_RETURN_VAL(efl_pack_index_get(pd->bx, existing) >= 0, EINA_FALSE);
if (existing)
EINA_SAFETY_ON_FALSE_RETURN_VAL(efl_pack_index_get(pd->bx, existing) >= 0, EINA_FALSE);
EINA_SAFETY_ON_FALSE_RETURN_VAL(_register_item(obj, pd, subobj), EINA_FALSE);
return efl_pack_after(pd->bx, subobj, existing);
}

View File

@ -14,7 +14,10 @@
static void
_select(Eo *obj EINA_UNUSED, Efl_Ui_Tab_Page *page)
{
efl_ui_selectable_selected_set(efl_ui_tab_page_tab_bar_item_get(page), EINA_TRUE);
Efl_Ui_Tab_Bar_Default_Item *item = efl_ui_tab_page_tab_bar_item_get(page);
if (!efl_ui_selectable_selected_get(item))
efl_ui_selectable_selected_set(item, EINA_TRUE);
}
static void

View File

@ -577,7 +577,8 @@ _path_start_angle_adjust(Eo *obj, Efl_Ui_Textpath_Data *pd)
{
Eina_Rect r;
Efl_Ui_Textpath_Segment *seg;
Eina_Vector2 first, last;
Eina_Vector2 first = { 0, 0 };
Eina_Vector2 last = { 0, 0 };
int remained_w, len;
double rad, t, offset_angle;

View File

@ -182,7 +182,7 @@ _elm_scrollable_is(const Evas_Object *obj)
efl_isa(obj, ELM_INTERFACE_SCROLLABLE_MIXIN);
else
return
efl_isa(obj, EFL_UI_SCROLLABLE_INTERACTIVE_INTERFACE);
efl_isa(obj, EFL_UI_SCROLLABLE_INTERFACE);
}
static void

View File

@ -201,11 +201,7 @@ _efl_ui_widget_factory_efl_ui_factory_create(Eo *obj, Efl_Ui_Widget_Factory_Data
r->factory = efl_ref(obj);
f = calloc(count + 1, sizeof (Eina_Future *));
if (!f)
{
free(r);
return efl_loop_future_rejected(obj, ENOMEM);
}
if (!f) goto alloc_array_error;
EINA_ITERATOR_FOREACH(models, model)
{
@ -214,11 +210,7 @@ _efl_ui_widget_factory_efl_ui_factory_create(Eo *obj, Efl_Ui_Widget_Factory_Data
.free = _efl_ui_widget_factory_single_cleanup);
f = realloc(f, (count + 1) * sizeof (Eina_Future *));
if (!f)
{
free(r);
return efl_loop_future_rejected(obj, ENOMEM);
}
if (!f) goto alloc_array_error;
}
eina_iterator_free(models);
@ -227,6 +219,13 @@ _efl_ui_widget_factory_efl_ui_factory_create(Eo *obj, Efl_Ui_Widget_Factory_Data
return efl_future_then(obj, eina_future_all_array(f),
.data = r,
.free = _efl_ui_widget_factory_create_cleanup);
alloc_array_error:
efl_unref(r->parent);
efl_unref(r->factory);
free(r);
eina_iterator_free(models);
return efl_loop_future_rejected(obj, ENOMEM);
}
static void

View File

@ -3,14 +3,14 @@ parse efl_text_format;
mixin @beta Efl.Ui.Widget_Scrollable_Content requires Efl.Object
{
[[Efl widget scrollable content mixin
[[Mixin helper to add scrollable content to widgets.
This can be used to provide scrollable contents and text for widgets. When a scrollable
text or content is set, this mixin will create and manage an internal scroller object which
This can be used to provide scrollable contents and text for widgets. When @.scrollable_content or
@.scrollable_text is set, this mixin will create and manage an internal scroller object which
will be the container of that text or content.
Only a single content or text can be set at any given time. Setting @.scrollable_content
will unset @.scrollable_text and vice versa.
Only a single content or text can be set at any given time. Setting @.scrollable_text
will unset @.scrollable_content.
@since 1.23
]]
@ -21,34 +21,32 @@ mixin @beta Efl.Ui.Widget_Scrollable_Content requires Efl.Object
@property scrollable_content_did_group_calc @protected @beta {
[[Widgets can call this function during their @Efl.Canvas.Group.group_calculate
implementation after the super call to determine whether the internal scroller
has performed sizing calculations.
has already performed sizing calculations.
The optimal_size,calc event will have been emitted during the super call if
this method returns $true.
In the case that this returns $true, it's likely that the widget should be completing
its internal sizing calculations from the @[Efl.Ui.Widget_Scrollable_Content.optimal_size,calc] callback using
If this property is $true, the @[Efl.Ui.Widget_Scrollable_Content.optimal_size,calc] event will have been
emitted during the super call. In this case it's likely that the widget should be completing
its internal sizing calculations from that event using:
efl_canvas_group_calculate(efl_super(ev->object, EFL_UI_WIDGET_SCROLLABLE_CONTENT_MIXIN));
in order to skip the scrollable sizing calc.
in order to skip the scrollable sizing calculation.
@since 1.23
]]
get {}
values {
did_group_calc: bool; [[Whether the internal scroller has done sizing calcs.]]
did_group_calc: bool; [[Whether the internal scroller has already done sizing calculations.]]
}
}
@property scrollable_content {
[[This is the content which will be placed in the internal scroller.
If a scrollable text string is set, this will return $NULL.
If a @.scrollable_text string is set, this property will be $NULL.
@since 1.23
]]
set {
return: bool; [[True on success]]
return: bool; [[$true on success.]]
}
get {}
values {

View File

@ -28,7 +28,7 @@ enum Elm.Scroller.Single_Direction
last [[Internal. Sentinel value to indicate last enum field during iteration.]]
}
mixin @beta Elm.Interface_Scrollable requires Efl.Ui.Widget extends Efl.Ui.Scrollable, Efl.Ui.Focus.Manager_Sub, Efl.Ui.Widget_Focus_Manager
mixin @beta Elm.Interface_Scrollable requires Efl.Ui.Widget extends Efl.Ui.Focus.Manager_Sub, Efl.Ui.Widget_Focus_Manager
{
[[Elm scrollable mixin]]
c_prefix: elm_interface_scrollable;

View File

@ -62,10 +62,9 @@ typedef struct _Efl_Ui_Layout_Data
Eina_Bool updating : 1;
} connect;
int frozen; /**< Layout freeze counter */
unsigned int finger_size_multiplier_x, finger_size_multiplier_y; /**< multipliers for finger_size during group_calc */
Eina_Bool frozen; /**< Layout freeze state */
Eina_Bool can_access : 1; /**< This is true when all text(including textblock) parts can be accessible by accessibility. */
Eina_Bool destructed_is : 1; /**< This flag indicates if Efl.Ui.Layout destructor was called. This is needed to avoid unnecessary calculation of subobject deletion during layout object's deletion. */
Eina_Bool file_set : 1; /**< This flag indicates if Efl.Ui.Layout source is set from a file*/

View File

@ -289,7 +289,7 @@ abstract Efl.Object
]]
}
event_global_thaw @static {
[[Gobally thaw events for ALL EFL OBJECTS.
[[Globally thaw events for ALL EFL OBJECTS.
Allows event callbacks to be called for all EFL objects after they have
been disabled by @.event_global_freeze. The amount of thaws must match
@ -347,7 +347,7 @@ abstract Efl.Object
}
}
children_iterator_new {
[[Get an iterator on all childrens]]
[[Get an iterator on all children.]]
return: iterator<Efl.Object> @move @no_unused; [[Children iterator]]
}
composite_attach @beta {

View File

@ -646,11 +646,11 @@ _validate_event(Validate_State *vals, Eolian_Event *event, Eina_Hash *nhash)
}
/* any type past builtin value types and containers is not allowed,
* any_value is allowed but passed as const reference, any_value_ref
* is not; string is allowed, but mutable strings or stringshares are
* is not; string and stringshare is allowed, but mutable strings are
* not and neither are string buffers, the type is never owned by the
* callee, so all strings passed in are unowned and read-only
*/
if (kwid >= KW_any_value_ref && kwid != KW_string)
if (kwid >= KW_any_value_ref && kwid != KW_string && kwid != KW_stringshare)
{
_eo_parser_log(&tp->base, "forbidden event type");
return _reset_stable(vals, was_stable, EINA_FALSE);

View File

@ -26,7 +26,8 @@ struct html_escaped_string_generator
case '\'': out.append("&apos;"); break;
case '<': out.append("&lt;"); break;
case '>': out.append("&gt;"); break;
case '\\': if (pos < input.size() - 1) pos++; // Deliberate fallthrough
case '\\': if (pos < input.size() - 1) pos++;
// fall through
default: out.append(&input[pos], 1); break;
}
}

View File

@ -495,7 +495,7 @@ inline void type_def::set(Eolian_Type const* eolian_type, Eolian_Unit const* uni
complex.subtypes.push_back({stp
, unit
, ::eolian_type_c_type_get(stp)
, eolian_type_is_move(stp)
, static_cast<bool>(eolian_type_is_move(stp))
, is_by::value});
stp = eolian_type_next_type_get(stp);
}
@ -532,6 +532,7 @@ inline void type_def::set(Eolian_Expression_Type eolian_exp_type)
break;
case EOLIAN_EXPR_STRING:
set("string", "const char *");
break;
case EOLIAN_EXPR_BOOL:
set("bool", "Eina_Bool");
break;

View File

@ -71,7 +71,7 @@ _zoom_compute(Efl_Canvas_Gesture_Recognizer_Zoom_Data *pd,
Evas_Coord diam = _finger_gap_length_get(xx1, yy1, xx2, yy2,
&x, &y);
zd->radius = diam / 2;
zd->radius = diam / 2.0;
if (!pd->zoom_base)
{
@ -202,7 +202,7 @@ _efl_canvas_gesture_recognizer_zoom_efl_canvas_gesture_recognizer_recognize(Eo *
pd->zoom_st.cur.pos.y,
&x, &y);
zd->radius = pd->zoom_base / 2;
zd->radius = pd->zoom_base / 2.0;
if ((efl_gesture_state_get(gesture) != EFL_GESTURE_STARTED) &&
(efl_gesture_state_get(gesture) != EFL_GESTURE_UPDATED))

View File

@ -13,19 +13,29 @@ if sys_windows == true
]
endif
have_gl_engine = false
if get_option('opengl') != 'none'
engines += [
['gl_generic', []],
['gl_x11', ['x11']],
['gl_drm', ['drm']],
['gl_cocoa', ['cocoa']],
['gl_drm', ['drm']]
]
have_gl_engine = true
endif
if get_option('opengl') == 'full'
engines += [['gl_cocoa', ['cocoa']]]
have_gl_engine = true
endif
if get_option('opengl') == 'es-egl'
engines += [['wayland_egl', ['wl']]]
have_gl_engine = true
endif
if have_gl_engine
engines += [['gl_generic', []]]
endif
foreach engine_conf : engines
engine = engine_conf[0]

View File

@ -51,9 +51,9 @@ _children_slice_get_then(void *data EINA_UNUSED,
p_true = efl_model_property_get(child, "test_p_true");
p_false = efl_model_property_get(child, "test_p_false");
eina_value_int_get(p_int, &v_int);
eina_value_bool_get(p_true, &v_true);
eina_value_bool_get(p_false, &v_false);
fail_if(!eina_value_int_get(p_int, &v_int));
fail_if(!eina_value_bool_get(p_true, &v_true));
fail_if(!eina_value_bool_get(p_false, &v_false));
fail_if(v_int != base_ints[i]);
fail_if(v_true != EINA_TRUE);

View File

@ -642,7 +642,7 @@ verify_anchor(Eo *popup, Eo **align_buttons, Align align, Eina_Size2D *popup_sz)
else
anchor_geom = win_geom;
Evas_Coord x, y;
Evas_Coord x = 0, y = 0;
/* click the button to trigger changing the align on the popup
* this could be done manually, but we're trying to copy the elm_test case

View File

@ -6,6 +6,32 @@
#include <Elementary.h>
#include "elm_suite.h"
EFL_START_TEST(elm_test_check_size)
{
Evas_Object *win, *check, *box;
int width, height;
win = elm_win_util_standard_add("check", "Check");
box = elm_box_add(win);
evas_object_size_hint_weight_set(box, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
elm_win_resize_object_add(win, box);
evas_object_show(box);
check = elm_check_add(box);
elm_box_pack_end(box, check);
evas_object_show(check);
evas_object_show(win);
get_me_to_those_events(check);
evas_object_size_hint_min_get(check, &width, &height);
ck_assert_int_gt(width, 0);
ck_assert_int_gt(height, 0);
}
EFL_END_TEST
EFL_START_TEST(elm_test_check_legacy_type_check)
{
Evas_Object *win, *check;
@ -122,6 +148,7 @@ EFL_END_TEST
void elm_test_check(TCase *tc)
{
tcase_add_test(tc, elm_test_check_size);
tcase_add_test(tc, elm_test_check_legacy_type_check);
tcase_add_test(tc, elm_test_check_onoff_text);
tcase_add_test(tc, elm_test_check_state);

View File

@ -182,6 +182,21 @@ EFL_START_TEST(pack_before3)
}
EFL_END_TEST
EFL_START_TEST(pack_before4)
{
Efl_Ui_Widget *wid[3];
Efl_Ui_Widget *inv = create_test_widget();
_fill_array(wid);
for (int i = 0; i < 3; i++)
efl_pack_end(widget, wid[i]);
ck_assert_int_eq(efl_pack_before(widget, inv, NULL), EINA_TRUE);
ck_assert_ptr_eq(efl_pack_content_get(widget, 0), inv);
}
EFL_END_TEST
EFL_START_TEST(pack_after1)
{
Efl_Ui_Widget *wid[3];
@ -247,6 +262,21 @@ EFL_START_TEST(pack_after3)
}
EFL_END_TEST
EFL_START_TEST(pack_after4)
{
Efl_Ui_Widget *wid[3];
Efl_Ui_Widget *inv = create_test_widget();
_fill_array(wid);
for (int i = 0; i < 3; i++)
efl_pack_end(widget, wid[i]);
ck_assert_int_eq(efl_pack_after(widget, inv, NULL), EINA_TRUE);
ck_assert_ptr_eq(efl_pack_content_get(widget, 3), inv);
}
EFL_END_TEST
EFL_START_TEST(pack_at1)
{
for (int x = -3; x < 3; ++x)
@ -449,9 +479,11 @@ efl_pack_linear_behavior_test(TCase *tc)
tcase_add_test(tc, pack_before1);
tcase_add_test(tc, pack_before2);
tcase_add_test(tc, pack_before3);
tcase_add_test(tc, pack_before4);
tcase_add_test(tc, pack_after1);
tcase_add_test(tc, pack_after2);
tcase_add_test(tc, pack_after3);
tcase_add_test(tc, pack_after4);
tcase_add_test(tc, pack_at1);
tcase_add_test(tc, pack_at2);
tcase_add_test(tc, pack_at3);