mirror of
https://github.com/mappu/miqt.git
synced 2024-12-23 01:18:37 +00:00
genbindings: fixes for QStrings
This commit is contained in:
parent
050d668765
commit
97a56647b7
@ -472,6 +472,13 @@ func emitBindingCpp(src *CppParsedHeader, filename string) (string, error) {
|
|||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ref == "QString" {
|
||||||
|
ret.WriteString("#include <QString>\n")
|
||||||
|
ret.WriteString("#include <QByteArray>\n")
|
||||||
|
ret.WriteString("#include <cstring>\n")
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
if strings.Contains(ref, `::`) {
|
if strings.Contains(ref, `::`) {
|
||||||
ret.WriteString(`#define WORKAROUND_INNER_CLASS_DEFINITION_` + cabiClassName(ref) + "\n")
|
ret.WriteString(`#define WORKAROUND_INNER_CLASS_DEFINITION_` + cabiClassName(ref) + "\n")
|
||||||
continue
|
continue
|
||||||
|
@ -90,6 +90,10 @@ func (p CppParameter) QtClassType() bool {
|
|||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if p.ParameterType == "QString" {
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user