!7 p { BufferedImage img = cast time(f singleImageFromLastWebcam); ImageSurface is = showImage("Will upload in 3! Close window to stop this.", img); sleepSeconds(3); if (!is.isShowing()) { print("Upload cancelled."); ret; } setFrameTitle(is, "Uploading..."); S imageURL = uploadToImageServer(img, "User webcam image"); print("Image uploaded as " + imageURL); setFrameTitle(is, "Posting..."); if (postToStefansChat("[IMAGE] " + imageURL)) setFrameTitle(is, print("Posted image to chat!")); else setFrameTitle(is, print("Could not post image.")); }