修改弹窗逻辑

This commit is contained in:
NSArray
2026-03-13 17:20:45 +08:00
parent 1bfe617cab
commit 6f9f903ca1
2 changed files with 16 additions and 4 deletions
@@ -217,10 +217,10 @@
#pragma mark - 点击背景关闭 #pragma mark - 点击背景关闭
- (void)addGesture { - (void)addGesture {
// UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(close)]; UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(close)];
// tap.cancelsTouchesInView = NO; tap.cancelsTouchesInView = YES;
// [self addGestureRecognizer:tap]; [self addGestureRecognizer:tap];
} }
- (void)close { - (void)close {
@@ -365,6 +365,13 @@ weekLabel;
- (void)moreClick { - (void)moreClick {
if (![HQCommonUtils isLogin]) {
KPostNotification(KNotificationLoginStateChange, @NO);
return;
}
if (self.watchModel.hasWatch == true) { if (self.watchModel.hasWatch == true) {
if (self.watchMoreBlock) { if (self.watchMoreBlock) {
self.watchMoreBlock(); self.watchMoreBlock();
@@ -494,8 +501,13 @@ weekLabel;
_devView.hidden = isFirst; _devView.hidden = isFirst;
if (isFirst) { if (isFirst) {
// 切换回第一个 Tab,重新根据数据状态显示 emptyView
BOOL isEmpty = (_dataList.count == 0);
_emptyView.hidden = !isEmpty;
[self p_restartAutoScroll]; [self p_restartAutoScroll];
} else { } else {
// 切换到其他 Tab,隐藏 emptyView
_emptyView.hidden = YES;
[self p_stopAutoScroll]; [self p_stopAutoScroll];
} }