update:2020.05.22
fix:图标更新 add:
27
app/app.iml
@@ -12,13 +12,13 @@ def releaseTime() {
|
||||
|
||||
android {
|
||||
compileSdkVersion 29
|
||||
buildToolsVersion "29.0.2"
|
||||
buildToolsVersion "29.0.3"
|
||||
defaultConfig {
|
||||
applicationId "com.appstore.uiui"
|
||||
minSdkVersion 23
|
||||
targetSdkVersion 29
|
||||
versionCode 18
|
||||
versionName "1.1.8"
|
||||
versionCode 19
|
||||
versionName "1.1.9"
|
||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||
//极光
|
||||
ndk {
|
||||
@@ -100,9 +100,9 @@ android {
|
||||
|
||||
dependencies {
|
||||
implementation fileTree(dir: 'libs', include: ['*.jar'])
|
||||
implementation 'androidx.appcompat:appcompat:1.0.2'
|
||||
implementation 'androidx.appcompat:appcompat:1.1.0'
|
||||
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
|
||||
implementation 'androidx.recyclerview:recyclerview:1.0.0'
|
||||
implementation 'androidx.recyclerview:recyclerview:1.1.0'
|
||||
implementation 'androidx.cardview:cardview:1.0.0'
|
||||
|
||||
testImplementation 'junit:junit:4.12'
|
||||
|
||||
@@ -36,7 +36,6 @@ import java.io.File;
|
||||
|
||||
import cn.jpush.android.api.CustomMessage;
|
||||
import cn.jpush.android.api.JPushInterface;
|
||||
import uk.co.chrisjenx.calligraphy.CalligraphyConfig;
|
||||
|
||||
/**
|
||||
* Created by asus on 2017/10/27.
|
||||
@@ -59,7 +58,7 @@ public class MyApplication extends Application {
|
||||
@NonNull
|
||||
@Override
|
||||
public RefreshHeader createRefreshHeader(@NonNull Context context, @NonNull RefreshLayout layout) {
|
||||
layout.setPrimaryColorsId(R.color.download, R.color.green);//全局设置主题颜色
|
||||
layout.setPrimaryColorsId(R.color.download, R.color.red);//全局设置主题颜色
|
||||
return new ClassicsHeader(context);//.setTimeFormat(new DynamicTimeFormat("更新于 %s"));//指定为经典Header,默认是 贝塞尔雷达Header
|
||||
}
|
||||
});
|
||||
|
||||
@@ -17,6 +17,7 @@ import com.appstore.uiui.R;
|
||||
import com.appstore.uiui.adapter.ImageAdapter;
|
||||
import com.appstore.uiui.base.BaseActivity;
|
||||
import com.appstore.uiui.bean.AppInfo;
|
||||
import com.appstore.uiui.bean.GlideCircleWithBorder;
|
||||
import com.appstore.uiui.helper.CustomSnapHelper;
|
||||
import com.appstore.uiui.utils.ApkUtils;
|
||||
import com.appstore.uiui.utils.ToastUtil;
|
||||
@@ -80,12 +81,13 @@ public class DetailsActivity extends BaseActivity {
|
||||
tv_name.setText(appInfo.getApp_name());
|
||||
tv_company.setText(appInfo.getApp_developer());
|
||||
detali_tv_size.setText("大小\t" + "(" + appInfo.getApp_size() + "MB" + ")");
|
||||
detail_tv_Developers.setText("供应商\t" + appInfo.getApp_developer());
|
||||
detail_tv_Developers.setText("开发者\t" + appInfo.getApp_developer());
|
||||
tv_update_time.setText("时间\t" + appInfo.getCreatetime());
|
||||
tv_version.setText("版本\t" + appInfo.getApp_version_name());
|
||||
tv_content.setText(appInfo.getApp_desc());
|
||||
rating_bar.setRating((float) appInfo.getApp_score());
|
||||
Glide.with(this).asBitmap().load(appInfo.getApp_img()).into(iv_icon);
|
||||
Glide.with(this).asBitmap().load(appInfo.getApp_img()) .transform(new GlideCircleWithBorder(this))
|
||||
.into(iv_icon);
|
||||
List<String> list = new ArrayList<String>() {{
|
||||
this.add(appInfo.getApp_preview1());
|
||||
this.add(appInfo.getApp_preview2());
|
||||
|
||||
@@ -130,7 +130,7 @@ public class MainActivity extends BaseActivity {
|
||||
|
||||
private void initTabLayout() {
|
||||
final List<Fragment> fragmentList = new ArrayList<>();
|
||||
fragmentList.add(new FeaturedFragment());
|
||||
fragmentList.add(new FeaturedFragment(this));
|
||||
fragmentList.add(new RankFragment());
|
||||
fragmentList.add(new KindFragment());
|
||||
fragmentList.add(new ManageFragment());
|
||||
|
||||
@@ -1,8 +1,10 @@
|
||||
package com.appstore.uiui.activity;
|
||||
|
||||
import android.graphics.Color;
|
||||
import android.os.Handler;
|
||||
import android.os.Message;
|
||||
import android.view.View;
|
||||
import android.widget.TextView;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.appcompat.widget.SearchView;
|
||||
@@ -36,6 +38,10 @@ public class SearcherActivity extends BaseActivity {
|
||||
@Override
|
||||
protected void initView() {
|
||||
search = findViewById(R.id.search);
|
||||
// int id = search.getContext().getResources().getIdentifier("android:id/search_src_text", null, null);
|
||||
TextView textView = search.findViewById(androidx.appcompat.R.id.search_src_text);
|
||||
textView.setTextColor(Color.WHITE);
|
||||
textView.setHintTextColor(Color.WHITE);//提示字体颜色**
|
||||
recyclerView = findViewById(R.id.recyclerView);
|
||||
}
|
||||
|
||||
|
||||
@@ -2,6 +2,8 @@ package com.appstore.uiui.adapter;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.graphics.Bitmap;
|
||||
import android.graphics.Color;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
@@ -15,6 +17,7 @@ import androidx.recyclerview.widget.RecyclerView;
|
||||
import com.appstore.uiui.R;
|
||||
import com.appstore.uiui.activity.DetailsActivity;
|
||||
import com.appstore.uiui.bean.AppInfo;
|
||||
import com.appstore.uiui.bean.GlideCircleWithBorder;
|
||||
import com.appstore.uiui.listener.LogDownloadListener;
|
||||
import com.appstore.uiui.utils.ApkUtils;
|
||||
import com.appstore.uiui.utils.ToastUtil;
|
||||
@@ -70,11 +73,22 @@ public class AppAdapter extends RecyclerView.Adapter<AppAdapter.Holder> {
|
||||
holder.refresh(downloadTask.progress);
|
||||
}
|
||||
|
||||
|
||||
|
||||
if (!isNotLoadBitmap) {
|
||||
Glide.with(mContext).asBitmap().load(appInfo.getApp_img()).placeholder(R.drawable.ic_place_holder).into(holder.ivIcon);
|
||||
Glide.with(mContext)
|
||||
.asBitmap()
|
||||
.load(appInfo.getApp_img())
|
||||
.placeholder(R.drawable.ic_place_holder)
|
||||
.transform(new GlideCircleWithBorder(mContext))
|
||||
.into(holder.ivIcon);
|
||||
} else {
|
||||
Glide.with(mContext).load(R.drawable.ic_place_holder).into(holder.ivIcon);
|
||||
Glide.with(mContext)
|
||||
.load(R.drawable.ic_place_holder)
|
||||
.transform(new GlideCircleWithBorder(mContext))
|
||||
.into(holder.ivIcon);
|
||||
}
|
||||
|
||||
holder.tvCompany.setText(appInfo.getApp_developer());
|
||||
if (isShowOrder) {
|
||||
holder.tvName.setText((position + 1) + "." + appInfo.getApp_name());
|
||||
|
||||
@@ -16,6 +16,7 @@ import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
import com.appstore.uiui.R;
|
||||
import com.appstore.uiui.bean.AppInfo;
|
||||
import com.appstore.uiui.bean.GlideCircleWithBorder;
|
||||
import com.appstore.uiui.listener.LogDownloadListener;
|
||||
import com.appstore.uiui.view.NumberProgressBar;
|
||||
import com.bumptech.glide.Glide;
|
||||
@@ -125,7 +126,11 @@ public class DownloadManagerAdapter extends RecyclerView.Adapter<DownloadManager
|
||||
Progress progress = task.progress;
|
||||
AppInfo apk = (AppInfo) progress.extra1;
|
||||
if (apk != null) {
|
||||
Glide.with(mContext).load(apk.getApp_img()).error(R.mipmap.ic_launcher).into(icon);
|
||||
Glide.with(mContext)
|
||||
.load(apk.getApp_img())
|
||||
.error(R.mipmap.ic_launcher)
|
||||
.transform(new GlideCircleWithBorder(mContext))
|
||||
.into(icon);
|
||||
name.setText(apk.getApp_name());
|
||||
} else {
|
||||
name.setText(progress.fileName);
|
||||
|
||||
@@ -13,6 +13,7 @@ import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
import com.appstore.uiui.R;
|
||||
import com.appstore.uiui.activity.KindDetailActivity;
|
||||
import com.appstore.uiui.bean.GlideCircleWithBorder;
|
||||
import com.appstore.uiui.bean.Kind;
|
||||
import com.bumptech.glide.Glide;
|
||||
|
||||
@@ -41,7 +42,9 @@ public class KindAdapter extends RecyclerView.Adapter<KindAdapter.KindViewHolder
|
||||
public void onBindViewHolder(KindViewHolder holder, int position) {
|
||||
final Kind kind = mKindList.get(position);
|
||||
holder.tvName.setText(kind.getName());
|
||||
Glide.with(mContext).load(kind.getIcon()).into(holder.ivIcon);
|
||||
Glide.with(mContext).load(kind.getIcon())
|
||||
// .transform(new GlideCircleWithBorder(mContext))
|
||||
.into(holder.ivIcon);
|
||||
holder.itemView.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
|
||||
@@ -3,6 +3,8 @@ package com.appstore.uiui.adapter;
|
||||
import android.content.ComponentName;
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.graphics.Bitmap;
|
||||
import android.graphics.drawable.BitmapDrawable;
|
||||
import android.net.Uri;
|
||||
import android.text.format.Formatter;
|
||||
import android.view.LayoutInflater;
|
||||
@@ -17,8 +19,11 @@ import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
import com.appstore.uiui.R;
|
||||
import com.appstore.uiui.bean.AppInfo;
|
||||
import com.appstore.uiui.bean.GlideCircleWithBorder;
|
||||
import com.appstore.uiui.bean.LocalApp;
|
||||
import com.appstore.uiui.utils.ApkUtils;
|
||||
import com.appstore.uiui.utils.Utils;
|
||||
import com.bumptech.glide.Glide;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@@ -49,8 +54,11 @@ public class LocalAppAdapter extends RecyclerView.Adapter<LocalAppAdapter.LocalA
|
||||
@Override
|
||||
public void onBindViewHolder(LocalAppViewHolder holder, int position) {
|
||||
final LocalApp localApp = localAppList.get(position);
|
||||
|
||||
holder.ivIcon.setImageDrawable(localApp.getIcon());
|
||||
Bitmap bitmap = Utils.getRoundedBitmap(Utils.DrawableToBitmap(localApp.getIcon()), context);
|
||||
Glide.with(context).load(bitmap)
|
||||
.transform(new GlideCircleWithBorder(context))
|
||||
.into(holder.ivIcon);
|
||||
holder.ivIcon.setImageDrawable(new BitmapDrawable(context.getResources(), bitmap));
|
||||
holder.tvCompany.setText(localApp.getCompany());
|
||||
holder.tvName.setText(localApp.getAppName());
|
||||
holder.tvVersion.setText(localApp.getVersion());
|
||||
|
||||
@@ -9,6 +9,7 @@ import android.widget.ImageView;
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
import com.appstore.uiui.R;
|
||||
import com.appstore.uiui.bean.GlideCircleWithBorder;
|
||||
import com.bumptech.glide.Glide;
|
||||
|
||||
import java.util.List;
|
||||
@@ -36,7 +37,12 @@ public class ShowImageAdapter extends RecyclerView.Adapter<ShowImageAdapter.Imag
|
||||
@Override
|
||||
public void onBindViewHolder(ImageViewHolder holder, int position) {
|
||||
String src = mSrcList.get(position);
|
||||
Glide.with(mContext).asBitmap().load(src).placeholder(R.drawable.ic_place_holder).into(holder.imageView);
|
||||
Glide.with(mContext)
|
||||
.asBitmap()
|
||||
.load(src)
|
||||
.placeholder(R.drawable.ic_place_holder)
|
||||
.transform(new GlideCircleWithBorder(mContext))
|
||||
.into(holder.imageView);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -8,7 +8,6 @@ import android.widget.Button;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.TextView;
|
||||
|
||||
import androidx.cardview.widget.CardView;
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
import com.appstore.uiui.R;
|
||||
@@ -59,7 +58,7 @@ public class UpdateAppAdapter extends RecyclerView.Adapter<UpdateAppAdapter.Upda
|
||||
holder.tvName.setText(appInfo.getAppName());
|
||||
holder.tvVersion.setText(appInfo.getVersionName() + "->" + appInfo.getNewVersionName());
|
||||
holder.btnDownLoad.setText("更新");
|
||||
holder.btnDownLoad.setTextColor(context.getColor(R.color.green));
|
||||
holder.btnDownLoad.setTextColor(context.getColor(R.color.red));
|
||||
holder.btnDownLoad.setBackground(context.getDrawable(R.drawable.btn_style_none));
|
||||
holder.btnDownLoad.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
|
||||
@@ -0,0 +1,112 @@
|
||||
package com.appstore.uiui.bean;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.res.Resources;
|
||||
import android.graphics.Bitmap;
|
||||
import android.graphics.BitmapFactory;
|
||||
import android.graphics.BitmapShader;
|
||||
import android.graphics.Canvas;
|
||||
import android.graphics.Color;
|
||||
import android.graphics.Paint;
|
||||
import android.graphics.PorterDuff;
|
||||
import android.graphics.PorterDuffXfermode;
|
||||
import android.graphics.RectF;
|
||||
|
||||
import com.appstore.uiui.R;
|
||||
import com.bumptech.glide.load.engine.bitmap_recycle.BitmapPool;
|
||||
import com.bumptech.glide.load.resource.bitmap.BitmapTransformation;
|
||||
|
||||
import java.security.MessageDigest;
|
||||
|
||||
/**
|
||||
* 加载圆形头像带白色边框
|
||||
*/
|
||||
public class GlideCircleWithBorder extends BitmapTransformation {
|
||||
private Paint mBorderPaint;
|
||||
private float mBorderWidth;
|
||||
private Context mContext;
|
||||
|
||||
public GlideCircleWithBorder(Context context) {
|
||||
this.mContext = context;
|
||||
}
|
||||
|
||||
// public GlideCircleWithBorder(Context context, int borderWidth, int borderColor) {
|
||||
// this.mContext = context;
|
||||
// mBorderWidth = Resources.getSystem().getDisplayMetrics().density * borderWidth;
|
||||
// mBorderPaint = new Paint();
|
||||
// mBorderPaint.setDither(true);
|
||||
// mBorderPaint.setAntiAlias(true);
|
||||
// mBorderPaint.setColor(borderColor);
|
||||
// mBorderPaint.setStyle(Paint.Style.STROKE);
|
||||
// mBorderPaint.setStrokeWidth(mBorderWidth);
|
||||
// }
|
||||
|
||||
protected Bitmap transform(BitmapPool pool, Bitmap toTransform, int outWidth, int outHeight) {
|
||||
return circleCrop(pool, toTransform);
|
||||
}
|
||||
|
||||
private Bitmap circleCrop(BitmapPool pool, Bitmap source) {
|
||||
if (source == null) {
|
||||
return null;
|
||||
}
|
||||
// int size = (int) (Math.min(source.getWidth(), source.getHeight()) - (mBorderWidth / 2));
|
||||
// int x = (source.getWidth() - size) / 2;
|
||||
// int y = (source.getHeight() - size) / 2;
|
||||
// Bitmap squared = Bitmap.createBitmap(source, x, y, size, size);
|
||||
// Bitmap result = pool.get(size, size, Bitmap.Config.ARGB_8888);
|
||||
// if (result == null) {
|
||||
// result = Bitmap.createBitmap(size, size, Bitmap.Config.ARGB_8888);
|
||||
// }
|
||||
//创建画笔 画布 手动描绘边框
|
||||
// Canvas canvas = new Canvas(result);
|
||||
// Paint paint = new Paint();
|
||||
// paint.setShader(new BitmapShader(squared, BitmapShader.TileMode.CLAMP, BitmapShader.TileMode.CLAMP));
|
||||
// paint.setAntiAlias(true);
|
||||
// float r = size / 2f;
|
||||
// canvas.drawCircle(r, r, r, paint);
|
||||
// if (mBorderPaint != null) {
|
||||
// float borderRadius = r - mBorderWidth / 2;
|
||||
// canvas.drawCircle(r, r, borderRadius, mBorderPaint);
|
||||
// }
|
||||
// Bitmap bgBitmap = Bitmap.createBitmap(mBitmap.getWidth(), mBitmap.getHeight(), Bitmap.Config.ARGB_8888);
|
||||
|
||||
Bitmap mask = BitmapFactory.decodeResource(mContext.getResources(), R.drawable.mask);
|
||||
//获取背景
|
||||
int width = mask.getWidth();
|
||||
int height = mask.getHeight();
|
||||
Bitmap result = pool.get(width, height, Bitmap.Config.ARGB_8888);
|
||||
if (result == null) {
|
||||
result = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888);
|
||||
}
|
||||
|
||||
Bitmap bitmapScale = Bitmap.createScaledBitmap(source, width, height, true);
|
||||
Canvas canvas = new Canvas();
|
||||
Paint paint = new Paint();
|
||||
canvas.setBitmap(result);
|
||||
canvas.drawBitmap(mask, 0, 0, paint);
|
||||
canvas.drawBitmap(bitmapScale, 0, 0, paint);
|
||||
Bitmap result2 = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888);
|
||||
|
||||
Canvas canvas2 = new Canvas();
|
||||
Paint paint2 = new Paint();
|
||||
canvas2.setBitmap(result2);
|
||||
canvas2.drawBitmap(mask, 0, 0, paint2);
|
||||
paint2.setXfermode(new PorterDuffXfermode(PorterDuff.Mode.SRC_IN));
|
||||
canvas2.drawBitmap(result, 0, 0, paint2);
|
||||
|
||||
Bitmap bitmapshadow =BitmapFactory.decodeResource(mContext.getResources(), R.drawable.mask_shadow);
|
||||
Bitmap bitmap=Bitmap.createScaledBitmap(bitmapshadow,width+2,height+2,true);
|
||||
Canvas canvas3=new Canvas();
|
||||
Paint paint3=new Paint();
|
||||
canvas3.setBitmap(bitmap);
|
||||
canvas3.drawBitmap(bitmapshadow,0,0,paint3);
|
||||
canvas3.drawBitmap(result2,1,1,paint3);
|
||||
|
||||
return bitmap;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void updateDiskCacheKey(MessageDigest messageDigest) {
|
||||
|
||||
}
|
||||
}
|
||||
@@ -53,6 +53,12 @@ public class FeaturedFragment extends LazyLoadFragment implements RefreshManager
|
||||
private boolean isNotLoadBitmap;
|
||||
|
||||
private installReceiver myReceiver;
|
||||
private Context mContext;
|
||||
|
||||
public FeaturedFragment(Context context) {
|
||||
this.mContext = context;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public int getLayoutId() {
|
||||
@@ -83,7 +89,7 @@ public class FeaturedFragment extends LazyLoadFragment implements RefreshManager
|
||||
filter.addAction("com.appstore.uiui.PACKAGE_REPLACED");
|
||||
filter.addAction("com.appstore.uiui.PACKAGE_REMOVED");
|
||||
filter.setPriority(IntentFilter.SYSTEM_HIGH_PRIORITY);
|
||||
getActivity().getApplication().registerReceiver(myReceiver, filter);
|
||||
mContext.registerReceiver(myReceiver, filter);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -108,7 +114,7 @@ public class FeaturedFragment extends LazyLoadFragment implements RefreshManager
|
||||
return new BannerViewHolder();
|
||||
}
|
||||
})
|
||||
.setIndicatorColor(getResources().getColor(R.color.colorAccent), getResources().getColor(R.color.colorAccent))
|
||||
.setIndicatorColor(getResources().getColor(R.color.white), getResources().getColor(R.color.colorAccent))
|
||||
.setOnPageClickListener(new BannerViewPager.OnPageClickListener() {
|
||||
@Override
|
||||
public void onPageClick(int position) {
|
||||
@@ -180,7 +186,7 @@ public class FeaturedFragment extends LazyLoadFragment implements RefreshManager
|
||||
return new BannerViewHolder();
|
||||
}
|
||||
})
|
||||
.setIndicatorColor(getResources().getColor(R.color.colorAccent), getResources().getColor(R.color.colorAccent))
|
||||
.setIndicatorColor(getResources().getColor(R.color.white), getResources().getColor(R.color.colorAccent))
|
||||
.setOnPageClickListener(new BannerViewPager.OnPageClickListener() {
|
||||
@Override
|
||||
public void onPageClick(int position) {
|
||||
|
||||
@@ -14,7 +14,6 @@ import androidx.recyclerview.widget.RecyclerView;
|
||||
import com.appstore.uiui.R;
|
||||
import com.appstore.uiui.adapter.KindAdapter;
|
||||
import com.appstore.uiui.base.BaseFragment;
|
||||
import com.appstore.uiui.base.RefreshManager;
|
||||
import com.appstore.uiui.bean.Kind;
|
||||
|
||||
import java.util.ArrayList;
|
||||
@@ -44,17 +43,17 @@ public class KindFragment extends BaseFragment {
|
||||
|
||||
private void initView() {
|
||||
kindList = new ArrayList<>();
|
||||
kindList.add(new Kind("语文", 1, R.drawable.icon_language));
|
||||
kindList.add(new Kind("数学", 2, R.drawable.icon_math));
|
||||
kindList.add(new Kind("英语", 3, R.drawable.icon_english));
|
||||
kindList.add(new Kind("物理", 4, R.drawable.icon_physics));
|
||||
kindList.add(new Kind("化学", 5, R.drawable.icon_chemistry));
|
||||
kindList.add(new Kind("生物", 6, R.drawable.icon_biology));
|
||||
kindList.add(new Kind("政治", 7, R.drawable.icon_politics));
|
||||
kindList.add(new Kind("历史", 8, R.drawable.icon_history));
|
||||
kindList.add(new Kind("地理", 9, R.drawable.icon_geography));
|
||||
kindList.add(new Kind("语文", 1, R.drawable.icon_language1));
|
||||
kindList.add(new Kind("数学", 2, R.drawable.icon_math1));
|
||||
kindList.add(new Kind("英语", 3, R.drawable.icon_english1));
|
||||
kindList.add(new Kind("物理", 4, R.drawable.icon_physics1));
|
||||
kindList.add(new Kind("化学", 5, R.drawable.icon_chemistry1));
|
||||
kindList.add(new Kind("生物", 6, R.drawable.icon_biology1));
|
||||
kindList.add(new Kind("政治", 7, R.drawable.icon_politics1));
|
||||
kindList.add(new Kind("历史", 8, R.drawable.icon_history1));
|
||||
kindList.add(new Kind("地理", 9, R.drawable.icon_geography1));
|
||||
|
||||
kindList.add(new Kind("娱乐", 0, R.drawable.icon_game));
|
||||
kindList.add(new Kind("娱乐", 0, R.drawable.icon_game1));
|
||||
|
||||
adapter = new KindAdapter(kindList, getContext());
|
||||
mRvKind.setAdapter(adapter);
|
||||
|
||||
@@ -12,6 +12,14 @@ import android.content.pm.PackageManager;
|
||||
import android.content.pm.PackageManager.NameNotFoundException;
|
||||
import android.content.pm.ResolveInfo;
|
||||
import android.content.res.Resources;
|
||||
import android.graphics.Bitmap;
|
||||
import android.graphics.BitmapFactory;
|
||||
import android.graphics.Canvas;
|
||||
import android.graphics.Paint;
|
||||
import android.graphics.PixelFormat;
|
||||
import android.graphics.PorterDuff;
|
||||
import android.graphics.PorterDuffXfermode;
|
||||
import android.graphics.drawable.Drawable;
|
||||
import android.net.ConnectivityManager;
|
||||
import android.net.NetworkInfo;
|
||||
import android.os.Build;
|
||||
@@ -24,6 +32,8 @@ import android.view.inputmethod.InputMethodManager;
|
||||
import android.widget.EditText;
|
||||
import android.widget.Toast;
|
||||
|
||||
import com.appstore.uiui.R;
|
||||
|
||||
import java.io.FileReader;
|
||||
import java.io.InputStreamReader;
|
||||
import java.io.LineNumberReader;
|
||||
@@ -704,4 +714,72 @@ public class Utils {
|
||||
|
||||
}
|
||||
|
||||
public static Bitmap getRoundedBitmap(Bitmap mBitmap, Context context) {
|
||||
Bitmap bgBitmap = Bitmap.createBitmap(mBitmap.getWidth(), mBitmap.getHeight(), Bitmap.Config.ARGB_8888);
|
||||
|
||||
Bitmap mask = BitmapFactory.decodeResource(context.getResources(), R.drawable.mask);
|
||||
int width = mask.getWidth();
|
||||
int height = mask.getHeight();
|
||||
Bitmap bitmapScale = Bitmap.createScaledBitmap(mBitmap, width, height, true);
|
||||
|
||||
// Palette p = Palette.from(mBitmap).generate();
|
||||
// Palette.Swatch vibrant = p.getVibrantSwatch();//有活力的
|
||||
// int color = vibrant.getRgb(); //样本中的像素数量
|
||||
|
||||
Bitmap result = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888);
|
||||
Canvas canvas = new Canvas();
|
||||
Paint paint = new Paint();
|
||||
|
||||
canvas.setBitmap(result);
|
||||
// canvas.drawColor(color);
|
||||
canvas.drawBitmap(mask, 0, 0, paint);
|
||||
// paint.setXfermode(new PorterDuffXfermode(PorterDuff.Mode.SRC_IN));
|
||||
canvas.drawBitmap(bitmapScale, 0, 0, paint);
|
||||
// return result;
|
||||
|
||||
Bitmap result2 = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888);
|
||||
Canvas canvas2 = new Canvas();
|
||||
Paint paint2 = new Paint();
|
||||
canvas2.setBitmap(result2);
|
||||
canvas2.drawBitmap(mask, 0, 0, paint2);
|
||||
paint2.setXfermode(new PorterDuffXfermode(PorterDuff.Mode.SRC_IN));
|
||||
canvas2.drawBitmap(result, 0, 0, paint2);
|
||||
return result2;
|
||||
|
||||
|
||||
// Canvas mCanvas = new Canvas();
|
||||
// mCanvas.setBitmap(bgBitmap);
|
||||
// Paint mPaint = new Paint();
|
||||
// RectF mRectM = new RectF(scaleM, scaleM, mBitmap.getWidth() - scaleM, mBitmap.getHeight() - scaleM); //设置剪裁圆角的区域
|
||||
// Rect mRect = new Rect(0, 0, mBitmap.getWidth(), mBitmap.getHeight());
|
||||
// RectF mRectF = mRectM;
|
||||
//
|
||||
// float roundPx = 15; //圆角半径
|
||||
// mPaint.setAntiAlias(true);
|
||||
// //Log.d("wy"+TAG,"mBitmap.getWidth()="+mBitmap.getWidth()+", mBitmap.getHeight()="+mBitmap.getHeight());
|
||||
// mCanvas.drawRoundRect(mRectF, roundPx, roundPx, mPaint);
|
||||
// mPaint.setXfermode(new PorterDuffXfermode(PorterDuff.Mode.SRC_IN));
|
||||
// mCanvas.drawBitmap(mBitmap, mRect, mRect, mPaint);
|
||||
// return bgBitmap;
|
||||
}
|
||||
public static Bitmap DrawableToBitmap(Drawable drawable) {
|
||||
|
||||
// 获取 drawable 长宽
|
||||
int width = drawable.getIntrinsicWidth();
|
||||
int heigh = drawable.getIntrinsicHeight();
|
||||
|
||||
drawable.setBounds(0, 0, width, heigh);
|
||||
|
||||
// 获取drawable的颜色格式
|
||||
Bitmap.Config config = drawable.getOpacity() != PixelFormat.OPAQUE ? Bitmap.Config.ARGB_8888
|
||||
: Bitmap.Config.RGB_565;
|
||||
// 创建bitmap
|
||||
Bitmap bitmap = Bitmap.createBitmap(width, heigh, config);
|
||||
// 创建bitmap画布
|
||||
Canvas canvas = new Canvas(bitmap);
|
||||
// 将drawable 内容画到画布中
|
||||
drawable.draw(canvas);
|
||||
return bitmap;
|
||||
}
|
||||
|
||||
}
|
||||
|
Before Width: | Height: | Size: 148 B After Width: | Height: | Size: 148 B |
|
Before Width: | Height: | Size: 27 KiB After Width: | Height: | Size: 27 KiB |
|
Before Width: | Height: | Size: 3.3 KiB After Width: | Height: | Size: 3.3 KiB |
|
Before Width: | Height: | Size: 1.9 KiB After Width: | Height: | Size: 1.9 KiB |
|
Before Width: | Height: | Size: 43 KiB After Width: | Height: | Size: 43 KiB |
|
Before Width: | Height: | Size: 865 B After Width: | Height: | Size: 865 B |
|
Before Width: | Height: | Size: 1006 B After Width: | Height: | Size: 1006 B |
|
Before Width: | Height: | Size: 2.0 KiB After Width: | Height: | Size: 2.0 KiB |
|
Before Width: | Height: | Size: 6.5 KiB After Width: | Height: | Size: 6.5 KiB |
BIN
app/src/main/res/drawable-xhdpi/ic_back.png
Normal file
|
After Width: | Height: | Size: 1.8 KiB |
|
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.8 KiB |
|
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.2 KiB |
BIN
app/src/main/res/drawable-xhdpi/ic_menu_search.png
Normal file
|
After Width: | Height: | Size: 2.1 KiB |
|
Before Width: | Height: | Size: 1001 B After Width: | Height: | Size: 1001 B |
|
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 1.7 KiB |
|
Before Width: | Height: | Size: 331 B After Width: | Height: | Size: 331 B |
|
Before Width: | Height: | Size: 214 B After Width: | Height: | Size: 214 B |
BIN
app/src/main/res/drawable-xhdpi/ic_place_holder.png
Normal file
|
After Width: | Height: | Size: 6.0 KiB |
BIN
app/src/main/res/drawable-xhdpi/icon_biology1.png
Normal file
|
After Width: | Height: | Size: 10 KiB |
BIN
app/src/main/res/drawable-xhdpi/icon_chemistry1.png
Normal file
|
After Width: | Height: | Size: 5.5 KiB |
BIN
app/src/main/res/drawable-xhdpi/icon_download_task.png
Normal file
|
After Width: | Height: | Size: 1.9 KiB |
BIN
app/src/main/res/drawable-xhdpi/icon_english1.png
Normal file
|
After Width: | Height: | Size: 7.2 KiB |
BIN
app/src/main/res/drawable-xhdpi/icon_game1.png
Normal file
|
After Width: | Height: | Size: 4.7 KiB |
BIN
app/src/main/res/drawable-xhdpi/icon_geography1.png
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
app/src/main/res/drawable-xhdpi/icon_history1.png
Normal file
|
After Width: | Height: | Size: 9.7 KiB |
BIN
app/src/main/res/drawable-xhdpi/icon_language1.png
Normal file
|
After Width: | Height: | Size: 8.6 KiB |
BIN
app/src/main/res/drawable-xhdpi/icon_math1.png
Normal file
|
After Width: | Height: | Size: 11 KiB |
BIN
app/src/main/res/drawable-xhdpi/icon_my_task.png
Normal file
|
After Width: | Height: | Size: 2.0 KiB |
|
Before Width: | Height: | Size: 68 KiB After Width: | Height: | Size: 68 KiB |
|
Before Width: | Height: | Size: 68 KiB After Width: | Height: | Size: 68 KiB |
BIN
app/src/main/res/drawable-xhdpi/icon_physics1.png
Normal file
|
After Width: | Height: | Size: 8.1 KiB |
BIN
app/src/main/res/drawable-xhdpi/icon_politics1.png
Normal file
|
After Width: | Height: | Size: 6.3 KiB |
BIN
app/src/main/res/drawable-xhdpi/icon_search.png
Normal file
|
After Width: | Height: | Size: 2.3 KiB |
BIN
app/src/main/res/drawable-xhdpi/icon_update_task.png
Normal file
|
After Width: | Height: | Size: 2.2 KiB |
BIN
app/src/main/res/drawable-xhdpi/mask.png
Normal file
|
After Width: | Height: | Size: 2.1 KiB |
BIN
app/src/main/res/drawable-xhdpi/mask_shadow.png
Normal file
|
After Width: | Height: | Size: 3.9 KiB |
|
Before Width: | Height: | Size: 2.3 KiB After Width: | Height: | Size: 2.3 KiB |
20
app/src/main/res/drawable/background_title.xml
Normal file
@@ -0,0 +1,20 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android" >
|
||||
<!--
|
||||
android:startColor="#aa000000" 渐变起始色值
|
||||
android:centerColor="" 渐变中间色值
|
||||
android:endColor="#ffffffff" 渐变结束颜色
|
||||
android:angle="45" 渐变的方向 默认为0 从做向右 ,90时从下向上 必须为45的整数倍
|
||||
android:type="radial" 渐变类型 有三种 线性linear 放射渐变radial 扫描线性渐变sweep
|
||||
android:centerX="0.5" 渐变中心相对X坐标只有渐变类型为放射渐变时有效
|
||||
android:centerY="0.5" 渐变中心相对Y坐标只有渐变类型为放射渐变时有效
|
||||
android:gradientRadius="100" 渐变半径 非线性放射有效
|
||||
-->
|
||||
<gradient
|
||||
android:startColor="#dd5035"
|
||||
android:endColor="#c12b6a"
|
||||
android:angle="90"
|
||||
/>
|
||||
|
||||
</shape>
|
||||
@@ -1,36 +1,84 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<!-- 连框颜色值 -->
|
||||
|
||||
<!--边-->
|
||||
<item>
|
||||
<shape>
|
||||
<solid android:color="#f9493c" />
|
||||
<corners android:radius="@dimen/dp_25" />
|
||||
|
||||
</shape>
|
||||
</item>
|
||||
<!-- 主体背景颜色值 -->
|
||||
<item
|
||||
android:bottom="1dp"
|
||||
android:left="1dp"
|
||||
android:right="1dp"
|
||||
android:top="1dp">
|
||||
<shape>
|
||||
<!-- <gradient-->
|
||||
<!-- android:angle="90"-->
|
||||
<!-- android:centerColor="#FFFFFF"-->
|
||||
<!-- android:centerX="0.5"-->
|
||||
<!-- android:centerY="0.5"-->
|
||||
<!-- android:endColor="#FFFFFF"-->
|
||||
<!-- android:startColor="#FFFFFF"-->
|
||||
<!-- android:type="linear" />-->
|
||||
|
||||
<shape android:shape="rectangle">
|
||||
<padding
|
||||
android:bottom="2dp"
|
||||
android:left="2dp"
|
||||
android:right="2dp"
|
||||
android:top="2dp" />
|
||||
<!-- 应该是圆角 -->
|
||||
<corners android:radius="@dimen/dp_25" />
|
||||
android:bottom="1px"
|
||||
android:left="1px"
|
||||
android:right="1px"
|
||||
android:top="1px" />
|
||||
|
||||
<solid android:color="#00CCCCCC" />
|
||||
|
||||
<corners android:radius="25dp" />
|
||||
</shape>
|
||||
</item>
|
||||
<item>
|
||||
<shape android:shape="rectangle">
|
||||
<padding
|
||||
android:bottom="1px"
|
||||
android:left="1px"
|
||||
android:right="1px"
|
||||
android:top="1px" />
|
||||
|
||||
<solid android:color="#10CCCCCC" />
|
||||
|
||||
<corners android:radius="225dp" />
|
||||
</shape>
|
||||
</item>
|
||||
<item>
|
||||
<shape android:shape="rectangle">
|
||||
<padding
|
||||
android:bottom="1px"
|
||||
android:left="1px"
|
||||
android:right="1px"
|
||||
android:top="1px" />
|
||||
|
||||
<solid android:color="#20CCCCCC" />
|
||||
|
||||
<corners android:radius="25dp" />
|
||||
</shape>
|
||||
</item>
|
||||
<item>
|
||||
<shape android:shape="rectangle">
|
||||
<padding
|
||||
android:bottom="1px"
|
||||
android:left="1px"
|
||||
android:right="1px"
|
||||
android:top="1px" />
|
||||
|
||||
<solid android:color="#30CCCCCC" />
|
||||
|
||||
<corners android:radius="25dp" />
|
||||
</shape>
|
||||
</item>
|
||||
<item>
|
||||
<shape android:shape="rectangle">
|
||||
<padding
|
||||
android:bottom="1px"
|
||||
android:left="1px"
|
||||
android:right="1px"
|
||||
android:top="1px" />
|
||||
|
||||
<solid android:color="#50CCCCCC" />
|
||||
<corners android:radius="25dp" />
|
||||
</shape>
|
||||
</item>
|
||||
|
||||
<!--中心背景 -->
|
||||
<item>
|
||||
<shape
|
||||
android:shape="rectangle"
|
||||
android:useLevel="false">
|
||||
<!--实心 -->
|
||||
<solid android:color="@color/red" />
|
||||
<corners android:radius="25dp" />
|
||||
<size android:width="32dp"
|
||||
android:height="32dp"/>
|
||||
|
||||
</shape>
|
||||
</item>
|
||||
|
||||
</layer-list>
|
||||
@@ -1,36 +1,84 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<!-- 连框颜色值 -->
|
||||
|
||||
<!--边-->
|
||||
<item>
|
||||
<shape>
|
||||
<solid android:color="@color/download" />
|
||||
<corners android:radius="@dimen/dp_25" />
|
||||
|
||||
</shape>
|
||||
</item>
|
||||
<!-- 主体背景颜色值 -->
|
||||
<item
|
||||
android:bottom="1dp"
|
||||
android:left="1dp"
|
||||
android:right="1dp"
|
||||
android:top="1dp">
|
||||
<shape>
|
||||
<!-- <gradient-->
|
||||
<!-- android:angle="90"-->
|
||||
<!-- android:centerColor="#FFFFFF"-->
|
||||
<!-- android:centerX="0.5"-->
|
||||
<!-- android:centerY="0.5"-->
|
||||
<!-- android:endColor="#FFFFFF"-->
|
||||
<!-- android:startColor="#FFFFFF"-->
|
||||
<!-- android:type="linear" />-->
|
||||
|
||||
<shape android:shape="rectangle">
|
||||
<padding
|
||||
android:bottom="2dp"
|
||||
android:left="2dp"
|
||||
android:right="2dp"
|
||||
android:top="2dp" />
|
||||
<!-- 应该是圆角 -->
|
||||
<corners android:radius="@dimen/dp_25" />
|
||||
android:bottom="1px"
|
||||
android:left="1px"
|
||||
android:right="1px"
|
||||
android:top="1px" />
|
||||
|
||||
<solid android:color="#00CCCCCC" />
|
||||
|
||||
<corners android:radius="25dp" />
|
||||
</shape>
|
||||
</item>
|
||||
<item>
|
||||
<shape android:shape="rectangle">
|
||||
<padding
|
||||
android:bottom="1px"
|
||||
android:left="1px"
|
||||
android:right="1px"
|
||||
android:top="1px" />
|
||||
|
||||
<solid android:color="#10CCCCCC" />
|
||||
|
||||
<corners android:radius="225dp" />
|
||||
</shape>
|
||||
</item>
|
||||
<item>
|
||||
<shape android:shape="rectangle">
|
||||
<padding
|
||||
android:bottom="1px"
|
||||
android:left="1px"
|
||||
android:right="1px"
|
||||
android:top="1px" />
|
||||
|
||||
<solid android:color="#20CCCCCC" />
|
||||
|
||||
<corners android:radius="25dp" />
|
||||
</shape>
|
||||
</item>
|
||||
<item>
|
||||
<shape android:shape="rectangle">
|
||||
<padding
|
||||
android:bottom="1px"
|
||||
android:left="1px"
|
||||
android:right="1px"
|
||||
android:top="1px" />
|
||||
|
||||
<solid android:color="#30CCCCCC" />
|
||||
|
||||
<corners android:radius="25dp" />
|
||||
</shape>
|
||||
</item>
|
||||
<item>
|
||||
<shape android:shape="rectangle">
|
||||
<padding
|
||||
android:bottom="1px"
|
||||
android:left="1px"
|
||||
android:right="1px"
|
||||
android:top="1px" />
|
||||
|
||||
<solid android:color="#50CCCCCC" />
|
||||
<corners android:radius="25dp" />
|
||||
</shape>
|
||||
</item>
|
||||
|
||||
<!--中心背景 -->
|
||||
<item>
|
||||
<shape
|
||||
android:shape="rectangle"
|
||||
android:useLevel="false">
|
||||
<!--实心 -->
|
||||
<solid android:color="@color/white" />
|
||||
<corners android:radius="25dp" />
|
||||
<size android:width="32dp"
|
||||
android:height="32dp"/>
|
||||
|
||||
</shape>
|
||||
</item>
|
||||
|
||||
</layer-list>
|
||||
@@ -1,36 +1,84 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<!-- 连框颜色值 -->
|
||||
|
||||
<!--边-->
|
||||
<item>
|
||||
<shape>
|
||||
<solid android:color="@color/green" />
|
||||
<corners android:radius="@dimen/dp_25" />
|
||||
|
||||
</shape>
|
||||
</item>
|
||||
<!-- 主体背景颜色值 -->
|
||||
<item
|
||||
android:bottom="1dp"
|
||||
android:left="1dp"
|
||||
android:right="1dp"
|
||||
android:top="1dp">
|
||||
<shape>
|
||||
<!-- <gradient-->
|
||||
<!-- android:angle="90"-->
|
||||
<!-- android:centerColor="#FFFFFF"-->
|
||||
<!-- android:centerX="0.5"-->
|
||||
<!-- android:centerY="0.5"-->
|
||||
<!-- android:endColor="#FFFFFF"-->
|
||||
<!-- android:startColor="#FFFFFF"-->
|
||||
<!-- android:type="linear" />-->
|
||||
|
||||
<shape android:shape="rectangle">
|
||||
<padding
|
||||
android:bottom="2dp"
|
||||
android:left="2dp"
|
||||
android:right="2dp"
|
||||
android:top="2dp" />
|
||||
<!-- 应该是圆角 -->
|
||||
<corners android:radius="@dimen/dp_25" />
|
||||
android:bottom="1px"
|
||||
android:left="1px"
|
||||
android:right="1px"
|
||||
android:top="1px" />
|
||||
|
||||
<solid android:color="#00CCCCCC" />
|
||||
|
||||
<corners android:radius="25dp" />
|
||||
</shape>
|
||||
</item>
|
||||
<item>
|
||||
<shape android:shape="rectangle">
|
||||
<padding
|
||||
android:bottom="1px"
|
||||
android:left="1px"
|
||||
android:right="1px"
|
||||
android:top="1px" />
|
||||
|
||||
<solid android:color="#10CCCCCC" />
|
||||
|
||||
<corners android:radius="225dp" />
|
||||
</shape>
|
||||
</item>
|
||||
<item>
|
||||
<shape android:shape="rectangle">
|
||||
<padding
|
||||
android:bottom="1px"
|
||||
android:left="1px"
|
||||
android:right="1px"
|
||||
android:top="1px" />
|
||||
|
||||
<solid android:color="#20CCCCCC" />
|
||||
|
||||
<corners android:radius="25dp" />
|
||||
</shape>
|
||||
</item>
|
||||
<item>
|
||||
<shape android:shape="rectangle">
|
||||
<padding
|
||||
android:bottom="1px"
|
||||
android:left="1px"
|
||||
android:right="1px"
|
||||
android:top="1px" />
|
||||
|
||||
<solid android:color="#30CCCCCC" />
|
||||
|
||||
<corners android:radius="25dp" />
|
||||
</shape>
|
||||
</item>
|
||||
<item>
|
||||
<shape android:shape="rectangle">
|
||||
<padding
|
||||
android:bottom="1px"
|
||||
android:left="1px"
|
||||
android:right="1px"
|
||||
android:top="1px" />
|
||||
|
||||
<solid android:color="#50CCCCCC" />
|
||||
<corners android:radius="25dp" />
|
||||
</shape>
|
||||
</item>
|
||||
|
||||
<!--中心背景 -->
|
||||
<item>
|
||||
<shape
|
||||
android:shape="rectangle"
|
||||
android:useLevel="false">
|
||||
<!--实心 -->
|
||||
<solid android:color="@color/red" />
|
||||
<corners android:radius="25dp" />
|
||||
<size android:width="32dp"
|
||||
android:height="32dp"/>
|
||||
|
||||
</shape>
|
||||
</item>
|
||||
|
||||
</layer-list>
|
||||
36
app/src/main/res/drawable/btn_style_shadow.xml
Normal file
@@ -0,0 +1,36 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<!-- 连框颜色值 -->
|
||||
<item>
|
||||
<shape>
|
||||
<solid android:color="@color/download" />
|
||||
<corners android:radius="@dimen/dp_25" />
|
||||
|
||||
</shape>
|
||||
</item>
|
||||
<!-- 主体背景颜色值 -->
|
||||
<item
|
||||
android:bottom="1dp"
|
||||
android:left="1dp"
|
||||
android:right="1dp"
|
||||
android:top="1dp">
|
||||
<shape>
|
||||
<!-- <gradient-->
|
||||
<!-- android:angle="90"-->
|
||||
<!-- android:centerColor="#FFFFFF"-->
|
||||
<!-- android:centerX="0.5"-->
|
||||
<!-- android:centerY="0.5"-->
|
||||
<!-- android:endColor="#FFFFFF"-->
|
||||
<!-- android:startColor="#FFFFFF"-->
|
||||
<!-- android:type="linear" />-->
|
||||
|
||||
<padding
|
||||
android:bottom="2dp"
|
||||
android:left="2dp"
|
||||
android:right="2dp"
|
||||
android:top="2dp" />
|
||||
<!-- 应该是圆角 -->
|
||||
<corners android:radius="@dimen/dp_25" />
|
||||
</shape>
|
||||
</item>
|
||||
</layer-list>
|
||||
|
Before Width: | Height: | Size: 1.5 KiB |
|
Before Width: | Height: | Size: 1.8 KiB |
|
Before Width: | Height: | Size: 7.6 KiB |
|
Before Width: | Height: | Size: 10 KiB |
|
Before Width: | Height: | Size: 8.6 KiB |
|
Before Width: | Height: | Size: 1.6 KiB |
|
Before Width: | Height: | Size: 8.5 KiB |
|
Before Width: | Height: | Size: 5.0 KiB |
|
Before Width: | Height: | Size: 12 KiB |
|
Before Width: | Height: | Size: 7.0 KiB |
|
Before Width: | Height: | Size: 8.7 KiB |
|
Before Width: | Height: | Size: 9.7 KiB |
|
Before Width: | Height: | Size: 1.7 KiB |
|
Before Width: | Height: | Size: 11 KiB |
|
Before Width: | Height: | Size: 5.0 KiB |
|
Before Width: | Height: | Size: 2.4 KiB |
|
Before Width: | Height: | Size: 2.4 KiB |
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<solid android:color="@color/green" />
|
||||
<solid android:color="@color/gray" />
|
||||
|
||||
</shape>
|
||||
@@ -4,6 +4,9 @@
|
||||
<solid android:color="@color/backgroundcolor" />
|
||||
<!-- 圆角的幅度 -->
|
||||
<corners
|
||||
android:bottomLeftRadius="@dimen/dp_25"
|
||||
android:topLeftRadius="@dimen/dp_25" />
|
||||
android:bottomLeftRadius="@dimen/dp_20"
|
||||
android:topLeftRadius="@dimen/dp_20" />
|
||||
<size
|
||||
android:width="@dimen/dp_20"
|
||||
android:height="@dimen/dp_40" />
|
||||
</shape>
|
||||
@@ -1,11 +1,12 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<!-- 内部颜色 -->
|
||||
<solid
|
||||
android:color="@color/backgroundcolor" />
|
||||
<solid android:color="@color/backgroundcolor" />
|
||||
<!-- 圆角的幅度 -->
|
||||
<corners
|
||||
android:topRightRadius="@dimen/dp_25"
|
||||
android:bottomRightRadius="@dimen/dp_25" />
|
||||
android:bottomRightRadius="@dimen/dp_20"
|
||||
android:topRightRadius="@dimen/dp_20" />
|
||||
<size
|
||||
android:width="@dimen/dp_20"
|
||||
android:height="@dimen/dp_20" />
|
||||
</shape>
|
||||
@@ -9,7 +9,8 @@
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/constraintLayout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_30"
|
||||
android:layout_height="@dimen/activity_title_height"
|
||||
android:background="@drawable/background_title"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
@@ -17,12 +18,12 @@
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_exit"
|
||||
android:layout_width="@dimen/dp_15"
|
||||
android:layout_height="@dimen/dp_15"
|
||||
android:layout_marginLeft="@dimen/dp_5"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_marginStart="20dp"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="centerCrop"
|
||||
android:src="@drawable/bt_return"
|
||||
android:src="@drawable/ic_back"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
@@ -33,8 +34,8 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_horizontal"
|
||||
android:text="关于"
|
||||
android:textColor="#4b4b4b"
|
||||
android:textSize="@dimen/sp_14"
|
||||
android:textColor="#ffffff"
|
||||
android:textSize="@dimen/activity_font_size"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
@@ -44,8 +45,8 @@
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/imageView3"
|
||||
android:layout_width="@dimen/dp_100"
|
||||
android:layout_height="@dimen/dp_100"
|
||||
android:layout_width="@dimen/dp_200"
|
||||
android:layout_height="@dimen/dp_200"
|
||||
android:layout_marginTop="64dp"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="fitCenter"
|
||||
|
||||
@@ -7,14 +7,15 @@
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="50dp"
|
||||
android:layout_marginLeft="20dp"
|
||||
android:layout_height="@dimen/activity_title_height"
|
||||
android:background="@drawable/background_title"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/search_iv_back"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_marginStart="20dp"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:adjustViewBounds="true"
|
||||
android:onClick="finish"
|
||||
@@ -29,8 +30,8 @@
|
||||
android:gravity="center_vertical"
|
||||
android:singleLine="true"
|
||||
android:text="应用详情"
|
||||
android:textColor="#8c8b8b"
|
||||
android:textSize="@dimen/sp_15"
|
||||
android:textColor="#ffffff"
|
||||
android:textSize="@dimen/activity_font_size"
|
||||
android:textStyle="bold" />
|
||||
|
||||
</LinearLayout>
|
||||
@@ -39,11 +40,13 @@
|
||||
<ScrollView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:background="@color/white"
|
||||
android:layout_weight="1">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@color/white"
|
||||
android:orientation="vertical">
|
||||
|
||||
<LinearLayout
|
||||
@@ -79,7 +82,7 @@
|
||||
android:singleLine="true"
|
||||
android:text="今日头条"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="@dimen/sp_11" />
|
||||
android:textSize="@dimen/sp_16" />
|
||||
|
||||
|
||||
<RatingBar
|
||||
@@ -106,6 +109,8 @@
|
||||
android:id="@+id/detail_rv_image"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@color/white"
|
||||
|
||||
android:layout_marginTop="15dp"
|
||||
android:layout_marginBottom="15dp" />
|
||||
|
||||
@@ -115,7 +120,7 @@
|
||||
android:layout_marginLeft="@dimen/dp_15"
|
||||
android:layout_marginRight="@dimen/dp_15"
|
||||
android:text="应用介绍"
|
||||
android:textSize="@dimen/sp_11"
|
||||
android:textSize="@dimen/sp_16"
|
||||
android:textStyle="bold">
|
||||
|
||||
</TextView>
|
||||
@@ -137,7 +142,7 @@
|
||||
android:layout_marginTop="@dimen/dp_2"
|
||||
android:layout_marginRight="@dimen/dp_15"
|
||||
android:text="更新"
|
||||
android:textSize="@dimen/sp_11"
|
||||
android:textSize="@dimen/sp_16"
|
||||
android:textStyle="bold">
|
||||
|
||||
</TextView>
|
||||
@@ -160,7 +165,7 @@
|
||||
android:layout_marginTop="@dimen/dp_2"
|
||||
android:layout_marginRight="@dimen/dp_15"
|
||||
android:text="信息"
|
||||
android:textSize="@dimen/sp_11"
|
||||
android:textSize="@dimen/sp_16"
|
||||
android:textStyle="bold">
|
||||
|
||||
</TextView>
|
||||
@@ -196,7 +201,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="@dimen/dp_15"
|
||||
android:layout_marginRight="@dimen/dp_15"
|
||||
android:text="供应商" />
|
||||
android:text="开发者" />
|
||||
|
||||
|
||||
</LinearLayout>
|
||||
@@ -207,13 +212,14 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="@dimen/dp_15"
|
||||
android:background="@color/white"
|
||||
android:orientation="horizontal">
|
||||
|
||||
|
||||
<Button
|
||||
android:id="@+id/detail_tv_download"
|
||||
android:layout_width="280dp"
|
||||
android:layout_height="40dp"
|
||||
android:layout_width="@dimen/dp_340"
|
||||
android:layout_height="@dimen/dp_60"
|
||||
android:layout_centerInParent="true"
|
||||
android:background="@drawable/btn_style_open"
|
||||
android:clickable="true"
|
||||
@@ -221,7 +227,7 @@
|
||||
android:stateListAnimator="@null"
|
||||
android:text="安装"
|
||||
android:textColor="#ffffff"
|
||||
android:textSize="15sp" />
|
||||
android:textSize="@dimen/sp_18" />
|
||||
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
@@ -9,8 +9,8 @@
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="50dp"
|
||||
android:layout_marginLeft="20dp"
|
||||
android:layout_height="@dimen/activity_title_height"
|
||||
android:background="@drawable/background_title"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ImageView
|
||||
@@ -20,6 +20,7 @@
|
||||
android:layout_gravity="center_vertical"
|
||||
android:adjustViewBounds="true"
|
||||
android:onClick="finish"
|
||||
android:layout_marginStart="20dp"
|
||||
android:scaleType="centerInside"
|
||||
android:src="@drawable/ic_back" />
|
||||
|
||||
@@ -30,13 +31,14 @@
|
||||
android:gravity="center_vertical"
|
||||
android:singleLine="true"
|
||||
android:text="下载管理"
|
||||
android:textColor="#8c8b8b"
|
||||
android:textSize="17sp"
|
||||
android:textColor="#ffffff"
|
||||
android:textSize="@dimen/activity_font_size"
|
||||
android:textStyle="bold" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<RelativeLayout
|
||||
android:background="@color/white"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
|
||||
@@ -4,19 +4,21 @@
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/white"
|
||||
android:orientation="vertical">
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="50dp"
|
||||
android:layout_marginLeft="20dp"
|
||||
android:layout_height="@dimen/activity_title_height"
|
||||
android:background="@drawable/background_title"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginStart="20dp"
|
||||
android:adjustViewBounds="true"
|
||||
android:onClick="finish"
|
||||
android:scaleType="centerInside"
|
||||
@@ -29,7 +31,7 @@
|
||||
android:layout_marginLeft="10dp"
|
||||
android:gravity="center_vertical"
|
||||
android:singleLine="true"
|
||||
android:textColor="#8c8b8b"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="17sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
|
||||
@@ -9,8 +9,8 @@
|
||||
<LinearLayout
|
||||
android:id="@+id/linearLayout2"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="50dp"
|
||||
android:layout_marginLeft="20dp"
|
||||
android:layout_height="@dimen/activity_title_height"
|
||||
android:background="@drawable/background_title"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
@@ -20,6 +20,7 @@
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginStart="20dp"
|
||||
android:adjustViewBounds="true"
|
||||
android:onClick="finish"
|
||||
android:scaleType="centerInside"
|
||||
@@ -32,7 +33,7 @@
|
||||
android:gravity="center_vertical"
|
||||
android:singleLine="true"
|
||||
android:text="本地管理"
|
||||
android:textColor="#8c8b8b"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="17sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
@@ -46,6 +47,7 @@
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
android:background="@color/white"
|
||||
app:layout_constraintTop_toBottomOf="@+id/linearLayout2">
|
||||
|
||||
<RelativeLayout
|
||||
|
||||
@@ -9,14 +9,13 @@
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
>
|
||||
android:orientation="vertical">
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="60dp"
|
||||
android:layout_margin="10dp"
|
||||
android:background="@drawable/background_title"
|
||||
android:orientation="horizontal">
|
||||
|
||||
|
||||
@@ -24,8 +23,8 @@
|
||||
android:id="@+id/iv_appicon"
|
||||
android:layout_width="50dp"
|
||||
android:layout_height="50dp"
|
||||
android:layout_marginLeft="20dp"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginLeft="20dp"
|
||||
android:adjustViewBounds="true"
|
||||
android:background="@drawable/ic_place_holder"
|
||||
android:scaleType="centerInside" />
|
||||
@@ -41,31 +40,32 @@
|
||||
|
||||
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/search_ll"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_24"
|
||||
android:layout_height="@dimen/dp_40"
|
||||
android:layout_centerInParent="true"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
|
||||
<ImageView
|
||||
android:layout_width="@dimen/dp_12"
|
||||
android:layout_height="@dimen/dp_24"
|
||||
android:layout_width="@dimen/dp_20"
|
||||
android:layout_height="@dimen/dp_40"
|
||||
android:gravity="center_vertical"
|
||||
android:src="@drawable/shap_search_left" />
|
||||
|
||||
<ImageView
|
||||
android:layout_width="@dimen/dp_15"
|
||||
android:layout_height="@dimen/dp_24"
|
||||
android:layout_width="@dimen/dp_20"
|
||||
android:layout_height="@dimen/dp_40"
|
||||
android:adjustViewBounds="true"
|
||||
android:background="@color/backgroundcolor"
|
||||
android:scaleType="centerInside"
|
||||
android:src="@drawable/icon_serach"></ImageView>
|
||||
android:src="@drawable/icon_search" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_24"
|
||||
android:layout_height="@dimen/dp_40"
|
||||
android:background="@drawable/shap_search_right"
|
||||
android:gravity="center_vertical"
|
||||
android:text="@string/search_edit"
|
||||
@@ -74,7 +74,6 @@
|
||||
</TextView>
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<ImageView
|
||||
@@ -83,8 +82,8 @@
|
||||
android:layout_height="30dp"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginRight="20dp"
|
||||
android:visibility="gone"
|
||||
android:src="@drawable/ic_action_bar">
|
||||
android:src="@drawable/ic_action_bar"
|
||||
android:visibility="gone">
|
||||
|
||||
</ImageView>
|
||||
|
||||
@@ -98,7 +97,8 @@
|
||||
app:tl_indicator_style="TRIANGLE"
|
||||
app:tl_tab_space_equal="true"
|
||||
app:tl_textBold="SELECT"
|
||||
app:tl_textSelectColor="@color/green"
|
||||
app:tl_textsize="@dimen/sp_15"
|
||||
app:tl_textSelectColor="@color/red"
|
||||
app:tl_textUnselectColor="@color/install" />
|
||||
|
||||
<androidx.viewpager.widget.ViewPager
|
||||
|
||||
@@ -9,7 +9,8 @@
|
||||
<LinearLayout
|
||||
android:id="@+id/linearLayout3"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="50dp"
|
||||
android:layout_height="@dimen/activity_title_height"
|
||||
android:background="@drawable/background_title"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
@@ -30,8 +31,10 @@
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginEnd="@dimen/dp_40"
|
||||
android:textColor="@color/white"
|
||||
app:iconifiedByDefault="false"
|
||||
app:queryHint="@string/search_edit">
|
||||
app:queryHint="@string/search_edit"
|
||||
app:searchIcon="@drawable/ic_menu_search">
|
||||
|
||||
</androidx.appcompat.widget.SearchView>
|
||||
|
||||
@@ -44,6 +47,7 @@
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
android:background="@color/white"
|
||||
app:layout_constraintTop_toBottomOf="@+id/linearLayout3">
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
|
||||
@@ -15,13 +15,13 @@
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<com.zhpan.bannerview.BannerViewPager
|
||||
android:id="@+id/banner_view"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_150"
|
||||
android:layout_height="@dimen/dp_230"
|
||||
android:layout_margin="10dp" />
|
||||
|
||||
<RelativeLayout
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
<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">
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/white"
|
||||
android:orientation="vertical">
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
@@ -158,6 +159,7 @@
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/manage_rv_local"
|
||||
android:layout_width="match_parent"
|
||||
android:background="@color/white"
|
||||
android:layout_height="match_parent" />
|
||||
|
||||
<ImageView
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
<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">
|
||||
|
||||
<com.scwang.smartrefresh.layout.SmartRefreshLayout
|
||||
|
||||
@@ -5,7 +5,6 @@
|
||||
android:layout_height="80dp"
|
||||
android:background="@drawable/ll_selector"
|
||||
android:clickable="true"
|
||||
|
||||
android:orientation="vertical">
|
||||
|
||||
<LinearLayout
|
||||
@@ -23,7 +22,7 @@
|
||||
android:layout_height="55dp"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginRight="10dp"
|
||||
android:background="@mipmap/ic_launcher" />
|
||||
/>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
@@ -73,15 +72,15 @@
|
||||
|
||||
<Button
|
||||
android:id="@+id/app_btn_download"
|
||||
android:layout_width="@dimen/dp_40"
|
||||
android:layout_height="@dimen/dp_20"
|
||||
android:layout_width="@dimen/dp_80"
|
||||
android:layout_height="@dimen/dp_40"
|
||||
android:textColor="#000000"
|
||||
android:stateListAnimator="@null"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginRight="10dp"
|
||||
android:background="@drawable/btn_style_none"
|
||||
android:text="下载中"
|
||||
android:textSize="@dimen/sp_10"
|
||||
android:textSize="@dimen/sp_16"
|
||||
android:visibility="visible" />
|
||||
|
||||
|
||||
|
||||
@@ -41,8 +41,8 @@
|
||||
|
||||
<Button
|
||||
android:id="@+id/item_finish_btn_install"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_width="@dimen/dp_80"
|
||||
android:layout_height="@dimen/dp_40"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:layout_marginRight="20dp"
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginRight="10dp" />
|
||||
android:layout_marginEnd="10dp" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
@@ -52,7 +52,7 @@
|
||||
android:id="@+id/item_downloading_tv_state"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginRight="10dp"
|
||||
android:layout_marginEnd="10dp"
|
||||
/>
|
||||
</LinearLayout>
|
||||
|
||||
@@ -60,11 +60,11 @@
|
||||
|
||||
<Button
|
||||
android:id="@+id/item_downloading_btn_donwload"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_width="@dimen/dp_80"
|
||||
android:layout_height="@dimen/dp_40"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:layout_marginRight="20dp"
|
||||
android:layout_marginStart="10dp"
|
||||
android:layout_marginEnd="20dp"
|
||||
android:background="@drawable/btn_selector"
|
||||
android:text="开始" />
|
||||
</LinearLayout>
|
||||
@@ -2,7 +2,7 @@
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_60">
|
||||
android:layout_height="@dimen/dp_80">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/linearLayout"
|
||||
@@ -16,9 +16,10 @@
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/icon"
|
||||
android:layout_width="@dimen/dp_40"
|
||||
android:layout_height="@dimen/dp_40"
|
||||
android:layout_width="@dimen/dp_45"
|
||||
android:layout_height="@dimen/dp_45"
|
||||
android:layout_margin="@dimen/dp_5"
|
||||
android:layout_gravity="center"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="centerInside"
|
||||
android:src="@mipmap/ic_launcher">
|
||||
@@ -28,6 +29,7 @@
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_marginLeft="@dimen/dp_20"
|
||||
android:layout_weight="2"
|
||||
android:orientation="vertical">
|
||||
|
||||
@@ -92,6 +94,7 @@
|
||||
android:layout_width="@dimen/dp_15"
|
||||
android:layout_height="@dimen/dp_15"
|
||||
android:layout_gravity="center"
|
||||
android:layout_margin="@dimen/dp_20"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="centerInside"
|
||||
android:src="@drawable/bt_delete">
|
||||
@@ -100,7 +103,7 @@
|
||||
|
||||
<Button
|
||||
android:id="@+id/start"
|
||||
android:layout_width="60dp"
|
||||
android:layout_width="@dimen/dp_80"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:text="暂停"
|
||||
@@ -112,12 +115,14 @@
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/imageView"
|
||||
android:layout_width="@dimen/dp_340"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dp"
|
||||
android:layout_marginLeft="@dimen/dp_20"
|
||||
android:layout_marginRight="@dimen/dp_20"
|
||||
android:src="#9B9B9B"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/linearLayout"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent">
|
||||
app:layout_constraintEnd_toEndOf="@+id/linearLayout"
|
||||
app:layout_constraintStart_toStartOf="@+id/linearLayout">
|
||||
|
||||
</ImageView>
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
android:layout_height="60dp"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginLeft="20dp"
|
||||
android:background="@mipmap/ic_launcher" />
|
||||
/>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
@@ -37,7 +37,6 @@
|
||||
android:layout_weight="1"
|
||||
android:gravity="center_vertical"
|
||||
android:singleLine="true"
|
||||
android:text="王者荣耀"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="17sp" />
|
||||
|
||||
@@ -62,8 +61,8 @@
|
||||
|
||||
<Button
|
||||
android:id="@+id/local_app_btn_download"
|
||||
android:layout_width="@dimen/dp_40"
|
||||
android:layout_height="@dimen/dp_20"
|
||||
android:layout_width="@dimen/dp_80"
|
||||
android:layout_height="@dimen/dp_40"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginRight="10dp"
|
||||
android:background="@drawable/btn_style_delete"
|
||||
|
||||
|
Before Width: | Height: | Size: 5.8 KiB After Width: | Height: | Size: 8.3 KiB |
|
Before Width: | Height: | Size: 5.8 KiB After Width: | Height: | Size: 8.3 KiB |
|
Before Width: | Height: | Size: 5.8 KiB After Width: | Height: | Size: 8.3 KiB |
|
Before Width: | Height: | Size: 5.8 KiB After Width: | Height: | Size: 8.3 KiB |
|
Before Width: | Height: | Size: 5.8 KiB After Width: | Height: | Size: 8.3 KiB |
|
Before Width: | Height: | Size: 5.8 KiB After Width: | Height: | Size: 8.3 KiB |