Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
BC
public
liblinphone
Commits
07381345
Commit
07381345
authored
Feb 21, 2017
by
Ghislain MARY
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix automatic wrapper generation where class methods were considered to be instance properties.
parent
fc2e9efe
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
14 deletions
+2
-14
tools/genapixml.py
tools/genapixml.py
+2
-14
No files found.
tools/genapixml.py
View file @
07381345
...
@@ -202,20 +202,8 @@ class CClass(CObject):
...
@@ -202,20 +202,8 @@ class CClass(CObject):
self
.
properties
[
name
].
setter
=
f
self
.
properties
[
name
].
setter
=
f
def
__addClassMethod
(
self
,
f
):
def
__addClassMethod
(
self
,
f
):
name
=
f
.
name
[
len
(
self
.
cFunctionPrefix
):]
if
not
f
.
name
in
self
.
classMethods
:
if
name
.
startswith
(
'get_'
)
and
len
(
f
.
arguments
)
==
0
:
self
.
classMethods
[
f
.
name
]
=
f
self
.
__addPropertyGetter
(
name
[
4
:],
f
)
elif
name
.
startswith
(
'is_'
)
and
len
(
f
.
arguments
)
==
0
and
f
.
returnArgument
.
ctype
==
'bool_t'
:
self
.
__addPropertyGetter
(
name
[
3
:],
f
)
elif
name
.
endswith
(
'_enabled'
)
and
len
(
f
.
arguments
)
==
0
and
f
.
returnArgument
.
ctype
==
'bool_t'
:
self
.
__addPropertyGetter
(
name
,
f
)
elif
name
.
startswith
(
'set_'
)
and
len
(
f
.
arguments
)
==
1
:
self
.
__addPropertySetter
(
name
[
4
:],
f
)
elif
name
.
startswith
(
'enable_'
)
and
len
(
f
.
arguments
)
==
1
and
f
.
arguments
[
0
].
ctype
==
'bool_t'
:
self
.
__addPropertySetter
(
name
[
7
:]
+
'_enabled'
,
f
)
else
:
if
not
f
.
name
in
self
.
classMethods
:
self
.
classMethods
[
f
.
name
]
=
f
def
__addInstanceMethod
(
self
,
f
):
def
__addInstanceMethod
(
self
,
f
):
name
=
f
.
name
[
len
(
self
.
cFunctionPrefix
):]
name
=
f
.
name
[
len
(
self
.
cFunctionPrefix
):]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment