Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
VirtualCard-iOS
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
APP
VirtualCard-iOS
Commits
7544f296
Commit
7544f296
authored
May 28, 2020
by
guanghui.shi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
弹窗逻辑再次变更
parent
96cbac69
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
40 additions
and
31 deletions
+40
-31
QGActivityPopManager.m
...es/Card/Function/QGActivityManager/QGActivityPopManager.m
+38
-29
QGFloatsPopView.m
...Classes/Card/Function/QGActivityManager/QGFloatsPopView.m
+2
-2
No files found.
VirtualPayment/VirtualPayment/QGClasses/Card/Function/QGActivityManager/QGActivityPopManager.m
View file @
7544f296
...
...
@@ -107,46 +107,55 @@ static NSString * floats_pop_sets = @"floats_pop_sets";
self
.
floatsPopViews
=
[
NSMutableArray
array
];
self
.
activePopViews
=
[
NSMutableArray
array
];
[[
NSNotificationCenter
defaultCenter
]
addObserver
:
self
selector
:
@selector
(
r
emoveAllPopViews
)
name
:
ModelCenterUserLogOutNotification
object
:
nil
];
[[
NSNotificationCenter
defaultCenter
]
addObserver
:
self
selector
:
@selector
(
reset
AllPopViews
)
name
:
ModelCenterUserLoginNotification
object
:
nil
];
[[
NSNotificationCenter
defaultCenter
]
addObserver
:
self
selector
:
@selector
(
logoutR
emoveAllPopViews
)
name
:
ModelCenterUserLogOutNotification
object
:
nil
];
[[
NSNotificationCenter
defaultCenter
]
addObserver
:
self
selector
:
@selector
(
loginRemove
AllPopViews
)
name
:
ModelCenterUserLoginNotification
object
:
nil
];
}
return
self
;
}
/// 移除当前所有的弹窗
-
(
void
)
r
emoveAllPopViews
-
(
void
)
logoutR
emoveAllPopViews
{
/// 移除当前所有的弹窗视图
if
(
self
.
activePopViews
.
count
)
{
[
self
.
activePopViews
enumerateObjectsWithOptions
:
NSEnumerationReverse
usingBlock
:
^
(
UIView
*
_Nonnull
obj
,
NSUInteger
idx
,
BOOL
*
_Nonnull
stop
)
{
[
obj
removeFromSuperview
];
}];
[
self
.
activePopViews
removeAllObjects
];
}
/// 移除所有浮窗视图
if
(
self
.
floatsPopViews
.
count
)
{
[
self
.
floatsPopViews
enumerateObjectsWithOptions
:
NSEnumerationReverse
usingBlock
:
^
(
UIView
*
_Nonnull
obj
,
NSUInteger
idx
,
BOOL
*
_Nonnull
stop
)
{
[
obj
removeFromSuperview
];
}];
[
self
.
floatsPopViews
removeAllObjects
];
}
[
self
.
activePops
removeAllObjects
];
[
self
.
invalidActivityPops
removeAllObjects
];
[
self
.
invalidFloatPops
removeAllObjects
];
/// 清空本地的标记
[
self
cleanLocalUniques
];
for
(
QGActivityPopControlModel
*
model
in
self
.
popIndexs
)
{
model
.
shouldReset
=
YES
;
}
[
self
resetAllPopViewsCleanLocal
:
YES
];
}
/// 重新设置所有的弹窗
-
(
void
)
reset
AllPopViews
-
(
void
)
loginRemove
AllPopViews
{
[
self
removeAllPopViews
];
[
self
resetAllPopViewsCleanLocal
:
NO
];
}
-
(
void
)
resetAllPopViewsCleanLocal
:(
BOOL
)
clean
{
/// 移除当前所有的弹窗视图
if
(
self
.
activePopViews
.
count
)
{
[
self
.
activePopViews
enumerateObjectsWithOptions
:
NSEnumerationReverse
usingBlock
:
^
(
UIView
*
_Nonnull
obj
,
NSUInteger
idx
,
BOOL
*
_Nonnull
stop
)
{
[
obj
removeFromSuperview
];
}];
[
self
.
activePopViews
removeAllObjects
];
}
/// 移除所有浮窗视图
if
(
self
.
floatsPopViews
.
count
)
{
[
self
.
floatsPopViews
enumerateObjectsWithOptions
:
NSEnumerationReverse
usingBlock
:
^
(
UIView
*
_Nonnull
obj
,
NSUInteger
idx
,
BOOL
*
_Nonnull
stop
)
{
[
obj
removeFromSuperview
];
}];
[
self
.
floatsPopViews
removeAllObjects
];
}
[
self
.
activePops
removeAllObjects
];
if
(
clean
)
{
/// 清空本地的标记
[
self
cleanLocalUniques
];
[
self
.
invalidActivityPops
removeAllObjects
];
[
self
.
invalidFloatPops
removeAllObjects
];
}
for
(
QGActivityPopControlModel
*
model
in
self
.
popIndexs
)
{
model
.
shouldReset
=
YES
;
}
}
#pragma mark - 网络模块
...
...
VirtualPayment/VirtualPayment/QGClasses/Card/Function/QGActivityManager/QGFloatsPopView.m
View file @
7544f296
...
...
@@ -130,9 +130,9 @@
}
else
{
// 其他一律放在右下,下面的位置偏下一点
if
(
self
.
controller
&&
self
.
controller
.
tabBarController
.
tabBar
.
isHidden
){
self
.
bottom
=
controller
.
view
.
height
-
2
0
;
self
.
bottom
=
controller
.
view
.
height
-
7
0
;
}
else
{
self
.
bottom
=
controller
.
view
.
height
-
2
0
-
[
DeviceAdaptation
getTabBarHeight
];
self
.
bottom
=
controller
.
view
.
height
-
7
0
-
[
DeviceAdaptation
getTabBarHeight
];
}
}
...
...
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