diff --git a/.gitignore b/.gitignore index 9c4de58..d9d8571 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,4 @@ .DS_Store /build /captures +/learn diff --git a/.idea/.name b/.idea/.name deleted file mode 100644 index 0f36dd6..0000000 --- a/.idea/.name +++ /dev/null @@ -1 +0,0 @@ -UserGuideView \ No newline at end of file diff --git a/.idea/assetWizardSettings.xml b/.idea/assetWizardSettings.xml new file mode 100644 index 0000000..370f413 --- /dev/null +++ b/.idea/assetWizardSettings.xml @@ -0,0 +1,32 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/caches/build_file_checksums.ser b/.idea/caches/build_file_checksums.ser new file mode 100644 index 0000000..f7875ea Binary files /dev/null and b/.idea/caches/build_file_checksums.ser differ diff --git a/.idea/compiler.xml b/.idea/compiler.xml index 96cc43e..61a9130 100644 --- a/.idea/compiler.xml +++ b/.idea/compiler.xml @@ -1,22 +1,6 @@ - - - - - - - - - - - - - - - - - + \ No newline at end of file diff --git a/.idea/gradle.xml b/.idea/gradle.xml index 4e373fc..314a962 100644 --- a/.idea/gradle.xml +++ b/.idea/gradle.xml @@ -1,11 +1,13 @@ + + - + @@ -14,6 +16,8 @@ + + diff --git a/.idea/jarRepositories.xml b/.idea/jarRepositories.xml new file mode 100644 index 0000000..c01cbe6 --- /dev/null +++ b/.idea/jarRepositories.xml @@ -0,0 +1,40 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/misc.xml b/.idea/misc.xml index 1a3eaff..449f18f 100644 --- a/.idea/misc.xml +++ b/.idea/misc.xml @@ -1,8 +1,5 @@ - - - @@ -27,17 +24,7 @@ - - - - - - - - - - - + diff --git a/.idea/modules.xml b/.idea/modules.xml index 690268d..d948eb7 100644 --- a/.idea/modules.xml +++ b/.idea/modules.xml @@ -2,9 +2,9 @@ - - - + + + \ No newline at end of file diff --git a/.idea/modules/HighLight-UserGuideView.iml b/.idea/modules/HighLight-UserGuideView.iml new file mode 100644 index 0000000..3f7117b --- /dev/null +++ b/.idea/modules/HighLight-UserGuideView.iml @@ -0,0 +1,20 @@ + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/modules/Userguidelibrary/HighLight-UserGuideView.Userguidelibrary.iml b/.idea/modules/Userguidelibrary/HighLight-UserGuideView.Userguidelibrary.iml new file mode 100644 index 0000000..d43c9cb --- /dev/null +++ b/.idea/modules/Userguidelibrary/HighLight-UserGuideView.Userguidelibrary.iml @@ -0,0 +1,78 @@ + + + + + + + + + + + + + + + + + generateDebugSources + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/modules/app/HighLight-UserGuideView.app.iml b/.idea/modules/app/HighLight-UserGuideView.app.iml new file mode 100644 index 0000000..764251e --- /dev/null +++ b/.idea/modules/app/HighLight-UserGuideView.app.iml @@ -0,0 +1,87 @@ + + + + + + + + + + + + + + + + + generateDebugSources + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/UserGuideView.iml b/UserGuideView.iml deleted file mode 100644 index dd58473..0000000 --- a/UserGuideView.iml +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/Userguidelibrary/Userguidelibrary.iml b/Userguidelibrary/Userguidelibrary.iml deleted file mode 100644 index aa12c0a..0000000 --- a/Userguidelibrary/Userguidelibrary.iml +++ /dev/null @@ -1,96 +0,0 @@ - - - - - - - - - - - - - - - - - - generateDebugAndroidTestSources - generateDebugSources - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/Userguidelibrary/src/main/java/com/zhl/userguideview/AnimGuideView.java b/Userguidelibrary/src/main/java/com/zhl/userguideview/AnimGuideView.java new file mode 100644 index 0000000..3243577 --- /dev/null +++ b/Userguidelibrary/src/main/java/com/zhl/userguideview/AnimGuideView.java @@ -0,0 +1,252 @@ +package com.zhl.userguideview; + +import android.animation.ObjectAnimator; +import android.content.Context; +import android.content.res.Resources; +import android.graphics.Bitmap; +import android.graphics.BitmapFactory; +import android.graphics.BlurMaskFilter; +import android.graphics.Canvas; +import android.graphics.Paint; +import android.graphics.PorterDuff; +import android.graphics.PorterDuffXfermode; +import android.graphics.Rect; +import android.graphics.RectF; +import android.util.AttributeSet; +import android.view.View; +import android.view.animation.LinearInterpolator; + +import androidx.annotation.DrawableRes; +import androidx.annotation.Nullable; + +public class AnimGuideView extends View { + public static final int VIEWSTYLE_RECT = 0; + public static final int VIEWSTYLE_CIRCLE = 1; + public static final int VIEWSTYLE_OVAL = 2; + public static final int MASKBLURSTYLE_SOLID = 0; // 模糊 + public static final int MASKBLURSTYLE_NORMAL = 1; //模糊 + + + private int screenW, screenH;// 屏幕宽高 + private int maskblurstyle = MASKBLURSTYLE_SOLID; + private int highLightStyle = VIEWSTYLE_RECT; //高亮的模式 + + private Canvas mCanvas;// 给蒙版层的画布 + private Paint mPaint;//绘制蒙版层画笔 + private Bitmap fgBitmap; //前景 + private Bitmap tipBitmap; // 提示的bitmap + private int maskColor = 0x99000000;// 蒙版层颜色 + + private Bitmap bmHands;// 手指指向 + private Bitmap bmIknow; + + private float corner = 20; + private int statusBarHeight; // 状态栏的高度 + + private float handsOffset = 0; + + //private Bitmap jtUpLeft, jtUpRight, jtUpCenter, jtDownRight, jtDownLeft, jtDownCenter;// 指示箭头 + private View targetView; + + public AnimGuideView(Context context) { + super(context); + initialize(context, null); + } + + public AnimGuideView(Context context, @Nullable AttributeSet attrs) { + super(context, attrs); + initialize(context, attrs); + } + + public AnimGuideView(Context context, @Nullable AttributeSet attrs, int defStyleAttr) { + super(context, attrs, defStyleAttr); + initialize(context, attrs); + } + + private void initialize(Context context, AttributeSet attrs) { + + if (attrs != null) { +// TypedArray array = context.obtainStyledAttributes(attrs, R.styleable.UserGuideView); +// highLightStyle = array.getInt(R.styleable.UserGuideView_HighlightViewStyle, VIEWSTYLE_RECT); +// maskblurstyle = array.getInt(R.styleable.UserGuideView_MaskBlurStyle, MASKBLURSTYLE_SOLID); +// BitmapDrawable drawable = (BitmapDrawable) array.getDrawable(R.styleable.UserGuideView_tipView); +// maskColor = array.getColor(R.styleable.UserGuideView_maskColor, maskColor); +// if (drawable != null) { +// tipBitmap = drawable.getBitmap(); +// } + +// array.recycle(); + bmHands = getBitmap(R.drawable.hands, 36, 36);// BitmapFactory.decodeResource(getResources(), R.drawable.shouzhi); + bmIknow = BitmapFactory.decodeResource(getResources(), R.mipmap.iknown); + } + + + cal(context); + init(context); + } + + + public Bitmap getBitmap(@DrawableRes final int resId, + final int maxWidth, + final int maxHeight) { + BitmapFactory.Options options = new BitmapFactory.Options(); + final Resources resources = getResources(); + options.inJustDecodeBounds = true; + BitmapFactory.decodeResource(resources, resId, options); + options.inSampleSize = calculateInSampleSize(options, maxWidth, maxHeight); + options.inJustDecodeBounds = false; + return BitmapFactory.decodeResource(resources, resId, options); + } + + /** + * Return the sample size. + * + * @param options The options. + * @param maxWidth The maximum width. + * @param maxHeight The maximum height. + * @return the sample size + */ + private int calculateInSampleSize(final BitmapFactory.Options options, + final int maxWidth, + final int maxHeight) { + int height = options.outHeight; + int width = options.outWidth; + int inSampleSize = 1; + while ((width>>= 1)>= maxWidth && (height>>= 1)>= maxHeight) { + inSampleSize <<= 1; + } + return inSampleSize; + } + + + private void cal(Context context) { + int[] screenSize = MeasureUtil.getScreenSize(context); + screenW = screenSize[0]; + screenH = screenSize[1]; + } + + + /** + * 初始化对象 + */ + private void init(Context context) { + mPaint = new Paint(Paint.ANTI_ALIAS_FLAG | Paint.DITHER_FLAG); + + mPaint.setARGB(0, 255, 0, 0); + mPaint.setXfermode(new PorterDuffXfermode(PorterDuff.Mode.DST_IN)); + BlurMaskFilter.Blur blurStyle = null; + switch (maskblurstyle) { + case MASKBLURSTYLE_SOLID: + blurStyle = BlurMaskFilter.Blur.SOLID; + break; + case MASKBLURSTYLE_NORMAL: + blurStyle = BlurMaskFilter.Blur.NORMAL; + break; + } + mPaint.setMaskFilter(new BlurMaskFilter(15, blurStyle)); + + fgBitmap = MeasureUtil.createBitmapSafely(screenW, screenH, Bitmap.Config.ARGB_8888, 2); + if (fgBitmap == null) { + throw new RuntimeException("out of memory cause fgbitmap create fail"); + } + mCanvas = new Canvas(fgBitmap); + mCanvas.drawColor(maskColor); + } + + @Override + protected void onDraw(Canvas canvas) { + if (targetView == null) { + return; + } + + // 画背景 + canvas.drawBitmap(fgBitmap, 0, 0, null); + + Rect rect = new Rect(); + targetView.getGlobalVisibleRect(rect); + rect.offset(0, -statusBarHeight); + + // 绘制高亮 + switch (highLightStyle) { + case VIEWSTYLE_RECT: // 正方形 + RectF rectF = new RectF(rect); + mCanvas.drawRoundRect(rectF, corner, corner, mPaint); + break; + case VIEWSTYLE_CIRCLE: // 圆形 + break; + case VIEWSTYLE_OVAL: //椭圆形 + break; + } + + + // rect.offset(0, statusBarHeight); + drawHands(canvas, rect); + drawHints(canvas, rect); + } + + private void drawHints(Canvas canvas, Rect rect) { + // "我知道了" 提示 + canvas.drawBitmap(bmIknow, getIKnowLeft(rect), getIKnowTop(rect), null); + } + + + private float getIKnowLeft(Rect rect) { + return rect.left - bmIknow.getWidth() - 20; + } + + private float getIKnowTop(Rect rect) { + return rect.top - (Math.abs(rect.top - rect.bottom)>> 1 - bmIknow.getHeight()>> 1); + } + + + private void drawHands(Canvas canvas, Rect rect) { + // 手指头 + canvas.drawBitmap(bmHands, getHandsLeft(rect), getHandsTop(rect), null); + } + + + private float getHandsLeft(Rect targetRect) { + return targetRect.left + (Math.abs(targetRect.left - targetRect.right)>> 1) - (bmHands.getWidth()>> 1); + } + + private float getHandsTop(Rect targetRect) { + return targetRect.top - bmHands.getHeight() - handsOffset; + } + + + public void setStatusBarHeight(int statusBarHeight) { + this.statusBarHeight = statusBarHeight; + } + + // 设置高亮的View + public void setHighLightView(View targetView) { + if (this.targetView != null && targetView != null && this.targetView != targetView) { + Paint paint = new Paint(Paint.ANTI_ALIAS_FLAG); + paint.setXfermode(new PorterDuffXfermode(PorterDuff.Mode.CLEAR)); // 清除之前的模式 + mCanvas.drawPaint(paint); + mCanvas.drawColor(maskColor); + } + this.targetView = targetView; + invalidate(); + setVisibility(VISIBLE); + } + + + public void setHandsOffset(float handsOffset) { + this.handsOffset = handsOffset; + invalidate(); + } + + public float getHandsOffset() { + return handsOffset; + } + + public void startHandsAnimate() { + ObjectAnimator handsOffset = ObjectAnimator.ofFloat(this, "handsOffset", 0F, 1F, 2F, 3F, 10F, 15F, 17F, 18F, 19F, 20F); + handsOffset.setInterpolator(new LinearInterpolator()); + handsOffset.setDuration(500); + handsOffset.setRepeatCount(ObjectAnimator.INFINITE); + handsOffset.setRepeatMode(ObjectAnimator.REVERSE); + handsOffset.start(); + } +} diff --git a/Userguidelibrary/src/main/java/com/zhl/userguideview/UserGuideView.java b/Userguidelibrary/src/main/java/com/zhl/userguideview/UserGuideView.java index 262032b..d73484e 100644 --- a/Userguidelibrary/src/main/java/com/zhl/userguideview/UserGuideView.java +++ b/Userguidelibrary/src/main/java/com/zhl/userguideview/UserGuideView.java @@ -254,7 +254,7 @@ protected void onDraw(Canvas canvas) { if (targetView == null) { return; } - canvas.drawBitmap(fgBitmap, 0, 0, null); + canvas.drawBitmap(fgBitmap, 0, 0, null);// 整个背景 // int left = targetView.getLeft(); // int top = targetView.getTop(); int left = 0; @@ -265,7 +265,7 @@ protected void onDraw(Canvas canvas) { int vHeight = targetView.getHeight(); Rect tagetRect = new Rect(); - targetView.getGlobalVisibleRect(tagetRect); + targetView.getGlobalVisibleRect(tagetRect); // 目标 tagetRect.offset(0, -statusBarHeight); left = tagetRect.left - offestMargin; top = tagetRect.top - offestMargin; @@ -284,25 +284,25 @@ protected void onDraw(Canvas canvas) { // 绘制高亮框 switch (highLightStyle) { case VIEWSTYLE_RECT: - RectF rect = new RectF(left, top, right, bottom); + RectF rect = new RectF(left, top, right, bottom); // 方形 mCanvas.drawRoundRect(rect, 20, 20, mPaint); break; - case VIEWSTYLE_CIRCLE: + case VIEWSTYLE_CIRCLE: // 圆框 radius = (int) Math.sqrt(vWidth * vWidth + vHeight * vHeight) / 2 + offestMargin; if (radius < 50) { radius = 100; } mCanvas.drawCircle(left + offestMargin + vWidth / 2, top + offestMargin + vHeight / 2, radius, mPaint); break; - case VIEWSTYLE_OVAL: + case VIEWSTYLE_OVAL: //椭圆 RectF rectf = new RectF(left, top, right, bottom); mCanvas.drawOval(rectf, mPaint); break; } - tipViewMoveX = getTipViewMoveX(); - tipViewMoveY = getTipViewMoveY(); + tipViewMoveX = getTipViewMoveX(); //提示需要移动的X + tipViewMoveY = getTipViewMoveY(); //提示需要移动的Y // 绘制箭头和提示view if (bottom < screenH / 2 || (screenH / 2 - top> bottom - screenH / 2)) {// top @@ -414,12 +414,12 @@ private int getDownJTtop(Bitmap jtBitmap, int trgetTop, int targetHeight) { public void setHighLightView(View targetView) { if (this.targetView != null && targetView != null && this.targetView != targetView) { Paint paint = new Paint(Paint.ANTI_ALIAS_FLAG); - paint.setXfermode(new PorterDuffXfermode(PorterDuff.Mode.CLEAR)); + paint.setXfermode(new PorterDuffXfermode(PorterDuff.Mode.CLEAR)); // 挖空了这个View mCanvas.drawPaint(paint); mCanvas.drawColor(maskColor); } - this.targetView = targetView; - invalidate(); + this.targetView = targetView;// 给这个targetView赋值 + invalidate();//刷新界面 setVisibility(VISIBLE); } diff --git a/Userguidelibrary/src/main/res/drawable/hands.png b/Userguidelibrary/src/main/res/drawable/hands.png new file mode 100644 index 0000000..2f0357e Binary files /dev/null and b/Userguidelibrary/src/main/res/drawable/hands.png differ diff --git a/Userguidelibrary/src/main/res/mipmap-hdpi/iknown.png b/Userguidelibrary/src/main/res/mipmap-hdpi/iknown.png new file mode 100644 index 0000000..65a7409 Binary files /dev/null and b/Userguidelibrary/src/main/res/mipmap-hdpi/iknown.png differ diff --git a/Userguidelibrary/src/main/res/mipmap-mdpi/iknown.png b/Userguidelibrary/src/main/res/mipmap-mdpi/iknown.png new file mode 100644 index 0000000..57b6db6 Binary files /dev/null and b/Userguidelibrary/src/main/res/mipmap-mdpi/iknown.png differ diff --git a/Userguidelibrary/src/main/res/mipmap-xhdpi/iknown.png b/Userguidelibrary/src/main/res/mipmap-xhdpi/iknown.png new file mode 100644 index 0000000..cf542cd Binary files /dev/null and b/Userguidelibrary/src/main/res/mipmap-xhdpi/iknown.png differ diff --git a/Userguidelibrary/src/main/res/mipmap-xxhdpi/iknown.png b/Userguidelibrary/src/main/res/mipmap-xxhdpi/iknown.png new file mode 100644 index 0000000..9ea3100 Binary files /dev/null and b/Userguidelibrary/src/main/res/mipmap-xxhdpi/iknown.png differ diff --git a/Userguidelibrary/src/main/res/mipmap-xxxhdpi/iknown.png b/Userguidelibrary/src/main/res/mipmap-xxxhdpi/iknown.png new file mode 100644 index 0000000..90f3c06 Binary files /dev/null and b/Userguidelibrary/src/main/res/mipmap-xxxhdpi/iknown.png differ diff --git a/app/app.iml b/app/app.iml deleted file mode 100644 index 12e624c..0000000 --- a/app/app.iml +++ /dev/null @@ -1,100 +0,0 @@ - - - - - - - - - - - - - - - - - - generateDebugAndroidTestSources - generateDebugSources - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/app/build.gradle b/app/build.gradle index 6488ae6..e6cbacf 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -5,7 +5,7 @@ android { buildToolsVersion "28.0.3" defaultConfig { - applicationId "com.zhl.userguideview" + applicationId "com.zhl.userguideview.userguideview" minSdkVersion 15 targetSdkVersion 26 versionCode 1 diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index 6114817..e12f995 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -17,6 +17,9 @@ android:name="com.zhl.userguideview.UserGuideTestActivity" android:label="@string/app_name" android:theme="@android:style/Theme.Black.NoTitleBar"> + + + diff --git a/app/src/main/java/com/zhl/userguideview/AnimGuideActivity.java b/app/src/main/java/com/zhl/userguideview/AnimGuideActivity.java new file mode 100644 index 0000000..4d87a03 --- /dev/null +++ b/app/src/main/java/com/zhl/userguideview/AnimGuideActivity.java @@ -0,0 +1,71 @@ +package com.zhl.userguideview; + +import android.app.Activity; +import android.os.Bundle; +import android.view.View; +import android.widget.Toast; + +import androidx.annotation.Nullable; + +import com.zhl.userguideview.userguideview.R; + + +public class AnimGuideActivity extends Activity { + + + @Override + protected void onCreate(@Nullable Bundle savedInstanceState) { + super.onCreate(savedInstanceState); + setContentView(R.layout.activity_animguide); + + + findViewById(R.id.ll1).setOnClickListener(new View.OnClickListener() { + @Override + public void onClick(View v) { + Toast.makeText(AnimGuideActivity.this, "ll1", Toast.LENGTH_SHORT).show(); + } + }); + findViewById(R.id.ll2).setOnClickListener(new View.OnClickListener() { + @Override + public void onClick(View v) { + Toast.makeText(AnimGuideActivity.this, "ll2", Toast.LENGTH_SHORT).show(); + } + }); + findViewById(R.id.ll3).setOnClickListener(new View.OnClickListener() { + @Override + public void onClick(View v) { + Toast.makeText(AnimGuideActivity.this, "ll3", Toast.LENGTH_SHORT).show(); + } + }); + findViewById(R.id.ll4).setOnClickListener(new View.OnClickListener() { + @Override + public void onClick(View v) { + Toast.makeText(AnimGuideActivity.this, "ll4", Toast.LENGTH_SHORT).show(); + } + }); + + findViewById(R.id.second).setOnClickListener(new View.OnClickListener() { + @Override + public void onClick(View v) { + Toast.makeText(AnimGuideActivity.this, "second", Toast.LENGTH_SHORT).show(); + } + }); + + + AnimGuideView animGuideView = findViewById(R.id.animGuideView); + animGuideView.setVisibility(View.VISIBLE); + + + View second = findViewById(R.id.second); + animGuideView.setHighLightView(second); + animGuideView.setStatusBarHeight(MeasureUtil.getStatuBarHeight(this)); + animGuideView.startHandsAnimate(); + + + // 1. 先把背景涂黑 + // 2。 找到那个View的位置,画圆 + // 3. 提示的小手 (上下动起来) + // 4. 我知道了 + + } +} diff --git a/app/src/main/java/com/zhl/userguideview/UserGuideTestActivity.java b/app/src/main/java/com/zhl/userguideview/UserGuideTestActivity.java index dccf827..1d07410 100644 --- a/app/src/main/java/com/zhl/userguideview/UserGuideTestActivity.java +++ b/app/src/main/java/com/zhl/userguideview/UserGuideTestActivity.java @@ -9,6 +9,7 @@ import android.widget.GridView; import android.widget.ImageView; import android.widget.TextView; +import android.widget.Toast; import com.zhl.userguideview.userguideview.R; @@ -22,7 +23,7 @@ public class UserGuideTestActivity extends Activity { private String[] datas = new String[]{"收藏", "字体大小", "软件设置", "换肤"}; GridView mGridView; private UserGuideView guideView; - private ImageView bottom, topLeft, top,topRight ,bottomLeft, bottomRight; + private ImageView bottom, topLeft, top, topRight, bottomLeft, bottomRight; View tipTextView; @Override @@ -81,14 +82,22 @@ public void onClick(View v) { guideView.setArrowDownLeft(R.mipmap.guide_arrow_left); guideView.setArrowUpLeftMoveX(-30); guideView.setArrowDownRightMoveX(0); - guideView.setTipViewMoveX(bottomLeft,-60); + guideView.setTipViewMoveX(bottomLeft, -60); // guideView.setTipViewMoveX(bottomRight,140); - guideView.setTipViewMoveX(topRight,-50); + guideView.setTipViewMoveX(topRight, -50); guideView.setArrowDownLeftMoveX(-20); // guideView.setArrowDownCenterMoveX(100); // guideView.setTipViewMoveX(icon,-100); // guideView.setTipViewMoveY(icon,100); guideView.setHighLightView(targets); + + + findViewById(R.id.touch).setOnClickListener(new View.OnClickListener() { + @Override + public void onClick(View v) { + Toast.makeText(UserGuideTestActivity.this, "点击了", Toast.LENGTH_SHORT).show(); + } + }); } private class MyAaapter extends BaseAdapter { @@ -124,6 +133,13 @@ public View getView(int position, View convertView, ViewGroup parent) { //// guideView.setTipView(BitmapFactory.decodeResource(getResources(),R.mipmap.sidebar_photo)); // guideView.setHighLightView(convertView); // } + convertView.setOnClickListener(new View.OnClickListener() { + @Override + public void onClick(View v) { + // 点击了 + + } + }); return convertView; } diff --git a/app/src/main/res/drawable/topic_start.png b/app/src/main/res/drawable/topic_start.png new file mode 100644 index 0000000..bd82dde Binary files /dev/null and b/app/src/main/res/drawable/topic_start.png differ diff --git a/app/src/main/res/layout/activity_animguide.xml b/app/src/main/res/layout/activity_animguide.xml new file mode 100644 index 0000000..95847ae --- /dev/null +++ b/app/src/main/res/layout/activity_animguide.xml @@ -0,0 +1,141 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/app/src/main/res/layout/layout_userguide.xml b/app/src/main/res/layout/layout_userguide.xml index f74684c..9fb03b5 100644 --- a/app/src/main/res/layout/layout_userguide.xml +++ b/app/src/main/res/layout/layout_userguide.xml @@ -6,95 +6,106 @@ android:background="#ffffff" android:orientation="vertical"> - - - - - - + android:layout_height="50dp" + android:background="#00ff00" + android:scaleType="center" + android:src="@mipmap/ic_launcher" /> + + android:layout_height="match_parent" + android:orientation="vertical"> + + - + android:numColumns="2" /> + + + + + + + + + + + - - + - - - - - - - + + - + + \ No newline at end of file AltStyle によって変換されたページ (->オリジナル) / アドレス: モード: デフォルト 音声ブラウザ ルビ付き 配色反転 文字拡大 モバイル
AltStyle によって変換されたページ (->オリジナル) / アドレス: モード: デフォルト 音声ブラウザ ルビ付き 配色反転 文字拡大 モバイル