Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
beyond-clouds-android
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
云深项目组
beyond-clouds-android
Commits
739626f5
Commit
739626f5
authored
Mar 19, 2020
by
段启岩
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修复PopupWindow在android5以下关闭不了的问题
parent
42d3d4af
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
16 additions
and
7 deletions
+16
-7
app/src/main/java/cn/yunliyunwai/beyondclouds/ui/popup/PopupAddMenu.java
+2
-0
app/src/main/res/drawable/background_fix_popup_window_under_android_5.xml
+7
-0
app/src/main/res/layout/beyond_text_icon_button.xml
+7
-7
No files found.
app/src/main/java/cn/yunliyunwai/beyondclouds/ui/popup/PopupAddMenu.java
View file @
739626f5
...
...
@@ -4,6 +4,7 @@ import android.content.Context;
import
android.view.LayoutInflater
;
import
android.widget.PopupWindow
;
import
cn.yunliyunwai.beyondclouds.R
;
import
cn.yunliyunwai.beyondclouds.databinding.PopupMenuAddBinding
;
import
cn.yunliyunwai.beyondclouds.util.SizeUtils
;
...
...
@@ -14,6 +15,7 @@ public class PopupAddMenu extends PopupWindow {
super
(
SizeUtils
.
toPx
(
130
),
SizeUtils
.
toPx
(
235
));
setOutsideTouchable
(
true
);
setFocusable
(
true
);
setBackgroundDrawable
(
context
.
getResources
().
getDrawable
(
R
.
drawable
.
background_fix_popup_window_under_android_5
));
binding
=
PopupMenuAddBinding
.
inflate
(
LayoutInflater
.
from
(
context
));
setContentView
(
binding
.
getRoot
());
}
...
...
app/src/main/res/drawable/background_fix_popup_window_under_android_5.xml
0 → 100644
View file @
739626f5
<?xml version="1.0" encoding="utf-8"?>
<shape
xmlns:android=
"http://schemas.android.com/apk/res/android"
android:shape=
"rectangle"
>
<solid
android:color=
"#00000000"
/>
</shape>
\ No newline at end of file
app/src/main/res/layout/beyond_text_icon_button.xml
View file @
739626f5
...
...
@@ -6,16 +6,16 @@
<cn.yunliyunwai.beyondclouds.view.BeyondTextIcon
android:id=
"@+id/txt_icon"
a
pp:layout_constraintTop_toTopOf=
"par
ent"
a
pp:layout_constraintBottom_toBottomOf=
"par
ent"
a
pp:layout_constraintStart_toStartOf=
"parent
"
a
ndroid:layout_width=
"wrap_cont
ent"
a
ndroid:layout_height=
"wrap_cont
ent"
a
ndroid:background=
"@null
"
android:text=
"@string/icon_scan"
android:textColor=
"#ffffff"
android:textSize=
"18dp"
android:textStyle=
"bold"
android:textColor=
"#ffffff"
android:background=
"@null"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
/>
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
/>
<TextView
android:id=
"@+id/txt_title"
android:text=
"扫一扫"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment