diff --git a/README.md b/README.md index ccd61ed..5dc8a4a 100644 --- a/README.md +++ b/README.md @@ -85,11 +85,11 @@ At present, UETool provides functionality as follows: ```gradle dependencies { - debugImplementation 'me.ele:uetool:1.2.8' - releaseImplementation 'me.ele:uetool-no-op:1.2.8' + debugImplementation 'me.ele:uetool:1.2.9' + releaseImplementation 'me.ele:uetool-no-op:1.2.9' // if you want to show more attrs about Fresco's DraweeView - debugImplementation 'me.ele:uetool-fresco:1.2.8' + debugImplementation 'me.ele:uetool-fresco:1.2.9' } ``` diff --git a/README_zh.md b/README_zh.md index 144ca14..d2039d4 100644 --- a/README_zh.md +++ b/README_zh.md @@ -82,11 +82,11 @@ UETool 是一个各方人员(设计师、程序员、测试)都可以使用 ```gradle dependencies { - debugImplementation 'me.ele:uetool:1.2.8' - releaseImplementation 'me.ele:uetool-no-op:1.2.8' + debugImplementation 'me.ele:uetool:1.2.9' + releaseImplementation 'me.ele:uetool-no-op:1.2.9' // if you want to show more attrs about Fresco's DraweeView - debugImplementation 'me.ele:uetool-fresco:1.2.8' + debugImplementation 'me.ele:uetool-fresco:1.2.9' } ``` diff --git a/build.gradle b/build.gradle index 504fdb3..e64dfb3 100644 --- a/build.gradle +++ b/build.gradle @@ -11,7 +11,7 @@ buildscript { 'supportLibrary': '27.1.1', 'fresco' : '1.0.1', - 'release' : '1.2.8',] + 'release' : '1.2.9',] repositories { jcenter() google() diff --git a/uetool/src/main/java/me/ele/uetool/BoardTextView.java b/uetool/src/main/java/me/ele/uetool/BoardTextView.java index ac2aec8..288242c 100644 --- a/uetool/src/main/java/me/ele/uetool/BoardTextView.java +++ b/uetool/src/main/java/me/ele/uetool/BoardTextView.java @@ -2,6 +2,8 @@ import android.content.Context; import android.support.annotation.Nullable; +import android.support.v4.content.ContextCompat; +import android.support.v4.graphics.drawable.DrawableCompat; import android.support.v7.widget.AppCompatTextView; import android.util.AttributeSet; @@ -31,6 +33,8 @@ private void initView() { setTextColor(0xffffffff); setTextSize(9); setText(defaultInfo); + setCompoundDrawablesRelativeWithIntrinsicBounds(null, null, ContextCompat.getDrawable(getContext(), R.drawable.uet_close), null); + setCompoundDrawablePadding(DimenUtil.dip2px(2)); } public void updateInfo(String info) { diff --git a/uetool/src/main/java/me/ele/uetool/TransparentActivity.java b/uetool/src/main/java/me/ele/uetool/TransparentActivity.java index a0b2c10..01dc38d 100644 --- a/uetool/src/main/java/me/ele/uetool/TransparentActivity.java +++ b/uetool/src/main/java/me/ele/uetool/TransparentActivity.java @@ -38,6 +38,13 @@ protected void onCreate(Bundle savedInstanceState) { vContainer = findViewById(R.id.container); final BoardTextView board = new BoardTextView(this); + board.setOnClickListener(new View.OnClickListener() { + @Override + public void onClick(View v) { + UETool.getInstance().getTargetActivity().finish(); + finish(); + } + }); type = getIntent().getIntExtra(EXTRA_TYPE, TYPE_UNKNOWN); diff --git a/uetool/src/main/res/drawable-xxhdpi/uet_close.png b/uetool/src/main/res/drawable-xxhdpi/uet_close.png new file mode 100644 index 0000000..69a8dfe Binary files /dev/null and b/uetool/src/main/res/drawable-xxhdpi/uet_close.png differ