WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
101978
Web Inspector: Fix docking behaviour on Windows.
https://bugs.webkit.org/show_bug.cgi?id=101978
Summary
Web Inspector: Fix docking behaviour on Windows.
Roger Fong
Reported
2012-11-12 13:43:39 PST
There are a number of problems for docking behaviour on Windows. For starters it does not ever constrain the inspectors size properly while docked. It also does not properly set the whether or not the inspector can be docked/undocked.
Attachments
patch
(3.77 KB, patch)
2012-11-12 13:45 PST
,
Roger Fong
bweinstein
: review-
Details
Formatted Diff
Diff
revised patch
(4.17 KB, patch)
2012-11-12 15:49 PST
,
Roger Fong
bweinstein
: review+
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Roger Fong
Comment 1
2012-11-12 13:45:21 PST
Created
attachment 173710
[details]
patch
Tim Horton
Comment 2
2012-11-12 14:17:10 PST
Comment on
attachment 173710
[details]
patch View in context:
https://bugs.webkit.org/attachment.cgi?id=173710&action=review
> Source/WebCore/inspector/InspectorFrontendClientLocal.cpp:143 > + // Call setDockingUnavailable before bringToFront. If we display the inspector's HWND first it causes the call to canAttachWindow to return the wrong result.
I wonder if you can talk about this in a more generic way. Using the word HWND in cross-platform code is weird (at the very least, note that this is Windows only). Also, what/why does it cause canAttachWindow to return the wrong result?
> Source/WebKit/win/ChangeLog:8 > + There are a number of problems for docking behaviour on Windows.
s/for/with/
> Source/WebKit/win/ChangeLog:9 > + For starters it does not ever constrain the inspectors size properly while docked.
s/For starters/For starters,/ s/inspectors/inspector's/
> Source/WebKit/win/WebCoreSupport/WebInspectorClient.cpp:296 > + // We need to set the attached windows height before we actually attach the window.
s/windows/window's/
> Source/WebKit/win/WebCoreSupport/WebInspectorClient.cpp:297 > + // Make sure that m_attached is true so that setAttachedWindowHeight succeeds.
s/succeeds/doesn't return early/?
Brian Weinstein
Comment 3
2012-11-12 14:44:36 PST
Comment on
attachment 173710
[details]
patch View in context:
https://bugs.webkit.org/attachment.cgi?id=173710&action=review
I'd like to see one more version with Tim's comments and mine addressed. Patch looks good though.
> Source/WebKit/win/ChangeLog:4 > +
https://bugs.webkit.org/show_bug.cgi?id=100000
100000!!!
> Source/WebKit/win/WebCoreSupport/WebInspectorClient.cpp:258 > + restoreAttachedWindowHeight();
A comment explaining why we are restoring the attached window height before attaching would be nice.
>> Source/WebKit/win/WebCoreSupport/WebInspectorClient.cpp:297 >> + // Make sure that m_attached is true so that setAttachedWindowHeight succeeds. > > s/succeeds/doesn't return early/?
Should this say restoreAttachedWindowHeight instead of setAttachedWindowHeight?
Roger Fong
Comment 4
2012-11-12 14:54:28 PST
> >> Source/WebKit/win/WebCoreSupport/WebInspectorClient.cpp:297 > >> + // Make sure that m_attached is true so that setAttachedWindowHeight succeeds. > > > > s/succeeds/doesn't return early/? > > Should this say restoreAttachedWindowHeight instead of setAttachedWindowHeight?
I meant setAttachedWindowHeight because restore calls setAttachedWindowHeight which has a check: if (!m_attached) return; which prevents the final height from being et properly. I guess both are correct but I figured it'd be a little clearer using the method that actually fails. Do you think I should make it restoreAttachedWindowHeight tho?
Roger Fong
Comment 5
2012-11-12 15:49:32 PST
Created
attachment 173746
[details]
revised patch
Brian Weinstein
Comment 6
2012-11-12 16:06:46 PST
Comment on
attachment 173746
[details]
revised patch View in context:
https://bugs.webkit.org/attachment.cgi?id=173746&action=review
> Source/WebCore/inspector/InspectorFrontendClientLocal.cpp:143 > + // Call setDockingUnavailable before bringToFront. If we display the inspector window via bringToFront first it causes the call to canAttachWindow to return the wrong result.
Another sentence on why this is the case would be helpful.
> Source/WebKit/win/ChangeLog:15 > + (WebInspectorFrontendClient::frontendLoaded): > + (WebInspectorFrontendClient::attachWindow):
A high level comment about the changes in these functions would nice for people reading the ChangeLog later.
> Source/WebKit/win/WebCoreSupport/WebInspectorClient.cpp:299 > + // Immediately after calling showWindowWithoutNotifications(), the parent frameview's visibleHeight incorrectly returns 0 always.
Is this a WebKit bug or a Windows bug?
Roger Fong
Comment 7
2012-11-12 16:40:19 PST
Committed:
http://trac.webkit.org/changeset/134327
And made the last few remaining changes.
> Is this a WebKit bug or a Windows bug?
Yeup, windows bug. I added a comment or two to clarify
Tim Horton
Comment 8
2012-11-27 15:39:36 PST
Closing since it looks like this landed.
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