Commit Graph

89 Commits

Author SHA1 Message Date
Jean-Philippe Andre d504284dd2 efl: Rename Efl.Event.XX to Efl.Input.XX
This removes:
 Efl.Event interface

And renames:
 Efl.Event.Input -> Efl.Input.Event
 Efl.Event -> Efl.Input.Event (merged)
 Efl.Event.Pointer -> Efl.Input.Pointer
 Efl.Event.Key -> Efl.Input.Key
 Efl.Event.Hold -> Efl.Input.Hold

This also moves some interfaces from efl/ to evas/ where they
belong better.

This allows renaming Eo_Event to Efl_Event.
2016-08-26 10:18:01 +09:00
Gustavo Sverzut Barbieri 86e87b2fd9 efl_io_queue: basic class to interact with Efl.Io interfaces.
The use of low-level interfaces such as Efl.Io.Reader and
Efl.Io.Writer are not that user-friendly as they can handle partial
data.

Classes such as Efl.Io.Copier makes them easy to use, but they need a
reader (source) or writer (destination) and in our examples we used
fixed buffers or some existing streams (stdin/stdout/stderr,
networking...).

However, if interactively we need to produce some data to be sent,
such as implementing some networking protocols, we'd have to write our
own Efl.Io.Reader and Efl.Io.Writer classes to handle the buffering.

Not anymore! With Efl.Io.Queue you can write stuff to it and it will
buffer to memory. Once stuff is read, it will automatically remove
those bytes from buffer.
2016-08-23 20:17:13 -03:00
Gustavo Sverzut Barbieri 5d4688679e efl.io: introduce basic interfaces and classes.
These interfaces allows generic operations on objects that can store
or provide data, such as a file or a buffer.

With well defined interfaces and events we can create code such as
Efl.Io.Copier, that will link a source with a destination and
progressively copy data as they appear.
2016-08-22 18:25:14 -03:00
Stefan Schmidt 00227b81f4 build: do not dist now longer available files
Another cleanup for commit dd1d3f0d2d. These
makefiles are now longer available better not try to dist them.
2016-08-02 08:32:13 +02:00
Jean-Philippe Andre d931c53919 efl: Remove eo struct Efl.Gfx.Color
So far this was protected behind ifdef EO_API_SUPPORT. It also
was not used internally. Dropping this before the release, since
we will soon have a (hopefully) better solution to handle various
color representations.
2016-06-28 10:52:28 +09:00
Jean-Philippe Andre 07613bf2f6 config: Simplify Efl.Config API, make C helpers only
This removes the mixin functions and uses static inline functions
instead. Much cleaner, looks the same to C devs.
2016-06-24 17:10:21 +09:00
Jean-Philippe Andre 47a1fae200 efl: Introduce general Efl.Config API
This is to port elm_config to EO APIs.

The current implementation relies on the legacy API, by
simply forwarding calls.

The new API is simply efl_config_set("config_name", value)
where value is an Eina_Value (aka. generic_value).
The C interface proposes a few helpers like config_int_set,
config_double_set, etc...

Unfortunately at the moment, not all config options are
supported, as some rely on more complex types:
- lists
- color class and multiple arguments
- unset functions
- enums

Profiles are also not handled at this point.

@feature
2016-06-24 16:57:04 +09:00
Stefan Schmidt fffe6dc7b8 build: clean generated js and lua files manually to avoid problems with CLEANFILES
We hit another argument too long error with CLEANFILES. Moving the generated
files for js and lua into separated variables and cleaning them manually fixes
the issue.
2016-06-21 17:07:13 +02:00
Jean-Philippe Andre f2fafb8044 Evas: Move BiDi type to Efl.Text
This renames it to Efl.Text.Bidirectional_Type.
2016-06-17 11:37:39 +09:00
Jean-Philippe Andre d97c07d675 Efl: Move Efl.Canvas to efl/interfaces
Not sure this is a good name for this interface, but it
definitely doesn't belong inside lib/evas/

