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
5aea376c
Commit
5aea376c
authored
Apr 15, 2024
by
pete谢兆麟
Browse files
Options
Browse Files
Download
Plain Diff
Merge commit '
5e584b57
' into xiezhaolin
parents
25055667
5e584b57
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
38 additions
and
6 deletions
+38
-6
project.pbxproj
galaxy/galaxy.xcodeproj/project.pbxproj
+3
-3
AppDelegate.swift
galaxy/galaxy/AppDelegate.swift
+4
-1
YHHomePageViewController.swift
...Classes/Modules/Home(首页)/C/YHHomePageViewController.swift
+27
-0
YHStartPageViewController.swift
...lasses/Modules/Home(首页)/C/YHStartPageViewController.swift
+4
-2
No files found.
galaxy/galaxy.xcodeproj/project.pbxproj
View file @
5aea376c
...
...
@@ -2932,7 +2932,7 @@
CODE_SIGN_IDENTITY
=
"Apple Development"
;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]"
=
"iPhone Developer"
;
CODE_SIGN_STYLE
=
Manual
;
CURRENT_PROJECT_VERSION
=
0
;
CURRENT_PROJECT_VERSION
=
2
;
DEVELOPMENT_TEAM
=
""
;
"DEVELOPMENT_TEAM[sdk=iphoneos*]"
=
RXHYW88XR7
;
ENABLE_USER_SCRIPT_SANDBOXING
=
NO
;
...
...
@@ -3133,7 +3133,7 @@
CODE_SIGN_IDENTITY
=
"Apple Development"
;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]"
=
"iPhone Developer"
;
CODE_SIGN_STYLE
=
Manual
;
CURRENT_PROJECT_VERSION
=
0
;
CURRENT_PROJECT_VERSION
=
2
;
DEVELOPMENT_TEAM
=
""
;
"DEVELOPMENT_TEAM[sdk=iphoneos*]"
=
RXHYW88XR7
;
ENABLE_USER_SCRIPT_SANDBOXING
=
NO
;
...
...
@@ -3175,7 +3175,7 @@
CODE_SIGN_IDENTITY
=
"Apple Development"
;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]"
=
"iPhone Developer"
;
CODE_SIGN_STYLE
=
Manual
;
CURRENT_PROJECT_VERSION
=
0
;
CURRENT_PROJECT_VERSION
=
2
;
DEVELOPMENT_TEAM
=
""
;
"DEVELOPMENT_TEAM[sdk=iphoneos*]"
=
RXHYW88XR7
;
ENABLE_USER_SCRIPT_SANDBOXING
=
NO
;
...
...
galaxy/galaxy/AppDelegate.swift
View file @
5aea376c
...
...
@@ -124,7 +124,10 @@ extension AppDelegate {
//1.设置主窗口
private
func
setupRootVC
()
{
let
tabBarController
=
YHTabBarViewController
()
let
v0
=
YHNavigationController
(
rootVC
:
YHHomePageViewController
())
let
homeVC
=
YHHomePageViewController
()
tabBarController
.
delegate
=
homeVC
let
v0
=
YHNavigationController
(
rootVC
:
homeVC
)
let
v1
=
YHNavigationController
(
rootVC
:
YHServiceViewController
())
let
v2
=
YHNavigationController
(
rootVC
:
YHMsgViewController
())
let
v3
=
YHNavigationController
(
rootVC
:
YHMyViewController
())
...
...
galaxy/galaxy/Classes/Modules/Home(首页)/C/YHHomePageViewController.swift
View file @
5aea376c
...
...
@@ -54,6 +54,10 @@ class YHHomePageViewController: YHBaseViewController {
let
view
=
YHHomeHeadView
()
return
view
}()
var
tapTimestamp
:
CFAbsoluteTime
=
-
10.0
}
private
extension
YHHomePageViewController
{
...
...
@@ -96,6 +100,11 @@ private extension YHHomePageViewController {
}
self
.
homeCollectView
.
reloadData
()
// DispatchQueue.main.asyncAfter(deadline: .now() + 3, execute:{
// printLog(YHHomeHeadView.viewH)
// printLog(self.homeCollectView.contentOffset)
// })
}
}
...
...
@@ -184,3 +193,21 @@ extension YHHomePageViewController : CollectionViewWaterfallLayoutDelegate {
return
CGSize
(
width
:
model
.
img_width_cell
,
height
:
model
.
img_height_cell
)
}
}
extension
YHHomePageViewController
:
UITabBarControllerDelegate
{
func
tabBarController
(
_
tabBarController
:
UITabBarController
,
didSelect
viewController
:
UIViewController
)
{
let
doubleTapInterval
:
CGFloat
=
0.3
if
tabBarController
.
selectedIndex
==
0
{
let
timestamp
=
CFAbsoluteTimeGetCurrent
()
printLog
(
timestamp
-
self
.
tapTimestamp
)
if
timestamp
-
self
.
tapTimestamp
<
doubleTapInterval
{
UIView
.
animate
(
withDuration
:
0.25
)
{
self
.
homeCollectView
.
contentOffset
=
CGPoint
(
x
:
0
,
y
:
-
YHHomeHeadView
.
viewH
)
//置顶功能
}
}
self
.
tapTimestamp
=
timestamp
}
}
}
galaxy/galaxy/Classes/Modules/Home(首页)/C/YHStartPageViewController.swift
View file @
5aea376c
...
...
@@ -26,7 +26,7 @@ class YHStartPageViewController: UIViewController {
lazy
var
closeBtn
:
UIButton
=
{
let
button
=
UIButton
(
type
:
.
custom
)
button
.
titleLabel
?
.
font
=
UIFont
.
PFSC_R
(
ofSize
:
12
)
button
.
setTitle
(
"跳过
5
"
,
for
:
.
normal
)
button
.
setTitle
(
"跳过
3
"
,
for
:
.
normal
)
button
.
setTitleColor
(
UIColor
(
hex
:
0xffffff
),
for
:
.
normal
)
button
.
setBackgroundColor
(
color
:
UIColor
(
red
:
0.071
,
green
:
0.102
,
blue
:
0.149
,
alpha
:
0.3
),
forState
:
.
normal
)
return
button
...
...
@@ -98,7 +98,9 @@ private extension YHStartPageViewController {
//1.设置主窗口
func
setupRootVC
()
{
let
tabBarController
=
YHTabBarViewController
()
let
v0
=
YHNavigationController
(
rootVC
:
YHHomePageViewController
())
let
homeVC
=
YHHomePageViewController
()
tabBarController
.
delegate
=
homeVC
let
v0
=
YHNavigationController
(
rootVC
:
homeVC
)
let
v1
=
YHNavigationController
(
rootVC
:
YHServiceViewController
())
let
v2
=
YHNavigationController
(
rootVC
:
YHMsgViewController
())
let
v3
=
YHNavigationController
(
rootVC
:
YHMyViewController
())
...
...
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