I'am writing android application with couple activities in eclipse. I have one object in MainActivity and I want it to be visible in all others activities, so i've made it:
public static cPlayer player = new cPlayer();
and when I do:
switch (MainActivity.player.getName())
I have error:
Cannot switch on a value of type String for source level below 1.7. Only convertible int values or enum variables are permitted
And it want to change JRE to 1.7. So i do it. But after that i have another error:
Android requires compiler compliance level 5.0 or 6.0. Found '1.7' instead. Please use Android Tools > Fix Project Properties.
But after that, the previous problem returns.
Please help.