Skip to content

Commit

Permalink
hzuapps#4 #学习软件 第4次实验
Browse files Browse the repository at this point in the history
  • Loading branch information
bujingyu committed May 10, 2018
1 parent 8caa842 commit 6e57770
Show file tree
Hide file tree
Showing 8 changed files with 185 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
package com.example.administrator.soft1614080902129;

import android.content.Intent;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;

public class MainActivity extends AppCompatActivity {

@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);

setContentView(R.layout.my_layout);
findViewById(R.id.btnStarAnotherAty).setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {
startActivity(new Intent(MainActivity.this,Soft1614080902129MainActivity.class));
}
});


}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
package com.example.administrator.soft1614080902129;

import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;

public class Soft1614080902129MainActivity extends AppCompatActivity {

@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_soft1614080902129_main);
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
17 changes: 17 additions & 0 deletions soft1614080902129/app3/src/main/res/layout/activity_main.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?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.administrator.soft1614080902129.MainActivity">

<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="nihao!"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent" />
</android.support.constraint.ConstraintLayout>
Original file line number Diff line number Diff line change
@@ -0,0 +1,112 @@
<?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=".Soft1614080902129MainActivity">


<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:background="@drawable/soft1614080902129"
android:layout_alignParentBottom="true"
android:layout_alignParentLeft="true"
android:layout_alignParentStart="true">

<ImageView
android:id="@+id/imageView"
android:layout_width="70dp"
android:layout_height="70dp"
android:layout_weight="1"
app:srcCompat="@drawable/jingyu"
android:layout_above="@+id/imageView4"
android:layout_alignLeft="@+id/imageView4"
android:layout_alignStart="@+id/imageView4"
android:layout_marginBottom="12dp" />

<ImageView
android:id="@+id/imageView2"
android:layout_width="70dp"
android:layout_height="70dp"
android:layout_alignParentStart="true"
android:layout_alignTop="@+id/imageView"
android:layout_marginStart="154dp"
android:layout_weight="1"
app:srcCompat="@drawable/jingyu" />

<ImageView
android:id="@+id/imageView3"
android:layout_width="70dp"
android:layout_height="70dp"
android:layout_weight="1"
app:srcCompat="@drawable/jingyu"
android:layout_alignTop="@+id/imageView2"
android:layout_alignRight="@+id/imageView9"
android:layout_alignEnd="@+id/imageView9" />

<ImageView
android:id="@+id/imageView4"
android:layout_width="70dp"
android:layout_height="70dp"
android:layout_weight="1"
app:srcCompat="@drawable/jingyu"
android:layout_alignTop="@+id/imageView5"
android:layout_toLeftOf="@+id/imageView8"
android:layout_toStartOf="@+id/imageView8"
android:layout_marginRight="24dp"
android:layout_marginEnd="24dp" />

<ImageView
android:id="@+id/imageView5"
android:layout_width="70dp"
android:layout_height="70dp"
android:layout_weight="1"
app:srcCompat="@drawable/jingyu"
android:layout_above="@+id/imageView7"
android:layout_centerHorizontal="true"
android:layout_marginBottom="11dp" />

<ImageView
android:id="@+id/imageView6"
android:layout_width="70dp"
android:layout_height="70dp"
android:layout_weight="1"
app:srcCompat="@drawable/jingyu"
android:layout_alignTop="@+id/imageView5"
android:layout_alignLeft="@+id/imageView3"
android:layout_alignStart="@+id/imageView3" />

<ImageView
android:id="@+id/imageView7"
android:layout_width="70dp"
android:layout_height="70dp"
android:layout_alignParentBottom="true"
android:layout_alignStart="@+id/imageView4"
android:layout_marginBottom="105dp"
android:layout_weight="1"
app:srcCompat="@drawable/jingyu" />

<ImageView
android:id="@+id/imageView8"
android:layout_width="70dp"
android:layout_height="70dp"
android:layout_alignParentBottom="true"
android:layout_alignStart="@+id/imageView2"
android:layout_marginBottom="97dp"
android:layout_weight="1"
app:srcCompat="@drawable/jingyu" />

<ImageView
android:id="@+id/imageView9"
android:layout_width="70dp"
android:layout_height="70dp"
android:layout_alignParentEnd="true"
android:layout_alignTop="@+id/imageView8"
android:layout_marginEnd="66dp"
android:layout_weight="1"
app:srcCompat="@drawable/jingyu" />
</RelativeLayout>

</RelativeLayout>
18 changes: 18 additions & 0 deletions soft1614080902129/app3/src/main/res/layout/my_layout.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent">

<Button
android:id="@+id/btnStarAnotherAty"
android:layout_width="143dp"
android:layout_height="338dp"
android:layout_marginTop="74dp"
android:drawableTop="@drawable/jingyu"
android:text="开始游戏"
android:gravity="center"
android:layout_alignParentTop="true"
android:layout_centerHorizontal="true" />
</RelativeLayout>
Binary file added soft1614080902129/youxi.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 6e57770

Please sign in to comment.