Version 3, 29 June 2007
Copyright © 2007 Free Software Foundation, Inc. <http://fsf.org/>
Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed.
- (void)showCard:(id)sender | |
{ | |
UIGraphicsBeginImageContext(self.view.window.frame.size); | |
[self.view.window.layer renderInContext:UIGraphicsGetCurrentContext()]; | |
UIImage *screenshot = UIGraphicsGetImageFromCurrentImageContext(); | |
UIGraphicsEndImageContext(); | |
UIViewControllerSubclass *card = [[UIViewControllerSubclass alloc] init]; | |
card.background = screenshot; | |
[self presentModalViewController:card animated:NO]; |
-- Print contents of `tbl`, with indentation. | |
-- `indent` sets the initial level of indentation. | |
function tprint (tbl, indent) | |
if not indent then indent = 0 end | |
for k, v in pairs(tbl) do | |
formatting = string.rep(" ", indent) .. k .. ": " | |
if type(v) == "table" then | |
print(formatting) | |
tprint(v, indent+1) | |
else |
Version 3, 29 June 2007
Copyright © 2007 Free Software Foundation, Inc. <http://fsf.org/>
Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed.