0

I am trying to set up a surface view for graphics but an error keeps showing up that I have to import SView when I already did. Everything I try never seems to work. Is anything missing in the following code? or is it that I forgot to add something.

Firstclass.java:

package com.XXX.XXX;

import android.app.Activity;
import android.os.Bundle;
import android.view.View;

import com.mtprogramming.blockfight.SView;

SView ourView;
 public class Singleplayer extends Activity {



@Override
protected void onCreate(Bundle savedInstanceState) {
    // TODO Auto-generated method stub
    super.onCreate(savedInstanceState);
    ourView = new SView(this);
    setContentView(ourView);

}




}

SView:

package com.XXX.XXX;

public class SView extends SurfaceView implements Runnable{

public SView(Singleplayer singleplayer) {
    // TODO Auto-generated constructor stub
}

public void run(){

}

}
verymessi
  • 117
  • 1
  • 12

1 Answers1

0

Check the package for SView.java: com.XXX.XXX it intended as so?

If yes, use import com.XXX.XXX.Sview instead of import com.mtprogramming.blockfight.SView in Firstclass.java

ecle
  • 3,952
  • 1
  • 18
  • 22