G4P.showMessage ... G4P.WARNING causes error

After just updating G4P Library to latest version (4.3.2) from 4.1.3, The following line of code (which worked under 4.1.3):

G4P.showMessage(this, “Not a valid Patch file?”, “Bad Patch Data”, G4P.WARNING);

now gives the error:

WARNING cannot be resolved or is not a field.

If I replace the constant G4P.WARNING with an integer (e.g. 3) the error goes away.

When I had a look in GConstants.java in the G4P library source code there is a constant defined as WARN_MESSAGE and I find that using G4P.WARN_MESSAGE instead of G4P.WARNING the error goes away.

@quark: were these message constants changed? I didn’t find any reference to it if they were.

Many thanks in advance :slight_smile:

Phil

1 Like

Yes they were changed in V4.3.0 and reported in the changes.txt file in the library download and on my website here

2 Likes

BTW welcome to the forum :smile:

2 Likes

Thanks - I should have read a bit more carefully!

Phil