# AFormChange **Repository Path**: quanke/AFormChange ## Basic Information - **Project Name**: AFormChange - **Description**: 一个免费的、开源的、简易的、遵循Apache Licence 2.0开源协议发布,超级容易扩展的android表单数据改变时处理的小框架 - **Primary Language**: Android - **License**: Apache-2.0 - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 11 - **Forks**: 3 - **Created**: 2015-04-14 - **Last Updated**: 2020-12-19 ## Categories & Tags **Categories**: android-modules **Tags**: None ## README #AFormChange android表单值修改框架 > AFormChange为库,可以直接导出jar包 > AFormChangeDemo为演示,快速学习使用AFormChange为库 ## AValidations使用 ## > 1.下载zip或者克隆AFormChange项目 > 2.导入Eclipse,右键工程->preference->Android->library->Add,选择AFormChange工程加入后 apply应用 > 3.demo private TextView tvChange; private EditText editText1; private EditText editText2; private Button button1; private FormHandler formHandler; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); tvChange = (TextView) findViewById(R.id.tv_change); editText1 = (EditText) findViewById(R.id.editText1); editText2 = (EditText) findViewById(R.id.editText2); button1 = (Button) findViewById(R.id.button1); formHandler = new FormHandler(ViewsUtil.getAllEditTexts(this)); //初始化数据和文本改变监听器,必须放在赋值之后 formHandler.initTextAndTextChangedListener(); button1.setOnClickListener(new OnClickListener() { @Override public void onClick(View v) { if (formHandler.isTextChange()) {//isTextChange判断是否改变 tvChange.setText("Change"); } else { tvChange.setText("Not Change"); } } }); } Copyright 2014 ken.cai (http://www.shangpuyun.com) 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.