efl interfaces: convert to new ownership

This commit is contained in:
Daniel Kolesa 2017-09-15 16:57:44 +02:00
parent 8f6ba61011
commit 9622511df0
14 changed files with 24 additions and 25 deletions

View File

@ -319,7 +319,7 @@ class Edje.Object (Efl.Canvas.Group, Efl.File, Efl.Container, Efl.Part,
access_part_iterate {
[[Iterates over all accessibility-enabled part names.]]
legacy: null;
return: free(own(iterator<string>), eina_iterator_free); [[Part name iterator]]
return: iterator<string> @owned; [[Part name iterator]]
}
part_exists @const {
[[Checks if a part exists in a given Edje object's group definition.

View File

@ -42,7 +42,7 @@ interface Efl.Canvas ()
objects, acting only on the ones at the "top level", with
regard to object parenting.
]]
return: free(own(iterator<Efl.Gfx>), eina_iterator_free) @warn_unused; [[
return: iterator<Efl.Gfx> @owned @warn_unused; [[
The list of objects that are over the given position in $e.
]]
params {
@ -99,7 +99,7 @@ interface Efl.Canvas ()
objects, acting only on the ones at the "top level", with
regard to object parenting.
]]
return: free(own(iterator<Efl.Gfx>), eina_iterator_free) @warn_unused; [[Iterator to objects]]
return: iterator<Efl.Gfx> @owned @warn_unused; [[Iterator to objects]]
params {
@in x: int; [[
The top left corner's horizontal coordinate for the
@ -165,7 +165,7 @@ interface Efl.Canvas ()
@since 1.20
]]
return: own(free(iterator<Efl.Input.Device>, eina_iterator_free));
return: iterator<Efl.Input.Device> @owned;
[[An iterator over the attached seats.]]
}
@property device {

View File

@ -17,14 +17,14 @@ interface Efl.Config ()
params {
name: string; [[Configuration option name]]
}
return: free(own(ptr(generic_value)), eina_value_free); [[Configuration option value]]
return: free(ptr(generic_value), eina_value_free) @owned; [[Configuration option value]]
}
config_list_get @const {
[[Returns a list of generic values under a given key.]]
params {
@in name: string; [[Configuration option name]]
}
return: free(own(iterator<ptr(generic_value)>), eina_iterator_free); [[
return: iterator<ptr(generic_value)> @owned; [[
List of configuration option values]]
}
}

View File

@ -27,7 +27,7 @@ interface Efl.Container (Efl.Gfx)
}
content_iterate {
[[Begin iterating over this object's contents.]]
return: free(own(iterator<Efl.Gfx>), eina_iterator_free) @warn_unused; [[Iterator to object content]]
return: iterator<Efl.Gfx> @owned @warn_unused; [[Iterator to object content]]
}
content_count {
[[Returns the number of UI elements packed in this container.]]

View File

@ -71,7 +71,7 @@ class Efl.Input.Device (Efl.Object)
@since 1.20
]]
return: own(free(iterator<const(Efl.Input.Device)>, eina_iterator_free)); [[List of device children]]
return: iterator<const(Efl.Input.Device)> @owned; [[List of device children]]
}
has_pointer_caps {
[[Determine whether a device has pointer capabilities.

View File

@ -132,7 +132,7 @@ class Efl.Io.Buffer (Efl.Object, Efl.Io.Reader, Efl.Io.Writer, Efl.Io.Closer, Ef
On failure, for example a read-only backing store was
adopted with @.adopt_readonly, NULL is returned.
]]
return: free(own(ptr(Eina.Binbuf)), eina_binbuf_free) @warn_unused; [[Binbuf]]
return: free(ptr(Eina.Binbuf), eina_binbuf_free) @owned @warn_unused; [[Binbuf]]
}
}

View File

@ -36,7 +36,7 @@ class Efl.Observable (Efl.Object) {
[[Return a new iterator associated with a group of observers.
@since 1.19]]
return: free(own(iterator<Efl.Observer>), eina_iterator_free); [[Iterator for observers group]]
return: iterator<Efl.Observer> @owned; [[Iterator for observers group]]
params {
@in key: string; [[A key to classify observer groups]]
}
@ -54,7 +54,7 @@ class Efl.Observable (Efl.Object) {
[[Return a new iterator associated to this observable.
@since 1.19]]
return: free(own(iterator<Efl.Observable.Tuple>), eina_iterator_free); [[Iterator for observer]]
return: iterator<Efl.Observable.Tuple> @owned; [[Iterator for observer]]
}
}
implements {

View File

@ -19,7 +19,7 @@ interface Efl.Pack (Efl.Container)
unpack {
[[Removes an existing item from the container, without deleting it.]]
params {
subobj: own(Efl.Gfx); [[Unpacked object]]
subobj: Efl.Gfx @owned; [[Unpacked object]]
}
return: bool; [[$false if $subobj wasn't a child or can't be removed]]
}
@ -34,7 +34,7 @@ interface Efl.Pack (Efl.Container)
failed, the object will be unrefed.
]]
params {
subobj: own(Efl.Gfx); [[Packed object]]
subobj: Efl.Gfx @owned; [[Packed object]]
}
return: bool; [[$false if $subobj could not be packed.]]
}

View File

@ -8,7 +8,7 @@ interface Efl.Pack.Grid (Efl.Pack.Linear)
pack_grid {
[[Pack object on the grid]]
params {
subobj: own(Efl.Gfx); [[Object]]
subobj: Efl.Gfx @owned; [[Object]]
col: int; [[Column number]]
row: int; [[Row number]]
colspan: int @optional; [[0 means 1, -1 means @.grid_columns]]
@ -18,7 +18,7 @@ interface Efl.Pack.Grid (Efl.Pack.Linear)
}
grid_contents_get {
[[Returns all objects at a given position in this grid.]]
return: free(own(iterator<Efl.Gfx>), eina_iterator_free); [[Iterator to grid contents]]
return: iterator<Efl.Gfx> @owned; [[Iterator to grid contents]]
params {
@in col: int; [[Column number]]
@in row: int; [[Row number]]

View File

@ -9,7 +9,7 @@ interface Efl.Pack.Linear (Efl.Pack)
This is the same as @.pack_at($subobj, 0).
]]
params {
@in subobj: own(Efl.Gfx); [[Item to pack.]]
@in subobj: Efl.Gfx @owned; [[Item to pack.]]
}
return: bool; [[$false if $subobj could not be packed]]
}
@ -19,14 +19,14 @@ interface Efl.Pack.Linear (Efl.Pack)
This is the same as @.pack_at($subobj, -1).
]]
params {
@in subobj: own(Efl.Gfx); [[Item to pack.]]
@in subobj: Efl.Gfx @owned; [[Item to pack.]]
}
return: bool; [[$false if $subobj could not be packed]]
}
pack_before {
[[Prepend item before other sub object.]]
params {
@in subobj: own(Efl.Gfx); [[Item to pack.]]
@in subobj: Efl.Gfx @owned; [[Item to pack.]]
@in existing: const(Efl.Gfx); [[Item to refer to.]]
}
return: bool; [[$false if $existing could not be found or $subobj
@ -35,7 +35,7 @@ interface Efl.Pack.Linear (Efl.Pack)
pack_after {
[[Append item after other sub object.]]
params {
@in subobj: own(Efl.Gfx); [[Item to pack.]]
@in subobj: Efl.Gfx @owned; [[Item to pack.]]
@in existing: const(Efl.Gfx); [[Item to refer to.]]
}
return: bool; [[$false if $existing could not be found or $subobj
@ -48,7 +48,7 @@ interface Efl.Pack.Linear (Efl.Pack)
Out of range indices will trigger an append.
]]
params {
@in subobj: own(Efl.Gfx); [[Item to pack.]]
@in subobj: Efl.Gfx @owned; [[Item to pack.]]
@in index: int; [[A position.]]
}
return: bool; [[$false if $subobj could not be packed]]

View File

@ -43,8 +43,7 @@ interface Efl.Text.Annotate {
@in start: ptr(const(Efl.Text.Cursor.Cursor)); [[Start of range]]
@in end: ptr(const(Efl.Text.Cursor.Cursor)); [[End of range]]
}
return: free(own(iterator<ptr(Efl.Text.Annotate.Annotation)>),
eina_iterator_free); [[Handle of the Annotation]]
return: iterator<ptr(Efl.Text.Annotate.Annotation)> @owned; [[Handle of the Annotation]]
}
annotation_insert {
[[Inserts an annotation format in a specified range [$start, $end - 1].

View File

@ -29,7 +29,7 @@ interface Efl.Ui.Menu {
@property items {
get {
[[Returns a list of the widget item.]]
return: free(own(iterator<Efl.Ui.Item>), eina_iterator_free) @warn_unused; [[Iterator to widget items]]
return: iterator<Efl.Ui.Item> @owned @warn_unused; [[Iterator to widget items]]
}
}
}

View File

@ -25,7 +25,7 @@ interface Efl.Vpath
params {
path: string; [[ The input virtual file path to fetch ]]
}
return: own(Efl.Vpath.File); [[ An object representing the file ]]
return: Efl.Vpath.File @owned; [[ An object representing the file ]]
}
}
}

View File

@ -11,7 +11,7 @@ class Efl.Vpath.Manager (Efl.Object)
params {
path: string; [[ The input virtual file path to fetch ]]
}
return: own(Efl.Vpath.File); [[ An object representing the file ]]
return: Efl.Vpath.File @owned; [[ An object representing the file ]]
}
register @class {
[[Register a vpath with the manager ]]