Adds the ability to enter multi-line commands in the console by holding the
authortimothy@apple.com <timothy@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 21 Apr 2008 20:54:55 +0000 (20:54 +0000)
committertimothy@apple.com <timothy@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 21 Apr 2008 20:54:55 +0000 (20:54 +0000)
alt/option key when pressing enter/return.

https://bugs.webkit.org/show_bug.cgi?id=18454

Reviewed by Darin Adler.

* page/inspector/Console.js:
(WebInspector.Console.prototype._enterKeyPressed): Return early if the
alt/option key is held when enter is pressed.
* page/inspector/inspector.css:
(.console-message-text): Added. Set white-space: pre-wrap.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@32346 268f45cc-cd09-0410-ab3c-d52691b4dbfc

WebCore/ChangeLog
WebCore/page/inspector/Console.js
WebCore/page/inspector/inspector.css

index 6603510..24f2e7c 100644 (file)
@@ -1,5 +1,20 @@
 2008-04-21  Timothy Hatcher  <timothy@apple.com>
 
+        Adds the ability to enter multi-line commands in the console by holding the
+        alt/option key when pressing enter/return.
+
+        https://bugs.webkit.org/show_bug.cgi?id=18454
+
+        Reviewed by Darin Adler.
+
+        * page/inspector/Console.js:
+        (WebInspector.Console.prototype._enterKeyPressed): Return early if the
+        alt/option key is held when enter is pressed.
+        * page/inspector/inspector.css:
+        (.console-message-text): Added. Set white-space: pre-wrap.
+
+2008-04-21  Timothy Hatcher  <timothy@apple.com>
+
         Fixes the bug where the Database table names do not update when
         running the CREATE TABLE or DROP TABLE queries. Also makes the
         table names update every time the database is collapsed and expanded.
index d41a8b0..ebac99b 100644 (file)
@@ -307,6 +307,9 @@ WebInspector.Console.prototype = {
 
     _enterKeyPressed: function(event)
     {
+        if (event.altKey)
+            return;
+
         event.preventDefault();
         event.stopPropagation();
 
index 070dcda..db67554 100644 (file)
@@ -406,6 +406,10 @@ body.console-visible #console {
     -webkit-user-select: none;
 }
 
+.console-message-text {
+    white-space: pre-wrap;
+}
+
 .console-error-level .console-message-text {
     color: red;
 }