2011-01-22 116 views

回答

26

執行下面的代碼:

float scale = getApplicationContext().getResources().getDisplayMetrics().density; 

並檢查scale值:

  • 0.75裝置低密度
  • 1.0裝置標準(介質) DENSI TY
  • 1.5裝置高(大)密度
  • 2.0裝置額外高密度
  • 3.0裝置額外額外高密度
  • 4.0裝置額外額外額外高密度

查看documentation瞭解更多信息。

+0

嗨chirag如果可能pls看到帖子http://stackoverflow.com/questions/4758278/redraw-image-on-canvas-on-touch-event – Hitendra 2011-01-22 05:04:25

相關問題