Eclipse調試Android App若選擇“Use same device for future launches”

來源:互聯網
上載者:User

標籤:android   future   blank   多媒體   target   

在狂批了某供應商的多媒體控制App有多爛後,誇下海口自己要做一個也是分分鐘的事。當然要做好不容易,要超過他們的爛軟體還是有信心的。過程中遇到各種坑,其中之一如下

剛開始只使用一個平板進行調試,老是彈出選擇裝置的視窗,於是勾選“Use same device for future launches”,於是Eclipse預設使用上次選擇的裝置進行調試。

650) this.width=650;" style="background-image: none; border-right- 0px; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto; padding-top: 0px" title="image" border="0" alt="image" src="http://s3.51cto.com/wyfs02/M02/83/1C/wKiom1drTN3BA-hYAAE_zxlNdss180.png" width="615" height="441" />

但是,隨後需要在另一個裝置(手機)進行調試時,Eclipse再也不讓我選擇了,即使你在Debug Configurations > Android Application > Target裡選擇了“Always prompt to pick device”也無用。

650) this.width=650;" style="background-image: none; border-right- 0px; padding-left: 0px; padding-right: 0px; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://s3.51cto.com/wyfs02/M00/83/1C/wKioL1drTOChPFNFAAEh_mDYGEc944.png" width="956" height="347" />

這應該這算是一個小bug,找了一圈解決方案如下。

將所有真機裝置拔除,然後準備一個虛擬設備AVD(Android Virtual Devices),這時在Debug Configurations裡選擇Always prompt to pick device,然後進行Debug,這時就會彈出選擇裝置(Android Device Chooser)的對話方塊。但是這時如果沒有選擇一個裝置,OK按鈕是灰色的,也就是說即使取消勾選“Use same device for future launches”沒有點OK也是無用,這時虛擬設備就派上用場了,選擇這個虛擬設備,OK。下次請謹慎選擇“Use same device for future launches”選項。

Eclipse調試Android App若選擇“Use same device for future launches”

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.