Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
GMBase
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
GMBase
Commits
bbe45f51
Commit
bbe45f51
authored
Apr 12, 2018
by
汪洋
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'jinzhu/master' into 'master'
修改removeKVO See merge request
!9
parents
709c8acf
f98eb318
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
WMBaseListViewController.m
GMBase/Classes/WMBaseListViewController.m
+5
-5
No files found.
GMBase/Classes/WMBaseListViewController.m
View file @
bbe45f51
...
...
@@ -162,7 +162,10 @@
}
-
(
void
)
removeKVO
{
// 因为fetchDataSuccess是在viewDidLoad中监听的,所以需要一个判断
if
([
self
isViewLoaded
])
{
[
self
.
viewModel
removeObserver
:
self
forKeyPath
:
@"fetchDataSuccess"
];
}
}
-
(
void
)
observeValueForKeyPath
:
(
NSString
*
)
keyPath
ofObject
:
(
id
)
object
change
:
(
NSDictionary
*
)
change
context
:
(
void
*
)
context
{
...
...
@@ -191,10 +194,7 @@
-
(
void
)
dealloc
{
[
self
removeKVO
];
// 因为fetchDataSuccess是在viewDidLoad中监听的,所以需要一个判断
if
([
self
isViewLoaded
])
{
[
self
.
viewModel
removeObserver
:
self
forKeyPath
:
@"fetchDataSuccess"
];
}
}
-
(
void
)
showEmptyView
:
(
GMEmptyViewType
)
type
{
...
...
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