show version of Mini vMac core in settings

This commit is contained in:
Jesús A. Álvarez 2017-09-23 15:54:13 +02:00
parent deeb7b1247
commit c3cc54e1f4
2 changed files with 7 additions and 6 deletions

View File

@ -73,11 +73,12 @@ typedef enum : NSInteger {
aboutTitle = aboutData[@"title"]; aboutTitle = aboutData[@"title"];
aboutItems = aboutData[@"items"]; aboutItems = aboutData[@"items"];
footerView = [[UITextView alloc] initWithFrame:CGRectZero]; footerView = [[UITextView alloc] initWithFrame:CGRectZero];
NSAttributedString *str = [[NSMutableAttributedString alloc] initWithData:[aboutData[@"footer.html"] dataUsingEncoding:NSUTF8StringEncoding] NSString *footerHTML = [aboutData[@"footer.html"] stringByReplacingOccurrencesOfString:@"$mnvmversion" withString:[[NSBundle mainBundle] objectForInfoDictionaryKey:@"MNVMVersion"]];
options:@{NSDocumentTypeDocumentAttribute: NSHTMLTextDocumentType, NSAttributedString *str = [[NSAttributedString alloc] initWithData:[footerHTML dataUsingEncoding:NSUTF8StringEncoding]
NSCharacterEncodingDocumentAttribute: @(NSUTF8StringEncoding)} options:@{NSDocumentTypeDocumentAttribute: NSHTMLTextDocumentType,
documentAttributes:nil NSCharacterEncodingDocumentAttribute: @(NSUTF8StringEncoding)}
error:NULL]; documentAttributes:nil
error:NULL];
footerView.attributedText = str; footerView.attributedText = str;
[footerView sizeToFit]; [footerView sizeToFit];
footerView.editable = NO; footerView.editable = NO;

View File

@ -42,7 +42,7 @@
©2008-2017 Jesús A. Álvarez<br/> ©2008-2017 Jesús A. Álvarez<br/>
<a href="https://namedfork.net/minivmac">namedfork.net/minivmac</a><br/> <a href="https://namedfork.net/minivmac">namedfork.net/minivmac</a><br/>
<hr/> <hr/>
based on Mini vMac<br/> based on Mini vMac $mnvmversion<br/>
©2001-2017 Paul C. Pratt<br/> ©2001-2017 Paul C. Pratt<br/>
&lt;a href=&quot;http://gryphel.com/c/minivmac&quot;&gt;gryphel.com/c/minivmac&lt;/a&gt;</string> &lt;a href=&quot;http://gryphel.com/c/minivmac&quot;&gt;gryphel.com/c/minivmac&lt;/a&gt;</string>
</dict> </dict>