I have a class Scores.java I need to know whats the correct way to create these. I get "The constructor Scores is not defined. Do I have to extend off everything in Android??
package com.threeuglymen.android.stuff;
import android.app.Application;
import android.app.Service;
import android.content.Context;
import android.content.Intent;
import android.content.SharedPreferences;
import android.content.SharedPreferences.Editor;
import android.preference.PreferenceManager;
import android.util.Log;
public class Scores {
private Context mycontext;
public Scores (Context context) {
// TODO Auto-generated method stub
this.mycontext = context;
}
public void resetScores(){
try {
SharedPreferences pref = PreferenceManager.getDefaultSharedPreferences(mycontext);
Editor edit = pref.edit();
edit.putInt("correct", 0);
edit.putInt("incorrect", 0);
edit.commit();
} catch (Exception e) {
Log.d("Scores", "Exception:" + e.toString());
}
return;
}
}
Thx for any guidance
Eric