android scrollby
来源:互联网 发布:怎么淘宝拍卖二手货 编辑:程序博客网 时间:2024/06/06 10:48
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent" > <Button android:id="@+id/button1" android:layout_width="75dip" android:layout_height="50dip" android:text="button1button2button3button4button5button6" /> <Button android:id="@+id/button2" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Button" /> </LinearLayout>
代码
package com.example.ss;import android.os.Bundle;import android.app.Activity;import android.view.Menu;import android.view.View;import android.view.View.OnClickListener;import android.widget.Button;public class MainActivity extends Activity {Button btn2,btn1; @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); btn1 = (Button) findViewById(R.id.button1); btn2 = (Button) findViewById(R.id.button2); btn2.setOnClickListener(new OnClickListener() {@Overridepublic void onClick(View v) {// TODO Auto-generated method stub//btn1.layout(100, 100, 300, 300);//容器左上为0,0// L 控件左边离容器左边的距离// T 控件顶部离容器顶部的距离// R 控件右边离容器左边的距离// B 控件底部离容器顶部的距离btn1.scrollBy(0,20);}}); } @Override public boolean onCreateOptionsMenu(Menu menu) { getMenuInflater().inflate(R.menu.activity_main, menu); return true; }}
- android scrollby
- Android View scrollTo scrollBy
- android scrollto scrollby 扯一扯
- 【Android】【滑屏】scrollTo,scrollBy
- Android滑动--scrollTo()、scrollBy()
- [Android] View scrollTo()与scrollBy()
- Android中的scrollBy和scrollTo
- android中scrollTo和scrollBy的理解~~
- Android View 的scrollTo 和 scrollBy方法
- Android滑屏 mScrollX mScrollY scrollTo() scrollBy()
- android中scrollTo和scrollBy的理解
- android中scrollTo和scrollBy的理解~~
- Android scrollTo() scrollBy() Scroller讲解及应用
- Android scrollTo() scrollBy() scroller 学习总结
- 【Android 疑难杂症】scrollTo和scrollBy探究
- Android Scroller入门(一)之ScrollTo、ScrollBy
- android中scrollTo和scrollBy的理解
- Android scrollTo() scrollBy() Scroller讲解及应用
- 关于爱情 (转)
- UIApplication深入学习
- Android display架构分析
- 《每日编程》----《设计模式》----《三》----bridge模式
- git命令小结
- android scrollby
- 网页换肤色的代码
- python学习笔记-安装mysql-python:EnvironmentError: mysql_config not found
- Apache CXF 2.7学习
- nginx+php的配置
- android学习笔记-序
- CreateMainWindow 创建主窗口属性
- EDM(邮件营销)
- 学习vi和vim编辑器——第三章 快速移动位置