本文整理汇总了Java中com.google.android.glass.widget.CardBuilder.setText方法的典型用法代码示例。如果您正苦于以下问题:Java CardBuilder.setText方法的具体用法?Java CardBuilder.setText怎么用?Java CardBuilder.setText使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.google.android.glass.widget.CardBuilder
的用法示例。
在下文中一共展示了CardBuilder.setText方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: buildView
import com.google.android.glass.widget.CardBuilder; //导入方法依赖的package包/类
/**
* Builds a Glass styled "Hello World!" view using the {@link CardBuilder} class.
*/
private View buildView() {
CardBuilder card = new CardBuilder(this, CardBuilder.Layout.TEXT);
card.setText(R.string.hello_world);
return card.getView();
}
示例2: addNoteCardToAdapter
import com.google.android.glass.widget.CardBuilder; //导入方法依赖的package包/类
private void addNoteCardToAdapter( Note note ) {
CardBuilder cb = new CardBuilder( this, Layout.TEXT );
cb.setText( note.getBody() );
if( mEmptyCardsList ) {
mCards.clear();
mEmptyCardsList = false;
}
mCards.add( cb );
}
示例3: buildView
import com.google.android.glass.widget.CardBuilder; //导入方法依赖的package包/类
/**
* Builds a Glass styled "Hello World!" view using the {@link CardBuilder} class
*/
private View buildView(String text) {
CardBuilder card = new CardBuilder(this, CardBuilder.Layout.TEXT);
card.setText(text);
return card.getView();
}
示例4: buildView
import com.google.android.glass.widget.CardBuilder; //导入方法依赖的package包/类
private View buildView() {
CardBuilder card = new CardBuilder(this, CardBuilder.Layout.TEXT);
card.setText(R.string.instructions);
return card.getView();
}
示例5: buildThirdView
import com.google.android.glass.widget.CardBuilder; //导入方法依赖的package包/类
private View buildThirdView(String textToDisplay) {
CardBuilder card = new CardBuilder(this, CardBuilder.Layout.TEXT);
card.setText(textToDisplay);
return card.getView();
}
示例6: buildView
import com.google.android.glass.widget.CardBuilder; //导入方法依赖的package包/类
private View buildView() {
CardBuilder card = new CardBuilder(this, CardBuilder.Layout.TEXT);
card.setText("Whatever");
return card.getView();
}