本文整理汇总了Java中net.qiujuer.genius.ui.widget.FloatActionButton类的典型用法代码示例。如果您正苦于以下问题:Java FloatActionButton类的具体用法?Java FloatActionButton怎么用?Java FloatActionButton使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
FloatActionButton类属于net.qiujuer.genius.ui.widget包,在下文中一共展示了FloatActionButton类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: initFloatActionButton
import net.qiujuer.genius.ui.widget.FloatActionButton; //导入依赖的package包/类
private void initFloatActionButton() {
final float density = getResources().getDisplayMetrics().density;
FloatActionButton addButton = (FloatActionButton) findViewById(R.id.action_add);
AddLineShape lineShape = new AddLineShape();
ShapeDrawable drawable = new ShapeDrawable(lineShape);
Paint paint = drawable.getPaint();
paint.setStyle(Paint.Style.STROKE);
paint.setAntiAlias(true);
paint.setDither(true);
paint.setColor(0xc0ffffff);
paint.setStrokeWidth(2 * density);
drawable.setIntrinsicWidth(100);
drawable.setIntrinsicHeight(100);
addButton.setImageDrawable(drawable);
addButton.setOnClickListener(this);
}
开发者ID:gentxq,项目名称:Genius-Android,代码行数:17,代码来源:MainActivity.java
示例2: onInit
import net.qiujuer.genius.ui.widget.FloatActionButton; //导入依赖的package包/类
@Override
protected void onInit(Bundle savedInstanceState) {
Intent intent = getIntent();
if (intent != null) {
String id = intent.getStringExtra("Id");
mId = UUID.fromString(id);
}
mPresenter = new ContactDetailPresenter(this);
mRelationStr = getResources().getStringArray(R.array.array_contacts_relations);
// InitList
RecyclerView recyclerView = (RecyclerView) findViewById(R.id.recycler_records);
View view = findViewById(R.id.text_status);
mAdapter = new ContactRecordsAdapter(mId, recyclerView, view, this);
// FindId
mContactsName = (TextView) findViewById(R.id.contacts_detail_txt_brief_name);
mContactsPhone = (TextView) findViewById(R.id.contacts_detail_txt_phone);
mContactsQq = (TextView) findViewById(R.id.contacts_detail_txt_QQ);
mContactsRelation = (TextView) findViewById(R.id.contacts_detail_txt_relation);
mFltAtnBtn = (FloatActionButton) findViewById(R.id.contacts_Detail_btn_to_edit);
mTop = findViewById(R.id.lay_top);
// Set onClick
mFltAtnBtn.setOnClickListener(this);
AnimJagDrawable drawable = new AnimJagDrawable();
drawable.setFluCount(new Rect(0, 0, 0, 36));
mTop.setLayerType(View.LAYER_TYPE_SOFTWARE, null);
mTop.setBackgroundDrawable(drawable);
}
开发者ID:qiujuer,项目名称:UPMiss,代码行数:32,代码来源:ContactDetailActivity.java
示例3: initFloatActionButton
import net.qiujuer.genius.ui.widget.FloatActionButton; //导入依赖的package包/类
private void initFloatActionButton() {
FloatActionButton addButton = (FloatActionButton) findViewById(R.id.action_add);
Drawable drawable = Drawables.getCreateDrawable(getResources());
addButton.setImageDrawable(drawable);
addButton.setOnClickListener(this);
}
开发者ID:PowerBack,项目名称:AnKey,代码行数:7,代码来源:MainActivity.java
示例4: initFloatActionButton
import net.qiujuer.genius.ui.widget.FloatActionButton; //导入依赖的package包/类
private void initFloatActionButton() {
FloatActionButton actionButton = (FloatActionButton) findViewById(R.id.action_submit);
Drawable drawable = Drawables.getOkDrawable(getResources());
actionButton.setImageDrawable(drawable);
actionButton.setOnClickListener(this);
}
开发者ID:PowerBack,项目名称:AnKey,代码行数:7,代码来源:CreateActivity.java
注:本文中的net.qiujuer.genius.ui.widget.FloatActionButton类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论