Thanks Jiyoun for the question / report :)
2016-06-16 10:57:56 +09:00
Stefan Schmidt 93eadd76d6 build: split EXTRA_DIST files in src/ off from DISTFILES and handle separately
This is again to avoid the "Argument list too long" error we are hitting more and
more now. Given we just merged elementary, emotion generic players, evas generic
loaders and elm_code it is not surprising we are hitting it again.

This time the number of files being hold in DISTFILES has just grown to big so a
make dist was no longer possible. If one looks at what the DISTFILES variable
from automake holds you can image it grows a lot with all the source files plus
generated files we have in tree now.

DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)

To cut off a big chunk but still keep all the other automagic in place for
SOURCE files I went and renamed the EXTRA_DIST in src/ to EXTRA_DIST2 and handle
the files in a dist-hook now.

Another thing to note here is that this also only happens as we have the one big
Makefile with includes. If we go back to per directory Makefiles this problem
should vanish as well. In any case we need a solution for 1.18 now and this is
what I have to offer. If you have a cleaner solution in mind feel welcome to
test it out and if everything we need keeps working (make, make examples,
make check, make benchmark, make dist and make distcheck) go ahead.
2016-06-10 13:04:18 +02:00
Ji-Youn Park 2bf508836d Efl.Gfx.Size.Hint: add Efl.Gfx.Size.Hint skeletton
create Efl.Gfx.Size.Hint skeletton and change elm_win eo.
remove size_step and size_base API from elm_win
and inherit from Efl.Gfx.Size.hint
2016-06-02 16:48:17 +08:30
Ji-Youn Park 0e6139e487 efl_screen: create efl_screen interface
elm_win have three feature releated with screen.
1. screen_rotation_get
2. scrren_size_get
3. screen_dpi_get
so create efl_screen interface, and elm_win implement that interface
2016-06-01 15:17:31 +08:30
Jean-Philippe Andre 0a27c78a33 Evas events: Split pointer events
This is going back to the same idea as legacy. We will have
events such as:
- move
- down
- up
- in
- out
- wheel
- cancel ("new" - very rare)

Now the question is whether/how we should divide "multi" events
which start from the 2nd finger from standard mouse events. The first
multitouch finger should by default look like a mouse event.
2016-05-31 19:03:04 +09:00
Jean-Philippe Andre c68f71239c Evas events: Add EO APIs for lock & modifiers
This moves Efl.Pointer.Event back to Evas. Originally I wanted
to share this class with Ecore but eventually I didn't need to
do so, since only ecore_evas (which depends on evas) really needs
access to these.

The internal data struct is not moved out of efl (yet?)
2016-05-31 19:03:04 +09:00
Jean-Philippe Andre c06cdadca2 Evas: Fix compilation warnings (enum implicit cast)
Moving enums to Efl renames them but keeps the value the same.
2016-05-31 19:03:04 +09:00
Jean-Philippe Andre 645a7b7d6c Efl: Add storage class Efl.Pointer.Event
This object is the data carried over in an event data pointer.

The private data should be accessible by Ecore and Evas, but
not externally. This means we should be able to easily extend
the feature set, adding more and more information, without
breaking API / ABI.

Also, this should allow applications to create fake input
events easily without exposing our internal structures, or
functions with more and more parameters (such as feed multi).

This is only a storage class, shouldn't contain any logic.
In the future, some logic may be added for gestures support
for instance, or input smoothing / resampling (eg. if input
frequency is 90Hz and screen refresh rate is 60Hz).

The aim is to replace:
- Evas_Event_Mouse_Xxx
- Evas_Event_Multi_Xxx
- Ecore_Event_Mouse_Xxx

We might want to also support Axis, Gestures, etc... with the
same model or even same storage class.
2016-05-31 19:03:04 +09:00
Jean-Philippe Andre ce5688a388 Evas: EO-ify Evas_Device and partly move to Efl
So, this is not a very clean solution, but this mostly
makes Evas_Device an Eo object of class Efl.Input.Device.
Since evas_device relies on some Evas knowledge (evas
callbacks, canvas private data), it can't be fully moved
to lib/efl/.

