第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號(hào)安全,請(qǐng)及時(shí)綁定郵箱和手機(jī)立即綁定
已解決430363個(gè)問題,去搜搜看,總會(huì)有你想問的

能幫我把后面 怎么讓 畫出的方塊下落代碼補(bǔ)充寫出來嗎?謝謝了

能幫我把后面 怎么讓 畫出的方塊下落代碼補(bǔ)充寫出來嗎?謝謝了

此生不變丶 2016-06-15 15:38:29
package?zuoye20160615; import?java.awt.Color; import?java.awt.Graphics; import?javax.swing.JFrame; import?javax.swing.JPanel; /**?*?@author??作者?E-mail:? @date?創(chuàng)建時(shí)間:2016年6月15日?下午2:40:27? ?*/ public?class?TuXing?extends?JFrame{ MyPanel?mp; public?static?void?main(String[]?args){ TuXing?jf?=?new?TuXing();//?調(diào)用TuXing?的構(gòu)造函數(shù) } public?TuXing(){ mp?=?new?MyPanel();//?調(diào)用?JPanel?的?paintComponent的方法 this.add(mp);//把Panel放到JFrame中 this.setTitle("方塊下落");//邊框名字 this.setSize(500,500);//邊框大小 this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);//關(guān)閉按鈕 this.setVisible(true);//界面可視 } } class?MyPanel?extends?JPanel{ protected?void?paintComponent(Graphics?g){ g.setColor(Color.black);//填充顏色 g.fillRect(20,?50,?100,?100);//畫出一個(gè)矩形 } }
查看完整描述

2 回答

  • 2 回答
  • 1 關(guān)注
  • 1909 瀏覽

添加回答

舉報(bào)

0/150
提交
取消
微信客服

購課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動(dòng)學(xué)習(xí)伙伴

公眾號(hào)

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號(hào)