【问题标题】:Not able to set custom color in SimpleArcLoader in android无法在 android 的 SimpleArcLoader 中设置自定义颜色
【发布时间】:2016-07-19 22:17:15
【问题描述】:

这是我用作进度条的 SimpleArcLoader 库。

https://github.com/generic-leo/SimpleArcLoader

这是我的代码:

int[] colors = {R.color.colorPrimaryDark, R.color.colorPrimary};

ArcConfiguration configuration = new ArcConfiguration(getActivity());
configuration.setColors(colors);

SimpleArcDialog  mDialog = new SimpleArcDialog(getActivity());
mDialog.setConfiguration(configuration);
mDialog.show();

这总是给我一个灰色的颜色。我也尝试了其他颜色,但结果相同。

Here is a screenshot

我的输入有误吗?或者有什么解决办法?

【问题讨论】:

    标签: java android progressdialog android-progressbar


    【解决方案1】:

    你必须像这样声明你的数组颜色: 私有 int mColors[] = {Color.parseColor("#F90101"),Color.parseColor("#0266C8")};

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2014-10-30
      • 1970-01-01
      • 1970-01-01
      • 2020-04-21
      • 1970-01-01
      • 2020-05-11
      • 1970-01-01
      相关资源
      最近更新 更多