「冒泡搜索」改为「热门话题」&一些 UI 调整 · CoderKman/Coding-iOS@abf0bed · GitHub
Skip to content

Commit abf0bed

Browse files
committed
「冒泡搜索」改为「热门话题」&一些 UI 调整
1 parent 14114b6 commit abf0bed

10 files changed

Lines changed: 31 additions & 6 deletions

File tree

Coding_iOS.xcodeproj/project.pbxproj

Lines changed: 16 additions & 0 deletions

Coding_iOS/Controllers/LocalFileViewController.m

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ - (void)viewDidLoad {
4646
[super viewDidLoad];
4747
// Do any additional setup after loading the view.
4848
self.title = self.fileName;
49-
[self.navigationItem setRightBarButtonItem:[[UIBarButtonItem alloc] initWithImage:[UIImage imageNamed:@"moreBtn_Nav"] style:UIBarButtonItemStylePlain target:self action:@selector(rightNavBtnClicked)] animated:NO];
49+
[self.navigationItem setRightBarButtonItem:[[UIBarButtonItem alloc] initWithImage:[UIImage imageNamed:@"share_Nav"] style:UIBarButtonItemStylePlain target:self action:@selector(rightNavBtnClicked)] animated:NO];
5050

5151
if ([self.fileType isEqualToString:@"md"]
5252
|| [self.fileType isEqualToString:@"html"]
@@ -94,6 +94,7 @@ - (void)loadWebView:(NSURL *)fileUrl{
9494
NSString *mdStr = [NSString stringWithContentsOfURL:fileUrl encoding:NSUTF8StringEncoding error:nil];
9595
[self.activityIndicator startAnimating];
9696
[[Coding_NetAPIManager sharedManager] request_MDHtmlStr_WithMDStr:mdStr inProject:nil andBlock:^(id data, NSError *error) {
97+
[self.activityIndicator stopAnimating];
9798
NSString *htmlStr;
9899
htmlStr = data? data: @"加载失败";
99100
NSString *contentStr = [WebContentManager markdownPatternedWithContent:htmlStr];

Coding_iOS/Controllers/RootControllers/Tweet_RootViewController.m

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@
2828
#import "CSSearchVC.h"
2929
#import "CSSearchDisplayVC.h"
3030
#import "FunctionTipsManager.h"
31+
#import "CSHotTopicPagesVC.h"
3132

3233
@interface Tweet_RootViewController () <UISearchBarDelegate, UISearchDisplayDelegate>
3334
{
@@ -103,7 +104,9 @@ - (void)viewDidLoad
103104
// [self refreshFirst];
104105
// }];
105106

106-
UIBarButtonItem *leftBarItem =[UIBarButtonItem itemWithIcon:@"search_Nav" showBadge:NO target:self action:@selector(searchItemClicked:)];
107+
// UIBarButtonItem *leftBarItem =[UIBarButtonItem itemWithIcon:@"search_Nav" showBadge:NO target:self action:@selector(searchItemClicked:)];
108+
UIBarButtonItem *leftBarItem =[UIBarButtonItem itemWithIcon:@"hot_topic_Nav" showBadge:NO target:self action:@selector(hotTopicBtnClicked:)];
109+
107110
[self.parentViewController.navigationItem setLeftBarButtonItem:leftBarItem animated:NO];
108111

109112
_tweetsDict = [[NSMutableDictionary alloc] initWithCapacity:4];
@@ -287,7 +290,12 @@ - (void)deleteComment:(Comment *)comment ofTweet:(Tweet *)tweet{
287290
}];
288291
}
289292

290-
#pragma mark - search
293+
#pragma mark - nav_LeftBtn
294+
295+
- (void)hotTopicBtnClicked:(id)sender{
296+
CSHotTopicPagesVC *vc = [CSHotTopicPagesVC new];
297+
[self.navigationController pushViewController:vc animated:YES];
298+
}
291299

292300
- (void)searchItemClicked:(id)sender{
293301
if ([[FunctionTipsManager shareManager] needToTip:kFunctionTipStr_Search]) {

Coding_iOS/Controllers/Topic/CSHotTopicPagesVC.m

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -160,13 +160,13 @@ - (void)setupUI {
160160
UILabel *la1 = [[UILabel alloc] initWithFrame:CGRectMake((kScreen_Width/2 - titleWidth/2) + 0*distance, 8, titleWidth, 16)];
161161
la1.text = @"热门话题";
162162
la1.textAlignment = NSTextAlignmentCenter;
163-
la1.font = [UIFont systemFontOfSize:16];
163+
la1.font = [UIFont boldSystemFontOfSize:18];
164164
la1.textColor = [UIColor whiteColor];
165165

166166
UILabel *la2 = [[UILabel alloc] initWithFrame:CGRectMake((kScreen_Width/2 - titleWidth/2) + 1*distance, 8, titleWidth, 16)];
167167
la2.text = @"我的话题";
168168
la2.textAlignment = NSTextAlignmentCenter;
169-
la2.font = [UIFont systemFontOfSize:16];
169+
la2.font = [UIFont boldSystemFontOfSize:18];
170170
la2.textColor = [UIColor whiteColor];
171171

172172

Coding_iOS/Controllers/TweetDetailViewController.m

Lines changed: 1 addition & 1 deletion

Coding_iOS/Images/.DS_Store

0 Bytes
Binary file not shown.
450 Bytes
Loading
597 Bytes
Loading
668 Bytes
Loading
983 Bytes
Loading

0 commit comments

Comments
 (0)