Changes

Jump to: navigation, search

Labs/Bespin/Commands/Pastebox

6 bytes added, 21:46, 26 February 2009
no edit summary
var pbw = window.open("", "PasteBox", "width=400,height=300");
pbw.document.open();
pbw.document.write("<h3>Paste Something in this textbox <button
onclick='window.opener.pasteboxfinish(window)'>Paste</button><
/h3>" + "<textarea id='tp' style='width: 100%;height: 80%'></textarea><br>");
pbw.document.close();
pbw.document.getElementById("tp").value = self.editor.model.getDocument();
 
window.pasteboxfinish = function(pw){
self.editor.model.insertDocument(pw.document.getElementById("tp").value);
_commandLine.showInfo("Done! It hopefully worked!");
}
}
}
355
edits

Navigation menu