]> git.saurik.com Git - cydget.git/blobdiff - PhotoExample.cydget/index.html
OMG this finally works.
[cydget.git] / PhotoExample.cydget / index.html
index 3cedb186b5a0ca5c06217d87f8f9564ed5e2989a..d16c35319decfa9163f76a29143812f26b65ddcb 100644 (file)
         vertical-align:middle;
     }
 </style></head><body>
         vertical-align:middle;
     }
 </style></head><body>
-    <div id="content"><script type="text/cycript">
-        document.write('<div id="lcd">');
-
-        var locale = CFLocaleCopyCurrent();
-        var now = CFDateCreate(NULL, CFAbsoluteTimeGetCurrent());
-        var formatter = CFDateFormatterCreate(NULL, locale, kCFDateFormatterNoStyle, kCFDateFormatterNoStyle);
-        CFRelease(locale);
-
-        CFDateFormatterSetFormat(formatter, UIDateFormatStringForFormatType(UINoAMPMTimeFormat));
-        var time = CFDateFormatterCreateStringWithDate(NULL, formatter, now);
-        document.write('<h1>');
-        document.write(time);
-        document.write('</h1>');
-        CFRelease(time);
-
-        CFDateFormatterSetFormat(formatter, UIDateFormatStringForFormatType(UIWeekdayNoYearDateFormat));
-        var date = CFDateFormatterCreateStringWithDate(NULL, formatter, now);
-        document.write('<h2>');
-        document.write(date);
-        document.write('</h2>');
-        CFRelease(date);
-
-        CFRelease(formatter);
-        CFRelease(now);
-
-        document.write('</div>');
-
+    <div id="content">
+        <script type="text/cycript" src="lcd.cy"></script>
+    <script type="text/cycript">
+        document.write([NSString stringWithString:'A'].toString());
+    </script>
+    <script type="text/cycript">
+        document.write([NSString stringWithString:'B'].toString());
+    </script>
+    <script type="text/cycript">
+        document.write([NSString stringWithString:'C'].toString());
+    </script>
+        <script type="text/cycript" src="lcd.cy"></script>
+        P       
+    <script type="text/cycript">
+        document.write([NSString stringWithString:'D'].toString());
+    </script>
+    <script type="text/cycript">
+        document.write([NSString stringWithString:'E'].toString());
+    </script>
+    <script type="text/cycript">
         dlopen("/System/Library/PrivateFrameworks/PhotoLibrary.framework/PhotoLibrary", RTLD_GLOBAL);
 
         var old = [PLCameraAlbum respondsToSelector:@selector(sharedInstance)];
         dlopen("/System/Library/PrivateFrameworks/PhotoLibrary.framework/PhotoLibrary", RTLD_GLOBAL);
 
         var old = [PLCameraAlbum respondsToSelector:@selector(sharedInstance)];
                     break;
             }
 
                     break;
             }
 
-        document.write('<img src="' + jpeg + '"/>');
+        document.write('<img src="' + jpeg.toString() + '"/>');
     </script></div>
 </body></html>
     </script></div>
 </body></html>