Commit Graph

166 Commits

Author SHA1 Message Date
Minkyu Kang 175905ce94 image: remove EINA_UNUSED
Summary:
parameter is used

Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>

Reviewers: Hermet, seoz, cedric

Reviewed By: cedric

Subscribers: seoz

Differential Revision: https://phab.enlightenment.org/D3718

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2016-02-29 15:40:06 -08:00
Minkyu Kang b08c67580e elm_image: fix wrong API call for scaling
Summary: Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>

Reviewers: cedric, Hermet

Reviewed By: Hermet

Subscribers: seoz

Differential Revision: https://phab.enlightenment.org/D3724
2016-02-23 20:28:21 +09:00
Davide Andreoli 1e78bc662b Elm Image: fix usage of animated gif on the same image object more than one time
This patch @fix this usage example:

0. image obj create
1. file_set(an animated gif)
2. animated_set(TRUE) + animated_play_set(TRUE) to make the gif play
3. file_set(a normal image)
... at this point elm_image is confused because it still think that the image is animated
4. file_set(an animated gif)
5. animated_set(TRUE) + animated_play_set(TRUE) to make the gif play
...this now do not work because elm think that the image is already animated
2016-01-25 22:17:36 +01:00
Marcel Hollerbach 860baa4657 Elm config: use a name instead of elm_widget_type_get
Summary:
The use of elm_widget_type_get here is pretty harmfull, for the usecase
of inheriting a widget elm_widget_type_get is something else than
before. But the key binding should still work.

@fix T2891

Reviewers: tasn

Reviewed By: tasn

Maniphest Tasks: T2891

Differential Revision: https://phab.enlightenment.org/D3470
2015-12-21 12:57:15 +00:00
Mike Blumenkrantz d0c95e2eef image: do not block null image loading in the elm layer
this is handled correctly in evas. checking load errors from
the engine/loaders is sufficient, but the printed ERR messages
for these cases have been improved

partially reverts 865383aa0da5d1eb6d29f4ed5447a73f63800a33
reverts ee7d5425628942a45e23a2cb6be253db8ec0b3fd
ref 840dcc618ead292414b0de64a7a3ae38d778311f
ref a915229dc87606472480a8b2eacce9514055ac27

fix Titalia
2015-12-20 11:10:41 -05:00
Jean-Philippe Andre 01f5083cab image: Lock access to thread variables
Fixes CID 1343345 "Data race condition"
2015-12-16 20:46:09 +09:00
Amitesh Singh dcc066569f image: use eo_isa for checking object types instead of string comparison 2015-10-22 22:14:40 +05:30
Amitesh Singh f1773531c3 image: remove unused variables 2015-10-13 09:08:01 +05:30
Cedric BAIL b7f6a004fa elm_image: let's not trigger confusing update add.
Elm_Image rely on Evas_Image ability to rotate content. There is no
pixels manipulation involved that require an update_add here. In fact
this cause a bug where the content would disapear due to evas trying
to get some pixels data that are not where it think they are.
2015-10-12 16:00:04 -07:00
jiin.moon fcb26c4b91 elm_image : call the evas_object_image_load_error_get() before calling the image_preload api
Summary:
If file path is wrong, don't need to call the image preload api.

And the result of evas_object_image_load_error_get api is not correct
after calling the image_preload api.
I will check more about it.

Reviewers: cedric, Hermet, jpeg

Reviewed By: jpeg

Differential Revision: https://phab.enlightenment.org/D3039
2015-09-15 10:25:31 +02:00
jiin.moon b7310bdb87 elm_image: fix image preload issue
Summary:
There are two issues about preload
1. elm_image_preload_disabled_set api does not work.
    Always returned before call the evas_object_image_preload()

2. image preload does not work at file_set time.
    If image's show property is not TRUE, do not call evas_object_image_preload() at file_set time.
    But there is no action when image's show property will be TRUE after call the file_set api.

@fix

Reviewers: Hermet, jpeg

Differential Revision: https://phab.enlightenment.org/D2989

