Fix inspector handling when inspector is disabled.
Do not try to show the inspector window when the inspector is disabled. Signed-off-by: Christoph Lohmann <20h@r-36.net>
This commit is contained in:
parent
1ebb5c624e
commit
2223e9ed22
1 changed files with 6 additions and 4 deletions
2
surf.c
2
surf.c
|
@ -695,11 +695,13 @@ initdownload(WebKitWebView *view, WebKitDownload *o, Client *c)
|
||||||
void
|
void
|
||||||
inspector(Client *c, const Arg *arg)
|
inspector(Client *c, const Arg *arg)
|
||||||
{
|
{
|
||||||
|
if (enableinspector) {
|
||||||
if (c->isinspecting)
|
if (c->isinspecting)
|
||||||
webkit_web_inspector_close(c->inspector);
|
webkit_web_inspector_close(c->inspector);
|
||||||
else
|
else
|
||||||
webkit_web_inspector_show(c->inspector);
|
webkit_web_inspector_show(c->inspector);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
WebKitWebView *
|
WebKitWebView *
|
||||||
inspector_new(WebKitWebInspector *i, WebKitWebView *v, Client *c)
|
inspector_new(WebKitWebInspector *i, WebKitWebView *v, Client *c)
|
||||||
|
|
Loading…
Reference in a new issue