Web Inspector: [Network] Ordering of cookies displayed is nondeterministic.
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 18 Dec 2012 12:57:16 +0000 (12:57 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 18 Dec 2012 12:57:16 +0000 (12:57 +0000)
https://bugs.webkit.org/show_bug.cgi?id=105272

Patch by Eugene Klyuchnikov <eustas@chromium.org> on 2012-12-18
Reviewed by Alexander Pavlov.

This patch fixes double-selection of request and sets default ordering
of cookies.

* inspector/front-end/CookiesTable.js: By default sort by name.
* inspector/front-end/NetworkPanel.js: Remove redundant member, make
rows "not-selectable", activate request selection on "mouse-down".

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

Source/WebCore/ChangeLog
Source/WebCore/inspector/front-end/CookiesTable.js
Source/WebCore/inspector/front-end/NetworkPanel.js

index fa9cad3..d6e8fd3 100644 (file)
@@ -1,3 +1,17 @@
+2012-12-18  Eugene Klyuchnikov  <eustas@chromium.org>
+
+        Web Inspector: [Network] Ordering of cookies displayed is nondeterministic.
+        https://bugs.webkit.org/show_bug.cgi?id=105272
+
+        Reviewed by Alexander Pavlov.
+
+        This patch fixes double-selection of request and sets default ordering
+        of cookies.
+
+        * inspector/front-end/CookiesTable.js: By default sort by name.
+        * inspector/front-end/NetworkPanel.js: Remove redundant member, make
+        rows "not-selectable", activate request selection on "mouse-down".
+
 2012-12-18  Tommy Widenflycht  <tommyw@chromium.org>
 
         [JSC] Refactoring CodeGeneratorJS.pm to simplify adding support for overloaded constructors
index 02457aa..59712f6 100644 (file)
@@ -45,6 +45,7 @@ WebInspector.CookiesTable = function(expandable, deleteCallback, refreshCallback
     columns[0].sortable = true;
     columns[0].disclosure = expandable;
     columns[0].width = "24%";
+    columns[0].sort = "ascending";
     columns[1].title = WebInspector.UIString("Value");
     columns[1].sortable = true;
     columns[1].width = "34%";
index 0522313..49937c5 100644 (file)
@@ -48,7 +48,6 @@ WebInspector.NetworkLogView = function()
     WebInspector.View.call(this);
     this.registerRequiredCSS("networkLogView.css");
 
-    this._allowRequestSelection = false;
     this._requests = [];
     this._requestsById = {};
     this._requestsByURL = {};
@@ -1489,7 +1488,6 @@ WebInspector.NetworkPanel.prototype = {
 
         this._networkLogView.switchToDetailedView();
         this._networkLogView.allowPopover = true;
-        this._networkLogView._allowRequestSelection = false;
     },
 
     _toggleViewingRequestMode: function()
@@ -1501,7 +1499,6 @@ WebInspector.NetworkPanel.prototype = {
         this.element.addStyleClass("viewing-resource");
         this.splitView.showMainElement();
         this._networkLogView.allowPopover = false;
-        this._networkLogView._allowRequestSelection = true;
         this._networkLogView.switchToBriefView();
     },
 
@@ -1846,8 +1843,9 @@ WebInspector.NetworkDataGridNode.prototype = {
         this._sizeCell = this._createDivInTD("size");
         this._timeCell = this._createDivInTD("time");
         this._createTimelineCell();
-        this._nameCell.addEventListener("click", this.select.bind(this), false);
+        this._nameCell.addEventListener("mousedown", this.select.bind(this), false);
         this._nameCell.addEventListener("dblclick", this._openInNewTab.bind(this), false);
+        this.selectable = false;
     },
 
     isFilteredOut: function()
@@ -1884,11 +1882,6 @@ WebInspector.NetworkDataGridNode.prototype = {
         InspectorFrontendHost.openInNewTab(this._request.url);
     },
 
-    get selectable()
-    {
-        return this._parentView._allowRequestSelection && !this.isFilteredOut();
-    },
-
     _createDivInTD: function(columnIdentifier)
     {
         var td = document.createElement("td");