summaryrefslogtreecommitdiffstats
path: root/WebKit/mac/WebCoreSupport/WebInspectorClient.mm
diff options
context:
space:
mode:
Diffstat (limited to 'WebKit/mac/WebCoreSupport/WebInspectorClient.mm')
-rw-r--r--WebKit/mac/WebCoreSupport/WebInspectorClient.mm12
1 files changed, 6 insertions, 6 deletions
diff --git a/WebKit/mac/WebCoreSupport/WebInspectorClient.mm b/WebKit/mac/WebCoreSupport/WebInspectorClient.mm
index d4d0213..b08c161 100644
--- a/WebKit/mac/WebCoreSupport/WebInspectorClient.mm
+++ b/WebKit/mac/WebCoreSupport/WebInspectorClient.mm
@@ -217,11 +217,9 @@ void WebInspectorFrontendClient::updateWindowTitle() const
return nil;
// Keep preferences separate from the rest of the client, making sure we are using expected preference values.
- // One reason this is good is that it keeps the inspector out of history via "private browsing".
WebPreferences *preferences = [[WebPreferences alloc] init];
[preferences setAutosaves:NO];
- [preferences setPrivateBrowsingEnabled:YES];
[preferences setLoadsImagesAutomatically:YES];
[preferences setAuthorAndUserStylesEnabled:YES];
[preferences setJavaScriptEnabled:YES];
@@ -358,8 +356,8 @@ void WebInspectorFrontendClient::updateWindowTitle() const
_visible = YES;
// If no preference is set - default to an attached window. This is important for inspector LayoutTests.
- String shouldAttach = [_inspectedWebView page]->inspectorController()->setting(InspectorController::inspectorStartsAttachedSettingName());
- _shouldAttach = shouldAttach != "false";
+ // FIXME: This flag can be fetched directly from the flags storage.
+ _shouldAttach = [_inspectedWebView page]->inspectorController()->inspectorStartsAttached();
if (_shouldAttach && !_frontendClient->canAttachWindow())
_shouldAttach = NO;
@@ -394,7 +392,8 @@ void WebInspectorFrontendClient::updateWindowTitle() const
if (_attachedToInspectedWebView)
return;
- [_inspectedWebView page]->inspectorController()->setSetting(InspectorController::inspectorStartsAttachedSettingName(), "true");
+ // FIXME: This flag can be saved directly to the flags storage.
+ [_inspectedWebView page]->inspectorController()->setInspectorStartsAttached(true);
[self close];
[self showWindow:nil];
@@ -405,7 +404,8 @@ void WebInspectorFrontendClient::updateWindowTitle() const
if (!_attachedToInspectedWebView)
return;
- [_inspectedWebView page]->inspectorController()->setSetting(InspectorController::inspectorStartsAttachedSettingName(), "false");
+ // FIXME: This flag can be saved to the flags storage directly.
+ [_inspectedWebView page]->inspectorController()->setInspectorStartsAttached(false);
[self close];
[self showWindow:nil];