Bug 77543

Summary: Web Inspector: Support hiding scripts panel debug sidebar.
Product: WebKit Reporter: Vsevolod Vlasov <vsevik>
Component: Web Inspector (Deprecated)Assignee: Vsevolod Vlasov <vsevik>
Status: RESOLVED FIXED    
Severity: Normal CC: apavlov, bweinstein, joepeck, keishi, loislo, pfeldman, pmuellr, rik, timothy, yurys
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Bug Depends on:    
Bug Blocks: 75093    
Attachments:
Description Flags
Screenshot with hidden navigator.
none
Screenshot with pinned navigator.
none
Screenshot with navigator overlay.
none
Patch pfeldman: review+

Description Vsevolod Vlasov 2012-02-01 04:20:13 PST
Support hiding scripts panel debug sidebar.
Comment 1 Vsevolod Vlasov 2012-02-08 10:33:01 PST
Created attachment 126113 [details]
Screenshot with hidden navigator.
Comment 2 Vsevolod Vlasov 2012-02-08 10:33:18 PST
Created attachment 126114 [details]
Screenshot with pinned navigator.
Comment 3 Vsevolod Vlasov 2012-02-08 10:33:35 PST
Created attachment 126115 [details]
Screenshot with navigator overlay.
Comment 4 Vsevolod Vlasov 2012-02-08 11:09:55 PST
Created attachment 126122 [details]
Patch
Comment 5 Patrick Mueller 2012-02-08 11:13:29 PST
Screenshot with hidden navigator
--------------------------------
+100!

Screenshot with pinned navigator
--------------------------------
+100!

Screenshot with navigator overlay
--------------------------------
Hideous beyond belief!  Why would some do such a thing?  :-)  I'd vote for not including it, it's just more code that has to be maintained.
Comment 6 Vsevolod Vlasov 2012-02-08 11:38:34 PST
> Hideous beyond belief!  Why would some do such a thing?  :-)  I'd vote for not including it, it's just more code that has to be maintained.

We need a mode similar to the current file selector implementation, in which file selector is modal and closes upon selection.
Comment 7 Vsevolod Vlasov 2012-02-08 11:41:44 PST
This is needed both for users with small screen and for debugging with undocked inspector, that is usually not so wide.
Comment 8 Patrick Mueller 2012-02-08 14:48:49 PST
(In reply to comment #6)
> We need a mode similar to the current file selector implementation, in which file selector is modal and closes upon selection.

Why does this NEED to be MODAL?  I'm not familiar with the modal file selector (or even what is).  What user gesture or event triggers the overlay into this mode?

(In reply to comment #7)
> This is needed both for users with small screen and for debugging with undocked inspector, that is usually not so wide.

The "small screen" rationale I can buy.  Must be a pretty small screen though.  Those subpanels on the right (Watch Expressions, etc) sure look like they're taking up a lot of room.  You've seen Xcode's shifting bottom panels thing before, right?  Seems like a better ui paradigm to me.

Besides, with Remote Web Inspector, who needs to debug on a small screen? :-)

OTOH, Eclipse has a similar capability called Fast Views (which I never used).  And iPad has modal pop overs (which I can't stand).
Comment 9 Vsevolod Vlasov 2012-02-09 03:25:26 PST
(In reply to comment #8)
> (In reply to comment #6)
> > We need a mode similar to the current file selector implementation, in which file selector is modal and closes upon selection.
> 
> Why does this NEED to be MODAL?  I'm not familiar with the modal file selector (or even what is).  What user gesture or event triggers the overlay into this mode?

We don't want to regress inspector's behavior, so our goal was to keep it as similar to the current file selector as possible.
Currently it is modal, meaning once you click on combo box you can't do anything until you close it by selecting a file or clicking elsewhere.

> (In reply to comment #7)
> > This is needed both for users with small screen and for debugging with undocked inspector, that is usually not so wide.
> 
> The "small screen" rationale I can buy.  Must be a pretty small screen though.  
We have already used current implementation of navigator (it can not be hidden now) for some time and it takes too much space in undocked or side-by-side/dock-to-right modes.

> Those subpanels on the right (Watch Expressions, etc) sure look like they're taking up a lot of room.  You've seen Xcode's shifting bottom panels thing before, right?  Seems like a better ui paradigm to me.
I am not sure what do you mean here, but it feels like another feature to me. Could you please file a new bug about watch expressions layout providing some more description and screenshots?
> 
> Besides, with Remote Web Inspector, who needs to debug on a small screen? :-)
Not everybody uses Web Inspector this remotely though.


> OTOH, Eclipse has a similar capability called Fast Views (which I never used).  And iPad has modal pop overs (which I can't stand).
This overlay was inspired by Eclipse's Fast Views indeed. I haven't used it in eclipse either because I usually open eclipse full screen on a wide monitor, while inspector is often used in small undocked window.
Comment 10 Pavel Feldman 2012-02-09 03:55:51 PST
Comment on attachment 126122 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=126122&action=review

> Source/WebCore/inspector/front-end/SidebarOverlay.js:40
> +    WebInspector.DialogDelegate.call(this);

Overlay is not a dialog. We should come up with a better abstraction.

> Source/WebCore/inspector/front-end/SidebarOverlay.js:68
> +        this._view.markAsRoot();

Why do you mark this view as root? It could have a valid element ancestor.
Comment 11 Vsevolod Vlasov 2012-02-09 06:24:01 PST
(In reply to comment #10)
> (From update of attachment 126122 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=126122&action=review
> 
> > Source/WebCore/inspector/front-end/SidebarOverlay.js:40
> > +    WebInspector.DialogDelegate.call(this);
> 
> Overlay is not a dialog. We should come up with a better abstraction.

I'll take care of that separately, I filed https://bugs.webkit.org/show_bug.cgi?id=78229 for that.

> > Source/WebCore/inspector/front-end/SidebarOverlay.js:68
> > +        this._view.markAsRoot();
> 
> Why do you mark this view as root? It could have a valid element ancestor.
In current implementation Dialog creates a glass pane that is a child of body element, so it does not have any ancestor views. Drawer also needs to call markAsRoot(). I'll have a look on that separately to see how this could be addressed.
Comment 12 Vsevolod Vlasov 2012-02-09 06:37:45 PST
Committed r107235: <http://trac.webkit.org/changeset/107235>