Signed-off-by: Jean-Philippe Andre <jp.andre@samsung.com>
2015-09-04 13:51:58 +09:00
Subodh Kumar 85e55ed89d elm: simulate the clicked event over the object only.
Summary:
Two different behaviour are observed with clicked event.
1. When scroller is not present:
   a. Mouse down over object,
   b. mouse move outside the object
   c. mouse up, clicked happens
2. When scroller is  present:
   a. Mouse down over object,
   b. mouse move outside the object
   c. mouse up, clicked NOT happens

So clicked callback should happen over the object only i.e when mouse move out of the objcet clicked should be ignored, and behaviour will be consistent

@fix

Test Plan: NA

Reviewers: shilpasingh, cedric

Differential Revision: https://phab.enlightenment.org/D2856

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2015-07-29 21:18:20 +02:00
ChunEon Park f8662bc2a0 image: fix a crash, 0 divide problem.
if the gif is invalid animated image,
the frame count could be 0.

@fix
2015-07-09 11:09:59 +09:00
Avi Levin 04ee4036d0 elm_image, elm_colorselector: porting evas smart callbacks to eo 2015-07-02 08:04:03 +03:00
Daniel Kolesa 3904cc7175 elm: constify Eolian methods correctly because of recent Eolian changes 2015-06-25 12:21:00 +01:00
Vitor Sousa c875a437bd elm_image: Solve clash on the meaning of "animated"
Summary:
Both Elm_Image and its base interface Efl.Image have a property named
"animated".
The meaning for Efl.Image is whether or not the image has animation.
On the other hand, Elm_Image use it to set whether an image, which supports
animation, is to animate itself or not.
Thus Elm_Image have another property (animated_available) to tell whether the
image have animation or not, making it even more confusing.

Renamed the "animated" property of Elm_Image to "animated_enable" to make
the intended meaning clearer.
Also replaced the "animated_available" property with the "animated" property
from the Efl.Image interface, since both refers to the same thing, in order
to reduce the API.

Added implementations of the legacy methods for backward compatibility.

Address the issue:
- Elm image and the image interface clash because of the meaning of "animated".
Specified in the page:
https://phab.enlightenment.org/w/efl_interfaces/

Reviewers: felipealmeida, tasn

Subscribers: raster

Differential Revision: https://phab.enlightenment.org/D2354
2015-06-17 10:17:19 +01:00
Tom Hacohen 27b72840c8 Adjust usage of eo_constructor() according to recent changes. 2015-05-20 13:03:28 +01:00
Carsten Haitzler c702668796 elm - fix repeat event fix - thanks dave
this fixes 2d64175722db124b1e4be6c735503f29e4453015 which was a fix to
elm image always repeating - which it shouldn't
2015-04-15 11:03:12 +09:00
Jean-Philippe Andre bce0487d55 elm_image: Do not open file again if already opening (async) 2015-04-13 20:30:27 +09:00
Jaeun Choi 62f95be91c elm_image: return EINA_FALSE if the data source is NULL in elm_image_memfile_set
@fix
2015-04-10 18:31:58 +09:00
Jean-Philippe Andre fc2980cead elm_image: Fix potential race conditions in async mode
Without any locking or thread-safe mechanism, the previous implementation
would have failed as soon as too many file_set() happened on the same
object. Indeed, file_set() can happen while the async open thread is
running. I shouldn't have blindly listened to Cedric :P
2015-04-10 16:46:56 +09:00
Carsten Haitzler ddfa4cb977 elm image - stop repeating events by default - wrong
why have elm image repeat events always (and unable to stop it)? this
is neither useful nor convenient. it's just painful. it makes images
not behave like prety much every object. they already are set up to
capture events - then do it normally.

@fix
2015-04-08 09:54:25 +09:00
Jean-Philippe Andre 8a801c995f elm_image: Simplify file_get 2015-04-06 15:54:50 +09:00
Jean-Philippe Andre 4a0202b40d elm_image: Use Efl.File interface for mmap_set 2015-04-06 15:54:33 +09:00
Jean-Philippe Andre 3e7aff9501 elm_image: Implement async file open
Summary: This implements the interface Efl.File.async.{set,get,wait}

