Ver código fonte

朋友圈详情隐藏

桂欢 1 ano atrás
pai
commit
a5b4950000

+ 16 - 0
SLAiELTS/SLAiELTS/Tool/SDPhotoBrowser/SDPhotoBrowser.m

@@ -23,6 +23,8 @@
 
 //  =============================================
 
+#import "SLMomentsVc.h"
+
 @interface SDPhotoBrowser()
 
 @property (nonatomic, strong) UIButton *operationLikeButton;
@@ -333,10 +335,24 @@
 
 - (void)show
 {
+    BOOL justShowImages = NO;
+    SLMomentsVc *vc = (SLMomentsVc *)[UIViewController getCurrentShowVC];
+    if ([vc isKindOfClass:SLMomentsVc.class] && !vc.isFriendList) {
+        justShowImages = YES;
+    }
     UIWindow *window = [UIApplication sharedApplication].keyWindow;
     self.frame = window.bounds;
     [window addObserver:self forKeyPath:@"frame" options:0 context:nil];
     [window addSubview:self];
+    if (justShowImages) {
+        [self.subviews enumerateObjectsUsingBlock:^(__kindof UIView * _Nonnull obj, NSUInteger idx, BOOL * _Nonnull stop) {
+            if (obj == _scrollView || obj == _indexLabel) {
+                obj.hidden = NO;
+            }else {
+                obj.hidden = YES;
+            }
+        }];
+    }
 }
 
 - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(UIView *)object change:(NSDictionary *)change context:(void *)context

+ 1 - 0
SLAiELTS/SLAiELTS/ViewControllers/Moments/MomentsVc/SLMomentsCommentVc.m

@@ -32,6 +32,7 @@
     self.textView.placeholder = @"请输入...";
     self.textView.font = [UIFont systemFontOfSize:14];
     self.textView.textColor = SL333Color;
+    self.textView.keyboardType = UIKeyboardTypeASCIICapable;
     
     YMBarButtonItem *rightBarItem = [[YMBarButtonItem alloc] initWithTitle:@"发布  " target:self action:@selector(preserveBtnClick)];
     rightBarItem.titleInsets = UIEdgeInsetsMake(0, 0, 0, 20);