Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
GMRefresh
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
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gengmeiios
GMRefresh
Commits
b0f79c00
Commit
b0f79c00
authored
Dec 26, 2018
by
汪洋
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'jql/refresh' into 'master'
添加不同时执行header、footer刷新 See merge request
!7
parents
a5165150
a5f497e3
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
32 additions
and
2 deletions
+32
-2
GMRefreshFooter.m
GMRefresh/Classes/GMRefreshFooter.m
+16
-1
GMRefreshHeader.m
GMRefresh/Classes/GMRefreshHeader.m
+16
-1
No files found.
GMRefresh/Classes/GMRefreshFooter.m
View file @
b0f79c00
...
...
@@ -35,7 +35,22 @@
-
(
void
)
executeRefreshingCallback
{
[
super
executeRefreshingCallback
];
dispatch_async
(
dispatch_get_main_queue
(),
^
{
MJRefreshHeader
*
header
=
_scrollView
.
mj_header
;
if
(
header
&&
[
header
isRefreshing
])
{
[
self
endRefreshing
];
}
else
{
if
(
self
.
refreshingBlock
)
{
self
.
refreshingBlock
();
}
if
([
self
.
refreshingTarget
respondsToSelector
:
self
.
refreshingAction
])
{
MJRefreshMsgSend
(
MJRefreshMsgTarget
(
self
.
refreshingTarget
),
self
.
refreshingAction
,
self
);
}
if
(
self
.
beginRefreshingCompletionBlock
)
{
self
.
beginRefreshingCompletionBlock
();
}
}
});
NSString
*
pageName
=
[
self
myViewController
].
pageName
?:
@""
;
[
Phobos
track
:
@"upload_page"
attributes
:@{
@"page_name"
:
pageName
}];
}
...
...
GMRefresh/Classes/GMRefreshHeader.m
View file @
b0f79c00
...
...
@@ -98,7 +98,22 @@
-
(
void
)
executeRefreshingCallback
{
[
super
executeRefreshingCallback
];
dispatch_async
(
dispatch_get_main_queue
(),
^
{
MJRefreshFooter
*
footer
=
_scrollView
.
mj_footer
;
if
(
footer
&&
[
footer
isRefreshing
])
{
[
self
endRefreshing
];
}
else
{
if
(
self
.
refreshingBlock
)
{
self
.
refreshingBlock
();
}
if
([
self
.
refreshingTarget
respondsToSelector
:
self
.
refreshingAction
])
{
MJRefreshMsgSend
(
MJRefreshMsgTarget
(
self
.
refreshingTarget
),
self
.
refreshingAction
,
self
);
}
if
(
self
.
beginRefreshingCompletionBlock
)
{
self
.
beginRefreshingCompletionBlock
();
}
}
});
NSString
*
pageName
=
[
self
myViewController
].
pageName
?:
@""
;
[
Phobos
track
:
@"refresh_page"
attributes
:@{
@"page_name"
:
pageName
}];
}
...
...
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