package my.AChartTest2;

import java.io.DataInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.net.URL;
import java.net.URLConnection;

import android.app.Activity;
import android.graphics.Canvas;
import android.os.Bundle;
import android.util.Log;

public class main extends Activity {
 /** Called when the activity is first created. */
 static KAmtChart m_AmtChart;

 @Override
 public void onCreate(Bundle savedInstanceState) {
  super.onCreate(savedInstanceState);

  m_AmtChart = new KAmtChart(this);
  StartReadData(m_Code, m_CodeName, m_CodeID, m_Term);
 }
 public static void StartReadData(String Code, String Name, int CodeID,
   int Term) {
  Thread AThread;
  AThread = new Thread(new main().new KReading(Code, Name, CodeID, Term),
    "Reading");
  AThread.start();
 }

 class KReading extends Object implements Runnable {
  KReading(String Code, String Name, int CodeID, int Term) {
  }

   public void run() {
   Log.d("main/run()","postInvalidate() start");
   m_AmtChart.postInvalidate();                             <-  호출안됨.ㅠㅠ
   Log.d("main/run()","postInvalidate() end");    
  }
}


----------------------------------------------------------------------------------------------------------------------
public class KAmtChart extends KChart
{
    public KAmtChart(Context context)
    {
     super(context);
    }

    public void onDraw(Canvas canvas)
    {
        //여기가 호출될줄 알았는데..안되네요..ㅠㅠ
    }
}
----------------------------------------------------------------------------------------------------------------------
public class KChart extends View
{
    public KChart (Context context)
    {
     super(context);
    }

    public void onDraw(Canvas canvas)
    {
    }
}





질문은

main Activity 에서

유저가 생성한 쓰레드에서 , 유저가 생성한 view 의 onDraw를 호출하기 위해서는

postInvalidate() 를 호출해야 한다고 하던데..

저런 식으로 호출을 하면 KAmtChart  의 onDraw() 가 호출이 안되더라구요...

어떤식으로 처리를 해야 하나요?ㅠ