-
Notifications
You must be signed in to change notification settings - Fork 334
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1978 from ZhuHongen/master
- Loading branch information
Showing
5 changed files
with
127 additions
and
0 deletions.
There are no files selected for viewing
27 changes: 27 additions & 0 deletions
27
...1614080902146/app/src/main/java/com/example/hzu/msoft1614080902146/Soft1614080902146.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
package com.example.hzu.msoft1614080902146; | ||
|
||
import android.content.Intent; | ||
import android.support.v7.app.AppCompatActivity; | ||
import android.os.Bundle; | ||
import android.view.View; | ||
import android.widget.TextView; | ||
|
||
public class Soft1614080902146 extends AppCompatActivity { | ||
|
||
private TextView textView; | ||
|
||
@Override | ||
protected void onCreate(Bundle savedInstanceState) { | ||
super.onCreate(savedInstanceState); | ||
setContentView(R.layout.activity_soft1614080902146); | ||
|
||
textView=(TextView)findViewById(R.id.text_view); | ||
textView.setOnClickListener(new View.OnClickListener() { | ||
@Override | ||
public void onClick(View v) { | ||
Intent intent=new Intent(Soft1614080902146.this,Soft16140809021462.class); | ||
startActivity(intent); | ||
} | ||
}); | ||
} | ||
} |
14 changes: 14 additions & 0 deletions
14
...614080902146/app/src/main/java/com/example/hzu/msoft1614080902146/Soft16140809021462.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
package com.example.hzu.msoft1614080902146; | ||
|
||
|
||
import android.support.v7.app.AppCompatActivity; | ||
import android.os.Bundle; | ||
|
||
public class Soft16140809021462 extends AppCompatActivity { | ||
|
||
@Override | ||
protected void onCreate(Bundle savedInstanceState) { | ||
super.onCreate(savedInstanceState); | ||
setContentView(R.layout.activity_soft16140809021462); | ||
} | ||
} |
19 changes: 19 additions & 0 deletions
19
soft1614080902146/app/src/main/res/layout/activity_soft1614080902146.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android" | ||
xmlns:app="http://schemas.android.com/apk/res-auto" | ||
xmlns:tools="http://schemas.android.com/tools" | ||
android:layout_width="match_parent" | ||
android:layout_height="match_parent" | ||
tools:context="com.example.hzu.msoft1614080902146.Soft1614080902146"> | ||
|
||
<TextView | ||
android:layout_width="wrap_content" | ||
android:layout_height="wrap_content" | ||
android:background="@drawable/timg" | ||
android:id="@+id/text_view" | ||
app:layout_constraintBottom_toBottomOf="parent" | ||
app:layout_constraintLeft_toLeftOf="parent" | ||
app:layout_constraintRight_toRightOf="parent" | ||
app:layout_constraintTop_toTopOf="parent" /> | ||
|
||
</android.support.constraint.ConstraintLayout> |
17 changes: 17 additions & 0 deletions
17
soft1614080902146/app/src/main/res/layout/activity_soft16140809021462.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<RelativeLayout | ||
xmlns:android="http://schemas.android.com/apk/res/android" | ||
xmlns:app="http://schemas.android.com/apk/res-auto" | ||
xmlns:tools="http://schemas.android.com/tools" | ||
android:layout_width="match_parent" | ||
android:layout_height="match_parent" | ||
tools:context="com.example.hzu.msoft1614080902146.Soft16140809021462"> | ||
|
||
<TextView | ||
android:layout_width="match_parent" | ||
android:layout_height="match_parent" | ||
android:textSize="22sp" | ||
android:text="这是第二个页面" | ||
android:gravity="center"/> | ||
|
||
</RelativeLayout> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
# 第一次实验 | ||
# 第三次实验 | ||
|
||
## 1.实验要求 | ||
掌握在Android应用中使用图片等资源的方法。 | ||
# 2.实验步骤 | ||
(1)在界面上显示至少一张图片(按照自己的题目添加); | ||
(2)提交res/drawable及图片使用的代码; | ||
(3)提交res/values, res/layout等其他代码; | ||
(4)将应用运行结果截图,放到实验报告中; | ||
(5)点击图片(或按钮)时,打开另一个Activity。 | ||
## 3.实验步骤 | ||
(1)阅读实验要求:https://github.com/hzuapps/android-labs-2018/labels/Lab | ||
(2)在电脑上Android Studio编写代码 | ||
// 代码要可以运行! | ||
(3)使用Git将代码提交到自己的库中:https://github.com/Qiujialin/android-labs-2018 | ||
## 1.实验要求 | ||
掌握在Android应用中使用图片等资源的方法。 | ||
## 2.实验步骤 | ||
(1)在界面上显示至少一张图片(按照自己的题目添加); | ||
(2)提交res/drawable及图片使用的代码; | ||
(3)提交res/values, res/layout等其他代码; | ||
(4)将应用运行结果截图,放到实验报告中; | ||
(5)点击图片(或按钮)时,打开另一个Activity。 | ||
## 3.实验步骤 | ||
(1)阅读实验要求:https://github.com/hzuapps/android-labs-2018/labels/Lab | ||
(2)在电脑上Android Studio编写代码 | ||
// 代码要可以运行! | ||
(3)使用Git将代码提交到自己的库中:https://github.com/Qiujialin/android-labs-2018 | ||
$ git pull | ||
$ git add soft1614080902146/* | ||
$ git commit "#3 #899 今日头条 " | ||
$ git commit "#3 #899 今日头条 " | ||
$ git push | ||
(4)在自己的GitHub库上创建和发送Pull Request(注意查看Changed files) | ||
// 是否只修改了自己的文件? | ||
(5)在GitHub中使用Markdown文件编写实验报告(report3.md) | ||
// 保存在自己的文件夹下 | ||
-## 4.实验结果 | ||
|
||
## 5.实验体会 | ||
通过本次实验学会了添加背景图片,创建一个Button、Activity,并且知道如何实现Activity的跳转。 | ||
(4)在自己的GitHub库上创建和发送Pull Request(注意查看Changed files) | ||
// 是否只修改了自己的文件? | ||
(5)在GitHub中使用Markdown文件编写实验报告(report3.md) | ||
// 保存在自己的文件夹下 | ||
## 4.实验结果 | ||
|
||
## 5.实验体会 | ||
通过本次实验学会了添加背景图片,创建一个Button、Activity,并且知道如何实现Activity的跳转。 |