Displaying overridden configuration
override func viewDidLoad() {
let label = APLConfigurationLabel(frame: .zero)
label.center = CGPoint(x: 7, y: self.navigationController!.view.bounds.size.height / 2)
self.navigationController!.view.addSubview(label)
}- (void) viewDidLoad {
APLConfigurationLabel* label = [[APLConfigurationLabel alloc] initWithFrame: CGRectZero];
label.center = CGPointMake(7, self.navigationController.view.bounds.size.height / 2);
[self.navigationController.view addSubview: label];
}<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent">
<original-layout-here/>
<nz.co.electricbolt.appfiguratelibrary.ConfigurationLabel
android:id="@+id/configuration_label"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"/>
</FrameLayout>Creating your own label
extension MyLogonController: APLConfigurationUpdated {
override func viewDidLoad() {
APLAddConfigurationUpdatedListener(self)
}
func configurationUpdated(_ notification: Notification?) {
label.text = APLConfiguration.shared().modifications
}
...@interface MyLogonController () <APLConfigurationUpdated>
@end
@implementation MyLogonController
- (void) viewDidLoad {
APLAddConfigurationUpdatedListener(self);
}
- (void) configurationUpdated: (NSNotification*) notification {
label.text = [[APLConfiguration sharedConfiguration] modifications];
}
...Last updated
