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
e3a47371
Commit
e3a47371
authored
Dec 04, 2019
by
徐健
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
导医更新
parent
ddff9e01
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
164 additions
and
16 deletions
+164
-16
config.gradle
config.gradle
+2
-2
AudioHomeActivity.kt
m-audioim/src/main/java/com/ydl/audioim/AudioHomeActivity.kt
+10
-5
ConsultAssistantDialog.kt
m-consultant/src/main/java/com/yidianling/consultant/dialog/ConsultAssistantDialog.kt
+56
-3
ConsultAssistantDialogUtils.kt
m-consultant/src/main/java/com/yidianling/consultant/modular/singlton/ConsultAssistantDialogUtils.kt
+0
-0
consultant_assistant_dialog_close_icon.png
m-consultant/src/main/res/drawable-xhdpi/consultant_assistant_dialog_close_icon.png
+0
-0
consultant_assistant_dialog_go_icon.png
m-consultant/src/main/res/drawable-xhdpi/consultant_assistant_dialog_go_icon.png
+0
-0
consultant_assistant_dialog_img.png
m-consultant/src/main/res/drawable-xhdpi/consultant_assistant_dialog_img.png
+0
-0
consultant_assistant_dialog_text_bg.xml
m-consultant/src/main/res/drawable/consultant_assistant_dialog_text_bg.xml
+13
-0
consultant_expert_consult_assistant_popup_window.xml
m-consultant/src/main/res/layout/consultant_expert_consult_assistant_popup_window.xml
+83
-6
No files found.
config.gradle
View file @
e3a47371
...
...
@@ -44,7 +44,7 @@ ext {
//第三步 若干
"m-confide"
:
"0.0.31.10"
,
"m-consultant"
:
"0.0.44"
,
"m-consultant"
:
"0.0.44
.13
"
,
"m-fm"
:
"0.0.21"
,
"m-user"
:
"0.0.37"
,
...
...
@@ -71,7 +71,7 @@ ext {
"ydl-webview"
:
"0.0.28"
,
"ydl-media"
:
"0.0.14"
,
"ydl-pay"
:
"0.0.11"
,
"m-audioim"
:
"0.0.31.1
1
"
,
"m-audioim"
:
"0.0.31.1
2
"
,
//以下 几乎不会动
"router"
:
"0.0.1"
,
...
...
m-audioim/src/main/java/com/ydl/audioim/AudioHomeActivity.kt
View file @
e3a47371
...
...
@@ -162,6 +162,8 @@ class AudioHomeActivity : BaseMvpActivity<IAudioHomeActivityContract.View, IAudi
//频道管理器
private
var
channelManager
:
ChannelManager
?
=
null
private
var
isLeavelChannel
:
Boolean
=
false
/**
* 声网事件回调 (SDK 通过指定的事件通知应用程序 SDK 的运行事件,如: 加入或离开频道,新用户加入频道等)
...
...
@@ -932,11 +934,14 @@ class AudioHomeActivity : BaseMvpActivity<IAudioHomeActivityContract.View, IAudi
* 声网离开频道
*/
private
fun
leaveChannel
()
{
//刷新h5页面
EventBus
.
getDefault
().
post
(
RefreshWebEvent
(
false
))
stopPlaying
()
//播放结束音频
playFinishMusic
()
if
(!
isLeavelChannel
)
{
isLeavelChannel
=
true
//刷新h5页面
EventBus
.
getDefault
().
post
(
RefreshWebEvent
(
false
))
stopPlaying
()
//播放结束音频
playFinishMusic
()
}
}
override
fun
onResume
()
{
...
...
m-consultant/src/main/java/com/yidianling/consultant/dialog/ConsultAssistantDialog.kt
View file @
e3a47371
package
com.yidianling.consultant.dialog
import
android.animation.Animator
import
android.animation.ObjectAnimator
import
android.app.Dialog
import
android.content.Context
import
android.os.Bundle
import
android.view.Gravity
import
android.view.View
import
android.view.ViewTreeObserver
import
android.view.WindowManager
import
com.ydl.ydlcommon.utils.SharedPreferencesEditor
import
com.yidianling.consultant.R
import
com.yidianling.consultant.modular.singlton.ConsultAssistantDialogUtils
import
kotlinx.android.synthetic.main.consultant_expert_consult_assistant_popup_window.*
/**
...
...
@@ -14,7 +20,12 @@ import kotlinx.android.synthetic.main.consultant_expert_consult_assistant_popup_
* Created by xj on 2019/10/30.
*/
class
ConsultAssistantDialog
(
context
:
Context
,
val
consultAssistantClickListener
:
OnConsultAssistantClickListener
?)
:
Dialog
(
context
,
R
.
style
.
consultant_expert_dialog_default_style
)
{
class
ConsultAssistantDialog
(
context
:
Context
,
val
consultAssistantClickListener
:
OnConsultAssistantClickListener
?
)
:
Dialog
(
context
,
R
.
style
.
consultant_expert_dialog_default_style
)
{
private
var
animate
:
ObjectAnimator
?
=
null
override
fun
onCreate
(
savedInstanceState
:
Bundle
?)
{
super
.
onCreate
(
savedInstanceState
)
...
...
@@ -31,14 +42,55 @@ class ConsultAssistantDialog(context: Context, val consultAssistantClickListener
window
.
setWindowAnimations
(
R
.
style
.
consultant_expert_consult_assistant_dialog_animate
)
consult_assistant
.
setOnClickListener
{
if
(!
ConsultAssistantDialogUtils
.
INSTANCE
.
canShowDesc
())
{
consultant_assistant_dialog_desc_ll
.
visibility
=
View
.
GONE
}
consultant_assistant_dialog_close
.
setOnClickListener
{
//一个dialog关闭左侧desc,所有导医左侧desc都关闭
SharedPreferencesEditor
.
putString
(
ConsultAssistantDialogUtils
.
INSTANCE
.
ASSISTANT_DIALOG_SP_TAG
,
System
.
currentTimeMillis
().
toString
()
)
animate
=
ObjectAnimator
.
ofFloat
(
consultant_assistant_dialog_desc_ll
,
"translationX"
,
0.0f
,
consultant_assistant_dialog_desc_ll
.
measuredWidth
.
toFloat
()
)
animate
?.
setDuration
(
700
)
?.
start
()
animate
?.
addListener
(
object
:
Animator
.
AnimatorListener
{
override
fun
onAnimationRepeat
(
animation
:
Animator
?)
{
}
override
fun
onAnimationEnd
(
animation
:
Animator
?)
{
ConsultAssistantDialogUtils
.
INSTANCE
.
setDescHide
()
}
override
fun
onAnimationCancel
(
animation
:
Animator
?)
{
}
override
fun
onAnimationStart
(
animation
:
Animator
?)
{
}
})
}
consultant_assistant
.
setOnClickListener
{
consultAssistantClickListener
?.
onClickAction
()
}
setCanceledOnTouchOutside
(
false
)
}
public
fun
setDescHide
()
{
if
(
null
!=
consultant_assistant_dialog_desc_ll
)
{
consultant_assistant_dialog_desc_ll
.
visibility
=
View
.
GONE
consultant_assistant_dialog_desc_outside_ll
.
visibility
=
View
.
GONE
}
}
interface
OnConsultAssistantClickListener
{
fun
onClickAction
()
//隐私设置
fun
onClickAction
()
}
}
\ No newline at end of file
m-consultant/src/main/java/com/yidianling/consultant/modular/singlton/ConsultAssistantDialogUtils.kt
View file @
e3a47371
This diff is collapsed.
Click to expand it.
m-consultant/src/main/res/drawable-xhdpi/consultant_assistant_dialog_close_icon.png
0 → 100644
View file @
e3a47371
471 Bytes
m-consultant/src/main/res/drawable-xhdpi/consultant_assistant_dialog_go_icon.png
0 → 100644
View file @
e3a47371
420 Bytes
m-consultant/src/main/res/drawable-xhdpi/consultant_assistant_dialog_img.png
0 → 100644
View file @
e3a47371
41.5 KB
m-consultant/src/main/res/drawable/consultant_assistant_dialog_text_bg.xml
0 → 100644
View file @
e3a47371
<?xml version="1.0" encoding="utf-8"?>
<shape
xmlns:android=
"http://schemas.android.com/apk/res/android"
android:shape=
"rectangle"
>
<corners
android:topLeftRadius=
"22dp"
android:bottomLeftRadius=
"22dp"
/>
<gradient
android:angle=
"0"
android:startColor=
"#DDFF7A5C"
android:endColor=
"#DDFF406C"
/>
</shape>
\ No newline at end of file
m-consultant/src/main/res/layout/consultant_expert_consult_assistant_popup_window.xml
View file @
e3a47371
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
xmlns:android=
"http://schemas.android.com/apk/res/android"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:
paddingBottom=
"60dp
"
android:layout_width=
"wrap_content"
android:
layout_height=
"wrap_content
"
android:paddingRight=
"11dp"
>
<LinearLayout
android:id=
"@+id/consultant_assistant_dialog_desc_outside_ll"
android:layout_width=
"wrap_content"
android:layout_height=
"84dp"
android:layout_alignParentRight=
"true"
android:layout_centerVertical=
"true"
android:layout_marginRight=
"25dp"
android:clipChildren=
"true"
android:gravity=
"center"
android:orientation=
"horizontal"
android:paddingRight=
"25dp"
android:paddingBottom=
"40dp"
>
<LinearLayout
android:id=
"@+id/consultant_assistant_dialog_desc_ll"
android:layout_width=
"wrap_content"
android:layout_height=
"match_parent"
android:background=
"@drawable/consultant_assistant_dialog_text_bg"
android:gravity=
"center"
>
<ImageView
android:id=
"@+id/consultant_assistant_dialog_close"
android:layout_width=
"35dp"
android:layout_height=
"30dp"
android:paddingLeft=
"15dp"
android:paddingTop=
"10dp"
android:paddingRight=
"10dp"
android:paddingBottom=
"10dp"
android:src=
"@drawable/consultant_assistant_dialog_close_icon"
/>
<View
android:layout_width=
"0.5dp"
android:layout_height=
"26dp"
android:layout_marginRight=
"8dp"
android:background=
"#ffffff"
/>
<LinearLayout
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginRight=
"15dp"
android:orientation=
"vertical"
>
<TextView
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:text=
"不知道如何选择?"
android:textColor=
"#ffffff"
android:textSize=
"12dp"
/>
<LinearLayout
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:gravity=
"center"
android:orientation=
"horizontal"
>
<TextView
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:text=
"为你精准匹配咨询师 "
android:textColor=
"#ffffff"
android:textSize=
"12dp"
/>
<ImageView
android:layout_width=
"10dp"
android:layout_height=
"10dp"
android:src=
"@drawable/consultant_assistant_dialog_go_icon"
/>
</LinearLayout>
</LinearLayout>
</LinearLayout>
</LinearLayout>
<ImageView
android:id=
"@+id/consult_assistant"
android:layout_width=
"66dp"
android:layout_height=
"68dp"
android:id=
"@+id/consultant_assistant"
android:layout_width=
"61dp"
android:layout_height=
"101dp"
android:layout_alignParentRight=
"true"
android:layout_centerVertical=
"true"
android:scaleType=
"centerCrop"
android:src=
"@drawable/consultant_expert_consult_assistant_img"
/>
android:src=
"@drawable/consultant_assistant_dialog_img"
android:paddingBottom=
"40dp"
/>
</RelativeLayout>
\ No newline at end of file
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