【问题标题】:Setting app icon as progress bar in android在android中将应用程序图标设置为进度条
【发布时间】:2015-06-03 04:20:44
【问题描述】:

在启动屏幕上的我的 android 应用程序上,我需要将我的应用程序图标设置为旋转进度条,我该如何实现它。

谁能帮我写代码? 例如

图片是一个应用程序的屏幕截图,它使用被包围的图像作为进度条。我需要完全实现这一点。

【问题讨论】:

    标签: android android-studio progress-bar


    【解决方案1】:

    尝试以下代码进行旋转。

    ImageView rotate_image =(ImageView) findViewById(R.id.your_image);
    RotateAnimation rotate = new RotateAnimation(30, 360, Animation.RELATIVE_TO_SELF, 0.5f, Animation.RELATIVE_TO_SELF, 0.5f);
    rotate.setDuration(2500);
    rotate_image.startAnimation(rotate);
    

    希望这会有所帮助。谢谢

    【讨论】:

      猜你喜欢
      • 2011-07-18
      • 1970-01-01
      • 2020-07-01
      • 1970-01-01
      • 2019-04-03
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多