Making the input device an interface rather than a class
was also not a great solution, as the goal is to share
the data structure around EFL internals (Ecore and Evas).
2016-05-31 19:03:04 +09:00
Jean-Philippe ANDRE d0f141077e Efl: Add Efl.Part and switch to it
This should now fix the part API usage once and for all.
EFL should have no part name in any of its APIs beyond
the Efl.Part interface.

Part proxy objects (may be real objects) have a lifetime
of only one function call, in a fashion similar to eo_super.

@feature
2016-05-24 18:50:58 +09:00
Felipe Magno de Almeida e3c8b280c6 c++: Reorganized C++ binding generation
Moved all generation to a single Makefile_Cxx.am file instead of
throughout the whole project. And fixed C++ generation on Elementary
after elm merge.
2016-05-23 15:05:50 -03:00
Tom Hacohen b0cd0a3b4b Efl gfx gradient: Remove the no longer needed .Base hack. 2016-05-10 16:30:18 +01:00
Tom Hacohen 0ca59b0402 Efl gfx: Remove the no longer needed .Base hack. 2016-05-10 12:25:44 +01:00
Tom Hacohen 138d4e1353 Efl model: Remove the no longer needed .Base hack. 2016-05-10 11:36:35 +01:00
Yeshwanth Reddivari f7e1be2062 spin interface: common interface for flipselector and spinner
Summary:
Added common interface for flipselector and spinner.
Implemented APIs of spinner like min_max_set, step_set, value_set etc in flipselector.

Test Plan: elementary_test

Reviewers: raster, jpeg, singh.amitesh, woohyun, SanghyeonLee, cedric

Reviewed By: cedric

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

Signed-off-by: Cedric Bail <cedric@osg.samsung.com>
2016-04-29 18:56:51 -07:00
Jean-Philippe Andre 902950018b Efl: Introduce Efl.Container and unify APIs
This removes Efl.Pack_Named which had a terrible name,
removes Elm.Container which should have been renamed
Efl.Ui.Container anyway, and introduces an interface
Efl.Container instead.

