@ -0,0 +1,14 @@
|
||||
*.iml
|
||||
.gradle
|
||||
/local.properties
|
||||
/.idea/caches
|
||||
/.idea/libraries
|
||||
/.idea/modules.xml
|
||||
/.idea/workspace.xml
|
||||
/.idea/navEditor.xml
|
||||
/.idea/assetWizardSettings.xml
|
||||
.DS_Store
|
||||
/build
|
||||
/captures
|
||||
.externalNativeBuild
|
||||
.cxx
|
@ -0,0 +1,3 @@
|
||||
# Default ignored files
|
||||
/shelf/
|
||||
/workspace.xml
|
@ -0,0 +1 @@
|
||||
Activity_FragmentTabHost
|
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="CompilerConfiguration">
|
||||
<bytecodeTargetLevel target="11" />
|
||||
</component>
|
||||
</project>
|
@ -0,0 +1,19 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="GradleMigrationSettings" migrationVersion="1" />
|
||||
<component name="GradleSettings">
|
||||
<option name="linkedExternalProjectsSettings">
|
||||
<GradleProjectSettings>
|
||||
<option name="testRunner" value="GRADLE" />
|
||||
<option name="distributionType" value="DEFAULT_WRAPPED" />
|
||||
<option name="externalProjectPath" value="$PROJECT_DIR$" />
|
||||
<option name="modules">
|
||||
<set>
|
||||
<option value="$PROJECT_DIR$" />
|
||||
<option value="$PROJECT_DIR$/app" />
|
||||
</set>
|
||||
</option>
|
||||
</GradleProjectSettings>
|
||||
</option>
|
||||
</component>
|
||||
</project>
|
@ -0,0 +1,25 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="RemoteRepositoriesConfiguration">
|
||||
<remote-repository>
|
||||
<option name="id" value="central" />
|
||||
<option name="name" value="Maven Central repository" />
|
||||
<option name="url" value="https://repo1.maven.org/maven2" />
|
||||
</remote-repository>
|
||||
<remote-repository>
|
||||
<option name="id" value="jboss.community" />
|
||||
<option name="name" value="JBoss Community repository" />
|
||||
<option name="url" value="https://repository.jboss.org/nexus/content/repositories/public/" />
|
||||
</remote-repository>
|
||||
<remote-repository>
|
||||
<option name="id" value="BintrayJCenter" />
|
||||
<option name="name" value="BintrayJCenter" />
|
||||
<option name="url" value="https://jcenter.bintray.com/" />
|
||||
</remote-repository>
|
||||
<remote-repository>
|
||||
<option name="id" value="Google" />
|
||||
<option name="name" value="Google" />
|
||||
<option name="url" value="https://dl.google.com/dl/android/maven2/" />
|
||||
</remote-repository>
|
||||
</component>
|
||||
</project>
|
@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ExternalStorageConfigurationManager" enabled="true" />
|
||||
<component name="ProjectRootManager" version="2" languageLevel="JDK_11" default="true" project-jdk-name="Android Studio default JDK" project-jdk-type="JavaSDK">
|
||||
<output url="file://$PROJECT_DIR$/build/classes" />
|
||||
</component>
|
||||
<component name="ProjectType">
|
||||
<option name="id" value="Android" />
|
||||
</component>
|
||||
</project>
|
@ -0,0 +1 @@
|
||||
/build
|
@ -0,0 +1,51 @@
|
||||
apply plugin: 'com.android.application'
|
||||
|
||||
android {
|
||||
compileSdkVersion 31
|
||||
buildToolsVersion "30.0.2"
|
||||
|
||||
defaultConfig {
|
||||
applicationId "ee.example.activity_fragmenttabhost"
|
||||
minSdkVersion 16
|
||||
targetSdkVersion 31
|
||||
versionCode 1
|
||||
versionName "1.0"
|
||||
|
||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
minifyEnabled false
|
||||
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
||||
}
|
||||
}
|
||||
compileOptions {
|
||||
|
||||
sourceCompatibility JavaVersion.VERSION_1_8
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation fileTree(dir: "libs", include: ["*.jar"])
|
||||
implementation 'androidx.appcompat:appcompat:1.2.0'
|
||||
implementation 'com.google.android.material:material:1.3.0'
|
||||
implementation 'androidx.constraintlayout:constraintlayout:2.0.4'
|
||||
testImplementation 'junit:junit:4.12'
|
||||
androidTestImplementation 'androidx.test.ext:junit:1.1.2'
|
||||
androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0'
|
||||
|
||||
implementation 'com.youth.banner:banner:1.4.10' //图片轮播最新版本
|
||||
//图片轮播框架
|
||||
|
||||
implementation 'com.github.bumptech.glide:glide:4.11.0'
|
||||
//recyclerview
|
||||
implementation 'androidx.recyclerview:recyclerview:1.1.0'
|
||||
//viewpager2
|
||||
implementation 'androidx.viewpager2:viewpager2:1.1.0-alpha01'
|
||||
|
||||
implementation 'com.qmuiteam:qmui:1.1.2'
|
||||
|
||||
implementation 'com.android.support:recyclerview-v7:30.0.0'
|
||||
}
|
@ -0,0 +1,21 @@
|
||||
# Add project specific ProGuard rules here.
|
||||
# You can control the set of applied configuration files using the
|
||||
# proguardFiles setting in build.gradle.
|
||||
#
|
||||
# For more details, see
|
||||
# http://developer.android.com/guide/developing/tools/proguard.html
|
||||
|
||||
# If your project uses WebView with JS, uncomment the following
|
||||
# and specify the fully qualified class name to the JavaScript interface
|
||||
# class:
|
||||
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
|
||||
# public *;
|
||||
#}
|
||||
|
||||
# Uncomment this to preserve the line number information for
|
||||
# debugging stack traces.
|
||||
#-keepattributes SourceFile,LineNumberTable
|
||||
|
||||
# If you keep the line number information, uncomment this to
|
||||
# hide the original source file name.
|
||||
#-renamesourcefileattribute SourceFile
|
@ -0,0 +1,26 @@
|
||||
package ee.example.activity_fragmenttabhost;
|
||||
|
||||
import android.content.Context;
|
||||
|
||||
import androidx.test.platform.app.InstrumentationRegistry;
|
||||
import androidx.test.ext.junit.runners.AndroidJUnit4;
|
||||
|
||||
import org.junit.Test;
|
||||
import org.junit.runner.RunWith;
|
||||
|
||||
import static org.junit.Assert.*;
|
||||
|
||||
/**
|
||||
* Instrumented test, which will execute on an Android device.
|
||||
*
|
||||
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
||||
*/
|
||||
@RunWith(AndroidJUnit4.class)
|
||||
public class ExampleInstrumentedTest {
|
||||
@Test
|
||||
public void useAppContext() {
|
||||
// Context of the app under test.
|
||||
Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext();
|
||||
assertEquals("ee.example.activity_fragmenttabhost", appContext.getPackageName());
|
||||
}
|
||||
}
|
@ -0,0 +1,44 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="ee.example.activity_fragmenttabhost">
|
||||
<uses-permission android:name="android.permission.INTERNET" />
|
||||
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
|
||||
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
|
||||
<application
|
||||
|
||||
android:allowBackup="true"
|
||||
android:icon="@mipmap/ic_launcher"
|
||||
android:label="@string/承德避暑山庄"
|
||||
android:roundIcon="@mipmap/ic_launcher_round"
|
||||
android:supportsRtl="true"
|
||||
android:theme="@style/AppTheme">
|
||||
<activity android:name=".LoginActivity"
|
||||
android:banner="@android:style/Theme.Light.NoTitleBar"
|
||||
android:exported="true">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN" />
|
||||
|
||||
<category android:name="android.intent.category.LAUNCHER" />
|
||||
</intent-filter>
|
||||
</activity>
|
||||
<activity
|
||||
android:name=".Content"
|
||||
android:label="详情"
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".MainActivity"
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".Regiter"
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".MainChangemima"
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".New1"
|
||||
android:exported="false" />
|
||||
|
||||
|
||||
</application>
|
||||
|
||||
</manifest>
|
@ -0,0 +1,34 @@
|
||||
package ee.example.activity_fragmenttabhost;
|
||||
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.TextView;
|
||||
|
||||
public class Content extends AppCompatActivity {
|
||||
private ImageView imageView1;
|
||||
private TextView textView1,textView2;
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
setContentView(R.layout.activity_content);
|
||||
intidata();
|
||||
if(Data.sat_con==0){
|
||||
imageView1.setImageResource(R.drawable.jinianguan);
|
||||
textView1.setText(R.string.con1);
|
||||
textView2.setText(R.string.con11);
|
||||
}
|
||||
else if(Data.sat_con==1){
|
||||
imageView1.setImageResource(R.drawable.jinian2);
|
||||
textView1.setText(R.string.con2);
|
||||
textView2.setText(R.string.con22);
|
||||
}
|
||||
}
|
||||
|
||||
private void intidata(){
|
||||
imageView1=(ImageView)findViewById(R.id.conImage1);
|
||||
textView1=findViewById(R.id.conText1);
|
||||
textView2=findViewById(R.id.conText2);
|
||||
}
|
||||
}
|
@ -0,0 +1,39 @@
|
||||
package ee.example.activity_fragmenttabhost;
|
||||
|
||||
import android.os.Bundle;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import android.os.Bundle;
|
||||
import android.view.View;
|
||||
|
||||
public class Data {
|
||||
|
||||
public static Boolean sta_dl=true;
|
||||
public static Boolean sta_np=false;
|
||||
public static String sta_name;
|
||||
public static String sta_password;
|
||||
public static int sat_con=0;
|
||||
public static ArrayList<Integer> images = new ArrayList<Integer>();
|
||||
public static void initView()
|
||||
{
|
||||
|
||||
|
||||
images.add(R.drawable.fj1);
|
||||
images.add(R.drawable.fj2);
|
||||
images.add(R.drawable.fj3);
|
||||
images.add(R.drawable.fj4);
|
||||
images.add(R.drawable.fj5);
|
||||
|
||||
|
||||
|
||||
|
||||
/*imageTitle.add("西柏坡");
|
||||
imageTitle.add("2");
|
||||
imageTitle.add("3");
|
||||
imageTitle.add("4");
|
||||
imageTitle.add("5");
|
||||
imageTitle.add("6");*/
|
||||
|
||||
}
|
||||
}
|
@ -0,0 +1,34 @@
|
||||
package ee.example.activity_fragmenttabhost;
|
||||
|
||||
public class Data2 {
|
||||
|
||||
private String new_title;
|
||||
private String new_content;
|
||||
private String content_title;
|
||||
|
||||
|
||||
|
||||
public Data2(String new_title,String content_title, String new_content) {
|
||||
this.new_title = new_title;
|
||||
this.new_content = new_content;
|
||||
this.content_title = content_title;
|
||||
}
|
||||
|
||||
public String getNew_title() {
|
||||
return new_title;
|
||||
}
|
||||
public String getContent_title() {
|
||||
return content_title;
|
||||
}
|
||||
public String getNew_content() {
|
||||
return new_content;
|
||||
}
|
||||
|
||||
public void setNew_title(String new_title) {
|
||||
this.new_title = new_title;
|
||||
}
|
||||
|
||||
public void setNew_content(String new_content) {
|
||||
this.new_content = new_content;
|
||||
}
|
||||
}
|
@ -0,0 +1,38 @@
|
||||
package ee.example.activity_fragmenttabhost;
|
||||
|
||||
|
||||
import android.content.Context;
|
||||
import android.database.sqlite.SQLiteDatabase;
|
||||
import android.database.sqlite.SQLiteOpenHelper;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
public class DataBaseHelper extends SQLiteOpenHelper {
|
||||
private static DataBaseHelper instance;
|
||||
private static String CREATE_USERS="create table users"
|
||||
+"(id integer primary key autoincrement,"
|
||||
+"name text,"
|
||||
+"password text)";
|
||||
|
||||
|
||||
public DataBaseHelper(@Nullable Context context, @Nullable String name, @Nullable SQLiteDatabase.CursorFactory factory, int version) {
|
||||
super(context, name, factory, version);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onCreate(SQLiteDatabase sqLiteDatabase) {
|
||||
|
||||
sqLiteDatabase.execSQL(CREATE_USERS);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onUpgrade(SQLiteDatabase sqLiteDatabase, int i, int i1) {
|
||||
|
||||
}
|
||||
|
||||
public static DataBaseHelper getInstance(Context context){
|
||||
if(instance==null)
|
||||
instance =new DataBaseHelper(context,"travel.db",null,2);
|
||||
return instance;
|
||||
}
|
||||
}
|
@ -0,0 +1,43 @@
|
||||
package ee.example.activity_fragmenttabhost;
|
||||
|
||||
public class Datas {
|
||||
public static int[] icons = {
|
||||
R.drawable.bishu,
|
||||
R.drawable.chengde,
|
||||
R.drawable.fj1,
|
||||
R.drawable.fj5,
|
||||
R.drawable.fj2,
|
||||
R.drawable.fj3,
|
||||
R.drawable.fj4,
|
||||
R.drawable.fj6,
|
||||
R.drawable.fj7,
|
||||
R.drawable.fj8,
|
||||
R.drawable.fj9,
|
||||
R.drawable.fj10,
|
||||
R.drawable.fj11,
|
||||
R.drawable.fj12,
|
||||
R.drawable.fj13,
|
||||
R.drawable.fj14,
|
||||
R.drawable.fj15,
|
||||
};
|
||||
public static String[] title = {
|
||||
"承德避暑山庄",
|
||||
"承德苏联红军烈士纪念碑",
|
||||
"景点",
|
||||
"景点",
|
||||
"景点",
|
||||
"景点",
|
||||
"景点",
|
||||
"景点",
|
||||
"景点",
|
||||
"景点",
|
||||
"景点",
|
||||
"景点",
|
||||
"景点",
|
||||
"景点",
|
||||
"景点",
|
||||
"景点",
|
||||
"景点",
|
||||
|
||||
};
|
||||
}
|
@ -0,0 +1,17 @@
|
||||
package ee.example.activity_fragmenttabhost;
|
||||
|
||||
import android.content.Context;
|
||||
import android.widget.ImageView;
|
||||
|
||||
import com.bumptech.glide.Glide;
|
||||
import com.youth.banner.loader.ImageLoader;
|
||||
|
||||
|
||||
public class GlideImageLoader extends ImageLoader {
|
||||
@Override
|
||||
public void displayImage(Context context, Object path, ImageView imageView) {
|
||||
//Glide 加载图片简单用法
|
||||
Glide.with(context).load(path).into(imageView);
|
||||
}
|
||||
}
|
||||
|
@ -0,0 +1,6 @@
|
||||
package ee.example.activity_fragmenttabhost;
|
||||
|
||||
public class ItemBean {
|
||||
public int icon;//图片资源
|
||||
public String title;//标题
|
||||
}
|
@ -0,0 +1,75 @@
|
||||
package ee.example.activity_fragmenttabhost;
|
||||
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.TextView;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class MyAdapter extends RecyclerView.Adapter<MyAdapter.InnerHolder> {
|
||||
|
||||
private final List<ItemBean> mData;
|
||||
private OnItemClickListener mOnItemClickListener;
|
||||
public MyAdapter(List<ItemBean> data) {
|
||||
this.mData = data;
|
||||
|
||||
}
|
||||
|
||||
@NonNull
|
||||
@Override
|
||||
public InnerHolder onCreateViewHolder(@NonNull ViewGroup parent, int viewType) {
|
||||
View view = View.inflate(parent.getContext(), R.layout.item_stagger, null);
|
||||
return new InnerHolder(view);
|
||||
}
|
||||
public void setOnItemClickListener(OnItemClickListener mOnItemClickListener) {
|
||||
this.mOnItemClickListener = mOnItemClickListener;
|
||||
}
|
||||
public interface OnItemClickListener {
|
||||
void onItemClick(View view, int position);
|
||||
}
|
||||
@Override
|
||||
public void onBindViewHolder(@NonNull final InnerHolder holder, int position) {
|
||||
holder.setData(mData.get(position),position);
|
||||
if(mOnItemClickListener != null){
|
||||
//为ItemView设置监听器
|
||||
holder.itemView.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
int position = holder.getLayoutPosition(); // 1
|
||||
mOnItemClickListener.onItemClick(holder.itemView,position); // 2
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getItemCount() {
|
||||
//返回条目个数
|
||||
if (mData != null) {
|
||||
return mData.size();
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
public class InnerHolder extends RecyclerView.ViewHolder {
|
||||
private TextView mTitle;
|
||||
private ImageView mIcon;
|
||||
|
||||
public InnerHolder(@NonNull View itemView) {
|
||||
super(itemView);
|
||||
mTitle = (TextView) itemView.findViewById(R.id.title);
|
||||
mIcon = (ImageView) itemView.findViewById(R.id.icon);
|
||||
}
|
||||
|
||||
public void setData(ItemBean itemBean,int position) {
|
||||
|
||||
mTitle.setText(itemBean.title);
|
||||
mIcon.setImageResource(itemBean.icon);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
@ -0,0 +1,56 @@
|
||||
package ee.example.activity_fragmenttabhost;
|
||||
|
||||
import android.content.Context;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.BaseAdapter;
|
||||
import android.widget.TextView;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class MyAdapter2 extends BaseAdapter{
|
||||
|
||||
private List<Data2> mData;
|
||||
private Context mContext;
|
||||
|
||||
public MyAdapter2(List<Data2> mData, Context mContext) {
|
||||
this.mData = mData;
|
||||
this.mContext = mContext;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getCount() {
|
||||
return mData.size();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Object getItem(int position) {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public long getItemId(int position) {
|
||||
return position;
|
||||
}
|
||||
|
||||
@Override
|
||||
public View getView(int position, View convertView, ViewGroup parent) {
|
||||
ViewHolder viewHolder;
|
||||
if(convertView == null){
|
||||
convertView = LayoutInflater.from(mContext).inflate(R.layout.list_item,parent,false);
|
||||
viewHolder = new ViewHolder();
|
||||
viewHolder.txt_item_title = (TextView) convertView.findViewById(R.id.txt_item_title);
|
||||
convertView.setTag(viewHolder);
|
||||
}else{
|
||||
viewHolder = (ViewHolder) convertView.getTag();
|
||||
}
|
||||
viewHolder.txt_item_title.setText(mData.get(position).getNew_title());
|
||||
return convertView;
|
||||
}
|
||||
|
||||
private class ViewHolder{
|
||||
TextView txt_item_title;
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,26 @@
|
||||
package ee.example.activity_fragmenttabhost;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.app.Fragment;
|
||||
import android.os.Bundle;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.TextView;
|
||||
|
||||
public class NewContentFragment extends Fragment {
|
||||
|
||||
@SuppressLint("ValidFragment")
|
||||
NewContentFragment() {
|
||||
}
|
||||
|
||||
@Override
|
||||
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
|
||||
View view = inflater.inflate(R.layout.fg_content, container, false);
|
||||
TextView txt_content = (TextView) view.findViewById(R.id.txt_content);
|
||||
//getArgument获取传递过来的Bundle对象
|
||||
txt_content.setText(getArguments().getString("content"));
|
||||
return view;
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,62 @@
|
||||
package ee.example.activity_fragmenttabhost;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.app.Fragment;
|
||||
import android.app.FragmentManager;
|
||||
import android.app.FragmentTransaction;
|
||||
import android.os.Bundle;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.AdapterView;
|
||||
import android.widget.ListAdapter;
|
||||
import android.widget.ListView;
|
||||
import android.widget.TextView;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
|
||||
@SuppressLint("ValidFragment")
|
||||
public class NewListFragment extends Fragment implements AdapterView.OnItemClickListener {
|
||||
private FragmentManager fManager;
|
||||
private ArrayList<Data2> datas;
|
||||
private ListView list_news;
|
||||
|
||||
public NewListFragment(FragmentManager fManager, ArrayList<Data2> datas) {
|
||||
this.fManager = fManager;
|
||||
this.datas = datas;
|
||||
}
|
||||
|
||||
@Override
|
||||
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
|
||||
View view = inflater.inflate(R.layout.fg_newlist, container, false);
|
||||
list_news = (ListView) view.findViewById(R.id.list_news);
|
||||
MyAdapter2 myAdapter = new MyAdapter2(datas, getActivity());
|
||||
list_news.setAdapter((ListAdapter) myAdapter);
|
||||
list_news.setOnItemClickListener(this);
|
||||
return view;
|
||||
}
|
||||
|
||||
|
||||
@SuppressLint("ResourceType")
|
||||
@Override
|
||||
public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
|
||||
FragmentTransaction fTransaction = fManager.beginTransaction();
|
||||
NewContentFragment ncFragment = new NewContentFragment();
|
||||
Bundle bd = new Bundle();
|
||||
bd.putString("content", datas.get(position).getNew_content());
|
||||
ncFragment.setArguments(bd);
|
||||
//获取Activity的控件
|
||||
TextView txt_title = (TextView) getActivity().findViewById(R.id.txt_title);
|
||||
|
||||
txt_title.setText(datas.get(position).getNew_content());
|
||||
txt_title.setText(datas.get(position).getContent_title());
|
||||
|
||||
//加上Fragment替换动画
|
||||
fTransaction.setCustomAnimations(R.anim.fragment_slide_left_enter, R.anim.fragment_slide_left_exit);
|
||||
fTransaction.replace(R.id.fl_content, ncFragment);
|
||||
//调用addToBackStack将Fragment添加到栈中
|
||||
fTransaction.addToBackStack(null);
|
||||
fTransaction.commit();
|
||||
}
|
||||
}
|
@ -0,0 +1,68 @@
|
||||
package ee.example.activity_fragmenttabhost;
|
||||
|
||||
import android.database.Cursor;
|
||||
import android.database.sqlite.SQLiteDatabase;
|
||||
import android.os.Bundle;
|
||||
import android.view.View;
|
||||
import android.widget.Button;
|
||||
import android.widget.EditText;
|
||||
import android.widget.Toast;
|
||||
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
|
||||
public class Regiter extends AppCompatActivity {
|
||||
private EditText name;
|
||||
private EditText password;
|
||||
private Button queren;
|
||||
private Button quxiao;
|
||||
private DataBaseHelper dbHelper;
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
setContentView(R.layout.regiter);
|
||||
dbHelper=DataBaseHelper.getInstance(this);
|
||||
iniview();
|
||||
quxiao.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View view) {
|
||||
finish();
|
||||
}
|
||||
});
|
||||
queren.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View view) {
|
||||
String Name= name.getText().toString();
|
||||
String Password= password.getText().toString();
|
||||
SQLiteDatabase db = dbHelper.getWritableDatabase();
|
||||
if(Name.equals("")){
|
||||
Toast.makeText(Regiter.this,"账号不能为空",Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
else {
|
||||
if(Password.equals("")){
|
||||
Toast.makeText(Regiter.this,"密码不能为空",Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
else{
|
||||
Cursor cursor = db.rawQuery("select name from users where name=? ", new String[]{Name});
|
||||
//用户是否存在
|
||||
if (cursor.moveToNext()){
|
||||
Toast.makeText(Regiter.this,"该用户已经存在",Toast.LENGTH_SHORT).show();
|
||||
cursor.close();
|
||||
}else{
|
||||
db.execSQL("insert into users(name,password)values(?,?)", new String[]{Name, Password});
|
||||
Toast.makeText(Regiter.this,"注册成功",Toast.LENGTH_SHORT).show();
|
||||
cursor.close();
|
||||
finish();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private void iniview(){
|
||||
name=findViewById(R.id.zhanghao);
|
||||
password=findViewById(R.id.mima);
|
||||
queren=findViewById(R.id.queding);
|
||||
quxiao=findViewById(R.id.quxiao);
|
||||
}
|
||||
}
|
@ -0,0 +1,38 @@
|
||||
package ee.example.activity_fragmenttabhost;
|
||||
|
||||
import android.content.Context;
|
||||
import android.os.Bundle;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.TextView;
|
||||
|
||||
import androidx.fragment.app.Fragment;
|
||||
|
||||
public class TabFragment_Community extends Fragment {
|
||||
private static final String TAG = "TabFirstFragment";
|
||||
protected View mView;
|
||||
protected Context mContext;
|
||||
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
}
|
||||
|
||||
@Override
|
||||
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
|
||||
mContext = getActivity();
|
||||
mView = inflater.inflate(R.layout.community, container, false);
|
||||
|
||||
return mView;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onPause() {
|
||||
super.onPause();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
@ -0,0 +1,80 @@
|
||||
package ee.example.activity_fragmenttabhost;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.os.Bundle;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.Button;
|
||||
import android.widget.TextView;
|
||||
|
||||
import androidx.fragment.app.Fragment;
|
||||
|
||||
public class TabFragment_Me extends Fragment {
|
||||
protected View mView;
|
||||
protected Context mContext;
|
||||
private Button me_Tuichu;
|
||||
private Button me_Gaimima;
|
||||
// private Button me_Gainicheng;
|
||||
private TextView me_Zhanghu;
|
||||
|
||||
@Override
|
||||
public void onActivityCreated( Bundle savedInstanceState) {
|
||||
super.onActivityCreated(savedInstanceState);
|
||||
|
||||
intiview();
|
||||
|
||||
me_Tuichu.setOnClickListener(new View.OnClickListener() {
|
||||
public void onClick(View view) {
|
||||
//Data.sta_dl=false;Intent intent=new Intent(getActivity(),LoginActivity.class);
|
||||
Data.sta_dl=false;Intent intent=new Intent(getActivity(),LoginActivity.class);
|
||||
startActivity(intent);
|
||||
Data.images.clear();
|
||||
getActivity().finish();
|
||||
}
|
||||
});
|
||||
|
||||
me_Gaimima.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View view) {
|
||||
Intent intent =new Intent(getActivity(),MainChangemima.class);
|
||||
startActivity(intent);
|
||||
Data.images.clear();
|
||||
getActivity().finish();
|
||||
}
|
||||
});
|
||||
|
||||
if(Data.sta_np==true){
|
||||
me_Zhanghu.setText("当前账户为:"+ Data.sta_name+" 密码为:"+ Data.sta_password);
|
||||
}
|
||||
else { me_Zhanghu.setText("当前为游客登陆");}
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onCreate( Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
}
|
||||
|
||||
@Override
|
||||
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
|
||||
mContext=getActivity();
|
||||
mView=inflater.inflate(R.layout.me,container,false);
|
||||
return mView;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onPause() {
|
||||
super.onPause();
|
||||
}
|
||||
|
||||
private void intiview(){
|
||||
me_Tuichu=getActivity().findViewById(R.id.me_tuichu);
|
||||
me_Zhanghu=getActivity().findViewById(R.id.me_zhanghu);
|
||||
me_Gaimima=getActivity().findViewById(R.id.me_gaimima);
|
||||
//me_Gainicheng=getActivity().findViewById(R.id.me_gainicheng);
|
||||
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,15 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<objectAnimator
|
||||
android:interpolator="@android:interpolator/decelerate_quint"
|
||||
android:valueFrom="100dp" android:valueTo="0dp"
|
||||
android:valueType="floatType"
|
||||
android:propertyName="translationX"
|
||||
android:duration="@android:integer/config_mediumAnimTime" />
|
||||
<objectAnimator
|
||||
android:interpolator="@android:interpolator/decelerate_quint"
|
||||
android:valueFrom="0.0" android:valueTo="1.0"
|
||||
android:valueType="floatType"
|
||||
android:propertyName="alpha"
|
||||
android:duration="@android:integer/config_mediumAnimTime" />
|
||||
</set>
|
@ -0,0 +1,15 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<objectAnimator
|
||||
android:interpolator="@android:interpolator/decelerate_quint"
|
||||
android:valueFrom="0dp" android:valueTo="-100dp"
|
||||
android:valueType="floatType"
|
||||
android:propertyName="translationX"
|
||||
android:duration="@android:integer/config_mediumAnimTime" />
|
||||
<objectAnimator
|
||||
android:interpolator="@android:interpolator/decelerate_quint"
|
||||
android:valueFrom="1.0" android:valueTo="0.0"
|
||||
android:valueType="floatType"
|
||||
android:propertyName="alpha"
|
||||
android:duration="@android:integer/config_mediumAnimTime" />
|
||||
</set>
|
@ -0,0 +1,15 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<objectAnimator
|
||||
android:interpolator="@android:interpolator/decelerate_quint"
|
||||
android:valueFrom="-100dp" android:valueTo="0dp"
|
||||
android:valueType="floatType"
|
||||
android:propertyName="translationX"
|
||||
android:duration="@android:integer/config_mediumAnimTime" />
|
||||
<objectAnimator
|
||||
android:interpolator="@android:interpolator/decelerate_quint"
|
||||
android:valueFrom="0.0" android:valueTo="1.0"
|
||||
android:valueType="floatType"
|
||||
android:propertyName="alpha"
|
||||
android:duration="@android:integer/config_mediumAnimTime" />
|
||||
</set>
|
@ -0,0 +1,15 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<objectAnimator
|
||||
android:interpolator="@android:interpolator/decelerate_quint"
|
||||
android:valueFrom="0dp" android:valueTo="100dp"
|
||||
android:valueType="floatType"
|
||||
android:propertyName="translationX"
|
||||
android:duration="@android:integer/config_mediumAnimTime" />
|
||||
<objectAnimator
|
||||
android:interpolator="@android:interpolator/decelerate_quint"
|
||||
android:valueFrom="1.0" android:valueTo="0.0"
|
||||
android:valueType="floatType"
|
||||
android:propertyName="alpha"
|
||||
android:duration="@android:integer/config_mediumAnimTime" />
|
||||
</set>
|
@ -0,0 +1,30 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:aapt="http://schemas.android.com/aapt"
|
||||
android:width="108dp"
|
||||
android:height="108dp"
|
||||
android:viewportWidth="108"
|
||||
android:viewportHeight="108">
|
||||
<path android:pathData="M31,63.928c0,0 6.4,-11 12.1,-13.1c7.2,-2.6 26,-1.4 26,-1.4l38.1,38.1L107,108.928l-32,-1L31,63.928z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:endX="85.84757"
|
||||
android:endY="92.4963"
|
||||
android:startX="42.9492"
|
||||
android:startY="49.59793"
|
||||
android:type="linear">
|
||||
<item
|
||||
android:color="#44000000"
|
||||
android:offset="0.0" />
|
||||
<item
|
||||
android:color="#00000000"
|
||||
android:offset="1.0" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#FFFFFF"
|
||||
android:fillType="nonZero"
|
||||
android:pathData="M65.3,45.828l3.8,-6.6c0.2,-0.4 0.1,-0.9 -0.3,-1.1c-0.4,-0.2 -0.9,-0.1 -1.1,0.3l-3.9,6.7c-6.3,-2.8 -13.4,-2.8 -19.7,0l-3.9,-6.7c-0.2,-0.4 -0.7,-0.5 -1.1,-0.3C38.8,38.328 38.7,38.828 38.9,39.228l3.8,6.6C36.2,49.428 31.7,56.028 31,63.928h46C76.3,56.028 71.8,49.428 65.3,45.828zM43.4,57.328c-0.8,0 -1.5,-0.5 -1.8,-1.2c-0.3,-0.7 -0.1,-1.5 0.4,-2.1c0.5,-0.5 1.4,-0.7 2.1,-0.4c0.7,0.3 1.2,1 1.2,1.8C45.3,56.528 44.5,57.328 43.4,57.328L43.4,57.328zM64.6,57.328c-0.8,0 -1.5,-0.5 -1.8,-1.2s-0.1,-1.5 0.4,-2.1c0.5,-0.5 1.4,-0.7 2.1,-0.4c0.7,0.3 1.2,1 1.2,1.8C66.5,56.528 65.6,57.328 64.6,57.328L64.6,57.328z"
|
||||
android:strokeWidth="1"
|
||||
android:strokeColor="#00000000" />
|
||||
</vector>
|
After Width: | Height: | Size: 191 KiB |
After Width: | Height: | Size: 280 KiB |
After Width: | Height: | Size: 219 KiB |
After Width: | Height: | Size: 344 KiB |
After Width: | Height: | Size: 7.9 KiB |
@ -0,0 +1,5 @@
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_selected="true" android:drawable="@drawable/shequ" />
|
||||
<item android:drawable="@drawable/shequ" />
|
||||
|
||||
</selector>
|
After Width: | Height: | Size: 4.7 KiB |
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_selected="true" android:drawable="@drawable/shouye_2"/>
|
||||
<item android:drawable="@drawable/home"/>
|
||||
</selector>
|
After Width: | Height: | Size: 2.9 KiB |
@ -0,0 +1,5 @@
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_selected="true" android:drawable="@drawable/faxian" />
|
||||
<item android:drawable="@drawable/faxian" />
|
||||
|
||||
</selector>
|
After Width: | Height: | Size: 134 KiB |
After Width: | Height: | Size: 2.1 MiB |
After Width: | Height: | Size: 1016 KiB |
After Width: | Height: | Size: 184 KiB |
After Width: | Height: | Size: 157 KiB |
After Width: | Height: | Size: 162 KiB |
After Width: | Height: | Size: 83 KiB |
After Width: | Height: | Size: 141 KiB |
After Width: | Height: | Size: 144 KiB |
After Width: | Height: | Size: 118 KiB |
After Width: | Height: | Size: 113 KiB |
After Width: | Height: | Size: 457 KiB |
After Width: | Height: | Size: 405 KiB |
After Width: | Height: | Size: 157 KiB |
After Width: | Height: | Size: 83 KiB |
After Width: | Height: | Size: 3.7 KiB |
After Width: | Height: | Size: 5.7 KiB |
@ -0,0 +1,5 @@
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_selected="true" android:drawable="@drawable/shouye_2" />
|
||||
<item android:drawable="@drawable/shouye_2" />
|
||||
|
||||
</selector>
|
@ -0,0 +1,170 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="108dp"
|
||||
android:height="108dp"
|
||||
android:viewportWidth="108"
|
||||
android:viewportHeight="108">
|
||||
<path
|
||||
android:fillColor="#3DDC84"
|
||||
android:pathData="M0,0h108v108h-108z" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M9,0L9,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M19,0L19,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M29,0L29,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M39,0L39,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M49,0L49,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M59,0L59,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M69,0L69,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M79,0L79,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M89,0L89,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M99,0L99,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,9L108,9"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,19L108,19"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,29L108,29"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,39L108,39"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,49L108,49"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,59L108,59"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,69L108,69"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,79L108,79"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,89L108,89"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,99L108,99"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M19,29L89,29"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M19,39L89,39"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M19,49L89,49"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M19,59L89,59"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M19,69L89,69"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M19,79L89,79"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M29,19L29,89"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M39,19L39,89"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M49,19L49,89"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M59,19L59,89"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M69,19L69,89"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M79,19L79,89"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
</vector>
|
After Width: | Height: | Size: 5.2 KiB |
After Width: | Height: | Size: 24 KiB |
After Width: | Height: | Size: 31 KiB |
@ -0,0 +1,5 @@
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_selected="true" android:drawable="@drawable/wode_1"/>
|
||||
<item android:drawable="@drawable/wode_1" />
|
||||
|
||||
</selector>
|
@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<corners android:bottomLeftRadius="8sp"
|
||||
android:topLeftRadius="8sp"
|
||||
android:bottomRightRadius="8sp"
|
||||
android:topRightRadius="8sp"/>
|
||||
<solid android:color="#3ED1D1D1"/>
|
||||
</shape>
|
||||
|
After Width: | Height: | Size: 3.3 KiB |
After Width: | Height: | Size: 1.9 KiB |
After Width: | Height: | Size: 118 B |
After Width: | Height: | Size: 17 KiB |
@ -0,0 +1,4 @@
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_selected="true" android:drawable="@drawable/tab_bg_s" />
|
||||
<item android:drawable="@drawable/tab_bg_n" />
|
||||
</selector>
|
@ -0,0 +1,4 @@
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_selected="true" android:color="@color/tab_text_selected" />
|
||||
<item android:color="@color/tab_text_normal" />
|
||||
</selector>
|
@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
</selector>
|
After Width: | Height: | Size: 20 KiB |
After Width: | Height: | Size: 4.3 KiB |
After Width: | Height: | Size: 3.8 KiB |
After Width: | Height: | Size: 5.1 KiB |
@ -0,0 +1,48 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout 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"
|
||||
android:orientation="vertical"
|
||||
tools:context=".Content">
|
||||
<ScrollView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:clipToOutline="false">
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
>
|
||||
<ImageView
|
||||
android:layout_marginTop="25dp"
|
||||
android:id="@+id/conImage1"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:layout_marginLeft="15dp"
|
||||
android:layout_marginRight="15dp"
|
||||
android:src="@drawable/jinian2"
|
||||
/>
|
||||
<TextView
|
||||
android:layout_marginLeft="8sp"
|
||||
android:layout_marginRight="8dp"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:id="@+id/conText1"
|
||||
android:textColor="#03A9F4"/>
|
||||
|
||||
<TextView
|
||||
android:layout_marginLeft="8sp"
|
||||
android:layout_marginRight="8dp"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:id="@+id/conText2"
|
||||
android:layout_marginBottom="30dp"
|
||||
android:textColor="#303030"/>
|
||||
|
||||
</LinearLayout>
|
||||
</ScrollView>
|
||||
</LinearLayout>
|
@ -0,0 +1,31 @@
|
||||
<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"
|
||||
tools:context=".MainActivity">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/txt_title"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="56dp"
|
||||
android:background="@color/text_selector"
|
||||
android:textColor="@color/white"
|
||||
android:text="新闻列表"
|
||||
android:textSize="20sp"
|
||||
android:textStyle="bold"
|
||||
android:gravity="center"/>
|
||||
|
||||
<ScrollView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_below="@+id/txt_title"
|
||||
android:layout_marginTop="1dp"
|
||||
android:fillViewport="true">
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/fl_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_below="@id/txt_title" />
|
||||
</ScrollView>
|
||||
</RelativeLayout>
|
@ -0,0 +1,120 @@
|
||||
<?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:orientation="horizontal"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".MainChangemima"
|
||||
android:background="@drawable/back">
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerInParent="true"
|
||||
|
||||
android:orientation="vertical">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="35sp"
|
||||
android:gravity="center"
|
||||
android:text="账 号:"
|
||||
android:textColor="@color/textcolorhint"
|
||||
android:textSize="@dimen/txtsize" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/main_gzhanghao"
|
||||
android:layout_width="230sp"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/editcolor"
|
||||
android:gravity="center"
|
||||
android:hint="请输入账号"
|
||||
android:maxLines="1" />
|
||||
</LinearLayout>
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="20sp"
|
||||
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="35sp"
|
||||
android:gravity="center"
|
||||
android:text="旧密码:"
|
||||
android:textColor="@color/textcolorhint"
|
||||
android:textSize="@dimen/txtsize" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/main_oldmima"
|
||||
android:layout_width="230sp"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/editcolor"
|
||||
android:gravity="center"
|
||||
android:hint="请输入旧密码"
|
||||
android:maxLines="1" />
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="20sp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="35sp"
|
||||
android:gravity="center"
|
||||
android:text="新密码:"
|
||||
android:textColor="@color/textcolorhint"
|
||||
android:textSize="@dimen/txtsize" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/main_newmima"
|
||||
android:layout_width="230sp"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/editcolor"
|
||||
android:gravity="center"
|
||||
android:hint="请输入新密码"
|
||||
android:maxLines="1" />
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<Button
|
||||
android:layout_width="100sp"
|
||||
android:layout_height="wrap_content"
|
||||
android:id="@+id/main_gquxiao"
|
||||
android:text="取消"
|
||||
android:backgroundTint="#3867AC"/>
|
||||
|
||||
<Button
|
||||
android:layout_width="100sp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="30sp"
|
||||
android:id="@+id/main_gqueding"
|
||||
android:text="确定"
|
||||
android:backgroundTint="#3867AC"/>
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
</RelativeLayout>
|
@ -0,0 +1,45 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:background="@color/xml_color"
|
||||
android:orientation="vertical"
|
||||
android:layout_height="match_parent">
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:background="@color/mTbhost_coloe"
|
||||
android:orientation="vertical"
|
||||
android:layout_height="45sp">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="18sp"
|
||||
android:layout_marginTop="10sp"
|
||||
android:background="@color/mTbhost_coloe"
|
||||
android:gravity="center"
|
||||
android:text="消息通知"
|
||||
android:textColor="#323232"
|
||||
android:textSize="22sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<ImageButton
|
||||
android:layout_width="22sp"
|
||||
android:layout_height="22sp"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:layout_marginTop="15dp"
|
||||
android:layout_marginEnd="45sp"
|
||||
android:background="@color/mTbhost_coloe"
|
||||
android:scaleType="fitCenter"
|
||||
android:src="@drawable/cleaner"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_marginRight="45sp" />
|
||||
</RelativeLayout>
|
||||
<TextView
|
||||
android:layout_marginTop="25sp"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="暂无通知"
|
||||
android:textColor="#CACACA"
|
||||
android:gravity="center"
|
||||
android:textSize="30sp"/>
|
||||
</LinearLayout>
|
@ -0,0 +1,15 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/txt_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center"
|
||||
android:textColor="@color/blue"
|
||||
android:textSize="20sp" />
|
||||
|
||||
</LinearLayout>
|
@ -0,0 +1,13 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/white"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ListView
|
||||
android:id="@+id/list_news"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent" />
|
||||
|
||||
</LinearLayout>
|
@ -0,0 +1,27 @@
|
||||
<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"
|
||||
tools:context=".MainActivity">
|
||||
|
||||
|
||||
<ScrollView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:clipToOutline="false">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@color/xml_color"
|
||||
android:orientation="vertical">
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/recycler_view"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@color/xml_color" />
|
||||
</LinearLayout>
|
||||
</ScrollView>
|
||||
|
||||
</RelativeLayout>
|
@ -0,0 +1,17 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/white"
|
||||
android:orientation="vertical"
|
||||
android:padding="10dp" >
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_community"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center"
|
||||
android:textColor="@color/tab_text_normal"
|
||||
android:textSize="20sp" />
|
||||
|
||||
</LinearLayout>
|
@ -0,0 +1,20 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/white"
|
||||
android:orientation="vertical"
|
||||
android:padding="10dp" >
|
||||
<TextView
|
||||
android:id="@+id/tv_find"
|
||||
android:layout_width="393dp"
|
||||
android:layout_height="166dp"
|
||||
android:gravity="bottom|left"
|
||||
android:textColor="@color/tab_text_normal"
|
||||
android:textSize="20sp"
|
||||
/>
|
||||
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
@ -0,0 +1,27 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/white"
|
||||
android:orientation="vertical"
|
||||
android:padding="10dp" >
|
||||
<!--<GridView android:verticalSpacing="2dp"
|
||||
android:numColumns="3"
|
||||
android:horizontalSpacing="2dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="match_parent"
|
||||
android:id="@+id/gridView" xmlns:tools="http://schemas.android.com/tools"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"/>
|
||||
-->
|
||||
<TextView
|
||||
android:id="@+id/tv_home"
|
||||
android:layout_width="393dp"
|
||||
android:layout_height="166dp"
|
||||
android:gravity="bottom|left"
|
||||
android:textColor="@color/tab_text_normal"
|
||||
android:textSize="20sp"
|
||||
/>
|
||||
|
||||
|
||||
|
||||
</LinearLayout>
|
@ -0,0 +1,17 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/white"
|
||||
android:orientation="vertical"
|
||||
android:padding="10dp" >
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_me"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="bottom|center"
|
||||
android:textColor="@color/tab_text_normal"
|
||||
android:textSize="20sp" />
|
||||
|
||||
</LinearLayout>
|
@ -0,0 +1,18 @@
|
||||
<?xml version="1.0"?>
|
||||
<LinearLayout android:padding="5dp"
|
||||
android:background="#eeeeee"
|
||||
android:gravity="center_horizontal"
|
||||
android:orientation="vertical"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_width="match_parent" xmlns:tools="http://schemas.android.com/tools"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<!--<ImageView android:layout_height="40dp"
|
||||
android:layout_width="40dp"
|
||||
android:layout_marginBottom="10dp"
|
||||
android:id="@+id/img"/>
|
||||
<TextView android:layout_height="wrap_content"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_marginBottom="5dp"
|
||||
android:id="@+id/name"
|
||||
android:textSize="12sp"/>-->
|
||||
</LinearLayout>
|
@ -0,0 +1,228 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:background="@color/xml_color"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
>
|
||||
|
||||
<SearchView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_marginLeft="25sp"
|
||||
android:layout_marginTop="10sp"
|
||||
android:layout_marginRight="25sp"
|
||||
android:background="@drawable/searchyuanjiao"
|
||||
android:iconifiedByDefault="false"
|
||||
android:queryBackground="@null"
|
||||
android:queryHint="请输入搜索内容" />
|
||||
</RelativeLayout>
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginRight="10sp"
|
||||
android:layout_marginLeft="10sp"
|
||||
android:layout_marginTop="8sp"
|
||||
android:orientation="horizontal">
|
||||
<com.youth.banner.Banner
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:id="@+id/banner"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="240dp" />
|
||||
</LinearLayout>
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="120dp"
|
||||
android:background="@drawable/searchyuanjiao"
|
||||
android:orientation="horizontal">
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_weight="1"
|
||||
android:background="@color/xml_color"
|
||||
android:orientation="vertical">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="80dp"
|
||||
android:layout_weight="1"
|
||||
android:background="@color/xml_color"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:backgroundTint="@color/xml_color"
|
||||
android:src="@drawable/jingdian" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@color/xml_color"
|
||||
android:gravity="center"
|
||||
android:text="红色景点"
|
||||
|
||||
android:textColor="@color/textcolorhint"
|
||||
android:textSize="12sp" />
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="80dp"
|
||||
android:layout_weight="1"
|
||||
android:background="@color/xml_color"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical">
|
||||
<!--
|
||||
<ImageView
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:backgroundTint="@color/xml_color"
|
||||
android:src="@drawable/guozhi" />- -->
|
||||
<ImageButton
|
||||
android:id="@+id/imb_queding"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:layout_centerInParent="true"
|
||||
android:src="@drawable/guozhi"/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@color/xml_color"
|
||||
android:gravity="center"
|
||||
android:text="特色景点"
|
||||
|
||||
android:textColor="@color/textcolorhint"
|
||||
android:textSize="12sp" />
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_weight="1"
|
||||
android:background="@color/xml_color"
|
||||
android:orientation="vertical">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="80dp"
|
||||
android:layout_weight="1"
|
||||
android:background="@color/xml_color"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="30dp"
|
||||
android:layout_marginTop="10dp"
|
||||
android:backgroundTint="@color/xml_color"
|
||||
android:src="@drawable/ditu" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="0dp"
|
||||
android:background="@color/xml_color"
|
||||
android:gravity="center"
|
||||
|
||||
android:text="公共空间"
|
||||
android:textColor="@color/textcolorhint"
|
||||
android:textSize="12sp" />
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="80dp"
|
||||
android:layout_weight="1"
|
||||
android:background="@color/xml_color"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:backgroundTint="@color/xml_color"
|
||||
android:src="@drawable/tuji" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@color/xml_color"
|
||||
android:gravity="center"
|
||||
android:text="图集"
|
||||
|
||||
android:textColor="@color/textcolorhint"
|
||||
android:textSize="12sp" />
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="120dp"
|
||||
android:background="@drawable/searchyuanjiao"
|
||||
android:orientation="horizontal">
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="80dp"
|
||||
android:layout_weight="1"
|
||||
android:background="@color/xml_color"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:backgroundTint="@color/xml_color"
|
||||
android:src="@drawable/gonglve" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@color/xml_color"
|
||||
android:gravity="center"
|
||||
android:text="攻略"
|
||||
|
||||
android:textColor="@color/textcolorhint"
|
||||
android:textSize="12sp" />
|
||||
</LinearLayout>
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="80dp"
|
||||
android:layout_weight="1"
|
||||
android:background="@color/xml_color"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:backgroundTint="@color/xml_color"
|
||||
android:src="@drawable/youji" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@color/xml_color"
|
||||
android:gravity="center"
|
||||
android:text="游记"
|
||||
|
||||
android:textColor="@color/textcolorhint"
|
||||
android:textSize="12sp" />
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
@ -0,0 +1,35 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||
|
||||
<androidx.cardview.widget.CardView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:cardUseCompatPadding="true">
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/icon"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:adjustViewBounds="true"
|
||||
android:src="@drawable/fj1" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@id/icon"
|
||||
android:gravity="center"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_marginTop="25dp"
|
||||
android:textSize="20sp" />
|
||||
</RelativeLayout>
|
||||
</androidx.cardview.widget.CardView>
|
||||
</RelativeLayout>
|
@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_item_tabbar"
|
||||
style="@style/TabLable"/>
|
||||
</LinearLayout>
|
@ -0,0 +1,16 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/txt_item_title"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="64dp"
|
||||
android:gravity="center_vertical"
|
||||
android:text="呵呵"
|
||||
android:textColor="#000000"
|
||||
android:textSize="20sp" />
|
||||
|
||||
</LinearLayout>
|
@ -0,0 +1,129 @@
|
||||
<?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"
|
||||
android:orientation="horizontal"
|
||||
tools:context=".MainActivity"
|
||||
android:background="@drawable/back">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tiaoguo"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentStart="true"
|
||||
android:layout_alignParentLeft="true"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_marginStart="269dp"
|
||||
android:layout_marginLeft="269dp"
|
||||
android:layout_marginTop="35sp"
|
||||
android:layout_marginRight="30sp"
|
||||
android:text="下次再说>>>"
|
||||
android:textColor="#2398FF"
|
||||
android:textSize="20sp" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerInParent="true"
|
||||
|
||||
android:orientation="vertical">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="35sp"
|
||||
android:gravity="center"
|
||||
android:text="账号:"
|
||||
android:textColor="@color/textcolorhint"
|
||||
android:textSize="@dimen/txtsize" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/main_zhanghao"
|
||||
android:layout_width="230sp"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/editcolor"
|
||||
android:gravity="center"
|
||||
android:hint="请输入账号"
|
||||
android:maxLines="1" />
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="20sp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="35sp"
|
||||
android:gravity="center"
|
||||
android:text="密码:"
|
||||
android:textColor="@color/textcolorhint"
|
||||
android:textSize="@dimen/txtsize" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/main_mima"
|
||||
android:layout_width="230sp"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/editcolor"
|
||||
android:gravity="center"
|
||||
android:hint="请输入密码"
|
||||
android:maxLines="1" />
|
||||
</LinearLayout>
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="30sp"
|
||||
android:orientation="horizontal"
|
||||
android:layout_marginTop="5sp"
|
||||
android:gravity="center">
|
||||
<CheckBox
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:textColor="@color/CheckBoxColor"
|
||||
android:id="@+id/Check_Box1"
|
||||
android:text="记住密码"/>
|
||||
<CheckBox
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="10sp"
|
||||
android:textColor="@color/CheckBoxColor"
|
||||
android:id="@+id/Check_Box2"
|
||||
android:text="自动登录"/>
|
||||
</LinearLayout>
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<Button
|
||||
android:layout_width="100sp"
|
||||
android:layout_height="wrap_content"
|
||||
android:id="@+id/main_zhuce"
|
||||
android:text="注册"
|
||||
android:backgroundTint="#3867AC"/>
|
||||
|
||||
<Button
|
||||
android:layout_width="100sp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="30sp"
|
||||
android:id="@+id/main_denglu"
|
||||
android:text="登录"
|
||||
android:backgroundTint="#3867AC"/>
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
</RelativeLayout>
|