| 注册
请输入搜索内容

热门搜索

Java Linux MySQL PHP JavaScript Hibernate jQuery Nginx
WarScullin
7年前发布

Android开源: 一个 Menu 控件

   <h2>简介</h2>    <p>这是一个简单的圆形菜单进度效果。 它用于一些需要逐步完成的项目。周围的默认颜色是深灰色,当你做任务涉及到某个圆圈的颜色会变绿,当你完成它们的蓝色。 当然,你可以改变这三种状态颜色,你喜欢在xml.Just复制我的代码,如果你需要这样一个菜单,这是很容易理解。 任何建议,请发送到:stewforani@gmail.com。 谢谢!</p>    <p>下载<a href="/misc/goto?guid=4959735236489857629"><strong>apk</strong></a></p>    <p><a href="/misc/goto?guid=4959735236566958234"><img src="https://simg.open-open.com/show/0a1bc1ea63c7535576bdd16725280c81.png"></a> <a href="/misc/goto?guid=4959735236655054924"><img src="https://simg.open-open.com/show/6bf5baaac9c216af45d922113059a3d0.png"></a> <a href="/misc/goto?guid=4959735236748992949"><img src="https://simg.open-open.com/show/dea47d11c450c05c84199a96d99b290d.png"></a></p>    <h2>如何使用</h2>    <pre>  <code class="language-java">//amount of the circles around  private int aroundCircleCount = 7;    //the currrent progress num(=<aroundCircleCount)  private int currentProgressNum = 3;    //Icons of around circle (set by yourself)  private int[] circleIcon = {R.drawable.xxx,"","","","","",""};    //the en and cn of the circles around  private int[] aroundCircleTitleEn = {R.string.xxx,"","","","","",""};  private int[] aroundCircleTitleCn = {R.string.xxx,"","","","","",""};    //status of every circle  //default->grey,doing->green,complete->blue  //three status and color set by yourself  private int[] circleCompleteStatusList = {"","","","","","",""};</code></pre>    <pre>  <code class="language-java">final CircleLayout circleLayout = (CircleLayout) findViewById(R.id.circle_layout);    circleLayout.setView(aroundCircleTitleEn,                        aroundCircleTitleCn,                       circleIcon,                       aroundCircleCount,                       circleCompleteStatusList);    circleLayout.setProgressNum(currentProgressNum);  circleLayout.initView();  circleLayout.startAnim(360f * currentProgressNum / 7);  circleLayout.setOnClickListener(new CircleLayout.circleClickListener() {      @Override      public void click(int tag) {      //the tag of circle which you click      }  });</code></pre>    <pre>  <code class="language-java"><com.stew.myapplication.CircleLayout      android:id="@+id/circle_layout"      android:layout_width="match_parent"      android:layout_height="match_parent"                                         app:aroundCircleCompleteColor="@color/around_circle_complete_color"      app:aroundCircleDefColor="@color/around_circle_def_color"      app:aroundCircleDoingColor="@color/around_circle_doing_color"      app:centerArcColor="@color/arc_change"      app:centerArcColorDef="@color/arc_default"      app:centerCircleColor="@color/center_circle_color"      app:centerCircleText="Start"      app:centerCircleTextColor="@color/white"      app:centerCircleTextSize="22sp"      app:aroundSmallCircleColor="@color/white"      app:titleSize="12sp"      app:titleColor="@color/white"/></code></pre>    <p> </p>    
 本文由用户 WarScullin 自行上传分享,仅供网友学习交流。所有权归原作者,若您的权利被侵害,请联系管理员。
 转载本站原创文章,请注明出处,并保留原始链接、图片水印。
 本站是一个以用户分享为主的开源技术平台,欢迎各类分享!
 本文地址:https://www.open-open.com/lib/view/open1484660660255.html
Android Android开发 移动开发