| 注册
请输入搜索内容

热门搜索

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

Android开源:ExpandableViewpager - 可以展开缩放的 Viewpager

   <p>这是很酷一个可以展开,缩小的Viewpager。</p>    <p style="text-align:center"><img src="https://simg.open-open.com/show/77b0d5da1881b0ce7700f6f28ea7a90f.gif"></p>    <h2>使用</h2>    <p>在gradle添加依赖</p>    <pre>  <code class="language-java">allprojects {          repositories {              ...              maven { url 'https://jitpack.io' }          }      }        dependencies {              compile 'com.github.githubwing:ExpandableViewpager:1.0.0'      }</code></pre>    <p>其次将ExpandableViewpager添加到布局。</p>    <p>ExpandViewPager提供了Viewpager常用方法以外。还有几个额外的方法:</p>    <pre>  <code class="language-java">//设置背景布局   mViewpager.setBackgroundView(int resId);     //设置最小高度   mViewpager.setMinHeight(int height);    //设置展开关闭监听器  mViewpager.setOnStateChangedListener(OnStateChangedListener listener);    //展开以及缩小  mViewpager.expand();  mViewpager.collaps();</code></pre>    <h2>License</h2>    <pre>  <code class="language-java">Copyright 2016 androidwing1992    Licensed under the Apache License, Version 2.0 (the "License");  you may not use this file except in compliance with the License.  You may obtain a copy of the License at        http://www.apache.org/licenses/LICENSE-2.0    Unless required by applicable law or agreed to in writing, software  distributed under the License is distributed on an "AS IS" BASIS,  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the License for the specific language governing permissions and  limitations under the License.</code></pre>    <p> </p>    <p> </p>    
 本文由用户 CorChilders 自行上传分享,仅供网友学习交流。所有权归原作者,若您的权利被侵害,请联系管理员。
 转载本站原创文章,请注明出处,并保留原始链接、图片水印。
 本站是一个以用户分享为主的开源技术平台,欢迎各类分享!
 本文地址:https://www.open-open.com/lib/view/open1481613900955.html
ViewPager Android开发 移动开发