Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
galaxy-iOS
Project
Project
Details
Activity
Releases
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
mobile-group
galaxy-iOS
Commits
fd2012c6
Commit
fd2012c6
authored
Feb 14, 2025
by
Steven杜宇
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
// 我的
parent
28001214
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
0 deletions
+18
-0
YHMyFunctionGroupItemCell.swift
...lasses/Modules/Mine(我的)/V/YHMyFunctionGroupItemCell.swift
+18
-0
No files found.
galaxy/galaxy/Classes/Modules/Mine(我的)/V/YHMyFunctionGroupItemCell.swift
View file @
fd2012c6
...
@@ -14,6 +14,7 @@ class YHMyFunctionGroupItemCell: UICollectionViewCell {
...
@@ -14,6 +14,7 @@ class YHMyFunctionGroupItemCell: UICollectionViewCell {
func
updateItem
(
_
item
:
PersonalModuleItem
)
{
func
updateItem
(
_
item
:
PersonalModuleItem
)
{
titleLabel
.
text
=
item
.
title
titleLabel
.
text
=
item
.
title
redPointView
.
isHidden
=
!
item
.
isShowRedPoint
if
let
icon
=
item
.
icon
,
!
icon
.
isEmpty
{
if
let
icon
=
item
.
icon
,
!
icon
.
isEmpty
{
iconImgView
.
image
=
UIImage
(
named
:
icon
)
iconImgView
.
image
=
UIImage
(
named
:
icon
)
}
else
{
}
else
{
...
@@ -34,6 +35,15 @@ class YHMyFunctionGroupItemCell: UICollectionViewCell {
...
@@ -34,6 +35,15 @@ class YHMyFunctionGroupItemCell: UICollectionViewCell {
return
v
return
v
}()
}()
private
lazy
var
redPointView
:
UIView
=
{
let
view
=
UIView
()
view
.
layer
.
cornerRadius
=
2.5
view
.
clipsToBounds
=
true
view
.
backgroundColor
=
.
failColor
view
.
isHidden
=
true
return
view
}()
required
init
?(
coder
:
NSCoder
)
{
required
init
?(
coder
:
NSCoder
)
{
super
.
init
(
coder
:
coder
)
super
.
init
(
coder
:
coder
)
}
}
...
@@ -46,6 +56,8 @@ class YHMyFunctionGroupItemCell: UICollectionViewCell {
...
@@ -46,6 +56,8 @@ class YHMyFunctionGroupItemCell: UICollectionViewCell {
func
setupUI
()
{
func
setupUI
()
{
self
.
contentView
.
addSubview
(
titleLabel
)
self
.
contentView
.
addSubview
(
titleLabel
)
self
.
contentView
.
addSubview
(
iconImgView
)
self
.
contentView
.
addSubview
(
iconImgView
)
self
.
contentView
.
addSubview
(
redPointView
)
iconImgView
.
snp
.
makeConstraints
{
make
in
iconImgView
.
snp
.
makeConstraints
{
make
in
make
.
top
.
equalTo
(
20
)
make
.
top
.
equalTo
(
20
)
...
@@ -53,6 +65,12 @@ class YHMyFunctionGroupItemCell: UICollectionViewCell {
...
@@ -53,6 +65,12 @@ class YHMyFunctionGroupItemCell: UICollectionViewCell {
make
.
centerX
.
equalToSuperview
()
make
.
centerX
.
equalToSuperview
()
}
}
redPointView
.
snp
.
makeConstraints
{
make
in
make
.
width
.
height
.
equalTo
(
5
)
make
.
top
.
equalTo
(
iconImgView
)
make
.
left
.
equalTo
(
iconImgView
.
snp
.
right
)
.
offset
(
0
)
}
titleLabel
.
snp
.
makeConstraints
{
make
in
titleLabel
.
snp
.
makeConstraints
{
make
in
make
.
top
.
equalTo
(
iconImgView
.
snp
.
bottom
)
.
offset
(
8
)
make
.
top
.
equalTo
(
iconImgView
.
snp
.
bottom
)
.
offset
(
8
)
make
.
height
.
equalTo
(
18
)
make
.
height
.
equalTo
(
18
)
...
...
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