summaryrefslogtreecommitdiff
path: root/src/tests/efl_mono/Eo.cs (follow)
AgeCommit message (Collapse)Author
2020-02-18C#: Add error checking for Eina.Success_Flag return typeFelipe Magno de Almeida
When a get and/or set from property is defined to return, explicitly, a Eina.Success_Flag, the mono generator will check the return value and generate an exception if the call fails. Resolves T8383. Reviewed-by: João Paulo Taylor Ienczak Zanette <joao.tiz@expertisesolutions.com.br> Differential Revision: https://phab.enlightenment.org/D11281
2020-02-18eolian-mono: Make Get/Set internal for generated propertiesFelipe Magno de Almeida
Make Get and Set methods internal for properties that get the property syntax generated. Reviewed-by: João Paulo Taylor Ienczak Zanette <joao.tiz@expertisesolutions.com.br> Differential Revision: https://phab.enlightenment.org/D11252
2020-01-23csharp: cleanup concrete classYeongjong Lee
Summary: Concrete class is only used to call static member of NativeMethod. they don't need any inheritance and implementation of c functions. Depends on D9893 Test Plan: ninja test Reviewers: lauromoura, felipealmeida Subscribers: Jaehyun_Cho, woohyun, segfaultxavi, cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D9894
2020-01-22eolian_mono: avoid generating set-only propertyYeongjong Lee
Summary: According to Property Design Guidelines of MS, set-only properties are not recommeneded. (see more, https://docs.microsoft.com/en-us/dotnet/standard/design-guidelines/property) Furthermore, there is stylecop warnings(CA1044) ref T8396 List of removed set-only properies. ``` Efl.Access.Editable.IText.TextContent { set; } Efl.App.CommandArray { set; } Efl.App.CommandString { set; } Efl.Canvas.Filter.IInternal.FilterChanged { set; } Efl.Canvas.Filter.IInternal.FilterInvalid { set; } Efl.Canvas.ImageInternal.FilterChanged { set; } Efl.Canvas.ImageInternal.FilterInvalid { set; } Efl.Canvas.Textblock.FilterChanged { set; } Efl.Canvas.Textblock.FilterInvalid { set; } Efl.Canvas.Vg.Image.Data { set; } Efl.Canvas.Vg.Node.CompMethod { set; } Efl.Core.ICommandLine.CommandArray { set; } Efl.Core.ICommandLine.CommandString { set; } Efl.Exe.CommandArray { set; } Efl.Exe.CommandString { set; } Efl.Ui.AlertPopup.Button { set; } Efl.Ui.Collection.MatchContent { set; } Efl.Ui.CollectionView.MatchContent { set; } Efl.Ui.IScrollable.MatchContent { set; } Efl.Ui.ImageZoomable.MatchContent { set; } Efl.Ui.Panel.MatchContent { set; } Efl.Ui.PositionManager.Grid.DataAccess { set; } Efl.Ui.PositionManager.Grid.ScrollPosition { set; } Efl.Ui.PositionManager.Grid.Viewport { set; } Efl.Ui.PositionManager.IDataAccessV1.DataAccess { set; } Efl.Ui.PositionManager.IEntity.ScrollPosition { set; } Efl.Ui.PositionManager.IEntity.Viewport { set; } Efl.Ui.PositionManager.List.DataAccess { set; } Efl.Ui.PositionManager.List.ScrollPosition { set; } Efl.Ui.PositionManager.List.Viewport { set; } Efl.Ui.Scroll.Manager.MatchContent { set; } Efl.Ui.Scroll.Manager.Pan { set; } Efl.Ui.Scroller.MatchContent { set; } Efl.Ui.Spotlight.Manager.Size { set; } Efl.Ui.Textbox.TextContent { set; } Efl.Ui.Widget.ResizeObject { set; } Efl.Ui.Win.PropFocusSkip { set; } ``` Test Plan: meson build -Dbindings=mono,cxx -Dmono-beta=true Reviewers: woohyun, felipealmeida, segfaultxavi Reviewed By: segfaultxavi Subscribers: cedric, #reviewers, #committers Tags: #efl Maniphest Tasks: T8396 Differential Revision: https://phab.enlightenment.org/D11138
2020-01-21Revert "csharp: Property Indexer implementation"Yeongjong Lee
Summary: This reverts commit 0954e501fd4008c40b3848de1f2c91bcd53b2f71. According to Framework Design Guidelines of MS, most of indexed properties are not recommended in EFL#. (see, https://docs.microsoft.com/en-us/dotnet/standard/design-guidelines/property) It is better to leave properties which have a key as methods. Reviewers: woohyun, felipealmeida Reviewed By: woohyun Subscribers: segfaultxavi, cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D11114
2019-12-23csharp: Property Indexer implementationLauro Moura
Use Indexers to use brackets, eg [i], syntax. Keys now can be used as following: var someVal = obj.SomeProperty[key]; obj.SomeProperty[key] = someNewVal; And for multiple keys: var someVal = obj.SomeProperty[(key1, key2)]; obj.SomeProperty[(key1, key2)] = someNewVal; T8384 Reviewed-by: WooHyun Jung <wh0705.jung@samsung.com> Differential Revision: https://phab.enlightenment.org/D10791
2019-12-18csharp: Fix passing acessor with ownershipLauro Moura
Summary: When passing an owned acessor from a converted collection we need a way to unpin the passed data when the accessor is freed. This commits adds a thin wrapper around the CArray accessor that unpins the data when freed. Depends on D10900 Reviewers: YOhoho, felipealmeida Reviewed By: YOhoho Subscribers: cedric, #reviewers, #committers, jptiz, brunobelo Tags: #efl Maniphest Tasks: T8486 Differential Revision: https://phab.enlightenment.org/D10901
2019-12-17csharp : add move tag info to EinaAccessor, EinaIterator converterYeongjong Lee
Summary: Included commits in devs/lauromoura/remove_eina_mono-rebased ``` commit ed6679db1901c710cc6ddb50e7001cfd20caa77a Author: Lauro Moura <lauromoura@expertisesolutions.com.br> Date: Mon Dec 2 13:58:04 2019 -0300 csharp: add move information to EnumerableToAccessor Still need to fix the converted accessor ownership, maybe by creating a custom accessor class that released the pinned memory when is freed. ``` ref T8486 Depends On D10878 Co-authored-by: Lauro Moura <lauromoura@expertisesolutions.com.br> Test Plan: meson build -Dbindings=mono,cxx -Dmono-beta=true Reviewers: YOhoho Reviewed By: YOhoho Subscribers: cedric, #reviewers, #committers Tags: #efl Maniphest Tasks: T8486 Differential Revision: https://phab.enlightenment.org/D10879
2019-12-17eina_mono: replace EinaAccessor and EinaIerator with IEnumerableYeongjong Lee
Summary: Eina.Accessor<T> => System.Collections.IEnumerable<T> Eina.Iterator<T> => System.Collections.IEnumerable<T> Unit test will work with D10879. ref T8486 Test Plan: meson build -Dbindings=mono,cxx -Dmono-beta=true Reviewers: lauromoura Reviewed By: lauromoura Subscribers: cedric, #reviewers, #committers Tags: #efl Maniphest Tasks: T8486 Differential Revision: https://phab.enlightenment.org/D10878
2019-12-09csharp: Marking property with static.Lauro Moura
Summary: ref T8420 Reviewers: lauromoura, felipealmeida, YOhoho, jptiz Reviewed By: jptiz Subscribers: cedric, #reviewers, #committers Tags: #efl Maniphest Tasks: T8420 Differential Revision: https://phab.enlightenment.org/D10657
2019-11-19csharp: Fix CA1815 for generated structs and aliasesLauro Moura
Summary: Adds IEquatable<T> and friends. Reviewers: felipealmeida, YOhoho, brunobelo Reviewed By: brunobelo Subscribers: cedric, #reviewers, segfaultxavi, #committers Tags: #efl Maniphest Tasks: T8418 Differential Revision: https://phab.enlightenment.org/D10694
2019-11-15csharp: Silence CA2000 in testsLauro Moura
Summary: These objects are expected to leave scope while alive. Ref T8423 Depends on D10671 Reviewers: brunobelo, felipealmeida, YOhoho Reviewed By: brunobelo Subscribers: cedric, #reviewers, #committers Tags: #efl Maniphest Tasks: T8423 Differential Revision: https://phab.enlightenment.org/D10672
2019-11-14csharp: Disposing IDisposable objects.Bruno da Silva Belo
Summary: ref T8423 Reviewers: lauromoura, felipealmeida, YOhoho Reviewed By: lauromoura Subscribers: cedric, #reviewers, #committers Tags: #efl Maniphest Tasks: T8423 Differential Revision: https://phab.enlightenment.org/D10644
2019-11-07csharp: Removing a never used class.Bruno da Silva Belo
Summary: ref T8417 Reviewers: lauromoura, felipealmeida, YOhoho, segfaultxavi Reviewed By: segfaultxavi Subscribers: segfaultxavi, cedric, #reviewers, #committers Tags: #efl Maniphest Tasks: T8417 Differential Revision: https://phab.enlightenment.org/D10611
2019-10-31csharp: space after keywords.Bruno da Silva Belo
Reviewers: felipealmeida, lauromoura, YOhoho Reviewed By: lauromoura Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D10576
2019-10-24csharp: Add licensing information.Lauro Moura
Summary: C# bindings will be lincensed under Apache Sofware License 2.0. This commit adds the license text to the licenses folder and a copyright notice to the binding files. Fixes T8039 Reviewers: woohyun, felipealmeida, vitor.sousa Reviewed By: felipealmeida Subscribers: cedric, #reviewers, #committers Tags: #efl Maniphest Tasks: T8039 Differential Revision: https://phab.enlightenment.org/D9414
2019-09-24csharp: Fix wrapping of private classesLauro Moura
Summary: Sometimes, valid Eo objects of private classes can be returned from methods. Currently we try to wrap in a minimal `Efl.Object` instance, but as it is an abstract class, we can't instantiate directly. This commits adds a dummy `Efl.ObjectRealized` to be instantiated when wrapping such classes alongside a test case. Fixes: T8258 Reviewers: felipealmeida, brunobelo, segfaultxavi, Jaehyun_Cho Reviewed By: brunobelo Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D10101
2019-09-11csharp: Minor change to D9692Bruno da Silva Belo
Summary: Changing Evt to Event from some files that it wasn't catch on D9692 Reviewers: lauromoura, felipealmeida Reviewed By: lauromoura Subscribers: cedric, felipealmeida, #reviewers, lauromoura, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D9904
2019-09-10csharp: Add test for static interface membersLauro Moura
For the checks added in D9893
2019-09-10csharp: Skip non-public members from interfacesLauro Moura
Summary: Eolian allows non-public members in interfaces and mixins (usually @protected). As both kinds are converted to C# interfaces, this causes problem as non-public members are forbidden in C# interfaces. This commit changes eolian_mono by removing those members from the C# interfaces. If a generated class implements the interface, the method is generated as if it were a protected member of the class directly. For mixed properties like `Efl.Io.Reader.CanRead { get; set @protected; }`, the interface has only the public getter and the the implementing class has both the public getter and the protected setter. With this, C# devs won't be able to directly implement protected Eo methods from interfaces. (But this really does not make sense from the C# point of view). ref T7494 Reviewers: segfaultxavi, felipealmeida, YOhoho Reviewed By: YOhoho Subscribers: cedric, brunobelo, Jaehyun_Cho, #reviewers, woohyun, #committers Tags: #efl Maniphest Tasks: T7494 Differential Revision: https://phab.enlightenment.org/D9800
2019-08-23eolian-mono: Add support for multi-value properties with tuplesFelipe Magno de Almeida
Summary: T8133 Reviewers: woohyun, segfaultxavi, felipealmeida Reviewed By: felipealmeida Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D9577
2019-07-12csharp: fix some unit tests that rely on garbage collectionVitor Sousa
Summary: Fix unit tests `TestEoInherit.inherited_collected` and `TestFunctionPointers.set_callback_inherited_called_from_c`. Iterate through garbage collection and EFL main loop more times to ensure that allocated objects are really collected. Also expand the test utility method `CollectAndIterate` to receive the number of times to call the whole cleaning iteration process (not only the garbage collection). Test Plan: `meson test` Reviewers: lauromoura Reviewed By: lauromoura Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D9271
2019-05-31csharp: Refactor wrapper lifetime.Vitor Sousa
Summary: This commit makes use of the `ownership,shared` and `ownership,unique` events from Efl.Object in order to avoid the C# wrapper from being collected while C code holds a reference to the object. For example, creating a list of items in a for loop and attaching events to them would fails without this commit, as the C# GC may collect the wrapper. The basic idea is that we use a `WrapperSupervisor`, which is stored in the Eo data storage, with a GCHandle allocated for the lifetime of the underlying Eo object. This supervisor takes care of holding either a weak C# reference (when in unique mode, allowing the wrapper to be GC'd) or a hard C# reference (when in shared mode, making the wrapper non-collectable while the Eo has extra references). One limitation is that object graphs can leak if a shared object in the graph - an Eo child for example - stores a hard reference to another object in the graph as a C# field. In this example, this causes the parent to always have a hard C# reference (from the child) as the child is non-collectable due to the parent holding an Eo reference to it. Depends on D8678 Test Plan: `ninja test` and `make test` Reviewers: lauromoura, felipealmeida, woohyun, segfaultxavi Reviewed By: lauromoura Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D9014
2019-05-31csharp: Add some testsLauro Moura
Summary: - Wrappers losing C# ref while alive in Eo - Inherited instances being collected Also cleanup GC and loop queue before each test Reviewers: vitor.sousa Reviewed By: vitor.sousa Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D9063
2019-04-05efl-csharp: fix crash when events trigger after C# object `Dispose`Vitor Sousa
Summary: Rework general event handling to check individually each event call, if the object is not alive then the event will not be propagated. WeakReferences (and lambdas capturing those WeakRefs) are used to ensure this. Dispose methods in object now take care of checking if efl libraries are still initialized and thread-safely unregister each event before performing an efl_unref on the Eo object. Event handling in C# is now centered around a single dictionary inside the object: `EoEvents`. C# event triggers now properly trigger events on C too. Standardize C# event-triggering methods names (remove underscores). Some diminished use of static memory due events no longer requiring static key objects to be registered/unregistered. Some fixing of white space generation for generated events. Depends on D8431 Reviewers: lauromoura, felipealmeida, segfaultxavi Reviewed By: lauromoura Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D8564
2019-04-05csharp: Make classes abstract and rework castingLauro Moura
Summary: Abstract Eo classes are now proper C# abstract classes. As a side effect, returning Eo instances from native code was reworked to return instances of their actual Eo classes instead of previous behavior of returning a generic Efl.Object and using static_cast. Instead of `var window = Efl.Ui.Win.static_cast(widget.GetParent());` Use `var window = widget.GetParent() as Efl.Ui.Win;` Another side effect was that `efl_constructor` was removed from the list of supported `Efl.Object` overrides. It is invoked inside `efl_add_internal_start`, before the bindings makes the association of the newly created EoId with the C# instance that created it, making the managed delegate meaningless. C# users then can use regular C# constructors to initialize fields. Also changed to set the private data of C#-inherited classes before the call to constructing methods (aka constructor parameters) so C# classes can override them correctly. Fixes T7778 Fixes T7757 Reviewers: vitor.sousa, felipealmeida, segfaultxavi Reviewed By: vitor.sousa, segfaultxavi Subscribers: cedric, #reviewers, #committers Tags: #efl Maniphest Tasks: T7778, T7757, T7702 Differential Revision: https://phab.enlightenment.org/D8550
2019-03-21efl-csharp: Add back I prefix for interfaces.Lauro Moura
Summary: Conforming to C# coding conventions. For properties, now we only generate a wrapper if its name does not clash with the name of the class that would be implementing it. Fixes T7751 Reviewers: vitor.sousa, felipealmeida, segfaultxavi Reviewed By: vitor.sousa, segfaultxavi Subscribers: cedric, #reviewers, #committers Tags: #efl Maniphest Tasks: T7751 Differential Revision: https://phab.enlightenment.org/D8397
2019-03-15csharp: Support Efl.Class for interfacesLauro Moura
Summary: The `GetEflClassStatic` method for interface is in their Concrete sidekick. Previously, passing a valid Eo interface as a type caused the binding to complain that `Type is not an Efl.Object`. Test Plan: run test case Reviewers: vitor.sousa, felipealmeida Reviewed By: vitor.sousa Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D8360
2019-03-11efl-csharp: Respect beta for classes and other stuff.Lauro Moura
Summary: In order to work around an issue with Efl.App, which is stable but inherits from Efl.Core.Command_Line, @beta interfaces/mixins in the inheritance chain are simply skipped. Also changed the class used int test for inheritance from C# Efl.Loop is stable but internally it uses a @beta class as argument to its Register() method in the constructor. When instantiating a user-defined C# subclass, the binding calls the C# override in the NativeInherit class and the marshalling fails as no code is generated for the beta class. Also moved Efl.Part test to a beta class. Efl.Part is still beta. Regarding parts, they are skipped if its class is @beta too. Also rejected all elm_* files in elm public eo files. They should get back in as they are converted to Efl.Ui.* api. An exception is elm_interface_scrollable.eo, as efl_ui_panel depends on it. Fixes T7730 Test Plan: Run tests Reviewers: vitor.sousa, segfaultxavi, felipealmeida, cedric, bu5hm4n, zmike Reviewed By: vitor.sousa Subscribers: #reviewers, #committers Tags: #efl Maniphest Tasks: T7730 Differential Revision: https://phab.enlightenment.org/D8268
2019-03-07efl-csharp: Respect beta in constructor parameters.Lauro Moura
Summary: Fixes compilation after Efl.Ui.Win parameter changes. Also removed an unused var and now we pass the beta option to the eolian mono invocation for the tests. Fixes T7723 Reviewers: segfaultxavi, felipealmeida, vitor.sousa Reviewed By: segfaultxavi Subscribers: cedric, #reviewers, #committers Tags: #efl Maniphest Tasks: T7723 Differential Revision: https://phab.enlightenment.org/D8150
2019-03-01efl-mono: Add support for dotnet coreFelipe Magno de Almeida
Summary: This commits adds dotnet as a supported C# platform for EFL# bindings. Due to differences between Mono and Dotnet regarding DllImport, the bindings now are using an imperative approach to load the function pointers through the NativeModule and FunctionWrapper classes. These classes handle the dlopen/LoadLibrary and dlsym/GetProcAddress calls. Also, the previous caching of non-owned strings returned to native code was removed until further memory checks. We also had to create workaround for bool and chars in Structs for C# marshaling. Going through System.Byte instead and Marshaling manually to their respective types. In order to actually build efl_mono.dll with dotnet right now, issue #4782 from Meson should be fixed to make it properly detect and used the Dotnet compiler. Also use "-Ddotnet=true" when running meson. Fixes T7394 Reviewers: felipealmeida, vitor.sousa, bu5hm4n Reviewed By: vitor.sousa Subscribers: cedric Tags: #efl Maniphest Tasks: T7394 Differential Revision: https://phab.enlightenment.org/D8069
2019-03-01efl-mono: Add support for Efl.ClassLauro Moura
Efl.Class (in practice, the return from the *_class_get() functions) can be used as argument to functions, like in Efl.Object.provider_find and Efl.Ui.Widget_Factory.item_class(get/set). This commits adds support by representing Efl.Class instances as System.Type in the C# API, allowing someone to do things like: `factory.ItemClass == typeof(MyFramework.MyButton)` It also supports user-defined classes that inherit from efl classes.
2019-02-28efl-csharp: Fix variable generation for RoslynLauro Moura
Summary: Mono's old compiler (mcs) accepts LL as suffix for longs while Roslyn (csc) is strict, allowing only a single L. Test Plan: Run tests Reviewers: vitor.sousa, felipealmeida Reviewed By: vitor.sousa Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D8061
2019-02-28efl_csharp: add constant variable generation to C# binding (constants)Vitor Sousa
Reviewers: lauromoura, q66, bu5hm4n, zmike, cedric, felipealmeida, segfaultxavi Reviewed By: segfaultxavi Subscribers: segfaultxavi, cedric, #reviewers, #committers Tags: #efl_language_bindings Differential Revision: https://phab.enlightenment.org/D8048
2019-02-11efl-csharp: Fix self in iface concrete functionsLauro Moura
Summary: It was mistakenly being called as static functions. Fixes T7619 Test Plan: See attached testcase. Reviewers: segfaultxavi, bu5hm4n, vitor.sousa Reviewed By: vitor.sousa Subscribers: cedric, #reviewers, #committers Tags: #efl Maniphest Tasks: T7619 Differential Revision: https://phab.enlightenment.org/D7904
2019-02-01eolian-mono: Provide constructor parameters based on the constructorsFelipe Magno de Almeida
section of the Eo files. Reviewers: woohyun, segfaultxavi, bu5hm4n, felipealmeida Reviewed By: segfaultxavi Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D7789
2018-12-14efl-mono: Fix call of virtual methods after new APILauro Moura
Summary: After the new API, the virtual wrapper classes (*NativeInherit) just declared the wrappers for the current class. But as they didn't have any inheritance information, reimplementing methods from a parent Eo class wouldn't work. (e.g. Efl.Ui.Button reimplementing Efl.Object FinalizeAdd). This commit changes these NativeInherit classes to mimic the inheritance chain of their regular/abstract counterparts, reusing the virtual wrapper implementations. In order to access the correct Eo class created, the methods on it were changed from static to instance methods. The instance will be held as a class member of the regular/abstract API class to keep the delegates alive and allow getting C Function pointers from them. The class_initializer method was also split in two. The method collecting the wrapper delegates was extracted in order to call the parent ones. Also avoid exception in cached strings queries as TryGetValue requires non-null keys. Test Plan: Run test suite. Reviewers: vitor.sousa, felipealmeida Reviewed By: vitor.sousa Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D7460
2018-12-14eolian_mono: Add support for C# style propertiesLauro Moura
Summary: Syntatic sugar around the Get/Set functions for now. Test Plan: Run efl-mono-suite Reviewers: vitor.sousa, segfaultxavi, felipealmeida, Jaehyun_Cho Reviewed By: vitor.sousa Subscribers: cedric Tags: #efl_language_bindings Differential Revision: https://phab.enlightenment.org/D7394
2018-11-29csharp: Change to new class API.Lauro Moura
Summary: As discussed in T7204: - Eo Interfaces/mixins -> C# Interfaces with concrete class implementations - Eo Regular/Abstracts -> Proper C# classes - Added some new generators and helper methods. - Refactored the class generator, splitting into helper methods Eo handles now are stored only in the "root" class in any given inheritance tree (generally, Efl.Object), and accessible to each child. Methods also are defined in a single place instead of repeatedly generated in everyfile, reducing the size of the generated .dll from 30MB to around 4.5MB. Mixins are generated as C# interfaces but any regular class it inherits from is lost, as we can't have interfaces inheriting from regular classes. This will be dealt with in a later commit. Summary of API Changes: - Merged Inherit/Concrete classes. (These suffixes disappear from regular classes). - Interface still have implementations with 'Concrete' suffix for when they are returned from methods. - Removed 'I' from interface names. - Removed interfaces for regular/abstract Eo classes. - Concrete classes for interfaces/mixins hold the event argument struct. - Removed '_' from classes, enums, structs, etc, as indicated in C# naming conventions. - Namespaces are now Camel.Cased. - Renamed IWrapper's raw_handle/raw_klass to NativeHandle/NativeClass Also renamed the test classes as after the namespace change, the test namespace Test can conflict with the helper Test namespace. (And use more meaningful names than Test.Testing...) Also Fixes T7336 by removing a deprecated example and adding efl_loop_timer_example to build system. Fixes T7451 by hiding the class_get DllImports and renaming the IWrapper fields. The native handlers are used in the manual binding. Still need to work: - As there are still some events names clashing (e.g. Efl.Ui.Bg with "resize" from Efl.Gfx.Entity and Efl.Gfx.Image), Events are currently declared on the interface and implemented "namespaced" in the classes, requiring the cast to the interface to access the event. - The Mixin Conundrum. Mixin inheritance will be dealt in a future commit. Depends on D7260 Reviewers: segfaultxavi, vitor.sousa, felipealmeida, Jaehyun_Cho Reviewed By: vitor.sousa Subscribers: cedric, #reviewers, #committers Tags: #efl Maniphest Tasks: T7451, T7336 Differential Revision: https://phab.enlightenment.org/D7262
2018-09-05efl-csharp: Make sure efl_finalize overrides are callableLauro Moura
Summary: efl_finalize override is called inside efl_add_end. Previously by this time the constructor still hadn't saved the C# wrapper handle into the Eo instance private data, to be recovered in the static delegates that call the C# overrides. This commit just changes the order to save the C# handle *before* calling efl_add_end. Test Plan: added unit test to be run with make check Reviewers: felipealmeida, vitor.sousa, Jaehyun_Cho Reviewed By: vitor.sousa Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D6956
2018-05-23efl_mono: Generate support for accessors in .eosLauro Moura
Summary: Depends on D6190 Reviewers: felipealmeida, vitor.sousa Reviewed By: vitor.sousa Subscribers: cedric, #committers, zmike Tags: #efl Differential Revision: https://phab.enlightenment.org/D6191
2018-05-11efl_mono: Support type aliases.Lauro Moura
Summary: Due to the absence of typedef from C#, we generate thin structs with implicit operators to allow reference the data from their typedef'd name from C#. The other alternatives would be always converting to the lowest base on the alias stack (losing the meaningfulness of the typedef name) or using the 'using' directive. The latter has the restriction that it makes an alias visible only in the file they are declared. Reviewers: felipealmeida, cedric, segfaultxavi Reviewed By: segfaultxavi Subscribers: zmike Tags: #efl Differential Revision: https://phab.enlightenment.org/D6157
2018-05-03efl_mono: Update tests and examples after renameLauro Moura
Summary: Separated from the generator and libs for easier review Depends on D6050 Reviewers: felipealmeida, vitor.sousa Reviewed By: vitor.sousa Subscribers: cedric Tags: #efl Differential Revision: https://phab.enlightenment.org/D6051
2018-05-03efl_mono: More uniformization of the handling of namesLauro Moura
Summary: Uses a common helper to open and close namespaces, to get the managed and unmanaged name of things, the interface, concrete and inherit class names, etc. eolian_cxx: Add namespace information to func_def, as it'll avoid eolian-cxx clients dealing with the eolian C api directly when trying to access a function pointer namespace. Depends on D6048 Reviewers: felipealmeida, vitor.sousa Reviewed By: vitor.sousa Subscribers: cedric Tags: #efl Differential Revision: https://phab.enlightenment.org/D6049
2018-04-26efl_mono: Use PascalCase in eventsLauro Moura
Summary: To deal with events with the same name as some methods (Del, Invalidate, etc), the suffix Evt was added. Thus, now we use obj.ButtonClickedEvt += callback; Instead of obj.BUTTON_CLICKED += cal The argument classes use the same scheme, being called <Evt name>_Args. Depends on D5991 Reviewers: felipealmeida Reviewed By: felipealmeida Subscribers: cedric Differential Revision: https://phab.enlightenment.org/D5992
2018-04-12efl_mono: Proper support for @class methods.Lauro Moura
Previously, class methods were implemented as regular instance methods. This commits generates C# static methods for @class methods on the *Concrete classes (and their childs).
2017-12-04efl_mono: Added test files for the C# bindings.Lauro Moura
Buildsystem integration will come in a future commit.