Reviewers: cedric, raster, tasn

Differential Revision: https://phab.enlightenment.org/D2262
2015-04-06 15:54:32 +09:00
Daniel Juyung Seo 53fafc464e image: Initialize parameters in case of it just returns without assigning any value.
In this way, callers does not need to consider initializing the
parameters for their local variables.
2015-03-16 23:19:20 +09:00
Hosang Kim 74b6b65426 elm_image: Fix to initialize variable.
Summary: If _elm_image_object_size_get fails, w and h have garbage value.

Test Plan: no

Reviewers: seoz, Hermet, cedric, raster

Differential Revision: https://phab.enlightenment.org/D2163
2015-03-16 21:18:28 +09:00
kabeer khan 97cefca273 elm_image: changed orient_set code to use evas_object_image_orient_set API
Summary:
evas_image_orient_set is a newly added API to set orientation of evas image.
Using this API to set orientation of image widget.
Also removed Elm_Image_Orient enums and replaced it with Evas_Image_Orient enums.

Signed-off-by: kabeer khan <kabeer.khan@samsung.com>

Reviewers: raster, seoz, cedric

Differential Revision: https://phab.enlightenment.org/D1987

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2015-02-20 14:31:12 +01:00
Youngbok Shin 10fae20d33 elm_image: fix elm_image_memfile_set API fail when elm_image widget is not visible.
Summary:
It could success only when the widget was visible.
The API must return EINA_TRUE if buffer and size has no problem, not visiblity of widget.
@fix

Reviewers: Hermet, woohyun, jpeg

Differential Revision: https://phab.enlightenment.org/D1917

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2015-02-03 10:17:50 +01:00
Stefan Schmidt 26131fedc4 elm_image: Add missing semi-colon to terminate line.
No compiler warning for this because the macro was terminated with it.
It still looks wrong without it and does no harm.
2015-01-23 12:45:33 +01:00
Stefan Schmidt 969f9c1970 elm_image: Fix memory leak in GETDAT macro.
Free data2 on error path.

CID: 1265609, 1265610, 1265611, 1265612
2015-01-23 12:43:49 +01:00
Mike Blumenkrantz 0db8a01ab1 image now implements edje object size functions
Edje.Object.size_min.get;
      Edje.Object.size_max.get;
      Edje.Object.size_min_calc;
      Edje.Object.calc_force;

fixes all image-in-edje sizing issues/errors
2015-01-21 15:17:00 -05:00
Mike Blumenkrantz af7cfe1d6b image animation functions now work as expected for edje images 2015-01-21 15:17:00 -05:00
Carsten Haitzler a89f3d267c elm image - fix image rotation in non-common cases
this fixes d6f4040d0c62c220f2339d2a57126fde43e85e19 for the non-common
path that normalizes then applies new orientation

@fix
2015-01-13 08:53:14 +09:00
Carsten Haitzler 97e625c68c elm - elm image orientation api fix - major bug in implementation
@fix

The elm image orient_set api looks like it is a state, and it is
documented to SET the orietnation, but the code actually DOEs that
orientation when you set it. so docs and api name didnt match
functionality at all. this was bad an an oversight. you didn't notice
until you set orientation multiple times to an image. this fixes the
implementation to be as documented - a state that is applied and
remains that way until set to something else. setting to the same
orientation has no efect as with color, size, etc. etc. in evas.

you could look on this as an api break, but then either the docs
change AND api name changes to match the code, or code changes to
match the docs. we don't keep bug compatibility in efl and in this
case i'm making the call to break the behavior of a  function as it
was broken already with respect to name and docs.
2015-01-12 11:31:43 +09:00
Jee-Yong Um 4ade3552db elm_image: Fixed to have exact size using elm_image_fill_outside_set()
Summary:
There was a problem that image is stretched over its size
when elm_image_fill_outside_set() is applied.
This patch fixed that.

