The default bug view has changed. See this FAQ.

GCLI help output does not display the first time

RESOLVED FIXED in Firefox 16

Status

()

Firefox
Developer Tools
P1
normal
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: Kevin Dangoor, Assigned: jwalker)

Tracking

14 Branch
Firefox 16
x86
Mac OS X
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment, 1 obsolete attachment)

(Reporter)

Description

5 years ago
STR:

1. With Developer Toolbar closed, press the keyboard shortcut to open the toolbar
2. type "help" and hit enter
3. note the lack of output
4. type "help" and hit enter again
5. ahh, there it is!

expected:

output at step 3

This is in the 2012-06-04 Nightly on Mac.
(Reporter)

Updated

5 years ago
Assignee: jwalker → nobody
Thank you, I meant to file this last weekend but it slipped my mind.
Priority: -- → P1
Summary: [gcli] help output does not display the first time → GCLI help output does not display the first time
Target Milestone: --- → Firefox 16
Hey Neil - I wonder if you could help with a panel problem.

2 things to add to Kevin's STR:
- the pref to enable the toolbar is: devtools.toolbar.enabled=true
- this happens on Mac/Linux but not Windows

If you open browser/devtools/shared/DeveloperToolbar.jsm, line 354, you can see the call to openPopup, it is called at the right time on all OSes.

Relevant to the discussion is the _resize() function just below show(), although from adding debug to that function, it looks like sane values are being used for the height/width (i.e. 265x275) and those numbers are the same whether the output is displayed or not.

Thanks.

Comment 3

5 years ago
The panel is first resized to one size, then some left margin is being added to it, then the panel is resized to accomodate this margin.

<panel xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" id="gcli-tooltip" class="gcli-panel" noautofocus="true" noautohide="true"><iframe xmlns="http://www.w3.org/1999/xhtml" height="0" id="gcli-tooltip-frame" src="chrome://browser/content/devtools/gclitooltip.xhtml" flex="1" style="margin-left: 10px;"></iframe></panel>

Maybe you mean to add the margin on the panel itself, or in the iframe's content?

Is the margin or its size dependent on the size of the panel? If not, it should be applied before opening the panel.

Comment 4

5 years ago
Er, that comment was meant for bug 760450

Comment 5

5 years ago
Why is the panel being resized three times when being opened?
(In reply to Neil Deakin from comment #5)
> Why is the panel being resized three times when being opened?

Twice?

    this._panel.ownerDocument.defaultView.setTimeout(function() {
      this._resize();
    }.bind(this), 0);
  
    this._panel.openPopup(this._input, "before_start", 0, 0, false, false, null);
    this._resize();
  
    this._input.focus();

Displaying the panel causes it to re-flow, which can change the size it should be,
so we need to resize the iframe after the panel has displayed.

Comment 7

5 years ago
The panel is also being resized at:

  else if (aEvent.type == "resize") {
    this.outputPanel._resize();
  }
(In reply to Neil Deakin from comment #7)
> The panel is also being resized at:
> 
>   else if (aEvent.type == "resize") {
>     this.outputPanel._resize();
>   }

Ah, right that's so that when the window is resized, we ensure the output panel is the same width as the input area.
Blocks: 745773
Neil - I'd really like to get this fixed, can I get you any more info to help work out what's wrong?

Comment 10

5 years ago
I think I tested commenting out the resize I mentioned in comment 7 and the size worked fine. You might want to see if there's a way to skip that in this case. Possibly by seeing if the window really did change size.
Blocks: 768150
Created attachment 636424 [details] [diff] [review]
Upload 1
Assignee: nobody → jwalker
Status: NEW → ASSIGNED
Attachment #636424 - Flags: review?(dcamp)

Updated

5 years ago
Attachment #636424 - Flags: review?(dcamp) → review+
https://tbpl.mozilla.org/?tree=Try&rev=986cd926eb22
Created attachment 637439 [details] [diff] [review]
Upload 2

The previous version of this patch was done in somewhat of a hurry, this is a slightly better version of the same thing.
Attachment #636424 - Attachment is obsolete: true
Attachment #637439 - Flags: review?(dcamp)

Updated

5 years ago
Attachment #637439 - Flags: review?(dcamp) → review+
https://tbpl.mozilla.org/?tree=Try&rev=c11630ac6eb2
https://tbpl.mozilla.org/?tree=Try&rev=59729f63ee39
https://tbpl.mozilla.org/?tree=Fx-Team&rev=124c0182df1c
Whiteboard: [fixed-in-fx-team]
https://hg.mozilla.org/mozilla-central/rev/ea890a6eed56
Status: ASSIGNED → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
Whiteboard: [fixed-in-fx-team]
This issue has returned.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Actually it's not a problem with this bug.
Status: REOPENED → RESOLVED
Last Resolved: 5 years ago5 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.