Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>Safari plugin development is non-trivial. The interface is written in Objective-C, and most of it is not even part of WebKit (so you can't see the source), but there's machinery to inspect and patch the object hierarchy of a running application. It requires understanding of Cocoa and Objective-C, but no lower.</p> <p>Here's a high level overview I had in my bookmarks of the process <a href="http://livingcode.org/2006/tab-dumping-in-safari" rel="nofollow noreferrer">http://livingcode.org/2006/tab-dumping-in-safari</a>. It goes over creating Safari plugins using Python with working (probably outdated) code. Instead of Python you can use anything that has Objective-C bindings.</p> <p>There are two major parts to it:</p> <ul> <li><p>You need to attach your code to a running Safari. This is typically done with SIMBL <a href="http://www.culater.net/software/SIMBL/SIMBL.php" rel="nofollow noreferrer">http://www.culater.net/software/SIMBL/SIMBL.php</a>.</p></li> <li><p>Once you're inside, you need to figure what to patch. There's a tutorial on reversing Cocoa applications <a href="http://www.culater.net/wiki/moin.cgi/CocoaReverseEngineering" rel="nofollow noreferrer">http://www.culater.net/wiki/moin.cgi/CocoaReverseEngineering</a>, which links to the most important tool, class-dump <a href="http://www.codethecode.com/projects/class-dump/" rel="nofollow noreferrer">http://www.codethecode.com/projects/class-dump/</a> (the link on wiki is broken). Class-dump gives you a complete hierarchy of Safari's classes, where you can guess by names what, specifically, you need to patch. This is a very trial and error mode.</p></li> </ul> <p>Reading the links above will give you the scope of the project.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload