How to access the element of SurfaceView
<p>I have the button outside the GameView which extends SurfaceView</p>

<pre><code>&lt;Button
    android:id="@+id/move"
    android:text="@string/move"
    android:textStyle="bold"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
/&gt;
&lt;demo.android.life.GameView
    android:id="@+id/game"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
/&gt;
</code></pre>

<p>Constructor creates GameManager</p>

<pre><code>public GameView(Context context, AttributeSet attrs)
{
    super(context, attrs);
    mSurfaceHolder = getHolder();
    mSurfaceHolder.addCallback(this);
    mThread = new GameManager(mSurfaceHolder, context);
}
</code></pre>

<p>GameManager creates GameObject</p>

<pre><code>public GameManager(SurfaceHolder surfaceHolder, Context context)
{
    mSurfaceHolder = surfaceHolder;
    mRunning = false;

    mPaint = new Paint();
    mPaint.setColor(Color.BLUE);
    mPaint.setStrokeWidth(2);
    mPaint.setStyle(Style.STROKE);

    Resources res = context.getResources();
    player1 = new Player(res.getDrawable(R.drawable.player));
}
</code></pre>

<p>GameObject has method AddMove() that I want to access</p>

<pre><code>public class Player extends GameObject
{
private int moveLeft = 0;
private static final int STEP = 2;

public Player(Drawable image)
{
    super(image);
}

@Override
protected void updatePoint()
{
    if(moveLeft &gt; STEP)
    {
        mPoint.x += STEP;
        moveLeft -= STEP;
    }
}

public void AddMove(int move)
{
    moveLeft += move;
}
}
</code></pre>

<p>Added more code, hope it will be enough</p>
