diff --git a/build/build.sh b/build/build.sh index fe5337c..061b2a9 100755 --- a/build/build.sh +++ b/build/build.sh @@ -7,7 +7,6 @@ MAIN="../main" RELEASE="../release" rm -rf "$RELEASE" -mkdir "$RELEASE" cp -r "$MAIN" "$RELEASE" rm -rf "$RELEASE/scripts" rm -rf "$RELEASE/styles" @@ -19,7 +18,6 @@ doCompress () { TARGET="$RELEASE/$1" for i in `ls -1p $SOURCE | grep -v "/$"` do - echo "$SOURCE/$i" java -jar "$YUI" --charset=utf-8 -o "$TARGET/$i" "$SOURCE/$i" done } @@ -29,7 +27,6 @@ doCompress "scripts/handle" doCompress "scripts/model" doCompress "scripts/util" doCompress "styles" -mkdir "$RELEASE/scripts\lib" -cp -r "$MAIN/scripts/lib" "$RELEASE/scripts/lib" +cp -r "$MAIN/scripts/lib" "$RELEASE/scripts" echo finish diff --git a/main/manifest.json b/main/manifest.json index 31da26a..652300b 100644 --- a/main/manifest.json +++ b/main/manifest.json @@ -22,11 +22,11 @@ "options_page": "option.html", "permissions": [ "proxy", "tabs", "webRequest", "webRequestBlocking", "http://*/*", "https://*/*" ], "plugins": [ { - "path": "./plugins/npNPAPIFileIOforChrome.dll" + "path": "./plugins/npapi-file-io-32.dll" }, { - "path": "./plugins/npNPAPIFileIOforChrome.so" + "path": "./plugins/npapi-file-io-32.so" }, { - "path": "./plugins/npNPAPIFileIOforChrome.plugin" + "path": "./plugins/npapi-file-io-64.so" } ], "requirements": { "plugins": { diff --git a/main/plugins/npNPAPIFileIOforChrome.dll b/main/plugins/npNPAPIFileIOforChrome.dll deleted file mode 100644 index d73b523..0000000 Binary files a/main/plugins/npNPAPIFileIOforChrome.dll and /dev/null differ diff --git a/main/plugins/npNPAPIFileIOforChrome.plugin/Contents/Info.plist b/main/plugins/npNPAPIFileIOforChrome.plugin/Contents/Info.plist deleted file mode 100644 index 224c574..0000000 --- a/main/plugins/npNPAPIFileIOforChrome.plugin/Contents/Info.plist +++ /dev/null @@ -1,74 +0,0 @@ - - - - - BuildMachineOSBuild - 12F45 - CFBundleDevelopmentRegion - English - CFBundleExecutable - NPAPIFileIOforChrome - CFBundleGetInfoString - NPAPIFileIOforChrome 1.0.0.0, Copyright 2012 Benryan Software Inc. - CFBundleIdentifier - com.NPAPIFileIOforChromeLib.NPAPI File IO for Chrome - CFBundleInfoDictionaryVersion - 6.0 - CFBundlePackageType - BRPL - CFBundleShortVersionString - NPAPIFileIOforChrome 1.0.0.0 - CFBundleSignature - ???? - CFBundleVersion - 1.0.0.0 - CFPlugInDynamicRegisterFunction - - CFPlugInDynamicRegistration - NO - CFPlugInFactories - - 00000000-0000-0000-0000-000000000000 - MyFactoryFunction - - CFPlugInTypes - - 00000000-0000-0000-0000-000000000000 - - 00000000-0000-0000-0000-000000000000 - - - CFPlugInUnloadFunction - - DTCompiler - com.apple.compilers.llvm.clang.1_0 - DTPlatformBuild - 5A1413 - DTPlatformVersion - GM - DTSDKBuild - 12D75 - DTSDKName - macosx10.8 - DTXcode - 0500 - DTXcodeBuild - 5A1413 - WebPluginDescription - Adds file operations to a javascript api for Chrome - WebPluginMIMETypes - - application/x-npapifileioforchrome - - WebPluginExtensions - - - - WebPluginTypeDescription - Adds file operations to a javascript api for Chrome - - - WebPluginName - NPAPI File IO for Chrome - - diff --git a/main/plugins/npNPAPIFileIOforChrome.plugin/Contents/MacOS/npNPAPIFileIOforChrome b/main/plugins/npNPAPIFileIOforChrome.plugin/Contents/MacOS/npNPAPIFileIOforChrome deleted file mode 100644 index 1853c4c..0000000 Binary files a/main/plugins/npNPAPIFileIOforChrome.plugin/Contents/MacOS/npNPAPIFileIOforChrome and /dev/null differ diff --git a/main/plugins/npNPAPIFileIOforChrome.plugin/Contents/Resources/English.lproj/InfoPlist.strings b/main/plugins/npNPAPIFileIOforChrome.plugin/Contents/Resources/English.lproj/InfoPlist.strings deleted file mode 100644 index 496e01a..0000000 --- a/main/plugins/npNPAPIFileIOforChrome.plugin/Contents/Resources/English.lproj/InfoPlist.strings +++ /dev/null @@ -1,4 +0,0 @@ -/* Localized versions of Info.plist keys */ - -CFBundleName = "NPAPIFileIOforChrome.plugin"; -NSHumanReadableCopyright = "Copyright 2012 Benryan Software Inc."; diff --git a/main/plugins/npNPAPIFileIOforChrome.plugin/Contents/Resources/English.lproj/Localized.rsrc b/main/plugins/npNPAPIFileIOforChrome.plugin/Contents/Resources/English.lproj/Localized.rsrc deleted file mode 100644 index 28cc7c9..0000000 --- a/main/plugins/npNPAPIFileIOforChrome.plugin/Contents/Resources/English.lproj/Localized.rsrc +++ /dev/null @@ -1,18 +0,0 @@ -#include - -resource 'STR#' (126) -{ { - "Copyright 2012 Benryan Software Inc.", - "NPAPI File IO for Chrome" -} }; - -resource 'STR#' (127) -{ { - "", -} }; - -resource 'STR#' (128) -{ { - "application/x-npapifileioforchrome", - "", -} }; diff --git a/main/plugins/npNPAPIFileIOforChrome.so b/main/plugins/npNPAPIFileIOforChrome.so deleted file mode 100644 index 28658e8..0000000 Binary files a/main/plugins/npNPAPIFileIOforChrome.so and /dev/null differ diff --git a/main/plugins/npapi-file-io-32.dll b/main/plugins/npapi-file-io-32.dll new file mode 100644 index 0000000..5a1b173 Binary files /dev/null and b/main/plugins/npapi-file-io-32.dll differ diff --git a/main/plugins/npapi-file-io-32.so b/main/plugins/npapi-file-io-32.so new file mode 100644 index 0000000..722567b Binary files /dev/null and b/main/plugins/npapi-file-io-32.so differ diff --git a/main/plugins/npapi-file-io-64.so b/main/plugins/npapi-file-io-64.so new file mode 100644 index 0000000..298e954 Binary files /dev/null and b/main/plugins/npapi-file-io-64.so differ diff --git a/main/scripts/background.js b/main/scripts/background.js index 508de5a..41300c3 100644 --- a/main/scripts/background.js +++ b/main/scripts/background.js @@ -34,7 +34,7 @@ */ getHostsPath: function() { try { - if (/windows/i.test(navigator.userAgent)) { // TODO + if (embed.getPlatform() == 'windows') { return embed.getSystemPath() + '\\drivers\\etc\\hosts'; } else { return '/etc/hosts'; @@ -194,7 +194,7 @@ }); })((function() { var embed = document.createElement('embed'); - embed.type = 'application/x-npapifileioforchrome'; + embed.type = 'application/x-npapi-file-io'; document.getElementsByTagName('body')[0].appendChild(embed); return embed; })(), {}); \ No newline at end of file