本文整理汇总了Java中com.flyco.bannersamples.utils.DataProvider类的典型用法代码示例。如果您正苦于以下问题:Java DataProvider类的具体用法?Java DataProvider怎么用?Java DataProvider使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
DataProvider类属于com.flyco.bannersamples.utils包,在下文中一共展示了DataProvider类的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: sib
import com.flyco.bannersamples.utils.DataProvider; //导入依赖的package包/类
private void sib() {
sib
.setIndicatorGap(8) //set gap btween two indicators
.setSelectAnimClass(ZoomInEnter.class) //set indicator select anim
.setBarColor(Color.parseColor("#88000000")) //set bootom bar color
.setSource(DataProvider.getList()) //data source list
.setTransformerClass(transformerClass) //set page transformer
.startScroll(); //start scroll,the last method to call
sib.setOnItemClickL(new SimpleImageBanner.OnItemClickL() {
@Override
public void onItemClick(int position) {
T.showShort(context, "position--->" + position);
}
});
}
示例2: sib_res
import com.flyco.bannersamples.utils.DataProvider; //导入依赖的package包/类
private void sib_res() {
SimpleImageBanner sib = ViewFindUtils.find(decorView, R.id.sib_res);
sib
// .setIndicatorStyle(SimpleImageBanner.STYLE_DRAWABLE_RESOURCE)
// .setIndicatorSelectorRes(R.mipmap.banner_dot_unselect, R.mipmap.banner_dot_select)
.setSource(DataProvider.getList())
.startScroll();
sib.setOnItemClickL(new SimpleImageBanner.OnItemClickL() {
@Override
public void onItemClick(int position) {
T.showShort(context, "position--->" + position);
}
});
}
示例3: sib_corner_rectangle
import com.flyco.bannersamples.utils.DataProvider; //导入依赖的package包/类
private void sib_corner_rectangle() {
SimpleImageBanner sib = ViewFindUtils.find(decorView, R.id.sib_corner_rectangle);
sib
// .setIndicatorWidth(10)
// .setIndicatorHeight(4)
// .setIndicatorCornerRadius(2)
.setSource(DataProvider.getList())
.startScroll();
sib.setOnItemClickL(new SimpleImageBanner.OnItemClickL() {
@Override
public void onItemClick(int position) {
T.showShort(context, "position--->" + position);
}
});
}
示例4: sib_anim2
import com.flyco.bannersamples.utils.DataProvider; //导入依赖的package包/类
private void sib_anim2() {
SimpleImageBanner sib = ViewFindUtils.find(decorView, R.id.sib_anim2);
sib
// .setIndicatorWidth(10)
// .setIndicatorHeight(4)
// .setIndicatorCornerRadius(2)
.setSelectAnimClass(RotateEnter.class)
.setUnselectAnimClass(NoAnimExist.class)
.setSource(DataProvider.getList())
.startScroll();
sib.setOnItemClickL(new SimpleImageBanner.OnItemClickL() {
@Override
public void onItemClick(int position) {
T.showShort(context, "position--->" + position);
}
});
}
示例5: sib
import com.flyco.bannersamples.utils.DataProvider; //导入依赖的package包/类
private void sib() {
sib
.setIndicatorGap(8) //set gap btween two indicators
.setSelectAnimClass(ZoomInEnter.class) //set indicator select anim
.setBarColor(Color.parseColor("#88000000")) //set bootom bar color
.setSource(DataProvider.getList()) //data source list
.setTransformerClass(transformerClass) //set page transformer
.startScroll(); //start scroll,the last method to call
sib.setOnItemClickL(new SimpleImageBanner.OnItemClickL() {
@Override
public void onItemClick(int position) {
T.showShort(mContext, "position--->" + position);
}
});
}
示例6: sib_simple_usage
import com.flyco.bannersamples.utils.DataProvider; //导入依赖的package包/类
private void sib_simple_usage() {
SimpleImageBanner sib = ViewFindUtils.find(decorView, R.id.sib_simple_usage);
sib
.setSource(DataProvider.getList())
.startScroll();
sib.setOnItemClickL(new SimpleImageBanner.OnItemClickL() {
@Override
public void onItemClick(int position) {
T.showShort(context, "position--->" + position);
}
});
}
示例7: sib_the_most_comlex_usage
import com.flyco.bannersamples.utils.DataProvider; //导入依赖的package包/类
private void sib_the_most_comlex_usage() {
SimpleImageBanner sib = ViewFindUtils.find(decorView, R.id.sib_the_most_comlex_usage);
sib
/** methods in BaseIndicatorBanner */
// .setIndicatorStyle(BaseIndicaorBanner.STYLE_CORNER_RECTANGLE)//set indicator style
// .setIndicatorWidth(6) //set indicator width
// .setIndicatorHeight(6) //set indicator height
// .setIndicatorGap(8) //set gap btween two indicators
// .setIndicatorCornerRadius(3) //set indicator corner raduis
.setSelectAnimClass(ZoomInEnter.class) //set indicator select anim
/** methods in BaseBanner */
// .setBarColor(Color.parseColor("#88000000")) //set bootom bar color
// .barPadding(5, 2, 5, 2) //set bottom bar padding
// .setBarShowWhenLast(true) //set bottom bar show or not when the position is the last
// .setTextColor(Color.parseColor("#ffffff")) //set title text color
// .setTextSize(12.5f) //set title text size
// .setTitleShow(true) //set title show or not
// .setIndicatorShow(true) //set indicator show or not
// .setDelay(2) //setDelay before start scroll
// .setPeriod(10) //scroll setPeriod
.setSource(DataProvider.getList()) //data source list
.setTransformerClass(ZoomOutSlideTransformer.class) //set page transformer
.startScroll(); //start scroll,the last method to call
sib.setOnItemClickL(new SimpleImageBanner.OnItemClickL() {
@Override
public void onItemClick(int position) {
T.showShort(context, "position--->" + position);
}
});
}
示例8: sib_rectangle
import com.flyco.bannersamples.utils.DataProvider; //导入依赖的package包/类
private void sib_rectangle() {
SimpleImageBanner sib = ViewFindUtils.find(decorView, R.id.sib_rectangle);
sib
// .setIndicatorCornerRadius(0)
.setSource(DataProvider.getList())
.startScroll();
sib.setOnItemClickL(new SimpleImageBanner.OnItemClickL() {
@Override
public void onItemClick(int position) {
T.showShort(context, "position--->" + position);
}
});
}
示例9: sib_indicator_right_with_text
import com.flyco.bannersamples.utils.DataProvider; //导入依赖的package包/类
private void sib_indicator_right_with_text() {
SimpleImageBanner sib = ViewFindUtils.find(decorView, R.id.sib_indicator_right_with_text);
sib
.setSource(DataProvider.getList())
.startScroll();
sib.setOnItemClickL(new SimpleImageBanner.OnItemClickL() {
@Override
public void onItemClick(int position) {
T.showShort(context, "position--->" + position);
}
});
}
示例10: sib_indicator_left_with_text
import com.flyco.bannersamples.utils.DataProvider; //导入依赖的package包/类
private void sib_indicator_left_with_text() {
SimpleImageBanner sib = ViewFindUtils.find(decorView, R.id.sib_indicator_left_with_text);
sib
.setSource(DataProvider.getList())
.startScroll();
sib.setOnItemClickL(new SimpleImageBanner.OnItemClickL() {
@Override
public void onItemClick(int position) {
T.showShort(context, "position--->" + position);
}
});
}
示例11: sib_anim
import com.flyco.bannersamples.utils.DataProvider; //导入依赖的package包/类
private void sib_anim() {
SimpleImageBanner sib = ViewFindUtils.find(decorView, R.id.sib_anim);
sib
.setSelectAnimClass(ZoomInEnter.class)
.setSource(DataProvider.getList())
.startScroll();
sib.setOnItemClickL(new SimpleImageBanner.OnItemClickL() {
@Override
public void onItemClick(int position) {
T.showShort(context, "position--->" + position);
}
});
}
示例12: showSelectDialog
import com.flyco.bannersamples.utils.DataProvider; //导入依赖的package包/类
private void showSelectDialog(final boolean isSimpleImageBanner) {
ArrayList<String> itemList = new ArrayList<>();
for (Class<?> c : DataProvider.transformers) {
itemList.add(c.getSimpleName());
}
final String[] contents = new String[itemList.size()];
final NormalListDialog dialog = new NormalListDialog(context, itemList.toArray(contents));
dialog.title("Select Transformer")//
.cornerRadius(2)
.show();
dialog.setOnOperItemClickL(new OnOperItemClickL() {
@Override
public void onOperItemClick(AdapterView<?> parent, View view, int position, long id) {
if (isSimpleImageBanner) {
new BannerDialog(context)
.transformerClass(DataProvider.transformers[position])
.show();
return;
}
Intent intent = new Intent(context, UserGuideActivity.class);
intent.putExtra("isFromBannerHome", true);
intent.putExtra("position", position);
startActivity(intent);
}
});
}
示例13: onCreate
import com.flyco.bannersamples.utils.DataProvider; //导入依赖的package包/类
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_user_guide);
isFromBannerHome = getIntent().getBooleanExtra("isFromBannerHome", false);
int position = getIntent().getIntExtra("position", -1);
transformerClass = position != -1 ? DataProvider.transformers[position] : null;
decorView = getWindow().getDecorView();
sgb();
}