-
Notifications
You must be signed in to change notification settings - Fork 45
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
17 changed files
with
170 additions
and
140 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 15 additions & 0 deletions
15
GKWYMusic/Classes/Home/Artist/Controller/GKWYIntroDetailViewController.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
// | ||
// GKWYIntroDetailViewController.h | ||
// GKWYMusic | ||
// | ||
// Created by gaokun on 2018/5/20. | ||
// Copyright © 2018年 gaokun. All rights reserved. | ||
// | ||
|
||
#import "GKWYBaseViewController.h" | ||
|
||
@interface GKWYIntroDetailViewController : GKWYBaseViewController | ||
|
||
@property (nonatomic, copy) NSString *intro; | ||
|
||
@end |
48 changes: 48 additions & 0 deletions
48
GKWYMusic/Classes/Home/Artist/Controller/GKWYIntroDetailViewController.m
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
// | ||
// GKWYIntroDetailViewController.m | ||
// GKWYMusic | ||
// | ||
// Created by gaokun on 2018/5/20. | ||
// Copyright © 2018年 gaokun. All rights reserved. | ||
// | ||
|
||
#import "GKWYIntroDetailViewController.h" | ||
|
||
@interface GKWYIntroDetailViewController () | ||
|
||
@property (nonatomic, strong) UIScrollView *scrollView; | ||
|
||
@end | ||
|
||
@implementation GKWYIntroDetailViewController | ||
|
||
- (void)viewDidLoad { | ||
[super viewDidLoad]; | ||
|
||
[self.view addSubview:self.scrollView]; | ||
[self.scrollView mas_makeConstraints:^(MASConstraintMaker *make) { | ||
make.edges.equalTo(self.view); | ||
}]; | ||
|
||
UILabel *contentLabel = [UILabel new]; | ||
contentLabel.textColor = [UIColor blackColor]; | ||
contentLabel.font = [UIFont systemFontOfSize:16.0f]; | ||
contentLabel.numberOfLines = 0; | ||
contentLabel.text = self.intro; | ||
[self.scrollView addSubview:contentLabel]; | ||
|
||
contentLabel.frame = CGRectMake(kAdaptive(20.0f), kAdaptive(20.0f), KScreenW - kAdaptive(40.0f), 0); | ||
[contentLabel sizeToFit]; | ||
|
||
self.scrollView.contentSize = CGSizeMake(0, contentLabel.frame.size.height + kAdaptive(40.0f)); | ||
} | ||
|
||
#pragma mark - 懒加载 | ||
- (UIScrollView *)scrollView { | ||
if (!_scrollView) { | ||
_scrollView = [UIScrollView new]; | ||
} | ||
return _scrollView; | ||
} | ||
|
||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.