iOS Module SDK
0.97
Tools for building CampusLife modules
|
#import <D2LModuleBrand.h>
Public Member Functions | |
(void) | - applyPortraitBackgroundToView: |
(void) | - applyLandscapeBackgroundToView: |
(void) | - applyStyleToLabel: |
(void) | - applyStyleToNavigationBar: |
(void) | - applyStyleToSearchBar: |
(void) | - applyStyleToToolbar: |
(void) | - applyStyleToTableViewCell: |
(UIColor *) | - colorForKey: |
Static Public Member Functions | |
(D2LModuleBrand *) | + sharedBrand |
App creators can specify simple branding information while creating their app, such as background images, custom tint colors, etc. While it is not required that your module use the host application's branding settings, it is a way to make your module feel more unified with the rest of the application.
The shared brand object provides methods that allow you to access that branding information and style your UI controls to match.
- (void) applyLandscapeBackgroundToView: | (UIView *) | view |
Applies the application's module landscape background image to the given view.
view | - The view to apply the image to. |
- (void) applyPortraitBackgroundToView: | (UIView *) | view |
Applies the application's module portrait background image to the given view.
view | - The view to apply the image to. |
- (void) applyStyleToLabel: | (UILabel *) | label |
Brands the text and shadow colors of the given label. Meant to be used on labels that appear directly overtop the module background image.
label | - The label to brand. |
- (void) applyStyleToNavigationBar: | (UINavigationBar *) | navigationBar |
Brands the tint color of the given navigation bar.
navigationBar | - the navigation bar to brand. |
- (void) applyStyleToSearchBar: | (UISearchBar *) | searchBar |
Brands the tint color of the given search bar.
searchBar | - The search bar to brand. |
- (void) applyStyleToTableViewCell: | (UITableViewCell *) | tableViewCell |
Brands the text and background colors of the given table view cell. Meant for iOS preset table view cell styles, and not custom table view cells.
tableViewCell | - The table view cell to brand. |
- (void) applyStyleToToolbar: | (UIToolbar *) | toolbar |
Brands the tint color of the given toolbar.
toolbar | - The toolbar to brand. |
- (UIColor *) colorForKey: | (NSString *) | key |
Returns the brand color corresponding to a key string. Every application branding color can be accessed individually through this method, though when possible you should use one of the provided "applyStyle" methods instead.
key | - The key string for the color to retrieve. |
+ (D2LModuleBrand *) sharedBrand |
Returns the shared branding object.