@fix

Reviewers: Hermet

Subscribers: Hermet

Differential Revision: https://phab.enlightenment.org/D1854
2015-01-08 15:47:24 +09:00
Mike Blumenkrantz 799171a0c8 elm_image now inherits edje signal emit
@feature
2015-01-06 15:19:26 -05:00
jiin.moon c3397d302b image: fix clipped image issue if x or y is less than zero
Summary:
After applying clipping patch about image on outside,
the width or height of the image be decreased
if x or y of an image is less than zero.
The way to calculate width/height has changed.

This fixes a side effect added in 2839881f37ea85b3469d8fd37cfaa4f9d67458fa

Reviewers: Hermet

Differential Revision: https://phab.enlightenment.org/D1810
2014-12-24 14:10:05 +09:00
Daniel Juyung Seo 82eb0a210c image: Fix formatting for the latest commit 283988. 2014-12-19 02:36:16 +09:00
jiin.moon fe3bacf30a elm/image: Fix an unclipped issue about image bigger than object size
Summary:
When resizes an image
if "fill_inside" and "aspect_fixed" in Elm_Image_Data struct are "TRUE",
extra width or height go outside of the object area.
The width or height on outside will be clipped.
@fix

Reviewers: Hermet

Differential Revision: https://phab.enlightenment.org/D1794
2014-12-18 17:53:44 +09:00
Lukasz Stanislawski 2ca1f8a75a atspi: properly include at-spi headers.
Summary:
Change requested by TAsn. Previuosly AT-SPI headers were kept private
and included directly into elementary source code. From now on,
AT-SPI headers can be included from Elementary.h public header, however
will be marked as beta APIs.

Commit includes following changes:
* include all atspi headers into new elm_interfaces.h header.
* marking all at-spi interfaces methods/properties as @protected.
* wrap all common headers with EFL_BETA_API_SUPPORT.
* make some common APIs visible in lib, by adding EAPI attribute
  (if someone decides to use beta APIs).

Test Plan: out-off tree build with gcc, g++

Reviewers: tasn

Reviewed By: tasn

Subscribers: seoz, q66, kuuko

Maniphest Tasks: T1721

Differential Revision: https://phab.enlightenment.org/D1528
2014-10-17 16:57:26 +01:00
Mike Blumenkrantz 8391f8a860 elm_image no longer crashes when deleting the image from a download callback 2014-10-09 16:52:17 -04:00
Tom Hacohen 7629c147eb Eo related: Change according to recent changes in eo_add().
For more info check out a7560dbc61 in
the EFL tree.
2014-09-25 17:39:34 +01:00
Tom Hacohen 307e03c1b1 Image: Use image interface. 2014-08-21 11:04:28 +01:00
Tom Hacohen 4cc392ce5e Image: Use file interface. 2014-08-21 11:04:28 +01:00
Lukasz Stanislawski 09b9ef0bc0 atspi: expose more actions through atspi bus.
Summary:
Main purpose of exposing widget actions and keyboard shortcuts
is to allow accessibility clients to implement alternative methods
of GUI navigation.

Reviewers: z.kosinski

Reviewed By: z.kosinski

Subscribers: seoz

Differential Revision: https://phab.enlightenment.org/D1227
2014-07-25 11:58:16 +02:00
Lukasz Stanislawski f9ad7f921a atspi: expose elm_image "activate" action through d-bus 2014-07-15 16:45:55 +02:00
Yakov Goldberg 4f0bc40b91 image: fix segv in elm_image_file_set() 2014-07-08 16:34:23 +03:00
Zbigniew Kosinski 9ce23f0004 atspi:Set roles for widgets
Reviewers: stanluk, m.jagiello, raster

Differential Revision: https://phab.enlightenment.org/D930
2014-06-11 11:07:16 +09:00
Tom Hacohen efa41c7d75 Elm: Update code to use the new class names generated by eolian. 2014-06-03 11:54:44 +01:00