Closed Bug 613199 Opened 14 years ago Closed 14 years ago

URLBar FixUps [2010-11]

Categories

(SeaMonkey :: Location Bar, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
seamonkey2.1b2

People

(Reporter: philip.chee, Assigned: philip.chee)

References

Details

Attachments

(1 file, 1 obsolete file)

Port more Firefox URLBar patches now that Bug 599833 has introduced a suitable framework.
Attached patch Patch v1.0 [CopyCut] (obsolete) — Splinter Review
This patch does the following: 1. Port Bug 607518 (After performed Paste & Go and Paste & Search , Ctrl+Z makes blank, Ctrl+Z is necessary twice to undo it.) 2. Add copy and cut to the urlBar custom controller. 3. Implement "_getSelectedValueForClipboard() which fixes Bug 480537 (copied URL's from location bar are decoded and not meet RFC.) > --- a/suite/browser/urlbarBindings.xml > > case "cmd_pasteAndGo": > - this.value = ""; > + this.select(); c.f. https://bugzilla.mozilla.org/show_bug.cgi?id=473368#c3
Attachment #491765 - Flags: review?(neil)
Comment on attachment 491765 [details] [diff] [review] Patch v1.0 [CopyCut] > _fireEvent: this._fireEvent.bind(this), Not sure we ended up using this ;-) >+ if (!this._editItemsController.supportsCommand(aCommand)) >+ return false; Not sure why we need this, we won't get called for an unsupported command. >+ let start = this.selectionStart; >+ let end = this.selectionEnd; >+ this.value = this.inputField.value.substring(0, start) + >+ this.inputField.value.substring(end); >+ this.selectionStart = this.selectionEnd = start; >+ SetPageProxyState("invalid", null); IIRC this can all be replaced by goDoCommand("cmd_delete"); Also, this should happen after the copy.
Attachment #491765 - Flags: review?(neil)
> neil@parkwaycc.co.uk 2010-11-19 05:33:46 PST > > > _fireEvent: this._fireEvent.bind(this), > Not sure we ended up using this ;-) Removed. > >+ if (!this._editItemsController.supportsCommand(aCommand)) > >+ return false; > Not sure why we need this, we won't get called for an unsupported command. Removed. > >+ let start = this.selectionStart; > >+ let end = this.selectionEnd; > >+ this.value = this.inputField.value.substring(0, start) + > >+ this.inputField.value.substring(end); > >+ this.selectionStart = this.selectionEnd = start; > >+ SetPageProxyState("invalid", null); > IIRC this can all be replaced by goDoCommand("cmd_delete"); Fixed. > Also, this should happen after the copy. Fixed.
Attachment #491765 - Attachment is obsolete: true
Attachment #491864 - Flags: review?(neil)
Comment on attachment 491864 [details] [diff] [review] Patch v1.1 [CopyCut] >+ val = uri.spec; >+ >+ // Parentheses are known to confuse third-party applications (bug 458565). >+ val = val.replace(/[()]/g, function (c) escape(c)); [If it wasn't for the comment this would fit on one line...]
Attachment #491864 - Flags: review?(neil) → review+
Part1. Followup to PasteAndGo, implement copy and cut, and fix Bug 480537. Checked in to comm-central http://hg.mozilla.org/comm-central/rev/2ceaa8229eb1
Blocks: 480537
It's December. Closing. and moving subsequent work to other bugs :D
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Target Milestone: --- → seamonkey2.1b1
Target Milestone: seamonkey2.1b1 → seamonkey2.1b2
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: