androiddeveloperken / beginnginandroidgames2

Automatically exported from code.google.com/p/beginnginandroidgames2
0 stars 0 forks source link

Deprecated code in game framework #4 #5

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
in AndroidInput.java

public AndroidInput(Context context, View view, float scaleX, float scaleY) {
        accelHandler = new AccelerometerHandler(context);
        keyHandler = new KeyboardHandler(view);               
        if (Integer.parseInt(VERSION.SDK) < 5) 
            touchHandler = new SingleTouchHandler(view, scaleX, scaleY);
        else
            touchHandler = new MultiTouchHandler(view, scaleX, scaleY);        
    }

the line that has "(Integer.parseInt(VERSION.SDK)" should instead be:

if (VERSION.SDK_INT < 5)

Original issue reported on code.google.com by davidtia...@gmail.com on 9 Jan 2013 at 9:09