commit 2223e9ed2264cf1203865b7a0548e0724c89e527
Author:     Quentin Rameau <[email protected]>
AuthorDate: Tue Nov 3 15:42:30 2015 +0100
Commit:     Christoph Lohmann <[email protected]>
CommitDate: Tue Nov 3 19:45:04 2015 +0100

    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 <[email protected]>

diff --git a/surf.c b/surf.c
index ff2496d..dd9c306 100644
--- a/surf.c
+++ b/surf.c
@@ -695,10 +695,12 @@ initdownload(WebKitWebView *view, WebKitDownload *o, 
Client *c)
 void
 inspector(Client *c, const Arg *arg)
 {
-       if (c->isinspecting)
-               webkit_web_inspector_close(c->inspector);
-       else
-               webkit_web_inspector_show(c->inspector);
+       if (enableinspector) {
+               if (c->isinspecting)
+                       webkit_web_inspector_close(c->inspector);
+               else
+                       webkit_web_inspector_show(c->inspector);
+       }
 }
 
 WebKitWebView *

Reply via email to