Show Inspector not launching Web Inspector
I'm on Mac OS X Snow Leopard.
Selecting Show Inspector from Window menu does nothing. No Web Inspector.
I am able to launch the inspector using Titanium.UI.getWindows()[0].showInspector() in the sandbox.
Any idea what's going on?
Thanks!
5 Answers
-
Accepted Answer
In order to enable the Web Inspector panel in your application on Mac OSX you need to edit the preferences plist file.
This can be found in ~/Library/Preferences and is named using your application's ID. Open the file with the plist editor and add a new key called "WebKitDeveloperExtras" with type set to boolean. Setting this value to true will allow the Inspector panel to be opened.
To open Inspector right click on your application and select "Inspect element". This should cause Inspector to open up.
-
Thank YOU!!!!!!!!!
That's been bugging me for months!!!!!!
-
Didn't work for me either.
-
Anyone got any pointers on this? I've seen the plist suggestion (but I believe that's only for 1.2.x onwards?), I'm building on 1.1.0 under Snow Leopard (10.6.8), the plist value already exists, and right clicking and choosing 'Show Inspector' does nothing within the app, but dumps this exception back to the console;
2011-11-30 09:05:30.859 Desktop-Test[36270:b07] HIToolbox: ignoring exception '*** -[NSURL initFileURLWithPath:]: nil string parameter' that raised inside Carbon event dispatch ( 0 CoreFoundation 0x93c816ca __raiseError + 410 1 libobjc.A.dylib 0x935d25a9 objc_exception_throw + 56 2 CoreFoundation 0x93c813f8 +[NSException raise:format:arguments:] + 136 3 CoreFoundation 0x93c8136a +[NSException raise:format:] + 58 4 Foundation 0x93870a88 -[NSURL(NSURL) initFileURLWithPath:] + 90 5 Foundation 0x93870a16 +[NSURL(NSURL) fileURLWithPath:] + 72 6 WebKit 0x12f6cd36 -[WebInspectorWindowController init] + 806 7 WebKit 0x12f6c9d7 -[WebInspectorWindowController initWithInspectedWebView:] + 39 8 WebKit 0x12f6e003 _ZN18WebInspectorClient21openInspectorFrontendEPN7WebCore19InspectorControllerE + 67 9 WebCore 0x1371f443 _ZN7WebCore19InspectorController4showEv + 67 10 libtiuimodule.dylib 0x14bb32e0 _ZN2ti13OSXUserWindow13ShowInspectorEb + 48 11 AppKit 0x920d6a26 -[NSApplication sendAction:to:from:] + 112 12 AppKit 0x920d68d9 -[NSMenuItem _corePerformAction] + 435 13 AppKit 0x920d65ca -[NSCarbonMenuImpl performActionWithHighlightingForItemAtIndex:] + 174 14 AppKit 0x920d64b6 -[NSMenu performActionForItemAtIndex:] + 65 15 AppKit 0x920d6469 -[NSMenu _internalPerformActionForItemAtIndex:] + 50 16 AppKit 0x920d63cf -[NSMenuItem _internalPerformActionThroughMenuIfPossible] + 97 17 AppKit 0x920d6313 -[NSCarbonMenuImpl _carbonCommandProcessEvent:handlerCallRef:] + 336 18 AppKit 0x920caa55 NSSLMMenuEventHandler + 404 19 HIToolbox 0x99a03c2f _ZL23DispatchEventToHandlersP14EventTargetRecP14OpaqueEventRefP14HandlerCallRec + 1567 20 HIToolbox 0x99a02ef6 _ZL30SendEventToEventTargetInternalP14OpaqueEventRefP20OpaqueEventTargetRefP14HandlerCallRec + 411 21 HIToolbox 0x99a257f3 SendEventToEventTarget + 52 22 HIToolbox 0x99a51e87 _ZL18SendHICommandEventmPK9HICommandmmhPKvP20OpaqueEventTargetRefS5_PP14OpaqueEventRef + 448 23 HIToolbox 0x99a76b90 SendMenuCommandWithContextAndModifiers + 66 24 HIToolbox 0x99a76b47 SendMenuItemSelectedEvent + 121 25 HIToolbox 0x99a76a5d _ZL19FinishMenuSelectionP13SelectionDataP10MenuResultS2_ + 152 26 HIToolbox 0x99bf8364 _ZL19PopUpMenuSelectCoreP8MenuData5PointdS1_tjPK4RecttmS4_S4_PK10__CFStringPP13OpaqueMenuRefPt + 1857 27 HIToolbox 0x99bf86bb _HandlePopUpMenuSelection7 + 678 28 AppKit 0x923626e6 _NSSLMPopUpCarbonMenu3 + 3937 29 AppKit 0x92362a76 -[NSCarbonMenuImpl _popUpContextMenu:withEvent:forView:withFont:] + 220 30 AppKit 0x924db945 -[NSMenu _popUpContextMenu:withEvent:forView:withFont:] + 270 31 AppKit 0x924db9e4 -[NSMenu _popUpContextMenu:withEvent:forView:] + 63 32 AppKit 0x924db7b7 -[NSMenu _popUpMenuWithEvent:forView:] + 52 33 AppKit 0x926d265d -[NSView rightMouseDown:] + 103 34 AppKit 0x923c3d1b -[NSControl _rightMouseUpOrDown:] + 534 35 AppKit 0x921adb28 -[NSWindow sendEvent:] + 5757 36 AppKit 0x920c660b -[NSApplication sendEvent:] + 6431 37 AppKit 0x9205a253 -[NSApplication run] + 917 38 libkhost.dylib 0x02885cc7 _ZN5kroll4Host7RunLoopEv + 423 39 libkhost.dylib 0x0280e0eb _ZN5kroll4Host3RunEv + 251 40 libkhost.dylib 0x0280e579 Execute + 73 41 Desktop-Test 0x0002155e _ZN9KrollBoot9StartHostEv + 350 42 Desktop-Test 0x00022170 main + 480 43 Desktop-Test 0x000032ea start + 54 )
-
This can be resolved by manually installing the SDK, see this Jira issue for details and this other answer for links to SDK 1.2.0RC6e