{"id":18271299,"url":"https://github.com/mochidev/MDAboutControllerDemo","last_synced_at":"2025-04-05T01:31:19.413Z","repository":{"id":140661904,"uuid":"1634350","full_name":"mochidev/MDAboutControllerDemo","owner":"mochidev","description":"Automatically populated about view controller for iOS apps! This is the demo.","archived":false,"fork":false,"pushed_at":"2013-09-08T07:55:30.000Z","size":448,"stargazers_count":54,"open_issues_count":1,"forks_count":13,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-03-23T05:04:03.725Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://mochidev.com/open","language":"Objective-C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mochidev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2011-04-19T06:42:43.000Z","updated_at":"2024-12-18T11:57:34.000Z","dependencies_parsed_at":"2023-03-11T23:30:19.021Z","dependency_job_id":null,"html_url":"https://github.com/mochidev/MDAboutControllerDemo","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mochidev%2FMDAboutControllerDemo","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mochidev%2FMDAboutControllerDemo/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mochidev%2FMDAboutControllerDemo/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mochidev%2FMDAboutControllerDemo/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mochidev","download_url":"https://codeload.github.com/mochidev/MDAboutControllerDemo/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247276043,"owners_count":20912286,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-05T11:39:12.398Z","updated_at":"2025-04-05T01:31:14.395Z","avatar_url":"https://github.com/mochidev.png","language":"Objective-C","readme":"MDAboutController Demo\n======================\n\n![Screenshot](https://github.com/mochidev/MDAboutControllerDemo/raw/master/Artwork/Screenshot.png)\n\nPurpose\n-------\n\nMDAboutController is a complete About UIViewController package for iOS apps.\nIt automatically fetches info from your Info.plist, and also populates credits\nfrom Credits.plist. This repository serves to demonstrate and test the\nMDAboutController class. Please visit the\n[MDAboutController](https://github.com/mochidev/MDAboutController) repository\nfor the actual code :)\n\nMDAboutController is both iPhone (Portrait and Landscape) and iPad compatible,\nretrieves the app's name and version from your Info.plist, and even chooses the\nmost appropriate icon for the project depending on the device and your choices\nin Info.plist. Finally, the controller allows you to add credits, links, images,\nand text via a Credits.plist file (examples below).\n\nIf you use MDAboutController in your app, please add it to the\n[list](https://github.com/mochidev/MDAboutControllerDemo/wiki/Apps-That-Use-MDAboutController)!\n\nInstallation\n------------\n\n```bash\n$ git clone https://github.com/mochidev/MDAboutControllerDemo --recursive\n```\n\nTo include it into your own projects either download the\n[source](https://github.com/mochidev/MDAboutController), or run the following\non your git repo:\n\n```bash\n$ cd \u003cyour_repo\u003e\n$ git submodule add git@github.com:mochidev/MDAboutController.git \u003clocal_subpath\u003e\n```\n\nThis will allow you to update it at anytime by running `$ git submodule update`.\n\nUsage\n-----\n\nSimply add the\n[MDAboutController](https://github.com/mochidev/MDAboutController) submodule to\nyour project, and show the controller via UIViewController's\n`presentModalViewController:animated:` method.\n\nIn your interface, define the following instance variable and method:\n\n```obj-c\n// Defined in interface\nMDAboutController *aboutController;\n- (IBAction)showAbout:(id)sender;\n```\n\nThen, in your UIViewController subclass implementation, implement the following methods:\n\n```obj-c\n// Implemented in implementation of a UIViewController subclass\n- (void)dealloc\n{\n    [aboutController release];\n    [super dealloc];\n}\n\n- (void)didReceiveMemoryWarning\n{\n    [super didReceiveMemoryWarning];\n\n    // Check if the about controller is being shown\n    if (aboutController.parentViewController == nil) {\n        // Release and set to nil, so we can recreate it if we need to\n        [aboutController release];\n        aboutController = nil;\n    }\n}\n\n- (IBAction)showAbout:(id)sender\n{\n    // If the view controller doesn't already exist, create it\n    if (!aboutController) {\n        aboutController = [[MDAboutController alloc] init];\n    }\n    \n    // Present to user!\n    [self presentModalViewController:aboutController animated:YES];\n}\n```\n\nAlternatively, if you create the view controller as a part of a navigation\ncontroller stack, it will support loading `UIWebView`s and other specified\nview controllers. This can be easily done by using the `MDAboutNavigationController`\nclass, a subclass of `UINavigationController`, in the same way as `MDAboutController`\nwas used above. Please see the `MDAboutControllerDemo/MDAboutControllerViewController.m`\nfile for examples.\n\nTo add a custom controller to the navigation stack, first, make sure your\nabout controller is part of a navigation stack. Then, in your `Credits.plist`,\nadd a list item with the `Controller` key set to the class name of your\ncustom `UIViewController` subclass.\n\nIf you would like to include Email support directly in your app, please add\nthe `MessageUI` framework to your project, otherwise a new message will be\ncreated in Mail.app. The subject will be populated with \"App Name 1.0 (55)\nSupport\" automatically.\n\nIf you would like to edit the style of an `MDAboutController` (as is done in\nthe first demo), subclass `MDACStyle` and return values you wish to change.\nThen, when you create your controller, initialize it with that style:\n\n```obj-c\n- (IBAction)showAbout:(id)sender\n{\n    // If the view controller doesn't already exist, create it\n    if (!aboutController) {\n        aboutController = [[MDAboutController alloc] initWithStyle:[MyStyle style]];\n    }\n    \n    // Present to user!\n    [self presentModalViewController:aboutController animated:YES];\n}\n\n- (IBAction)showNavAbout:(id)sender\n{\n    // If the view controller doesn't already exist, create it\n    if (!aboutNavController) {\n        aboutNavController = [[MDAboutNavigationController alloc] initWithStyle:[MyStyle style]];\n    }\n    \n    // Present to user!\n    [self presentModalViewController:aboutNavController animated:YES];\n}\n```\n\nTwo styles are included by default. To get the default iOS user interface,\nsimply create the controller with `[[MDAboutController alloc] init]`,\nand `[MDACStyle style]` will automatically be used. Additionally,\nthe `MDACMochiDevStyle` style class is included to illustrate how\na different style may look.\n\n### Credits.plist\n-----------------\n\nTo get the most out of MDAboutViewController, be sure to include a `Credits.plist`\nfile in your project's resources. This will allow you to add credits,\nlinks, images, and text to your about screen. The property list must be\nconfigured as an array of dictionaries, with each dictionary representing\none section of the about screen.\n\nEach dictionary should have a `Type` key of type string, which can have a\nvalue of `List` for a group of links or credits, `Text` for blocks of text\nor copyright strings, or `Image` for images.\n\n`Type == List` Keys:\n\n- `Items` - an array of dictionaries with mandatory key `Name` and other optional keys that descripe the rows:\n  - `Name` - a required string which will be used as the row text.\n  - `Role` - an optional string shown in lower case in front of the `Name` string.\n  - `Link` - an optional URL string to link to if the text is tapped.\n  - `Email` - an optional Email string that will open an email panel.\n  - `EmailName` - an optional name to use in the To: field of the email panel.\n  - `Controller` - an optional controller to push on a navigation stack.\n  - `Identifier` - an optional identifier to identify individual items.\n- `Title` - an optional title string to include above the group.\n\n`Type == Text` Keys:\n\n- `Text` - the text to represent.\n- `Link` - an optional URL string to link to if the text is tapped.\n- `Size` - an optional font size of type number. The default is 13pt.\n- `Alignment` - an optional string representing the text alignment. Can be either `Left`, `Right`, or the default, `Center`.\n\n`Type == Image` Keys:\n\n- `Image` - the name of the image file, much like it is referenced from `UIImage`'s `imageNamed:` method.\n\n### For Open Source Software\n----------------------------\n\nIf you have open source software which you'd like to add to `MDAboutController`\nautomatically upon loading, simply implement a `+ (NSDictionary *)MDAboutControllerTextCreditDictionary`\nclass method as shown below. Valid keys are `Text` and `Link`, both `NSString`s.\nIf your open source user doesn't use `MDAboutController`, nothing will\nhappen and code will continue to run just fine. If they do, a single line entry will\nautomatically show up at the bottom of the controller to credit your code.\n\n```obj-c\n@implementation MyOpenSourceMainClass\n\n+ (NSDictionary *)MDAboutControllerTextCreditDictionary\n{\n    if (self == [\u003c#MyOpenSourceMainClass#\u003e class]) { // change \u003c#MyOpenSourceMainClass#\u003e to whatever the class name actually is!\n        return [NSDictionary dictionaryWithObjectsAndKeys:@\"Super awesome stuff powered by MyOpenSourceMainClass, by Mr. Awesome!\", @\"Text\",\n                                                          @\"https://awesomesauce.com/\", @\"Link\", nil];\n    }\n    return nil;\n}\n\n...\n\n@end\n```\n\nTo Do\n-----\n\n- List group titles\n- App portfolio for more info on other apps\n- Images in lists\n\nCoding Style Guidelines\n-----------------------\n\nPlease see https://mochidev.com/codestyle\n\nLicense\n-------\n\nCopyright (c) 2013 Dimitri Bouniol, Mochi Development, Inc.\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software, associated artwork, and documentation files (the \"Software\"),\nto deal in the Software without restriction, including without limitation the\nrights to use, copy, modify, merge, publish, distribute, sublicense, and/or\nsell copies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\n1. The above copyright notice and this permission notice shall be included in\n   all copies or substantial portions of the Software.\n2. Neither the name of Mochi Development, Inc. nor the names of its\n   contributors or products may be used to endorse or promote products\n   derived from this software without specific prior written permission.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\nTHE SOFTWARE.\n\nEleMints, the EleMints Icon, Mochi Dev, and the Mochi Development logo are\ncopyright Mochi Development, Inc.\n\nAlso, it'd be super awesome if you left in the credit line generated\nautomatically by the code that links back to this page :)\n\nCredits\n-------\n\n- Created by [Dimitri Bouniol](http://twitter.com/dimitribouniol) for [Mochi Development, Inc.](http://mochidev.com/)\n- Contributed to by [Doron Katz](http://doronkatz.com) of [DoronKatz.com](http://doronkatz.com)\n- Contributed to by [Denis Hennessy](http://hennessynet.com) of [Peer Assembly](http://www.peerassembly.com)\n- Contributed to by [John Arnold](https://github.com/MigrantP) of [Handelabra](http://handelabra.com)\n","funding_links":[],"categories":["etc"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmochidev%2FMDAboutControllerDemo","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmochidev%2FMDAboutControllerDemo","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmochidev%2FMDAboutControllerDemo/lists"}