Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
YDL-Component-Medical
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
杨凯
YDL-Component-Medical
Commits
b059f7bb
Commit
b059f7bb
authored
Jul 22, 2022
by
霍志良
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat:价格筛选刻度重写
parent
ae1127f3
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
2 deletions
+6
-2
RangeSeekBar.java
m-consultant/src/main/java/com/yidianling/consultant/ui/view/rangeseekbar/RangeSeekBar.java
+4
-0
consultant_ui_price_popup_window.xml
m-consultant/src/main/res/layout/consultant_ui_price_popup_window.xml
+2
-2
No files found.
m-consultant/src/main/java/com/yidianling/consultant/ui/view/rangeseekbar/RangeSeekBar.java
View file @
b059f7bb
...
...
@@ -436,11 +436,15 @@ public class RangeSeekBar extends View {
}
//draw steps
//绘制刻度线
protected
void
onDrawSteps
(
Canvas
canvas
,
Paint
paint
)
{
if
(!
verifyStepsMode
())
return
;
int
stepMarks
=
getProgressWidth
()
/
(
steps
);
float
extHeight
=
(
stepsHeight
-
getProgressHeight
())
/
2
f
;
//绘制刻度。其他场景要用,需要自己修改这部分代码
for
(
int
k
=
1
;
k
<=
steps
-
1
;
k
++)
{
//如果是奇数Setp,则不绘制刻度
if
(
k
%
2
==
1
)
continue
;
float
x
=
getProgressLeft
()
+
k
*
stepMarks
-
stepsWidth
/
2
f
;
stepDivRect
.
set
(
x
,
getProgressTop
()
+
stepsHeight
,
x
+
stepsWidth
,
getProgressBottom
()
+
3
*
stepsHeight
);
if
(
stepsBitmaps
.
isEmpty
()
||
stepsBitmaps
.
size
()
<=
k
)
{
...
...
m-consultant/src/main/res/layout/consultant_ui_price_popup_window.xml
View file @
b059f7bb
...
...
@@ -38,11 +38,11 @@
app:rsb_gravity=
"bottom"
app:rsb_mode=
"range"
app:rsb_progress_color=
"@color/platform_main_theme"
app:rsb_step_auto_bonding=
"
fals
e"
app:rsb_step_auto_bonding=
"
tru
e"
app:rsb_step_color=
"@color/platform_gray7"
app:rsb_step_height=
"5dp"
app:rsb_step_width=
"1dp"
app:rsb_steps=
"
6
"
app:rsb_steps=
"
12
"
app:rsb_thumb_drawable=
"@drawable/thumb_yellow_stroke"
app:rsb_thumb_height=
"15dp"
app:rsb_thumb_width=
"15dp"
...
...
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