Closed Bug 856008 Opened 12 years ago Closed 12 years ago

Move ContentAreaObserver out of browser.js and clean the code up a bit

Categories

(Firefox for Metro Graveyard :: General, defect)

x86_64
Windows 8.1
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
Firefox 23

People

(Reporter: jimm, Assigned: jimm)

References

Details

Attachments

(2 files, 1 obsolete file)

No description provided.
Attached patch move patch (obsolete) — Splinter Review
Attachment #731137 - Attachment is patch: true
Attachment #731137 - Attachment is obsolete: true
Attached patch cleanup workSplinter Review
Comment on attachment 731138 [details] [diff] [review] move cao out of browser.js This is a simple move of code with an added comment header as well in the file. No functional changes.
Attachment #731138 - Flags: review?(sfoster)
Comment on attachment 731139 [details] [diff] [review] cleanup work Some cleanup work and reorg of the code. One minor functional change here, I've remove the viewable-height and width classes from browsers for now. It's causing annoying shifting when the soft keyboard comes up. Form positioning will be address in follow up work.
Attachment #731139 - Flags: review?(sfoster)
Blocks: 855362
Comment on attachment 731138 [details] [diff] [review] move cao out of browser.js Review of attachment 731138 [details] [diff] [review]: ----------------------------------------------------------------- Looks good.
Attachment #731138 - Flags: review?(sfoster) → review+
Comment on attachment 731139 [details] [diff] [review] cleanup work I can't claim to really understand the implications of removing those width/height rules. Forwarding to Matt.
Attachment #731139 - Flags: review?(sfoster)
Attachment #731139 - Flags: review?(mbrubeck)
Attachment #731139 - Flags: feedback+
Comment on attachment 731139 [details] [diff] [review] cleanup work Review of attachment 731139 [details] [diff] [review]: ----------------------------------------------------------------- ::: browser/metro/base/content/ContentAreaObserver.js @@ +141,5 @@ > + this._disatchBrowserEvent("ViewableSizeChanged"); > + }, > + > + onBrowserCreated: function onBrowserCreated(aBrowser) { > + aBrowser.setAttribute("class", "content-width content-height"); Let's do this instead, so we can't end up accidentally overwriting classes added elsewhere: aBrowser.classList.add("content-width"); aBrowser.classList.add("content-height"); @@ +216,5 @@ > + _updateTabs: function _updateTabs(aWidth, aHeight) { > + for (let idx = Browser.tabs.length - 1; idx >=0; idx--) { > + let tab = Browser.tabs[idx]; > + let oldContentWindowWidth = tab.browser.contentWindowWidth; > + tab.updateViewportSize(aWidth, aHeight); // contentWindowWidth may change here. This whole function currently does nothing; I think we should just remove it (including the associated functions in browser.js, though that can be a separate patch). When we want to re-add support for <meta name=viewport> we should use the platform code instead (bug 716575). @@ +233,5 @@ > + > + _debugDumpDims: function _debugDumpDims() { > + let width = parseInt(this.styles["window-width"].width); > + let height = parseInt(this.styles["window-height"].height); > + Util.dumpLn("window:", width, height); You may want to remove this debug code before checkin.
Attachment #731139 - Flags: review?(mbrubeck) → review+
No longer blocks: 855237
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 23
OS: Windows 8 Metro → Windows 8.1
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: