WebKit Bugzilla
Attachment 358553 Details for
Bug 177676
: Web Inspector: Styles: Undo reverts all changes at once
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
patch.txt (text/plain), 2.91 KB, created by
Nikita Vasilyev
on 2019-01-07 16:36:01 PST
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Nikita Vasilyev
Created:
2019-01-07 16:36:01 PST
Size:
2.91 KB
patch
obsolete
>diff --git a/Source/WebInspectorUI/ChangeLog b/Source/WebInspectorUI/ChangeLog >index 710ce75ed41..2196d0d782d 100644 >--- a/Source/WebInspectorUI/ChangeLog >+++ b/Source/WebInspectorUI/ChangeLog >@@ -1,3 +1,19 @@ >+2019-01-07 Nikita Vasilyev <nvasilyev@apple.com> >+ >+ Web Inspector: Styles: Undo reverts all changes at once >+ https://bugs.webkit.org/show_bug.cgi?id=177676 >+ <rdar://problem/34745031> >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Command-Z used to revert all changes at once because Web Inspector never >+ set any history checkpoints in the style editor. >+ >+ * UserInterface/Views/SpreadsheetStyleProperty.js: >+ (WI.SpreadsheetStyleProperty.prototype.spreadsheetTextFieldDidBlur): >+ * UserInterface/Views/SpreadsheetTextField.js: >+ (WI.SpreadsheetTextField.prototype._handleBlur): >+ > 2019-01-04 Devin Rousso <drousso@apple.com> > > Web Inspector: Audit: disable breakpoints when running Audit >diff --git a/Source/WebInspectorUI/UserInterface/Views/SpreadsheetStyleProperty.js b/Source/WebInspectorUI/UserInterface/Views/SpreadsheetStyleProperty.js >index d454fa6020f..87b0b09d47c 100644 >--- a/Source/WebInspectorUI/UserInterface/Views/SpreadsheetStyleProperty.js >+++ b/Source/WebInspectorUI/UserInterface/Views/SpreadsheetStyleProperty.js >@@ -372,7 +372,7 @@ WI.SpreadsheetStyleProperty = class SpreadsheetStyleProperty extends WI.Object > this.remove(); > } > >- spreadsheetTextFieldDidBlur(textField, event) >+ spreadsheetTextFieldDidBlur(textField, event, hasChanged) > { > let focusedOutsideThisProperty = event.relatedTarget !== this._nameElement && event.relatedTarget !== this._valueElement; > if (focusedOutsideThisProperty && (!this._nameTextField.value.trim() || !this._valueTextField.value.trim())) { >@@ -385,6 +385,9 @@ WI.SpreadsheetStyleProperty = class SpreadsheetStyleProperty extends WI.Object > > if (typeof this._delegate.spreadsheetStylePropertyFocusMoved === "function") > this._delegate.spreadsheetStylePropertyFocusMoved(this, {direction: null}); >+ >+ if (hasChanged && window.DOMAgent) >+ DOMAgent.markUndoableState(); > } > > spreadsheetTextFieldDidBackspace(textField) >diff --git a/Source/WebInspectorUI/UserInterface/Views/SpreadsheetTextField.js b/Source/WebInspectorUI/UserInterface/Views/SpreadsheetTextField.js >index 109bbce34b0..ee6cb66c181 100644 >--- a/Source/WebInspectorUI/UserInterface/Views/SpreadsheetTextField.js >+++ b/Source/WebInspectorUI/UserInterface/Views/SpreadsheetTextField.js >@@ -220,7 +220,8 @@ WI.SpreadsheetTextField = class SpreadsheetTextField > this._applyCompletionHint(); > this.discardCompletion(); > >- this._delegate.spreadsheetTextFieldDidBlur(this, event); >+ let hasChanged = this._valueBeforeEditing !== this.value; >+ this._delegate.spreadsheetTextFieldDidBlur(this, event, hasChanged); > this.stopEditing(); > } >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
hi
:
review+
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 177676
:
322219
|
358553
|
358556
|
358661