﻿<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>学习日记 &#187; npapi</title>
	<atom:link href="https://www.softwareace.cn/?cat=17&#038;feed=rss2" rel="self" type="application/rss+xml" />
	<link>https://www.softwareace.cn</link>
	<description>时刻想着为自己的产品多做一些对他好的事情</description>
	<lastBuildDate>Fri, 20 Mar 2026 06:58:28 +0000</lastBuildDate>
	<language>zh-CN</language>
		<sy:updatePeriod>hourly</sy:updatePeriod>
		<sy:updateFrequency>1</sy:updateFrequency>
	
	<item>
		<title>用Visual Studio创建XPCOM组件</title>
		<link>https://www.softwareace.cn/?p=818</link>
		<comments>https://www.softwareace.cn/?p=818#comments</comments>
		<pubDate>Mon, 26 May 2014 01:47:03 +0000</pubDate>
		<dc:creator><![CDATA[admin]]></dc:creator>
				<category><![CDATA[npapi]]></category>

		<guid isPermaLink="false">http://www.softwareace.cn/?p=818</guid>
		<description><![CDATA[一、开发环境设置 下载XULRunner和XULRunner SDK，当前版本是1.8.1.3。可以在http [&#8230;]]]></description>
				<content:encoded><![CDATA[<p>一、开发环境设置<br />
下载<a href="http://releases.mozilla.org/pub/mozilla.org/xulrunner/releases/1.8.1.3/contrib/win32/xulrunner-1.8.1.3.en-US.win32.zip">XULRunner</a>和<a href="http://releases.mozilla.org/pub/mozilla.org/xulrunner/releases/1.8.1.3/contrib/sdk/xulrunner-1.8.1.3.en-US.win32.sdk.zip">XULRunner SDK</a>，当前版本是1.8.1.3。可以在<a href="http://releases.mozilla.org/pub/mozilla.org/xulrunner/releases/">http://releases.mozilla.org/pub/mozilla.org/xulrunner/releases/</a>找到最新的版本。</p>
<p>解压到一个目录下，我的目录结构：<br />
<img alt="" src="http://p.blog.csdn.net/images/p_blog_csdn_net/chinesejimmy/dir.PNG" /><br />
这个SDK里还需要两个dll文件，下载<a href="http://ftp.mozilla.org/pub/mozilla.org/mozilla/source/wintools.zip">wintools.zip</a>，从buildtools/windows/bin/x86里拷贝libIDL-0.6.dll、glib-1.2.dll到xulrunner/gecko-sdk/bin下。</p>
<p>二、XULRunner：Hello World!<br />
在xulrunner创建tests目录，如下：<br />
tests<br />
|&#8211;application.ini<br />
|&#8211;defaults<br />
|   |&#8211;preferences<br />
|   |   |&#8211;prefs.js<br />
|&#8211;chrome<br />
|   |&#8211;chrome.manifest<br />
|   |&#8211;HelloWorld<br />
|   |   |&#8211;test.xul</p>
<p>application.ini</p>
<div>
<pre class="crayon-plain-tag">[App]
Vendor=Duo
Name=tsetApp
Version=0.1
BuildID=20070530

[Gecko]
MinVersion=1.8
MaxVersion=1.8</pre>
</div>
<p>prefs.js:</p>
<div>
<pre class="crayon-plain-tag">pref("toolkit.defaultChromeURI", "chrome://tests/content/test.xul");</pre>
</div>
<p>chrome.manifest:</p>
<div>
<pre class="crayon-plain-tag">content tests HelloWorld/</pre>
</div>
<p>test.xul:</p>
<div><img alt="" src="http://images.csdn.net/syntaxhighlighting/OutliningIndicators/None.gif" align="top" />&nbsp;<br />
<pre class="crayon-plain-tag">&lt;?xml version="1.0"?&gt;
&lt;?xml-stylesheet href="chrome://global/skin/" type="text/css"?&gt;

&lt;window id="controller-example" title="Hello World"
        xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"&gt;

&lt;label value="Hello World!"/&gt;

&lt;/window&gt;</pre><br />
&nbsp;</p>
</div>
<p>在命令行下，进入xulrunner目录：</p>
<div><img alt="" src="http://images.csdn.net/syntaxhighlighting/OutliningIndicators/None.gif" align="top" />xulrunner.exe tests/application.ini</div>
<p>三、创建XPCOM组件<br />
参考：<a href="http://developer.mozilla.org/en/docs/How_to_build_a_binary_XPCOM_component_using_Visual_Studio">How to build a binary XPCOM component using Visual Studio</a><br />
VC++ Express Project：<a href="http://developer.mozilla.org/samples/xpcom/xpcom-test.zip">xpcom-test.zip</a><br />
主要有6步：</p>
<ul>
<li>把&#8221;xulrunner/gecko-sdk/include&#8221;加到Additional Include Directories里</li>
<li>把 &#8220;xulrunner/gecko-sdk/lib&#8221;加到Additional Library Directories里</li>
<li>添加&#8221;nspr4.lib xpcom.lib xpcomglue_s.lib&#8221;库</li>
<li>添加&#8221;XP_WIN;XP_WIN32″宏</li>
<li>不使用]预编译头</li>
<li>自定义XPCOM IDL编译步骤(右击*.idl文件，属性-&gt;自定义-&gt;命令行，输入$(ProjectDir)xpidl-build.bat $(InputFileName))</li>
</ul>
<p>四、测试XPCOM组件<br />
在上面建立的tests下创建components目录，把生成的.xpt、.dll文件拷贝到components。<br />
修改test.xul文件：（注意，要保存为uft-8编码。）</p>
<div>
<pre class="crayon-plain-tag">&lt;?xml version="1.0"?&gt;
&lt;?xml-stylesheet href="chrome://global/skin/" type="text/css"?&gt;

&lt;window id="controller-example" title="Controller Example"
        xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"&gt;

&lt;script&gt;
function doXPCOM() {
    try {
        const cid = "@starkravingfinkle.org/specialthing;1";
        var obj = Components.classes[cid].createInstance();
        obj = obj.QueryInterface(Components.interfaces.ISpecialThing);
    }
    catch(err) {
        alert(err);
        return;
    }

    var res = obj.add(3, 4);
    alert('3+4 = ' + res);

    var name = obj.name;
    alert('Name = ' + name);

    obj.name = 'New Name';
    name = obj.name;
    alert('Name = ' + name);
}
&lt;/script&gt;

&lt;button id="testXPCOM" label="测试XPCOM" oncommand="doXPCOM();"/&gt;

&lt;/window&gt;</pre><br />
<img alt="" src="http://images.csdn.net/syntaxhighlighting/OutliningIndicators/None.gif" align="top" /></p>
</div>
<p>修改application.ini的BuildID，我改为20070601，运行这个程序就可以测试了。</p>
]]></content:encoded>
			<wfw:commentRss>https://www.softwareace.cn/?feed=rss2&#038;p=818</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Mozilla plugin的MIME类型注册</title>
		<link>https://www.softwareace.cn/?p=177</link>
		<comments>https://www.softwareace.cn/?p=177#comments</comments>
		<pubDate>Tue, 19 Feb 2013 10:07:26 +0000</pubDate>
		<dc:creator><![CDATA[admin]]></dc:creator>
				<category><![CDATA[npapi]]></category>

		<guid isPermaLink="false">http://www.softwareace.cn/?p=177</guid>
		<description><![CDATA[1.最简便的方法：修改npp_gate.cpp中的 [crayon-69fb9552c4dac27756522 [&#8230;]]]></description>
				<content:encoded><![CDATA[<p>
	<span style="color: #666666; font-family: 宋体, Arial; font-size: 12px; line-height: 26px; background-color: #ffffff;">1.最简便的方法：修改npp_gate.cpp中的</span></p>
<p></p><pre class="crayon-plain-tag">char*
NPP_GetMIMEDescription(void)
{
return &amp;quot;application/mozilla-scriptable-plugin:.Suffixes:Description&amp;quot;;
}</pre><p></p>
<p>
	<span style="color: #666666; font-family: 宋体, Arial; font-size: 12px; line-height: 26px; background-color: #ffffff;">引号中的字段：MIME type：.扩展名：MIME type描述</span><br />
	<span style="color: #666666; font-family: 宋体, Arial; font-size: 12px; line-height: 26px; background-color: #ffffff;">2.如何在一个plugin中注册多个MIME type</span><br />
	<span style="color: #666666; font-family: 宋体, Arial; font-size: 12px; line-height: 26px; background-color: #ffffff;">格式是这样的：用&ldquo;；&rdquo;来分隔多个完整的MIME type描述（包括MIME type：.扩展名：MIME type描述），如果一个MIME type要支持多种扩展名则扩展名间用&ldquo;，&rdquo;做分隔符。</span></p>
]]></content:encoded>
			<wfw:commentRss>https://www.softwareace.cn/?feed=rss2&#038;p=177</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>使用NPAPI编写浏览器插件的调用本机上的程序</title>
		<link>https://www.softwareace.cn/?p=175</link>
		<comments>https://www.softwareace.cn/?p=175#comments</comments>
		<pubDate>Tue, 19 Feb 2013 06:18:48 +0000</pubDate>
		<dc:creator><![CDATA[admin]]></dc:creator>
				<category><![CDATA[npapi]]></category>

		<guid isPermaLink="false">http://www.softwareace.cn/?p=175</guid>
		<description><![CDATA[from:csdn 使用NPAPI编写浏览器插件的源码实例 &#160; code:http://downlo [&#8230;]]]></description>
				<content:encoded><![CDATA[<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	from:csdn<br />
	使用NPAPI编写浏览器插件的源码实例</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	&nbsp;</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	code:<a href="http://download.csdn.net/detail/echoisland/3878906" style="margin: 0px; padding: 0px; color: rgb(51, 102, 153); text-decoration: none; ">http://download.csdn.net/detail/echoisland/3878906</a></div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	&nbsp;</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	用于种种原因,最近对制作浏览器(chrome,firefox)的插件非常感兴趣</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	搜了一下,讲的几乎全都是在讲的方法和API,找个简单可以运行的代码实例,还真是难!</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	不过最终还算幸运,终于找一个例子(http://geeklu.com/2010/10/getting-started-with-npapi-plugin/comment-page-1/).</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	很遗憾这个例子在我的linux机器上无法正常工作.所以我以此例子为基础写了个新例子,顺路我还写了个chrome的扩展作为演示.</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	关于NPAPI和chrome的扩展:</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	NPAPI:</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	[1] http://colonelpanic.net/2009/05/building-a-firefox-plugin-part-two/</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	[2] http://rintarou.dyndns.org/2010/04/23/scriptable-plugin-%E6%8E%A2%E8%A8%8E-20090408/</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	[3] http://blogold.chinaunix.net/u3/94039/showart_2004756.html</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	[4] https://developer.mozilla.org/en/Plugins</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	&nbsp;</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	[5] 如何在chrome的扩展中使用:http://code.google.com/chrome/extensions/npapi.html</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	[6] 如何编写chrome的扩展:http://code.google.com/chrome/extensions/getstarted.html</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	&nbsp;</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	插件的功能:</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	提供网页的javascript可以调用本机上的程序的能力,</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	所以本插件其实是很危险的,当然任何可以让网页调用本机上程序的插件都是很危险的.</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	不过这里只是一个演示插件编写的例子,看到的人不要惊慌哦&#8230;</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	&nbsp;</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	关于源码的说明</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	npapi/npapi.h</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	npapi/npfunctions.h</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	npapi/npruntime.h</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	npapi/nptypes.h</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	直接来自:http://code.google.com/p/npapi-headers/</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	&nbsp;</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	plugin_exec.c中的一些函数:</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	char*</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	NP_GetMIMEDescription()</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	return的字符串的格式必须是:&quot;text/html:htm,html:HTML Document;application/x-texinfo:tex,texi,texinfo:TexInfo Document;&quot;</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	详情请看[3]</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	&nbsp;</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	NPError</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	NP_GetValue (void *future,</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	&nbsp;&nbsp; &nbsp; NPPVariable variable,</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	&nbsp;&nbsp; &nbsp; void *value)</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	一定要处理 variable为NPPVpluginNeedsXEmbed的case,否则chrome不会启用插件(firefox还算正常)</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	&nbsp;</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	插件的演示方法:</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	$cp libplugin_exec.so ~/.mozilla/plugins</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	$firefox wkt.html&nbsp;</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	$google-chrome wkt.html ###在网页输入一个命令(必须运行后能跳出窗口,例如gnome-terminal,否则看不见效果),然后点&quot;Run&quot;按钮.</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
<div style="margin: 0px; padding: 0px; ">
		<img alt="使用NPAPI编写浏览器插件的源码实例 - wkt55555 - wkt的博客" src="http://img115.ph.126.net/ISCKJDw0PO8BGbVpLvFOxg==/2010857233622925916.png" style="margin: 0px 10px 0px 0px; padding: 0px; border: 0px none; max-width: 100%; " /></div>
<div style="margin: 0px; padding: 0px; ">
		<img alt="使用NPAPI编写浏览器插件的源码实例 - wkt55555 - wkt的博客" src="http://img.ph.126.net/VffoOfq6JsY50_gNhaWE0g==/1509268825123097266.jpg" style="margin: 0px 10px 0px 0px; padding: 0px; border: 0px none; max-width: 100%; " /></div>
<p>
		&nbsp;&nbsp;</p>
</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	chrome扩展的演示方法:</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	扩展在chrome_extension目录下</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	加载扩展(加载方法看[6]的第4步),</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	然后页面上每个link的右键菜单会多出一个菜单项&quot;save link to /tmp/link.log&quot;,</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	点击该菜单项后link的url就会被保存到/tmp/link.log</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
<div style="margin: 0px; padding: 0px; ">
		<img alt="使用NPAPI编写浏览器插件的源码实例 - wkt55555 - wkt的博客" src="http://img609.ph.126.net/jKYyDqLInnLpqberhKuc8w==/1901081992705962707.png" style="margin: 0px 10px 0px 0px; padding: 0px; border: 0px none; max-width: 100%; " /></div>
</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	本例源码地址:http://u.115.com/file/f23aeb448f</div>
<div style="margin: 0px; padding: 0px; font-size: 14px; line-height: 25px; color: rgb(102, 102, 102); font-family: Arial, Helvetica, simsun, u5b8bu4f53; background-color: rgb(250, 249, 247); ">
	注意此例仅在debian sid/ubuntu10.10 编译/测试.</div>
]]></content:encoded>
			<wfw:commentRss>https://www.softwareace.cn/?feed=rss2&#038;p=175</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