The hierarchy tree is now changed as objects don't inherit
from Efl.Container (it's an interface, not a regular class)
but only implement it. Obviously it is very easy to
reintroduce an Efl.Ui.Container parent class if we need it,
but I guess it should have some actual logic. It's basically
part of what Elm.Widget already does.

Some function names have been modified to look better in C
with the efl_content prefix.

@feature
2016-04-26 11:36:23 +09:00
Jean-Philippe Andre 2d946d03ae Efl.Pack: Rename methods and properties
- Children are now contents
- Efl.Pack_Layout is now a separate class and
  merges Pack_Engine.
- Removed dumb class Efl.Pack_Item
- Updated docs
- Added pack_ or grid_ prefixes to some methods
2016-04-20 11:15:53 +09:00
Jean-Philippe Andre 24eccb6d62 Efl.Ui.Box: Implement way to override layout function
So, since we don't have function pointers, all the solutions
to reimplementing the layout function are quite convoluted:

1. use events
2. reimplement layout func
3. use an extra object
4. use a generic class (non instanciated)

Promises don't apply here (layout will run multiple times).

Problems:

1. Multiple event callbacks will be called, resulting in
   potential performance impact, extra events, etc...
   Also, there is no way to define standard implementations
   that would be provided by the framework.

2. Reimplementation of a function requires extra EO work
   (create an EO class, etc...), doesn't allow on-the-fly
   change of the layout method.

3. Probably the best solution is to have an object implementing
   the layout. But this means creating an extra object along
   with the container.

4. To avoid the extra object, use a class, and reimplement
   a @class function. This unfortunately requires extra
   EO work.

Solution 4. has been selected, but it's not very nice...
2016-04-20 10:47:40 +09:00
Jean-Philippe Andre 57e64ee65b Efl: Add skeletton for new containers "Pack" API
I chose the name "pack" instead of containers because it
is shorter, and allows out-of-the-box short C names like
efl_pack_end() instead of efl_container_pack_end().

All Pack interfaces will use the same efl_pack eo prefix.

This is still work in progress.

@feature
2016-04-20 10:47:40 +09:00
Cedric Bail fdaedf2bff autotools: fix make distcheck. 2016-04-15 11:07:02 -07:00
Jean-Philippe Andre d1709a2b57 Efl: Rename flip and orient enums
Efl.Flip is now the enum, the interface is Flipable.
We could even use names like Efl.IFlip a la Java.

eo_prefix is used to have pretty names in C. legacy: null
is removed from the enums. orient_x0 is removed and only
defined in C with #define
2016-04-07 17:32:40 +09:00
Yeshwanth Reddivari 7f9036dce5 Interface: Progress - Add common interface for Slider and Progressbar
Summary:
Implement common interface efl_ui_progress and inherit slider and progressbar from common interface.
Currently legacy APIs will also call interface functions and later it can be deprecated.
This interface will be moved to EFL in src/lib/efl/interfaces when elementary is merged into efl.

Test Plan:
elementary_test -to 'slider'
elementary_test -to 'progressbar'

Reviewers: singh.amitesh, raster, tasn, felipealmeida, woohyun, cedric, jpeg

Subscribers: saurabhbunty, alok25

Differential Revision: https://phab.enlightenment.org/D3759
2016-04-07 16:50:57 +09:00
Yeshwanth Reddivari 98edbd23a4 Interface: Flip and orientation interface
Summary:
Added flip and orientation interface and used them in evas_image.
Removed efl_image_orientation_set API and used efl_orientation_set and efl_flip_set API.
In implementation part, converted enums back and forth in order to keep current implementation as it is.

Test Plan: src/examples/evas/evas-images5.c

Reviewers: singh.amitesh, raster, tasn, herdsman, woohyun, cedric, felipealmeida, jpeg

Subscribers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D3844
2016-04-06 10:46:39 +09:00
Carsten Haitzler 6291c61556 efl: vpath subsystem
this adds a core vpath subsystem to efl that allows paths like:

  ~/file.jpg
  ~user/file.jpg
  (:tmp/file.jpg
  (:config/file.jpg
  (:videos/file.mp4
  (:pictures/file.jpg
  (:app.config/mycfg.cfg

etc. to be translated/looked up. it is desitgned to be async and call
event callbacks when ready. the reason for this complexity is fo in
future also handle:

  file:///whatever/file.jpg
  http://blah.com/file.jpg
  https://blah.com/file.jpg
  ssh://blah.com:~/file.jpg

etc.

@feature
2016-04-05 16:22:59 +09:00
Carsten Haitzler 13ecefe670 Revert "XXX - reword me when done"
This reverts commit bc23814614.
2016-04-01 09:58:02 +09:00
Carsten Haitzler e446fcc2db Revert "XXX"
This reverts commit 5e9d838e60.
2016-04-01 09:58:02 +09:00
Carsten Haitzler 5e9d838e60 XXX 2016-04-01 08:57:09 +09:00
Carsten Haitzler bc23814614 XXX - reword me when done 2016-04-01 08:57:09 +09:00
Stefan Schmidt 0a03e63350 build: keep our CLEANFILES tidy to avoid argument list too long during clean
We have been putting the generated eo files and BUILT_SOURCES into CLEANFILES
several times. So far this have not been a real problem but with the elm merge
and more and more eo files showing up this did explode recently.

During make distcheck a lot of files kept being around and make complained about
them. It took some digging to find the arguments list to long error. If you want
details on this great limitation have a look here:
http://www.linuxjournal.com/article/6060

In our case we have been lucky enough that we just appened many files over and
over again. Not doing that solves the issue for now. My testing showed no
problems but if I missed something let me know.

Fixes T3386
2016-03-31 16:29:32 +02:00
Jean-Philippe Andre 055ea6445a Evas image: Move content_hint and scale_hint to Efl.Image 2016-03-15 11:11:59 +09:00
Jean-Philippe Andre b458341a13 Efl.Gfx.Buffer: Add interface skeletton 2016-03-15 11:11:59 +09:00
Jean-Philippe Andre fd2c4b4a26 Evas image: Create interface Efl.Image.Animated
This interface groups all low-level animated image functions.

FIXME:
- Rename to Efl.Image.Animated once eolian is fixed
- Fix mess with emile enum (loop_hint)
2016-03-15 11:11:59 +09:00
Cedric BAIL 685681c864 efl: rename efl.core.animator to efl.animator.
It has been decided that we would not use any namespace for interface
and they will sit in efl main namespace.

This patch doesn't correct the naming of the event has we don't have a
prefix for event. We do still have EFL_ANIMATOR_EVENT_ANIMATOR_TICK,
instead of a nicer EFL_EVENT_ANIMATOR_TICK.
2016-03-10 13:14:13 -08:00
Vitor Sousa e79ee4d645 efl: fix installation and compilation of efl_types.eot.h
Summary:
Fix Efl.h include problem of the installed header "efl_types.eot.h".

Move efl_types.eot to src/lib/efl/interfaces to compile and install at
the same place of other Eolian-generated headers.

Test Plan: compile and test expedit

Reviewers: felipealmeida, stefan_schmidt, tasn, cedric, q66, JackDanielZ

Subscribers: jpeg

Differential Revision: https://phab.enlightenment.org/D3670
2016-02-10 20:02:11 -02:00
Felipe Magno de Almeida e1de58a3ad efl: Renamed Ecore.Time to Efl.Time and defined it
Moved the Ecore.Time @extern struct to Efl lib and defined it as
specified in C specification for struct tm. Thus, bindings can be
automatically generated for where struct tm is used.
2016-02-09 13:28:25 -02:00
Jean-Philippe Andre 1ac79c3b13 Efl: Eo-ify remaining Efl.Gfx enums and structs 2016-02-03 20:09:26 +09:00
Cedric BAIL e405afb2f9 efl: add Efl.Core.Animator interface. 2016-02-02 10:45:42 -08:00
Stefan Schmidt 2a089926cd build: hopefully last fix for efl_gfx.x
Cedrics original change made sure the file was actually dist_installed but
failed to be placed inthe correct inlucde folder and thus failed the elm build.
While raster fixed this he broke the distcheck build as the file was no longer
put into the tarball being marked as nodist.
This fix handles all the cases I tried in my testing here.
2016-01-08 11:57:55 +01:00
Carsten Haitzler e72f53de26 efl - fix build break with efl_gfx.x 2016-01-08 10:15:49 +09:00
Cedric BAIL c451d5885b efl: move Ector_Color to be defined in Efl.Gfx as it makes more sense.
This create some possible naming clash and is why I come up with
efl_gfx_color*_type_set functions. We will have to think about this more
carefully as it makes sense to now pass this colors directly to our color
API. Ideally the default 8 bits interface would become just a convenience
wrapper around the more complex possibility.
2016-01-07 16:27:57 -08:00
Felipe Magno de Almeida a3db1dddd3 efl-js: JavaScript Eolian binding
To configure efl sources with bindings to use in nodejs add ––with-js=nodejs in configure flags to generate node files

$ configure --with-js=nodejs

and compile normally with:

$ make
$ make install

To use, you have to require efl:

efl = require('efl')

The bindings is divided in two parts: generated and manually
written. The generation uses the Eolian library for parsing Eo files
and generate C++ code that is compiled against V8 interpreter library
to create a efl.node file that can be required in a node.js instance.

@feature
2015-12-23 23:59:40 -02:00