Hi everyone!
Could you tell me please, how I can clearly convert char (&name)[N] to
nsACString?
I tried this:
char* cname = new char[N];
memcpy(cname, &name, N);
nsAutoString strName;
strName.AssignWithConversion(cname, N);
I can't find out how to get nsACString. I could use nsACString instead
Use NS_NAMED_LITERAL_CSTRING, see [1] for plenty of examples.
-hb-
[1]
https://dxr.mozilla.org/mozilla-central/search?q=NS_NAMED_LITERAL_CSTRING&case=false
On 7/4/17 3:47 PM, Dexter wrote:
Hi everyone!
Could you tell me please, how I can clearly convert char (&name)[N] to
nsACString?
I t
On 07/04/2017 04:47 PM, Dexter wrote:
Hi everyone!
Could you tell me please, how I can clearly convert char (&name)[N] to
nsACString?
I tried this:
char* cname = new char[N];
memcpy(cname, &name, N);
nsAutoString strName;
strName.AssignWithConversion(cname, N);
I can't find out how to get ns
3 matches
Mail list logo