WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
107263
Web Inspector: Allow SplitView to change orientation after the construction
https://bugs.webkit.org/show_bug.cgi?id=107263
Summary
Web Inspector: Allow SplitView to change orientation after the construction
Vladislav Kaznacheev
Reported
2013-01-18 05:07:58 PST
Once WebInspector.SplitView object is created its orientation cannot be changed. This needs to change to make the layout more flexible (see
https://bugs.webkit.org/show_bug.cgi?id=107129
). An alternative solution is to recreate WebInspector.SplitView or WebInspector.SidebarView with a different orientation which would require extensive changes at every client of said classes.
Attachments
Patch
(12.22 KB, patch)
2013-01-18 05:27 PST
,
Vladislav Kaznacheev
no flags
Details
Formatted Diff
Diff
Patch
(12.35 KB, patch)
2013-01-18 07:10 PST
,
Vladislav Kaznacheev
no flags
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Vladislav Kaznacheev
Comment 1
2013-01-18 05:27:23 PST
Created
attachment 183429
[details]
Patch
Pavel Feldman
Comment 2
2013-01-18 06:01:40 PST
Comment on
attachment 183429
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=183429&action=review
Few nits and it is good to go.
> Source/WebCore/inspector/front-end/SplitView.js:45 > this._firstElement = document.createElement("div");
this._firstElement = this.element.createChild("div", "split-view-contents"); will do the same.
> Source/WebCore/inspector/front-end/SplitView.js:50 > + this._secondElement.className = "split-view-contents";
ditto
> Source/WebCore/inspector/front-end/SplitView.js:54 > + this._resizerElement.className = "split-view-resizer";
ditto
> Source/WebCore/inspector/front-end/SplitView.js:81 > + setIsVertical: function(isVertical)
setVertical
> Source/WebCore/inspector/front-end/SplitView.js:95 > + _innerSetIsVertical: function(isVertical)
_innerSetVertical
> Source/WebCore/inspector/front-end/SplitView.js:281 > + _updateTotalSize: function() {
{ on the next line
> Source/WebCore/inspector/front-end/SplitView.js:295 > + this._resizerElement.style.removeProperty("left");
This might look better as a part of removeAllLayoutProperties
> Source/WebCore/inspector/front-end/SplitView.js:396 > + _onDragStart: function(event) {
{ on the next line
> Source/WebCore/inspector/front-end/SplitView.js:405 > + if (!this._sidebarSizeSettingName)
4 space indent please
> Source/WebCore/inspector/front-end/SplitView.js:421 > + return (sizeSetting ? sizeSetting.get() : 0 ) || (this._isVertical ? this._savedSidebarWidth : this._savedSidebarHeight);
no space after 0, please split this into two lines?
> Source/WebCore/inspector/front-end/SplitView.js:430 > + this._savedSidebarWidth = size;
It is unfortunate split is now Width/Height aware, but I don't see a way to make it simpler. Maintaining both settings at all times and making settingName required is probably a good thing that will save on some lines here as well.
Vladislav Kaznacheev
Comment 3
2013-01-18 07:10:37 PST
Created
attachment 183445
[details]
Patch
Pavel Feldman
Comment 4
2013-01-20 23:31:55 PST
Comment on
attachment 183445
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=183445&action=review
> Source/WebCore/inspector/front-end/SplitView.js:46 > +
Now that each element takes one line to initialize, we no longer need whitespace between blocks.
WebKit Review Bot
Comment 5
2013-01-20 23:39:42 PST
Comment on
attachment 183445
[details]
Patch Clearing flags on attachment: 183445 Committed
r140304
: <
http://trac.webkit.org/changeset/140304
>
WebKit Review Bot
Comment 6
2013-01-20 23:39:45 PST
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug