mirror of
https://github.com/moonlight-stream/moonlight-ios.git
synced 2026-04-03 06:26:09 +00:00
Set the title of the view to the selected PC
This commit is contained in:
@@ -17,7 +17,9 @@
|
||||
|
||||
@interface MainFrameViewController : UICollectionViewController <DiscoveryCallback, PairCallback, HostCallback, AppCallback, AppAssetCallback, NSURLConnectionDelegate, SWRevealViewControllerDelegate>
|
||||
|
||||
#if !TARGET_OS_TV
|
||||
@property (strong, nonatomic) IBOutlet UIButton *limelightLogoButton;
|
||||
@property (weak, nonatomic) IBOutlet UIBarButtonItem *computerNameButton;
|
||||
#endif
|
||||
|
||||
@end
|
||||
|
||||
@@ -124,7 +124,11 @@ static NSMutableSet* hostList;
|
||||
return;
|
||||
}
|
||||
|
||||
#if TARGET_OS_TV
|
||||
self.title = host.name;
|
||||
#else
|
||||
self->_computerNameButton.title = host.name;
|
||||
#endif
|
||||
[self.navigationController.navigationBar setNeedsLayout];
|
||||
|
||||
[self updateAppsForHost:host];
|
||||
@@ -168,7 +172,11 @@ static NSMutableSet* hostList;
|
||||
return;
|
||||
}
|
||||
|
||||
#if TARGET_OS_TV
|
||||
self.title = host.name;
|
||||
#else
|
||||
self->_computerNameButton.title = host.name;
|
||||
#endif
|
||||
[self.navigationController.navigationBar setNeedsLayout];
|
||||
|
||||
[self updateAppsForHost:host];
|
||||
@@ -241,7 +249,11 @@ static NSMutableSet* hostList;
|
||||
|
||||
[_appManager stopRetrieving];
|
||||
_selectedHost = nil;
|
||||
#if TARGET_OS_TV
|
||||
self.title = @"";
|
||||
#else
|
||||
_computerNameButton.title = @"No Host Selected";
|
||||
#endif
|
||||
[self.collectionView reloadData];
|
||||
[self.view addSubview:hostScrollView];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user