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
4abddffe
Commit
4abddffe
authored
Apr 25, 2025
by
CZ1004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
【优化】去掉首次进入首页充电动画,没有设置的情况下
parent
7e28f310
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
19 deletions
+13
-19
HomeViewController.swift
...er/Class/Session/Home/Controller/HomeViewController.swift
+8
-12
HomeCollectionViewHeader.swift
...er/Class/Session/Home/View/HomeCollectionViewHeader.swift
+3
-7
HomeView.swift
PhoneManager/Class/Session/Home/View/HomeView.swift
+2
-0
No files found.
PhoneManager/Class/Session/Home/Controller/HomeViewController.swift
View file @
4abddffe
...
...
@@ -212,11 +212,6 @@ class HomeViewController:BaseViewController {
}
})
}
override
func
viewWillAppear
(
_
animated
:
Bool
)
{
super
.
viewWillAppear
(
animated
)
// 总数据 文件数量和文件大小
PhotoAndVideoMananger
.
mananger
.
fetchAllFile
{[
weak
self
]
index
,
FileSize
in
...
...
@@ -234,6 +229,10 @@ class HomeViewController:BaseViewController {
self
.
homeView
?
.
setTitle
()
}
}
override
func
viewWillAppear
(
_
animated
:
Bool
)
{
super
.
viewWillAppear
(
animated
)
// 可能是删除数据,重新获取下
PhotoDataManager
.
manager
.
loadFromFileSystem
(
resultModel
:
{[
weak
self
]
model
in
...
...
@@ -278,16 +277,13 @@ class HomeViewController:BaseViewController {
if
BatteryMonitorManager
.
shared
.
getBatteryIsCharging
()
{
// 从字典里面取 如果有
var
tempModel
:
ChargeDataModel
?
if
UserDefaults
.
standard
.
object
(
forKey
:
"chargePicInfo"
)
==
nil
{
tempModel
=
loadVideoItems
()
.
first
}
else
{
if
UserDefaults
.
standard
.
object
(
forKey
:
"chargePicInfo"
)
!=
nil
{
let
flag
:
String
=
UserDefaults
.
standard
.
object
(
forKey
:
"chargePicInfo"
)
as!
String
tempModel
=
loadVideoItems
()[
Int
(
flag
)
!
]
}
let
vc
:
ChargeInfoViewController
=
ChargeInfoViewController
(
model
:
tempModel
,
type
:
ChargeInfoViewController
.
ChargeInfoType
.
charge
)
self
.
navigationController
?
.
pushViewController
(
vc
,
animated
:
false
)
}
}
else
{
if
HomePayModel
.
share
.
isNoAd
==
false
{
HomePayViewController
.
show
{}
...
...
PhoneManager/Class/Session/Home/View/HomeCollectionViewHeader.swift
View file @
4abddffe
...
...
@@ -40,7 +40,7 @@ class HomeCollectionViewHeader : UICollectionReusableView {
private
var
tipLabel
:
UILabel
=
{
private
lazy
var
tipLabel
:
UILabel
=
{
let
label
=
UILabel
()
label
.
numberOfLines
=
0
// 支持多行
label
.
translatesAutoresizingMaskIntoConstraints
=
false
...
...
@@ -70,11 +70,12 @@ class HomeCollectionViewHeader : UICollectionReusableView {
}
// 文本
self
.
addSubview
(
tipLabel
)
self
.
addSubview
(
self
.
tipLabel
)
self
.
tipLabel
.
snp
.
makeConstraints
{
make
in
make
.
left
.
equalToSuperview
()
make
.
top
.
equalToSuperview
()
.
offset
(
32
)
make
.
height
.
equalTo
(
31
)
make
.
width
.
equalTo
(
300
)
}
self
.
addSubview
(
self
.
subTiplabel
)
...
...
@@ -134,11 +135,6 @@ class HomeCollectionViewHeader : UICollectionReusableView {
// 将 attributedText 赋值给 UILabel
self
.
tipLabel
.
attributedText
=
attributedText
}
}
PhoneManager/Class/Session/Home/View/HomeView.swift
View file @
4abddffe
...
...
@@ -316,4 +316,6 @@ extension HomeView:WaterfallMutiSectionDelegate,UICollectionViewDataSource,UICol
}
return
CGSize
.
zero
}
}
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