Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(63)

Unified Diff: Source/WebCore/inspector/front-end/StylesSidebarPane.js

Issue 6596106: Merge 76913 - 2011-01-27 Alexander Pavlov <apavlov@chromium.org>... (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/648/
Patch Set: Created 9 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/WebCore/inspector/front-end/StylesSidebarPane.js
===================================================================
--- Source/WebCore/inspector/front-end/StylesSidebarPane.js (revision 80114)
+++ Source/WebCore/inspector/front-end/StylesSidebarPane.js (working copy)
@@ -1709,10 +1709,6 @@
editingEnded: function(context)
{
- if (this._prompt) {
- this._prompt.removeFromElement();
- delete this._prompt;
- }
this.hasChildren = context.hasChildren;
if (context.expanded)
this.expand();
@@ -1727,6 +1723,7 @@
editingCancelled: function(element, context)
{
+ this._removePrompt();
if ("originalPropertyText" in this)
this.applyStyleText(this.originalPropertyText, true);
else {
@@ -1742,6 +1739,7 @@
editingCommitted: function(element, userInput, previousContent, context, moveDirection)
{
+ this._removePrompt();
this.editingEnded(context);
var isEditingName = context.isEditingName;
@@ -1839,6 +1837,15 @@
}
},
+ _removePrompt: function()
+ {
+ // BUG 53242. This cannot go into editingEnded(), as it should always happen first for any editing outcome.
+ if (this._prompt) {
+ this._prompt.removeFromElement();
+ delete this._prompt;
+ }
+ },
+
_hasBeenAppliedToPageViaUpDown: function()
{
// New properties applied via up/down have an originalPropertyText and will be deleted later
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698