Problem with Util.cpp on Mac[Fixed]

Money Manager Ex Development related posts
(http://github.moneymanagerex.org/)
Post Reply
elliswr
MMEX Developer
Posts: 102
Joined: Tue May 05, 2009 8:21 am
Are you a spam bot?: No
Location: Granbury, TX
Contact:

Problem with Util.cpp on Mac[Fixed]

Post by elliswr »

This line:

Code: Select all

 << wxT('L') << (!categ.IsEmpty() ? categ : _("Split")) << (!subcateg.IsEmpty() ? wxT(":") : wxT("")) << subcateg << endl
gives the following error.

Code: Select all

util.cpp:622: error: operands to ?: have different types 'wxString' and 'const wxChar*'
I don't really understand the syntax here with all the << stuff (never seen it before), but it appears to me that Xcode doesn't like the fact that there are two of these operations in the same line with different data types. Either that or "categ" is of type wxString and _("Split") is of a different type, because I am pretty sure that wxT(":") and wxT("") are both of type wxChar.

Nikolay
MMEX Developer
Posts: 1344
Joined: Sat Dec 06, 2008 2:27 pm
Are you a spam bot?: No
Location: Sankt-Petersburg, Russia

Re: Problem with Util.cpp on Mac

Post by Nikolay »

Hi,

Try this code:

Code: Select all

<< wxT('L') << (!categ.IsEmpty() ? categ : wxT("Split")) << (!subcateg.IsEmpty() ? wxT(":") : wxT("")) << subcateg << endl

elliswr
MMEX Developer
Posts: 102
Joined: Tue May 05, 2009 8:21 am
Are you a spam bot?: No
Location: Granbury, TX
Contact:

Re: Problem with Util.cpp on Mac

Post by elliswr »

That worked, thanks Nikolay.

The question now is, will the translation still work?

Nikolay
MMEX Developer
Posts: 1344
Joined: Sat Dec 06, 2008 2:27 pm
Are you a spam bot?: No
Location: Sankt-Petersburg, Russia

Re: Problem with Util.cpp on Mac

Post by Nikolay »

elliswr wrote: The question now is, will the translation still work?
Unfortunately no. But I think it's no big deal to give her attention.

Post Reply