JAVA上机题库:二级Java上机题
来源:优易学  2010-1-15 14:48:09   【优易学:中国教育考试门户网】   资料下载   IT书店


               ___paint___();    //此下划线中间的部分为要改正的部分

             }

         });

       }

      public void update(Graphics g) {

      ___repaint(g)___;      //此下划线中间的部分为要改正的部分

      }

      public void paint(Graphics g) {

         for(int I=0;I<points.size();I++) {

          Point dot=(Point)points.elementAt(I);

          g.drawString("x",dot.x,dot.y);

        }

      }

      public static void main(String args[]) {

          Frame fram=new Frame("CelayTree");

          SimpleHitMouse dot=new SimpleHitMouse();

          dot.init();

          dot.start();

          fram.add("Center",dot);

          fram.setSize(400,300);

          fram.addWindowListener(new WindowAdapter(){

            public void windowClosing(WindowEvent e)

               {System.exit(0);}

            });

上一页  [1] [2] [3] [4] 下一页

责任编辑:cyth

文章搜索:
 相关文章
热点资讯
资讯快报
热门课程培训