Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in / Register
Toggle navigation
P
PhoneManager
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
Yang
PhoneManager
Commits
28c5d648
Commit
28c5d648
authored
May 22, 2025
by
shenyong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix bug
parent
8dfd80ad
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
18 deletions
+18
-18
AppDelegateEx.swift
PhoneManager/AppDelegateEx.swift
+3
-3
PayDistanceViewController.swift
...s/Page/Pay/ViewController/PayDistanceViewController.swift
+15
-15
No files found.
PhoneManager/AppDelegateEx.swift
View file @
28c5d648
...
@@ -14,9 +14,9 @@ extension AppDelegate{
...
@@ -14,9 +14,9 @@ extension AppDelegate{
func
setupDynamicShortcuts
()
{
func
setupDynamicShortcuts
()
{
let
shortcutItem
=
UIApplicationShortcutItem
(
let
shortcutItem
=
UIApplicationShortcutItem
(
type
:
"com.app.phonemanager.iap.distance"
,
type
:
"com.app.phonemanager.iap.distance"
,
localizedTitle
:
"Unlock Special Offers"
,
localizedTitle
:
"
🎁
Unlock Special Offers"
,
localizedSubtitle
:
"A Special Offer Just for You!
🎁
"
,
localizedSubtitle
:
"A Special Offer Just for You!"
,
icon
:
UIApplicationShortcutIcon
(),
//UIApplicationShortcutIcon(templateImageName: "icon_gift_sa"), //UIApplicationShortcutIcon(systemImageName: "star.fill"),
icon
:
UIApplicationShortcutIcon
(
systemImageName
:
"chevron.right"
),
//UIApplicationShortcutIcon(templateImageName: "icon_gift_sa"), //UIApplicationShortcutIcon(systemImageName: "star.fill"),
userInfo
:
nil
userInfo
:
nil
)
)
UIApplication
.
shared
.
shortcutItems
=
[
shortcutItem
]
UIApplication
.
shared
.
shortcutItems
=
[
shortcutItem
]
...
...
PhoneManager/Class/Page/Pay/ViewController/PayDistanceViewController.swift
View file @
28c5d648
...
@@ -62,26 +62,26 @@ class PayDistanceViewController: UIViewController {
...
@@ -62,26 +62,26 @@ class PayDistanceViewController: UIViewController {
distanceL
=
UILabel
()
distanceL
=
UILabel
()
distanceL
.
text
=
"50% Discount"
distanceL
.
text
=
"50% Discount"
distanceL
.
textAlignment
=
.
center
distanceL
.
textAlignment
=
.
center
distanceL
.
font
=
UIFont
.
systemFont
(
ofSize
:
40
,
weight
:
.
semibold
)
distanceL
.
font
=
UIFont
.
systemFont
(
ofSize
:
40
.
RW
()
,
weight
:
.
semibold
)
distanceL
.
textColor
=
UIColor
.
colorWithHex
(
hexStr
:
"#111111"
)
distanceL
.
textColor
=
UIColor
.
colorWithHex
(
hexStr
:
"#111111"
)
scrollView
.
addSubview
(
distanceL
)
scrollView
.
addSubview
(
distanceL
)
annual
=
UILabel
()
annual
=
UILabel
()
annual
.
text
=
"Annual visit"
annual
.
text
=
"Annual visit"
annual
.
textAlignment
=
.
center
annual
.
textAlignment
=
.
center
annual
.
font
=
UIFont
.
systemFont
(
ofSize
:
18
,
weight
:
.
semibold
)
annual
.
font
=
UIFont
.
systemFont
(
ofSize
:
18
.
RW
()
,
weight
:
.
semibold
)
annual
.
textColor
=
UIColor
.
colorWithHex
(
hexStr
:
"#111111"
)
annual
.
textColor
=
UIColor
.
colorWithHex
(
hexStr
:
"#111111"
)
scrollView
.
addSubview
(
annual
)
scrollView
.
addSubview
(
annual
)
yearDistacePrice
=
UILabel
()
yearDistacePrice
=
UILabel
()
yearDistacePrice
.
font
=
UIFont
.
systemFont
(
ofSize
:
14
,
weight
:
.
semibold
)
yearDistacePrice
.
font
=
UIFont
.
systemFont
(
ofSize
:
14
.
RW
()
,
weight
:
.
semibold
)
yearDistacePrice
.
textColor
=
UIColor
.
colorWithHex
(
hexStr
:
"#111111"
)
yearDistacePrice
.
textColor
=
UIColor
.
colorWithHex
(
hexStr
:
"#111111"
)
yearDistacePrice
.
text
=
""
//"$39.99 $19.99 / Year"
yearDistacePrice
.
text
=
""
//"$39.99 $19.99 / Year"
yearDistacePrice
.
textAlignment
=
.
center
yearDistacePrice
.
textAlignment
=
.
center
scrollView
.
addSubview
(
yearDistacePrice
)
scrollView
.
addSubview
(
yearDistacePrice
)
cancelLabel
=
UILabel
()
cancelLabel
=
UILabel
()
cancelLabel
.
font
=
UIFont
.
systemFont
(
ofSize
:
12
,
weight
:
.
semibold
)
cancelLabel
.
font
=
UIFont
.
systemFont
(
ofSize
:
12
.
RW
()
,
weight
:
.
semibold
)
cancelLabel
.
textColor
=
UIColor
.
colorWithHex
(
hexStr
:
"#0082FF"
)
cancelLabel
.
textColor
=
UIColor
.
colorWithHex
(
hexStr
:
"#0082FF"
)
cancelLabel
.
text
=
"Cancel at any time"
cancelLabel
.
text
=
"Cancel at any time"
cancelLabel
.
textAlignment
=
.
center
cancelLabel
.
textAlignment
=
.
center
...
@@ -90,8 +90,8 @@ class PayDistanceViewController: UIViewController {
...
@@ -90,8 +90,8 @@ class PayDistanceViewController: UIViewController {
payBtn
=
UIButton
()
payBtn
=
UIButton
()
payBtn
.
setTitle
(
"Get discounts"
,
for
:
.
normal
)
payBtn
.
setTitle
(
"Get discounts"
,
for
:
.
normal
)
payBtn
.
setTitleColor
(
.
white
,
for
:
.
normal
)
payBtn
.
setTitleColor
(
.
white
,
for
:
.
normal
)
payBtn
.
titleLabel
?
.
font
=
UIFont
.
systemFont
(
ofSize
:
18
,
weight
:
.
semibold
)
payBtn
.
titleLabel
?
.
font
=
UIFont
.
systemFont
(
ofSize
:
18
.
RW
()
,
weight
:
.
semibold
)
payBtn
.
layer
.
cornerRadius
=
30
payBtn
.
layer
.
cornerRadius
=
30
.
RW
()
payBtn
.
isEnabled
=
false
payBtn
.
isEnabled
=
false
payBtn
.
addTarget
(
self
,
action
:
#selector(
iapPayAction
)
,
for
:
.
touchUpInside
)
payBtn
.
addTarget
(
self
,
action
:
#selector(
iapPayAction
)
,
for
:
.
touchUpInside
)
payBtn
.
backgroundColor
=
UIColor
.
colorWithHex
(
hexStr
:
"#0082FF"
)
payBtn
.
backgroundColor
=
UIColor
.
colorWithHex
(
hexStr
:
"#0082FF"
)
...
@@ -118,7 +118,7 @@ class PayDistanceViewController: UIViewController {
...
@@ -118,7 +118,7 @@ class PayDistanceViewController: UIViewController {
let
appleLabel
=
UILabel
()
let
appleLabel
=
UILabel
()
appleLabel
.
font
=
UIFont
.
systemFont
(
ofSize
:
10
,
weight
:
.
medium
)
appleLabel
.
font
=
UIFont
.
systemFont
(
ofSize
:
10
.
RW
()
,
weight
:
.
medium
)
appleLabel
.
textColor
=
UIColor
.
colorWithHex
(
hexStr
:
"#111111"
)
appleLabel
.
textColor
=
UIColor
.
colorWithHex
(
hexStr
:
"#111111"
)
appleLabel
.
text
=
" Apple Security Guarantee"
appleLabel
.
text
=
" Apple Security Guarantee"
scrollView
.
addSubview
(
appleLabel
)
scrollView
.
addSubview
(
appleLabel
)
...
@@ -157,8 +157,8 @@ class PayDistanceViewController: UIViewController {
...
@@ -157,8 +157,8 @@ class PayDistanceViewController: UIViewController {
payBtn
.
snp
.
makeConstraints
{
make
in
payBtn
.
snp
.
makeConstraints
{
make
in
make
.
centerX
.
equalToSuperview
()
make
.
centerX
.
equalToSuperview
()
make
.
width
.
equalTo
(
343
)
make
.
width
.
equalTo
(
343
.
RW
()
)
make
.
height
.
equalTo
(
57
)
make
.
height
.
equalTo
(
57
.
RW
()
)
make
.
bottom
.
equalTo
(
appleLabel
.
snp
.
top
)
.
offset
(
-
24
)
make
.
bottom
.
equalTo
(
appleLabel
.
snp
.
top
)
.
offset
(
-
24
)
}
}
...
@@ -243,10 +243,10 @@ class PayDistanceViewController: UIViewController {
...
@@ -243,10 +243,10 @@ class PayDistanceViewController: UIViewController {
width
:
111
,
width
:
111
,
height
:
37
)
height
:
37
)
self
.
distanceL
.
frame
=
CGRect
(
x
:
(
ScreenW
-
270
)
/
2
,
self
.
distanceL
.
frame
=
CGRect
(
x
:
(
ScreenW
-
CGFloat
(
300
.
RW
())
)
/
2
,
y
:
kSafeAreaInsets
.
top
+
CGFloat
(
129
.
RH
())
+
dropH
+
CGFloat
(
40
.
RH
()),
y
:
kSafeAreaInsets
.
top
+
CGFloat
(
129
.
RH
())
+
dropH
+
CGFloat
(
40
.
RH
()),
width
:
270
,
width
:
CGFloat
(
300
.
RW
())
,
height
:
40
)
height
:
CGFloat
(
40
.
RW
())
)
self
.
annual
.
frame
=
CGRect
(
x
:
(
ScreenW
-
150
)
/
2
,
self
.
annual
.
frame
=
CGRect
(
x
:
(
ScreenW
-
150
)
/
2
,
y
:
self
.
distanceL
.
frame
.
maxY
+
CGFloat
(
115
.
RH
()),
y
:
self
.
distanceL
.
frame
.
maxY
+
CGFloat
(
115
.
RH
()),
...
@@ -258,9 +258,9 @@ class PayDistanceViewController: UIViewController {
...
@@ -258,9 +258,9 @@ class PayDistanceViewController: UIViewController {
width
:
200
,
width
:
200
,
height
:
22
)
height
:
22
)
self
.
cancelLabel
.
frame
=
CGRect
(
x
:
(
ScreenW
-
15
0
)
/
2
,
self
.
cancelLabel
.
frame
=
CGRect
(
x
:
(
ScreenW
-
20
0
)
/
2
,
y
:
self
.
yearDistacePrice
.
frame
.
maxY
,
y
:
self
.
yearDistacePrice
.
frame
.
maxY
,
width
:
15
0
,
width
:
20
0
,
height
:
22
)
height
:
22
)
payBtn
.
alpha
=
0
payBtn
.
alpha
=
0
...
@@ -270,7 +270,7 @@ class PayDistanceViewController: UIViewController {
...
@@ -270,7 +270,7 @@ class PayDistanceViewController: UIViewController {
annual
.
alpha
=
0
annual
.
alpha
=
0
yearDistacePrice
.
alpha
=
0
yearDistacePrice
.
alpha
=
0
cancelLabel
.
alpha
=
0
cancelLabel
.
alpha
=
0
UIView
.
animate
(
withDuration
:
1
.1
)
{
UIView
.
animate
(
withDuration
:
1
)
{
self
.
payBtn
.
alpha
=
1
self
.
payBtn
.
alpha
=
1
self
.
dropImage
.
alpha
=
1
self
.
dropImage
.
alpha
=
1
self
.
offerImage
.
alpha
=
1
self
.
offerImage
.
alpha
=
1
...
...
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