Summary: there are wrong indentation in the elm_image_file_set, so removed the tabs
Reviewers: Jaehyun_Cho
Reviewed By: Jaehyun_Cho
Subscribers: cedric, #reviewers, #committers
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D11988
Summary:
when trying to set file using url path twice, the second api call's return value is EINA_FALSE
since image obj has already has same file path. After applying Efl.File interface, the behavior is changed compared to before.
both of the return values should be EINA_TRUE.
@fix
ex)
Eina_Bool ret1, ret2;
ret1 = elm_image_file_set(image, "http://sameurl/image.jpg", NULL);
ret2 = elm_image_file_set(image, "http://sameurl/image.jpg", NULL);
ret1 and ret2 should be EINA_TURE
Test Plan:
1. call elm_image_file_set api with same url path
2. see the return value
Reviewers: Hermet, kimcinoo, jsuya
Reviewed By: Hermet
Subscribers: bu5hm4n, cedric, #reviewers, #committers
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D11979
Summary:
when elm_image_preload_disabled_set(img, EINA_TRUE) is called before file set.
The image preload is not canceled, because the function will be returned since the image is not loaded.
so preload disabled api is fixed to work even if it is called before file set.
@fix
Reviewers: Hermet, kimcinoo, jsuya
Reviewed By: Hermet
Subscribers: cedric, #reviewers, #committers
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D11969
Summary:
Some applications have used "clicked" smart callback from elm_image which
does not have an image in it.
To keep backward compatibility, hit_rect needs to be resized properly to
call smart callback function.
@fix
Reviewers: Hermet, jsuya, kimcinoo
Reviewed By: Hermet
Subscribers: cedric, #reviewers, #committers
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D11840
Summary:
In D11392, fixed to call file_unload when doing memfile_set.
Therefore, "load,error" callback was called while unloading object
that was not loaded when first load with memfile_set.
So fix it to avoid unnecessary unloading.
Test Plan:
{F3871804}
cp ./test_imge.c ./efl/
cd efl
gcc -o test_image test_image.c -g `pkg-config --cflags --libs elementary`
./test_image
Loading image...
Async file load failed.
Image is ready to show.
Reviewers: Hermet, kimcinoo, herb
Reviewed By: Hermet
Subscribers: cedric, #reviewers, #committers, zmike
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D11758
these did not even look at aspect hints when calculating sizing. that
means any attempt to set them would lead to... nothing useful. this
handles horiz/vert/both cases (as best as is possible).
@fix
This reverts previous commit and fixes it in the box layout to respect
aspect in elm boxes. note - this probably needs doing in other
containers too like table...
Revert "elm icon/image efl ui image - respect aspect hints at all if set"
these did not even look at aspect hints when calculating sizing. that
means any attempt to set them would lead to... nothing useful. this
handles horiz/vert/both cases (as best as is possible).
@fix
Summary:
The size of internal image could be bigger than the size of efl_ui_image
with following code.
image = elm_image_add
elm_image_fill_outside_set(image, EINA_TRUE);
If the internal image object is 300x300, and efl_ui_image is 360x77, then
the internal image object will resize to 360x360 which is bigger than the
size of efl_ui_image.
This is a compatibility issue. This patch will make efl_ui_image work as
before commit 8cb6c3e Elm_image: implement 'scale_type' and 'scalable'...
Test Plan:
This is old example to reproduce the problem.
{F3859361}
This is newly added example to check if this patch breaks compatibility or not.
{F3859390}
You can use the example with following image.
{F3859391}
This is result before applying this patch.
{F3859388}
This is result after applying this patch.
{F3859389}
The translucent rectangle is the size of the efl_ui_image.
As you might be noticed, only FIT_WIDTH (the 4th one of each row),
and EXPAND (the 6th one of each row) are different.
One more difference the 1st one of 2nd row; NONE.
F.Y.I. and for quick understanding of example.
The 1st row efl_ui_image is bigger than internal image.
The 2nd row efl_ui_image is smaller than internal image.
From the left the scale type is NONE, FILL, FIT, FIT_WIDTH,
FIT_HEIGHT, EXPAND, and TILE.
Reviewers: Hermet, jsuya, herb
Reviewed By: Hermet
Subscribers: cedric, #reviewers, #committers
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D11587
this enables the existing looping functionality only when playback_loop
is set (which is always set for legacy widgets)
fix T8589
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D11308
this just calls efl.player::playing_set any time autoplay is true and
the internal image object is preloaded
ref T8589
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D11306
Summary:
3dc3deb patch was changed to start at 1 rather than 0.
gif image starts at 1, not 0.
Test Plan: N/A
Reviewers: Hermet, kimcinoo
Reviewed By: Hermet
Subscribers: cedric, #reviewers, #committers
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D11474
Summary:
this should operate on the internal image object to reflect the file
state there instead of the outer object
Reviewers: kimcinoo, Hermet
Reviewed By: Hermet
Subscribers: cedric, #reviewers, #committers
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D11396
Summary:
If _icon_standard_set() fails, _icon_freedesktop_set() is tried.
This was causing missing icons in the homescreen example, which uses
application icons which are obviously not present in the default theme.
Thanks to @bu5hm4n!
Test Plan: The homescreen sample application from the examples repository now correctly shows all missing icons.
Reviewers: bu5hm4n, zmike
Reviewed By: zmike
Subscribers: cedric, #reviewers, #committers, bu5hm4n
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D11381
Summary:
If memfile_set does not remove prev file information, it is not possilbe to
load image using the same file information after memefile_set.
It means that below line 3 does not work because the same file information
remains for Efl.Ui.Image_Legacy.
1 | elm_image_file_set(obj, "1.jpg", NULL)
2 | elm_image_memfile_set(obj, img, size, "jpg", NULL)
3 | elm_image_file_set(obj, "1.jpg", NULL)
This patch removes line calling _efl_ui_image_file_set_do becasue it is called
in efl_file_unload > _efl_ui_image_efl_file_unload.
Test Plan:
[Sample Code]
{F3848315}
[Reproduce Step]
1. File2
2. Memfile
3. File2
Reviewers: Hermet, jsuya
Reviewed By: Hermet
Subscribers: cedric, #reviewers, #committers
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D11392
Summary:
Assigning a result of integral division to a double type variable
is not useful for division calculation.
Test Plan: N/A
Reviewers: Hermet, YOhoho
Reviewed By: YOhoho
Subscribers: cedric, #reviewers, #committers
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D11344
Summary:
This reverts commit 93bd970259.
efl.ui.image using prev and current inner image object.
Unloading the efl.ui.image class can be unloaded up to the prev image.
And because efl.ui.image is using the image caching feature together,
it may get unexpected errors. Therefore, revert this patch.
Test Plan: N/A
Reviewers: Hermet
Reviewed By: Hermet
Subscribers: cedric, #reviewers, #committers
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D11157
Summary:
We have checked that unload is not called even if different files
call again elm_image_file_set on the same object.
If file_set is called repeatedly, I think a potential error can occur.
So, modify to call unload when doing file_set by referring to efl_ui_zoomable.
Test Plan: N/A
Reviewers: Hermet, zmike
Reviewed By: zmike
Subscribers: cedric, #reviewers, #committers
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D11148
As efl_gfx_image_expand specification,
it scales the image to cover the entire object area on one axis
while maintaining the aspect ratio though image may become larger than the object.
Thus, this option must work as one of fit_width / fit_height
by detertimining either way.
Previously, it was logically wrong.
@fix
I accidentally inverted this; the frame timing needs to be divided by
the playback speed to have the correct time here
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D10147
this is a bit of an overhaul wherein the existing 'play' mechanics are
all inverted. 'pause' is a state which stops playback but does not affect
the playback_position property.
this patch also includes implementations of Efl.Player::playing for
a couple classes which (now) only implement pause, as this is a requirement
for the objects to actually activate their animations
test cases:
* unit tests
* all elm_test animation cases
* elm_test video
* rage
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D10114
efl.playable implements a number of properties which are also present
in efl.player. playable was intended to be separate, so enforce this
split in all classes which use player
ref T7877
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D10109
at first i tried to implement that with composition, however, this does
not work, caused by the fact that the edje_object does not implement
efl.gfx.image nor load controller. which would mean i would have to
differentiate based on the type what kind of composition i would attach,
additionally, i would have to write an additional object which would
implement the correct behaviour.
To shortcut this overdone approach, this commit simply implements the
APIs in the image object.
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D10068
the API calls have not been implemented, this revision implements these
APIs as redirects to the image if those are a edje object.
Normally this should be a calling the legacy edje API. However, this is
here really hard as imitating the correct callback behaviour is hard.
And the correct behaviour with the eina value type is also just leading
to copying the implementation from edje. So in order to keep the amount
of code low here, this just uses the efl-api to redirect the requests.
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D9989
this removes the property from the image class to use the properties
from the interface
ref T7873
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9704
this is ideally a bit more clear and flexible than the previous enum names
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9691
this is effectively the same thing. no uses of this functionality exist anywhere
ref T7873
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9688
these methods exist only to trigger efl_canvas_group_change on geometry
change and apply image sizing policies, there's no need to duplicate existing
functionality as well
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9687
this changes image internals to use the more standardized group_calc method
of sizing and causes all previous operations on the image which would have
resulted in an immediate recalc to instead defer the calc until the
group_calc function is called
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9686
these function the same as the min size hint versions and enable
distinction between internally-set max size hints and user-set max size
hints
@feature
ref T8122
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Differential Revision: https://phab.enlightenment.org/D9553
unified widgets should use unified api internally and also be more explicit
about which min size hint (restricted or user) is being set in order to improve
readability of code
when unified widgets also implement legacy wrappers, legacy api should be used
for the legacy objects
no functional changes
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9495
efl_ui_clickable_util was only for efl_input_clickable interface,
but there can be more cases which want to connect object event
to specific action interfaces (such as scrolling) in the future.
For that extension, efl_ui_action_connector seems better.
ref: T7847
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9486
Summary:
elm_layout_sizing_eval is a legacy function which should not need to be called
on new widgets
Reviewers: segfaultxavi, bu5hm4n
Reviewed By: bu5hm4n
Subscribers: segfaultxavi, cedric, #reviewers, #committers
Tags: #efl_widgets
Maniphest Tasks: T8059
Differential Revision: https://phab.enlightenment.org/D9434
Summary:
Efl.Gfx.Image_Orientable and Efl.Ui.Layout_Orientable have same property name.
So when class extends both interfaces, it makes conflict.
Relates to T7924
Reviewers: woohyun, segfaultxavi
Reviewed By: segfaultxavi
Subscribers: cedric, #reviewers, #committers
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D9299
Summary:
when triggered before the image is loaded, this code cannot be run
@fix
Depends on D8978
Reviewers: devilhorns
Reviewed By: devilhorns
Subscribers: cedric, #reviewers, #committers
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D8979
Summary:
This will help disambiguate later on when we rename Efl.Ui.Direction
to Efl.Ui.Layout_Orientation.
Relates to T7919
Test Plan: Everything still builds and passes tests.
Reviewers: zmike
Reviewed By: zmike
Subscribers: cedric, #reviewers, #committers
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D8934
Summary:
And the Efl.Orientation interface -> Efl.Gfx.Orientable
(with proper c_prefix so it is not too cumbersome to use from C).
Also, turned the theme_rotation_apply() parameter into an int to avoid confusion.
Fixes T7919
Depends on D8912
Test Plan: Everything continues to build and pass tests
Reviewers: zmike, bu5hm4n, cedric, Hermet, Jaehyun_Cho
Reviewed By: zmike
Subscribers: #reviewers, #committers
Tags: #efl
Maniphest Tasks: T7919
Differential Revision: https://phab.enlightenment.org/D8926
Summary:
This is similar to how it is in Evas, and simplifies the Efl.Orientation
interface, which only needs one property now.
Relates to T7919
Test Plan: Everything builds and tests pass. There's only one example of efl_orientation_set() so there's not much to test yet.
Reviewers: zmike, bu5hm4n, cedric, Hermet, Jaehyun_Cho
Reviewed By: zmike
Subscribers: #reviewers, #committers
Tags: #efl
Maniphest Tasks: T7919
Differential Revision: https://phab.enlightenment.org/D8912