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