Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in / Register
Toggle navigation
S
scanqrwhite2copy1
Project
Project
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
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wanglei
scanqrwhite2copy1
Commits
0cb86fee
Commit
0cb86fee
authored
Feb 19, 2025
by
wanglei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
...
parent
1cc4b60b
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
72 additions
and
12 deletions
+72
-12
SpotifyUIBean.kt
app/src/main/java/com/base/scanqrclear/bean/SpotifyUIBean.kt
+18
-0
SpotifyDialog.kt
...n/java/com/base/scanqrclear/ui/spotifyqr/SpotifyDialog.kt
+47
-1
dialog_facebook.xml
app/src/main/res/layout/dialog_facebook.xml
+1
-2
dialog_paypal.xml
app/src/main/res/layout/dialog_paypal.xml
+1
-2
dialog_spotify.xml
app/src/main/res/layout/dialog_spotify.xml
+3
-3
dialog_whastspp.xml
app/src/main/res/layout/dialog_whastspp.xml
+1
-2
dialog_x.xml
app/src/main/res/layout/dialog_x.xml
+1
-2
No files found.
app/src/main/java/com/base/scanqrclear/bean/SpotifyUIBean.kt
0 → 100644
View file @
0cb86fee
package
com.base.scanqrclear.bean
import
com.base.scanqrclear.bean.FunctionUIBean.Companion.KEY_SPOTIFY
data class
SpotifyUIBean
(
val
singerName
:
String
,
val
song
:
String
)
:
ScanBean
(
KEY_SPOTIFY
)
{
companion
object
{
// spotify:search:wanglei;唱山歌
fun
SpotifyUIBean
.
createSpotifyQrString
():
String
{
return
"spotify:search:$singerName;$song"
}
}
}
\ No newline at end of file
app/src/main/java/com/base/scanqrclear/ui/spotifyqr/SpotifyDialog.kt
View file @
0cb86fee
...
@@ -2,12 +2,19 @@ package com.base.scanqrclear.ui.spotifyqr
...
@@ -2,12 +2,19 @@ package com.base.scanqrclear.ui.spotifyqr
import
android.app.Activity
import
android.app.Activity
import
android.app.AlertDialog
import
android.app.AlertDialog
import
android.content.Intent
import
android.text.Editable
import
android.view.Gravity
import
android.view.Gravity
import
android.view.LayoutInflater
import
android.view.LayoutInflater
import
androidx.constraintlayout.widget.ConstraintLayout
import
androidx.constraintlayout.widget.ConstraintLayout
import
androidx.core.widget.addTextChangedListener
import
com.base.scanqrclear.R
import
com.base.scanqrclear.R
import
com.base.scanqrclear.ads.AdsMgr
import
com.base.scanqrclear.ads.AdsMgr
import
com.base.scanqrclear.ads.AdsShowCallBack
import
com.base.scanqrclear.bean.SpotifyUIBean
import
com.base.scanqrclear.bean.SpotifyUIBean.Companion.createSpotifyQrString
import
com.base.scanqrclear.databinding.DialogSpotifyBinding
import
com.base.scanqrclear.databinding.DialogSpotifyBinding
import
com.base.scanqrclear.qr.QrStyleActivity
object
SpotifyDialog
{
object
SpotifyDialog
{
...
@@ -28,11 +35,50 @@ object SpotifyDialog {
...
@@ -28,11 +35,50 @@ object SpotifyDialog {
dialog
.
window
?.
attributes
=
params
dialog
.
window
?.
attributes
=
params
dialog
.
window
?.
setBackgroundDrawableResource
(
android
.
R
.
color
.
transparent
)
dialog
.
window
?.
setBackgroundDrawableResource
(
android
.
R
.
color
.
transparent
)
AdsMgr
.
showNative
(
binding
.
flAd
,
R
.
layout
.
layout_admob_native_custom
)
AdsMgr
.
showNative
(
binding
.
flAd
,
R
.
layout
.
layout_admob_native_custom
)
binding
.
flClose
.
setOnClickListener
{
binding
.
flClose
.
setOnClickListener
{
dialog
.
dismiss
()
dialog
.
dismiss
()
}
}
binding
.
editSingerName
.
addTextChangedListener
{
s
:
Editable
?
->
binding
.
tvBtn
.
isEnabled
=
!
s
.
isNullOrEmpty
()
&&
!
binding
.
editSong
.
text
.
isNullOrEmpty
()
}
binding
.
editSong
.
addTextChangedListener
{
s
:
Editable
?
->
binding
.
tvBtn
.
isEnabled
=
!
s
.
isNullOrEmpty
()
&&
!
binding
.
editSingerName
.
text
.
isNullOrEmpty
()
}
val
jump
=
{
dialog
.
dismiss
()
val
singerName
=
binding
.
editSingerName
.
text
.
toString
()
val
song
=
binding
.
editSong
.
text
.
toString
()
val
bean
=
SpotifyUIBean
(
singerName
,
song
)
startActivity
(
Intent
(
this
,
QrStyleActivity
::
class
.
java
).
apply
{
putExtra
(
"qrString"
,
bean
.
createSpotifyQrString
()
)
})
}
binding
.
tvBtn
.
setOnClickListener
{
AdsMgr
.
showInsert
(
this
,
false
,
object
:
AdsShowCallBack
()
{
override
fun
close
(
where
:
Int
)
{
jump
.
invoke
()
}
override
fun
failed
(
where
:
Int
)
{
jump
.
invoke
()
}
override
fun
googleFailed
(
where
:
Int
)
{
jump
.
invoke
()
}
})
}
}
}
}
}
\ No newline at end of file
app/src/main/res/layout/dialog_facebook.xml
View file @
0cb86fee
...
@@ -146,9 +146,8 @@
...
@@ -146,9 +146,8 @@
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"18dp"
android:layout_marginTop=
"18dp"
android:layout_marginBottom=
"8dp"
android:background=
"@drawable/bg_ecf6ff_20"
android:background=
"@drawable/bg_ecf6ff_20"
android:minHeight=
"1
33
dp"
android:minHeight=
"1
20
dp"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/tvBtn"
>
app:layout_constraintTop_toBottomOf=
"@id/tvBtn"
>
...
...
app/src/main/res/layout/dialog_paypal.xml
View file @
0cb86fee
...
@@ -146,9 +146,8 @@
...
@@ -146,9 +146,8 @@
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"18dp"
android:layout_marginTop=
"18dp"
android:layout_marginBottom=
"8dp"
android:background=
"@drawable/bg_ecf6ff_20"
android:background=
"@drawable/bg_ecf6ff_20"
android:minHeight=
"1
33
dp"
android:minHeight=
"1
20
dp"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/tvBtn"
>
app:layout_constraintTop_toBottomOf=
"@id/tvBtn"
>
...
...
app/src/main/res/layout/dialog_spotify.xml
View file @
0cb86fee
...
@@ -68,7 +68,7 @@
...
@@ -68,7 +68,7 @@
android:textSize=
"19sp"
/>
android:textSize=
"19sp"
/>
<EditText
<EditText
android:id=
"@+id/editName"
android:id=
"@+id/edit
Singer
Name"
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
android:layout_height=
"52dp"
android:layout_height=
"52dp"
android:layout_marginHorizontal=
"16dp"
android:layout_marginHorizontal=
"16dp"
...
@@ -107,7 +107,7 @@
...
@@ -107,7 +107,7 @@
android:textSize=
"19sp"
/>
android:textSize=
"19sp"
/>
<EditText
<EditText
android:id=
"@+id/edit
Number
"
android:id=
"@+id/edit
Song
"
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
android:layout_height=
"52dp"
android:layout_height=
"52dp"
android:layout_marginHorizontal=
"16dp"
android:layout_marginHorizontal=
"16dp"
...
@@ -146,7 +146,7 @@
...
@@ -146,7 +146,7 @@
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"18dp"
android:layout_marginTop=
"18dp"
android:background=
"@drawable/bg_ecf6ff_20"
android:background=
"@drawable/bg_ecf6ff_20"
android:minHeight=
"1
33
dp"
android:minHeight=
"1
20
dp"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/tvBtn"
>
app:layout_constraintTop_toBottomOf=
"@id/tvBtn"
>
...
...
app/src/main/res/layout/dialog_whastspp.xml
View file @
0cb86fee
...
@@ -120,9 +120,8 @@
...
@@ -120,9 +120,8 @@
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"18dp"
android:layout_marginTop=
"18dp"
android:layout_marginBottom=
"8dp"
android:background=
"@drawable/bg_ecf6ff_20"
android:background=
"@drawable/bg_ecf6ff_20"
android:minHeight=
"1
33
dp"
android:minHeight=
"1
20
dp"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/tvBtn"
>
app:layout_constraintTop_toBottomOf=
"@id/tvBtn"
>
...
...
app/src/main/res/layout/dialog_x.xml
View file @
0cb86fee
...
@@ -146,9 +146,8 @@
...
@@ -146,9 +146,8 @@
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"18dp"
android:layout_marginTop=
"18dp"
android:layout_marginBottom=
"8dp"
android:background=
"@drawable/bg_ecf6ff_20"
android:background=
"@drawable/bg_ecf6ff_20"
android:minHeight=
"1
33
dp"
android:minHeight=
"1
20
dp"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/tvBtn"
>
app:layout_constraintTop_toBottomOf=
"@id/tvBtn"
>
...
...
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