Closed Bug 608717 Opened 10 years ago Closed 10 years ago

Add CAN_DRAW_IN_TITLEBAR since MENUBAR_CAN_AUTOHIDE is overloaded

Categories

(Firefox :: General, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
Firefox 4.0b8

People

(Reporter: dao, Assigned: wgianopoulos)

References

Details

Attachments

(1 file, 2 obsolete files)

The patch in bug 585370 does this, but it would be wise to do it separately because a) it makes sense regardless of that bug and b) it will make the patch in that bug less scary.
Taking -> I will appropriately divide that patch up between both bugs.
Assignee: nobody → bill
Attached patch patch v1 (obsolete) — Splinter Review
I will ask for review once this passes my tests.
Status: NEW → ASSIGNED
Blocks: 585370
Attached patch patch v2-fix nested ifdefs (obsolete) — Splinter Review
Attachment #487458 - Attachment is obsolete: true
Attachment #487501 - Flags: review?(dao)
Attachment #487501 - Flags: review?(dao) → review+
Comment on attachment 487501 [details] [diff] [review]
patch v2-fix nested ifdefs

>--- a/browser/base/content/browser.js
>+++ b/browser/base/content/browser.js
>@@ -4720,22 +4720,26 @@ var TabsOnTop = {
> function updateAppButtonDisplay() {
>   var displayAppButton =
>     !gInPrintPreviewMode &&
>     window.menubar.visible &&
>     document.getElementById("toolbar-menubar").getAttribute("autohide") == "true";
> 
>   document.getElementById("titlebar").hidden = !displayAppButton;
> 
>+#ifdef CAN_DRAW_IN_TITLEBAR
>   if (displayAppButton)
>     document.documentElement.setAttribute("chromemargin", "0,-1,-1,-1");
>   else
>     document.documentElement.removeAttribute("chromemargin");
>-}
>-
>+#endif
>+}
>+#endif

document.getElementById("titlebar").hidden = !displayAppButton; should depend on CAN_DRAW_IN_TITLEBAR too.
(In reply to comment #4) 
> document.getElementById("titlebar").hidden = !displayAppButton; should depend
> on CAN_DRAW_IN_TITLEBAR too.

Of course it should.
Attached patch patch v3;r=daoSplinter Review
With that fixed.

Carrying review forward.
Attachment #487501 - Attachment is obsolete: true
Attachment #487509 - Flags: approval2.0?
Attachment #487509 - Flags: approval2.0?
http://hg.mozilla.org/mozilla-central/rev/7ca426c55d9b
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 4.0b8
You need to log in before you can comment on or make changes to this bug.