我可以知道,下面的代碼。什麼是TabHost.newTabSpec中使用的參數標籤的用法
// Initialize a TabSpec for each tab and add it to the TabHost
spec = tabHost.newTabSpec("artists").setIndicator("The Artists",
res.getDrawable(R.drawable.ic_tab_artists))
.setContent(intent);
什麼是具有「藝術家」的標籤作爲newTagSpec
參數的目的是什麼?我應該使用國際化字符串如
spec = tabHost.newTabSpec(getString(R.string.artists)).setIndicator(getString(R.string.the_artists),
res.getDrawable(R.drawable.ic_tab_artists))
.setContent(intent);
但是,這是否解釋了「組」標籤的用途?什麼是ic_tab_NameInNewTabSpec的方式? – 2011-04-21 02:50:49
這是您在newTabSpec()中使用的名稱...這就是「組」標籤的用途。它告訴編譯器使用ic_tab_groups。 – 2011-04-21 11:21:45
任何說明這就是它的文檔? – irwinb 2012-08-30 20:56:11