├── App ├── _locales │ ├── de │ │ └── messages.json │ ├── en │ │ └── messages.json │ ├── zh_CN │ │ └── messages.json │ └── zh_TW │ │ └── messages.json ├── common.js ├── config.js ├── data │ ├── DownloadPanel │ │ ├── index.html │ │ └── index.js │ ├── Sound │ │ ├── complete1.wav │ │ ├── complete2.wav │ │ └── complete3.wav │ ├── action │ │ ├── index.html │ │ └── index.js │ ├── ariang │ │ ├── LICENSE │ │ ├── css │ │ │ ├── aria-ng-2a46099f8c.min.css │ │ │ ├── bootstrap-3.4.1.min.css │ │ │ └── plugins-acd93e5a25.min.css │ │ ├── favicon.ico │ │ ├── favicon.png │ │ ├── fonts │ │ │ ├── fontawesome-webfont.eot │ │ │ ├── fontawesome-webfont.svg │ │ │ ├── fontawesome-webfont.ttf │ │ │ ├── fontawesome-webfont.woff │ │ │ └── fontawesome-webfont.woff2 │ │ ├── index.html │ │ ├── index.manifest │ │ ├── js │ │ │ ├── angular-packages-1.6.10.min.js │ │ │ ├── aria-ng-902a524d58.min.js │ │ │ ├── bootstrap-3.4.1.min.js │ │ │ ├── echarts-common-3.8.5.min.js │ │ │ ├── jquery-3.3.1.min.js │ │ │ ├── moment-with-locales-2.24.0.min.js │ │ │ └── plugins-01928ba731.min.js │ │ ├── langs │ │ │ ├── zh_Hans.txt │ │ │ └── zh_Hant.txt │ │ ├── robots.txt │ │ ├── tileicon.png │ │ └── touchicon.png │ ├── icons │ │ ├── 128.png │ │ ├── 16.png │ │ ├── 256.png │ │ ├── 32.png │ │ ├── 48.png │ │ ├── 64.png │ │ └── disabled │ │ │ ├── 128.png │ │ │ ├── 16.png │ │ │ ├── 256.png │ │ │ ├── 32.png │ │ │ ├── 48.png │ │ │ └── 64.png │ └── options │ │ ├── about.html │ │ ├── about.js │ │ ├── exception.html │ │ ├── exception.js │ │ ├── general.html │ │ ├── general.js │ │ ├── menu.html │ │ ├── menu.js │ │ ├── rpc.html │ │ ├── rpc.js │ │ ├── rpc2.html │ │ ├── rpc2.js │ │ ├── rpc3.html │ │ └── rpc3.js ├── lib │ ├── aria.LICENSE │ ├── aria.js │ ├── jschardet.LICENSE │ ├── jschardet.min.js │ ├── polygoat.LICENSE │ ├── polygoat.js │ ├── tools.js │ └── worker.js └── manifest.json ├── Bin ├── Aria2-uriScheme.reg ├── HideRun.vbs ├── Readme.txt ├── add_Aria2-uriScheme.bat ├── aria2.conf ├── aria2.session ├── aria2.zip ├── aria2Hide.c ├── aria2Hide.exe ├── aria2c.exe ├── aria2start.bat ├── del_Aria2-uriScheme.bat ├── dht.dat └── dht6.dat ├── CHANGELOG.md ├── LICENSE ├── README.md └── THIRDPARTY.md /App/_locales/de/messages.json: -------------------------------------------------------------------------------- 1 | { 2 | "extensionName": { 3 | "message": "Aria2-Download-Manager Integration", 4 | "description": "Name der Erweiterung." 5 | }, 6 | 7 | "extensionDescription": { 8 | "message": "Ersetzt den integrierten Download-Manager. Wenn aktiviert, werden Download-Links erkannt, zu diesem Add-on umgeleiten und an Aria2 gesendet.", 9 | "description": "Beschreibung der Erweiterung." 10 | }, 11 | 12 | "translator": { 13 | "message": "", 14 | "description": "" 15 | }, 16 | 17 | "translatorMessage": { 18 | "message": "", 19 | "description": "you can leave it blank if you have nothing to say" 20 | }, 21 | 22 | "direction": { 23 | "message": "ltr", 24 | "description": "Schreibrichtung" 25 | }, 26 | 27 | "enabled": { 28 | "message": "AKTIVIERT", 29 | "description": "" 30 | }, 31 | 32 | "disabled": { 33 | "message": "DEAKTIVIERT", 34 | "description": "" 35 | }, 36 | 37 | "error_setConfig": { 38 | "message": "Zuerst müssen die Einstellungen festgelegt werden." 39 | }, 40 | 41 | "error_connect": { 42 | "message": "Irgendetwas ist schief gelaufen. Überprüfe die Eingabe, die Optionen und den Status von Aria2 und versuche es erneut.", 43 | "description": "Benachrichtige den Benutzer, wenn die Anfrage an Aria2 zu einem Timeout führt oder wenn sie keine Erfolgsmeldung zurück gibt." 44 | }, 45 | 46 | "error_notSupported": { 47 | "message": "Nicht unterstützt", 48 | "description": "" 49 | }, 50 | 51 | "success_connect": { 52 | "message": "Lädt $NAME$ herunter", 53 | "description": "Benachrichtige den Benutzer, wenn die Anfrage an Aria2 erfolgreich ist.", 54 | "placeholders": { 55 | "name" : { 56 | "content" : "$1" 57 | } 58 | } 59 | }, 60 | 61 | "download_complete": { 62 | "message": "Download abgeschlossen \n\n $NAME$", 63 | "description": "Benachrichtige den Benutzer, wenn der Download abgeschlossen ist.", 64 | "placeholders": { 65 | "name" : { 66 | "content" : "$1" 67 | } 68 | } 69 | }, 70 | 71 | "download_error": { 72 | "message": "Download fehlgeschlagen \n\n $NAME$", 73 | "description": "Benachrichtige den Benutzer, wenn der Download fehlschlägt.", 74 | "placeholders": { 75 | "name" : { 76 | "content" : "$1" 77 | } 78 | } 79 | }, 80 | 81 | "UI_detail": { 82 | "message": "Details", 83 | "description": "" 84 | }, 85 | 86 | "UI_download": { 87 | "message": "Download", 88 | "description": "" 89 | }, 90 | 91 | "UI_save": { 92 | "message": "Speichern", 93 | "description": "für Download-Panel" 94 | }, 95 | 96 | "UI_saveas": { 97 | "message": "Speichern unter", 98 | "description": "" 99 | }, 100 | 101 | "UI_open": { 102 | "message": "Öffnen", 103 | "description": "" 104 | }, 105 | 106 | "UI_fileName": { 107 | "message": "Dateiname", 108 | "description": "" 109 | }, 110 | 111 | "UI_filePath": { 112 | "message": "Dateipfad", 113 | "description": "" 114 | }, 115 | 116 | "UI_from": { 117 | "message": "Von", 118 | "description": "" 119 | }, 120 | 121 | "OP_message1": { 122 | "message": "Aria2 muss selbst heruntergeladen und gestartet werden. Fülle zumindest 'Protokoll', 'Host', 'Port' und 'Interface' aus und klicke dann auf Speichern.", 123 | "description": "" 124 | }, 125 | 126 | "OP_message2": { 127 | "message": "Wenn du Aria2 nicht manuell starten möchtest, kannst du ein Programm schreiben, dass Aria2 im Hintergrund startet und sich im System unter 'Autostart' oder als 'Uri-Schema' registriert.", 128 | "description": "" 129 | }, 130 | 131 | 132 | "OP_message3": { 133 | "message": "Die Beispieldatei findest du hier.", 134 | "description": "" 135 | }, 136 | 137 | "OP_defaultPath": { 138 | "message": "Standard Downloadpfad:", 139 | "description": "" 140 | }, 141 | 142 | 143 | "OPN_defaultPath": { 144 | "message": "Downloadpfad von Aria2 (exklusiv), optional.", 145 | "description": "" 146 | }, 147 | 148 | "OP_protocol": { 149 | "message": "Protokoll:", 150 | "description": "" 151 | }, 152 | 153 | "OPN_protocol": { 154 | "message": "RPC-Verbindungsprotokoll von Aria2. Unterstützt ws, wss, http und https. Websocket bietet mehr Funktionen.", 155 | "description": "" 156 | }, 157 | 158 | "OP_host": { 159 | "message": "Host:", 160 | "description": "" 161 | }, 162 | 163 | "OPN_host": { 164 | "message": "RPC-Host von Aria2. Es können IP oder Domainnamen verwendet werden.", 165 | "description": "" 166 | }, 167 | 168 | "OP_port": { 169 | "message": "Port:", 170 | "description": "" 171 | }, 172 | 173 | "OPN_port": { 174 | "message": "Aria2 RPC-Port.", 175 | "description": "" 176 | }, 177 | 178 | "OP_interface": { 179 | "message": "Schnittstelle:", 180 | "description": "" 181 | }, 182 | 183 | "OPN_interface": { 184 | "message": "Aria2 RPC-Adresse. Der Standardwert ist 'jsonrpc'.", 185 | "description": "" 186 | }, 187 | 188 | "OP_token": { 189 | "message": "Token:", 190 | "description": "" 191 | }, 192 | 193 | "OPN_token": { 194 | "message": "Aria2 RPC-Secret, optional.", 195 | "description": "" 196 | }, 197 | 198 | "OP_zoom": { 199 | "message": "Vergrößerung:", 200 | "description": "" 201 | }, 202 | 203 | "OPN_zoom": { 204 | "message": "Zoomfaktor des Download-Panels. Standardwert ist 1.", 205 | "description": "" 206 | }, 207 | 208 | "OP_sound": { 209 | "message": "Klang für abgeschlossenen Downlod:", 210 | "description": "" 211 | }, 212 | 213 | "OP_sound0": { 214 | "message": "Ohne", 215 | "description": "" 216 | }, 217 | 218 | "OP_sound1": { 219 | "message": "Klang 1", 220 | "description": "" 221 | }, 222 | 223 | "OP_sound2": { 224 | "message": "Klang 2", 225 | "description": "" 226 | }, 227 | 228 | "OP_sound3": { 229 | "message": "Klang 3", 230 | "description": "" 231 | }, 232 | 233 | "OPN_sound": { 234 | "message": "[Websocket] Wähle einen Klang für einen abgeschlossenen Download.", 235 | "description": "" 236 | }, 237 | 238 | "OP_advanced": { 239 | "message": "Erweitert:", 240 | "description": "" 241 | }, 242 | 243 | "OP_contextMenu": { 244 | "message": "Füge Kontextmenüs hinzu", 245 | "description": "" 246 | }, 247 | 248 | "OPN_contextMenu": { 249 | "message": "Füge Kontextmenüs für Links, Videos und Audiodateien hinzu.", 250 | "description": "" 251 | }, 252 | 253 | "OP_shutdown": { 254 | "message": "Beende Aria2c wenn der Browser geschlossen wird", 255 | "description": "" 256 | }, 257 | 258 | "OPN_shutdown": { 259 | "message": "Sende '--stop-with-process='-Befehl zu Aria2c.", 260 | "description": "" 261 | }, 262 | 263 | "OP_aggressive": { 264 | "message": "Aggressiver Modus", 265 | "description": "" 266 | }, 267 | 268 | "OPN_aggressive": { 269 | "message": "Erkenne Download-Links aggressiv. Kann Probleme verursachen.", 270 | "description": "" 271 | }, 272 | 273 | "OP_winLoc": { 274 | "message": "Fensterposition speichern", 275 | "description": "" 276 | }, 277 | 278 | "OPN_winLoc": { 279 | "message": "Die Position des Downloadfensters wird gespeichert (Firefox hat jedoch einen Fehler und kann die Position des Fensters nicht festlegen).", 280 | "description": "" 281 | }, 282 | 283 | "OP_auto": { 284 | "message": "Aria2 automatisch starten", 285 | "description": "" 286 | }, 287 | 288 | "OPN_auto": { 289 | "message": "Aria2 automatisch mit Download starten.", 290 | "description": "" 291 | }, 292 | 293 | "OP_autoSet": { 294 | "message": "AriaNg automatisch auswählen", 295 | "description": "" 296 | }, 297 | 298 | "OPN_autoSet": { 299 | "message": "AriaNg automatisch auswählen, wenn der Benutzer auf 'Details' klickt.", 300 | "description": "" 301 | }, 302 | 303 | "OP_chgLog": { 304 | "message": "Zeige Änderungsprotokoll", 305 | "description": "" 306 | }, 307 | 308 | "OPN_chgLog": { 309 | "message": "Zeige Änderungsprotokoll nach Update", 310 | "description": "" 311 | }, 312 | 313 | "OP_badge": { 314 | "message": "Zeige aktuelle Anzahl der aktiven Downloads", 315 | "description": "" 316 | }, 317 | 318 | "OPN_badge": { 319 | "message": "[Websocket] Zeige aktuelle Anzahl der aktiven Downloads oben auf dem Icon.", 320 | "description": "" 321 | }, 322 | 323 | "OP_cmDownPanel": { 324 | "message": "Zeige Download-Panel", 325 | "description": "" 326 | }, 327 | 328 | "OPN_cmDownPanel": { 329 | "message": "Zeige das Download-Panel für Downloads an, die mit dem Kontextmenü gestartet wurden.", 330 | "description": "" 331 | }, 332 | 333 | "OP_winWidth": { 334 | "message": "Fensterbreite des Download-Panels", 335 | "description": "" 336 | }, 337 | 338 | "OPN_winWidth": { 339 | "message": "Feineinstellung der Download-Fenster-Breite.", 340 | "description": "" 341 | }, 342 | 343 | "OP_winHeight": { 344 | "message": "Fensterhöhe des Download-Panels", 345 | "description": "" 346 | }, 347 | 348 | "OPN_winHeight": { 349 | "message": "Feineinstellung der Download-Fenster-Höhe.", 350 | "description": "" 351 | }, 352 | 353 | "OP_save": { 354 | "message": "Speichern", 355 | "description": "Speichern-Button" 356 | }, 357 | 358 | "OP_saveComplete": { 359 | "message": "Einstellungen gespeichert.", 360 | "description": "" 361 | }, 362 | 363 | "CM_title": { 364 | "message": "Download mit Aria2", 365 | "description": "Kontextmenü" 366 | } 367 | } -------------------------------------------------------------------------------- /App/_locales/en/messages.json: -------------------------------------------------------------------------------- 1 | { 2 | "extensionName": { 3 | "message": "Aria2 Download Manager Integration", 4 | "description": "Name of the extension." 5 | }, 6 | 7 | "extensionDescription": { 8 | "message": "Replace built-in download manager. When activated, detects the download links to direct links to this add-on and send to Aria2", 9 | "description": "Description of the extension." 10 | }, 11 | 12 | "translator": { 13 | "message": "Translator: Ross Wang", 14 | "description": "" 15 | }, 16 | 17 | "translatorMessage": { 18 | "message": "English is not my native language, so there may have something wrong in the translation. Please help me correct the mistakes.", 19 | "description": "you can leave it blank if you have nothing to say" 20 | }, 21 | 22 | "direction": { 23 | "message": "ltr", 24 | "description": "Language direction" 25 | }, 26 | 27 | "enabled": { 28 | "message": "ENABLED", 29 | "description": "" 30 | }, 31 | 32 | "disabled": { 33 | "message": "DISABLED", 34 | "description": "" 35 | }, 36 | 37 | "error_setConfig": { 38 | "message": "You need to set the config first" 39 | }, 40 | 41 | "error_connect": { 42 | "message": "Something went wrong. Check the input, options or the state of Aria2 and retry.", 43 | "description": "If the request to Aria2 timeout or if it doesn't response success message, notify the user" 44 | }, 45 | 46 | "error_notSupported": { 47 | "message": "Not Supported", 48 | "description": "" 49 | }, 50 | 51 | "success_connect": { 52 | "message": "Downloading $NAME$", 53 | "description": "If the request to Aria2 success, notify the user", 54 | "placeholders": { 55 | "name" : { 56 | "content" : "$1" 57 | } 58 | } 59 | }, 60 | 61 | "download_complete": { 62 | "message": "Download Completed \n\n $NAME$", 63 | "description": "notify the user when download completed", 64 | "placeholders": { 65 | "name" : { 66 | "content" : "$1" 67 | } 68 | } 69 | }, 70 | 71 | "download_error": { 72 | "message": "Download Faild \n\n $NAME$", 73 | "description": "notify the user when download failed", 74 | "placeholders": { 75 | "name" : { 76 | "content" : "$1" 77 | } 78 | } 79 | }, 80 | 81 | "UI_detail": { 82 | "message": "Details", 83 | "description": "" 84 | }, 85 | 86 | "UI_download": { 87 | "message": "Download", 88 | "description": "" 89 | }, 90 | 91 | "UI_save": { 92 | "message": "Save", 93 | "description": "for download panel" 94 | }, 95 | 96 | "UI_saveas": { 97 | "message": "Save As", 98 | "description": "" 99 | }, 100 | 101 | "UI_open": { 102 | "message": "Open", 103 | "description": "" 104 | }, 105 | 106 | "UI_adv": { 107 | "message": "Advanced", 108 | "description": "" 109 | }, 110 | 111 | "UI_fileName": { 112 | "message": "File Name", 113 | "description": "" 114 | }, 115 | 116 | "UI_filePath": { 117 | "message": "File Path", 118 | "description": "" 119 | }, 120 | 121 | "UI_from": { 122 | "message": "From", 123 | "description": "" 124 | }, 125 | 126 | "OP_message1": { 127 | "message": "You need to download and start Aria2 by yourself, complete at least 'Protocol,' 'Host,' 'Port' and 'Interface' below and then click the 'Save' button.", 128 | "description": "" 129 | }, 130 | 131 | "OP_message2": { 132 | "message": "If you don't want to start Aria2 manually, just write a program to start Aria2 in the background and register it to the system's 'autostart' or 'uri scheme.'", 133 | "description": "" 134 | }, 135 | 136 | 137 | "OP_message3": { 138 | "message": "You can find the sample files here.", 139 | "description": "" 140 | }, 141 | 142 | "OP_defaultPath": { 143 | "message": "Default Download Path:", 144 | "description": "" 145 | }, 146 | 147 | 148 | "OPN_defaultPath": { 149 | "message": "Download path of Aria2(only), optional", 150 | "description": "" 151 | }, 152 | 153 | "OP_protocol": { 154 | "message": "Protocol:", 155 | "description": "" 156 | }, 157 | 158 | "OPN_protocol": { 159 | "message": "RPC connection protocol of Aria2. Support ws, wss, http and https. Using Websocket will have more function.", 160 | "description": "" 161 | }, 162 | 163 | "OP_host": { 164 | "message": "Host:", 165 | "description": "" 166 | }, 167 | 168 | "OPN_host": { 169 | "message": "RPC host of Aria2. You can use ip or domain name.", 170 | "description": "" 171 | }, 172 | 173 | "OP_port": { 174 | "message": "Port:", 175 | "description": "" 176 | }, 177 | 178 | "OPN_port": { 179 | "message": "Aria2 RPC port", 180 | "description": "" 181 | }, 182 | 183 | "OP_interface": { 184 | "message": "Interface:", 185 | "description": "" 186 | }, 187 | 188 | "OPN_interface": { 189 | "message": "Aria2 RPC address. Default value is 'jsonrpc'", 190 | "description": "" 191 | }, 192 | 193 | "OP_token": { 194 | "message": "Token:", 195 | "description": "" 196 | }, 197 | 198 | "OPN_token": { 199 | "message": "Aria2 RPC secret, optional.", 200 | "description": "" 201 | }, 202 | 203 | "OP_zoom": { 204 | "message": "Zoom Level:", 205 | "description": "" 206 | }, 207 | 208 | "OPN_zoom": { 209 | "message": "Zoom Level of Download Panel. Default value is 1.", 210 | "description": "" 211 | }, 212 | 213 | "OP_sound": { 214 | "message": "Downlod Complete Sound:", 215 | "description": "" 216 | }, 217 | 218 | "OP_sound0": { 219 | "message": "None", 220 | "description": "" 221 | }, 222 | 223 | "OP_sound1": { 224 | "message": "Sound 1", 225 | "description": "" 226 | }, 227 | 228 | "OP_sound2": { 229 | "message": "Sound 2", 230 | "description": "" 231 | }, 232 | 233 | "OP_sound3": { 234 | "message": "Sound 3", 235 | "description": "" 236 | }, 237 | 238 | "OPN_sound": { 239 | "message": "[Websocket]Select a sound for download compete", 240 | "description": "" 241 | }, 242 | 243 | "OP_advanced": { 244 | "message": "Advanced:", 245 | "description": "" 246 | }, 247 | 248 | "OP_contextMenu": { 249 | "message": "Add Context Menus", 250 | "description": "" 251 | }, 252 | 253 | "OPN_contextMenu": { 254 | "message": "Add Context Menus to links, videos and audios ", 255 | "description": "" 256 | }, 257 | 258 | "OP_shutdown": { 259 | "message": "Shutdown Aria2c when the browser closed", 260 | "description": "" 261 | }, 262 | 263 | "OPN_shutdown": { 264 | "message": "Send '--stop-with-process=' command to aria2c", 265 | "description": "" 266 | }, 267 | 268 | "OP_aggressive": { 269 | "message": "Aggressive Mode", 270 | "description": "" 271 | }, 272 | 273 | "OPN_aggressive": { 274 | "message": "Detect download links aggressively. May cause some problems.", 275 | "description": "" 276 | }, 277 | 278 | "OP_winLoc": { 279 | "message": "Remember window location", 280 | "description": "" 281 | }, 282 | 283 | "OPN_winLoc": { 284 | "message": "The location of Download Panel will be saved (but firefox has bug. It cannot create window in the specific place)", 285 | "description": "" 286 | }, 287 | 288 | "OP_auto": { 289 | "message": "Aria2 Auto Start", 290 | "description": "" 291 | }, 292 | 293 | "OPN_auto": { 294 | "message": "Start Aria2 automatically when the download start", 295 | "description": "" 296 | }, 297 | 298 | "OP_autoSet": { 299 | "message": "AriaNg Auto Set", 300 | "description": "" 301 | }, 302 | 303 | "OPN_autoSet": { 304 | "message": "Set AriaNg automatically when the user click 'details'", 305 | "description": "" 306 | }, 307 | 308 | "OP_chgLog": { 309 | "message": "Display Changelog", 310 | "description": "" 311 | }, 312 | 313 | "OPN_chgLog": { 314 | "message": "Display Changelog After Update", 315 | "description": "" 316 | }, 317 | 318 | "OP_badge": { 319 | "message": "Display Current Active Download Count", 320 | "description": "" 321 | }, 322 | 323 | "OPN_badge": { 324 | "message": "[Websocket]Display current active download count on top of the icon", 325 | "description": "" 326 | }, 327 | 328 | "OP_downPanel": { 329 | "message": "Display Download Panel", 330 | "description": "" 331 | }, 332 | 333 | "OPN_downPanel": { 334 | "message": "Whether to display a download panel for the download event trigger from the auto observer", 335 | "description": "" 336 | }, 337 | 338 | "OP_cmDownPanel": { 339 | "message": "Display Download Panel (context menu)", 340 | "description": "" 341 | }, 342 | 343 | "OPN_cmDownPanel": { 344 | "message": "Whether to display a download panel for the download event trigger from the context menu", 345 | "description": "" 346 | }, 347 | 348 | "OP_winWidth": { 349 | "message": "Download Panel width offset", 350 | "description": "" 351 | }, 352 | 353 | "OPN_winWidth": { 354 | "message": "Fine Tune Download Window width", 355 | "description": "" 356 | }, 357 | 358 | "OP_winHeight": { 359 | "message": "Download Panel height offset", 360 | "description": "" 361 | }, 362 | 363 | "OPN_winHeight": { 364 | "message": "Fine Tune Download Window height", 365 | "description": "" 366 | }, 367 | 368 | "OP_ua": { 369 | "message": "Send User-Agent To Aria2", 370 | "description": "" 371 | }, 372 | 373 | "OPN_ua": { 374 | "message": "User-Agent will be same as the browser send", 375 | "description": "" 376 | }, 377 | 378 | "OP_fileSizeLimit": { 379 | "message": "File Size Limit:", 380 | "description": "" 381 | }, 382 | 383 | "OPN_fileSizeLimit": { 384 | "message": "Lower limit of the file size in bytes to trigger the download", 385 | "description": "" 386 | }, 387 | 388 | "OP_typeFilterA": { 389 | "message": "Include File Type:", 390 | "description": "" 391 | }, 392 | 393 | "OP_typeFilterB": { 394 | "message": "Exclude File Type:", 395 | "description": "" 396 | }, 397 | 398 | "OPN_typeFilter": { 399 | "message": "Regular Expressions: Matches MIME type", 400 | "description": "" 401 | }, 402 | 403 | "OP_urlFilterA": { 404 | "message": "Include URL:", 405 | "description": "" 406 | }, 407 | 408 | "OP_urlFilterB": { 409 | "message": "Exclude URL:", 410 | "description": "" 411 | }, 412 | 413 | "OPN_urlFilter": { 414 | "message": "Regular Expressions: Matches URL", 415 | "description": "" 416 | }, 417 | 418 | "OP_title": { 419 | "message": "Aria2 Download Manager Integration Options", 420 | "description": "" 421 | }, 422 | 423 | "OP_general": { 424 | "message": "General", 425 | "description": "" 426 | }, 427 | 428 | "OP_rpcServer": { 429 | "message": "RPC Servers", 430 | "description": "" 431 | }, 432 | 433 | "OP_rpcDefault": { 434 | "message": "Default Server", 435 | "description": "" 436 | }, 437 | 438 | "OP_rpc2": { 439 | "message": "RPC Server 2", 440 | "description": "" 441 | }, 442 | 443 | "OP_rpc3": { 444 | "message": "RPC Server 3", 445 | "description": "" 446 | }, 447 | 448 | "OP_exception": { 449 | "message": "Exceptions", 450 | "description": "" 451 | }, 452 | 453 | "OP_about": { 454 | "message": "About", 455 | "description": "" 456 | }, 457 | 458 | "OP_save": { 459 | "message": "Save", 460 | "description": "save button" 461 | }, 462 | 463 | "OP_saveComplete": { 464 | "message": "Options saved", 465 | "description": "" 466 | }, 467 | 468 | "CM_title": { 469 | "message": "Download with Aria2", 470 | "description": "Context Menu" 471 | }, 472 | 473 | "about_M1": { 474 | "message": "What is Aria2?", 475 | "description": "" 476 | }, 477 | 478 | "about_M2": { 479 | "message": "This add-on uses Mayswind's AriaNg.", 480 | "description": "" 481 | }, 482 | 483 | "about_L1": { 484 | "message": "Add-on home page", 485 | "description": "" 486 | }, 487 | 488 | "about_L2": { 489 | "message": "Aria2 Settings Samples", 490 | "description": "" 491 | }, 492 | 493 | "about_L3": { 494 | "message": "Submit a Bug or Feedback", 495 | "description": "" 496 | }, 497 | 498 | "about_L4": { 499 | "message": "Release Notes", 500 | "description": "" 501 | }, 502 | 503 | "about_L5": { 504 | "message": "Help Translate", 505 | "description": "" 506 | } 507 | } -------------------------------------------------------------------------------- /App/_locales/zh_CN/messages.json: -------------------------------------------------------------------------------- 1 | { 2 | "extensionName": { 3 | "message": "Aria2 下载器集成组件", 4 | "description": "扩展的名称" 5 | }, 6 | 7 | "extensionDescription": { 8 | "message": "取代内置的下载器。当开启时侦测下载连结,导引到本扩展并传送到Aria2", 9 | "description": "扩展的简介" 10 | }, 11 | 12 | "translator": { 13 | "message": "", 14 | "description": "" 15 | }, 16 | 17 | "translatorMessage": { 18 | "message": "", 19 | "description": "you can leave it blank if you have nothing to say" 20 | }, 21 | 22 | "direction": { 23 | "message": "ltr", 24 | "description": "语言方向" 25 | }, 26 | 27 | "enabled": { 28 | "message": "已启用", 29 | "description": "" 30 | }, 31 | 32 | "disabled": { 33 | "message": "已禁用", 34 | "description": "" 35 | }, 36 | 37 | "error_setConfig": { 38 | "message": "你必须先进行设置" 39 | }, 40 | 41 | "error_connect": { 42 | "message": "出错啦! 你可以检查输入、设置或Aria2的状态然后再试一次", 43 | "description": "当对Aria2的请求超时或回复不成功时,告知用户" 44 | }, 45 | 46 | "error_notSupported": { 47 | "message": "不支持", 48 | "description": "" 49 | }, 50 | 51 | "success_connect": { 52 | "message": "正在下载 $NAME$", 53 | "description": "当请求成功时,告知用户", 54 | "placeholders": { 55 | "name" : { 56 | "content" : "$1" 57 | } 58 | } 59 | }, 60 | 61 | "download_complete": { 62 | "message": "下载完成 \n\n $NAME$", 63 | "description": "当下载完成时,告知使用者", 64 | "placeholders": { 65 | "name" : { 66 | "content" : "$1" 67 | } 68 | } 69 | }, 70 | 71 | "download_error": { 72 | "message": "下载失败 \n\n $NAME$", 73 | "description": "当下载失败时,告知使用者", 74 | "placeholders": { 75 | "name" : { 76 | "content" : "$1" 77 | } 78 | } 79 | }, 80 | 81 | "UI_detail": { 82 | "message": "详情", 83 | "description": "" 84 | }, 85 | 86 | "UI_download": { 87 | "message": "下载", 88 | "description": "" 89 | }, 90 | 91 | "UI_save": { 92 | "message": "保存", 93 | "description": "" 94 | }, 95 | 96 | "UI_saveas": { 97 | "message": "另存为", 98 | "description": "下载窗口" 99 | }, 100 | 101 | "UI_open": { 102 | "message": "开启", 103 | "description": "" 104 | }, 105 | 106 | 107 | "UI_adv": { 108 | "message": "高级", 109 | "description": "" 110 | }, 111 | 112 | "UI_fileName": { 113 | "message": "文件名", 114 | "description": "" 115 | }, 116 | 117 | "UI_filePath": { 118 | "message": "文件路径", 119 | "description": "" 120 | }, 121 | 122 | "UI_from": { 123 | "message": "从", 124 | "description": "" 125 | }, 126 | 127 | "OP_message1": { 128 | "message": "你需要自行下载Aria2,完成以下的选项(协议、地址、端口、接口)并保存才能开始使用", 129 | "description": "" 130 | }, 131 | 132 | "OP_message2": { 133 | "message": "如果你不想要手动启动Aria2, 你可以自己写一个在后台启动Aria2的程序并注册到系统中的 'autostart' 或 'uri scheme'", 134 | "description": "" 135 | }, 136 | 137 | 138 | "OP_message3": { 139 | "message": "你可以在这里找到示例文件", 140 | "description": "" 141 | }, 142 | 143 | "OP_defaultPath": { 144 | "message": "默认下载路径:", 145 | "description": "" 146 | }, 147 | 148 | 149 | "OPN_defaultPath": { 150 | "message": "只适用于Aria2,可不填。", 151 | "description": "" 152 | }, 153 | 154 | "OP_protocol": { 155 | "message": "协议:", 156 | "description": "" 157 | }, 158 | 159 | "OPN_protocol": { 160 | "message": "Aria2的RPC通讯协议。可使用ws,wss,http,https,使用WebSocket时功能较多", 161 | "description": "" 162 | }, 163 | 164 | "OP_host": { 165 | "message": "地址:", 166 | "description": "" 167 | }, 168 | 169 | "OPN_host": { 170 | "message": "Aria2的RPC地址。你可以使用ip或域名。", 171 | "description": "" 172 | }, 173 | 174 | "OP_port": { 175 | "message": "端口:", 176 | "description": "" 177 | }, 178 | 179 | "OPN_port": { 180 | "message": "Aria2的RPC端口。", 181 | "description": "" 182 | }, 183 | 184 | "OP_interface": { 185 | "message": "接口:", 186 | "description": "" 187 | }, 188 | 189 | "OPN_interface": { 190 | "message": "Aria2的RPC接口. 默认值是 'jsonrpc'。", 191 | "description": "" 192 | }, 193 | 194 | "OP_token": { 195 | "message": "密钥:", 196 | "description": "" 197 | }, 198 | 199 | "OPN_token": { 200 | "message": "Aria2的RPC密钥, 可不填。", 201 | "description": "" 202 | }, 203 | 204 | "OP_zoom": { 205 | "message": "缩放倍数:", 206 | "description": "" 207 | }, 208 | 209 | "OPN_zoom": { 210 | "message": "用于下载窗口的缩放倍数. 默认值是 1。", 211 | "description": "" 212 | }, 213 | 214 | "OP_sound": { 215 | "message": "下载完成音效:", 216 | "description": "" 217 | }, 218 | 219 | "OP_sound0": { 220 | "message": "无", 221 | "description": "" 222 | }, 223 | 224 | "OP_sound1": { 225 | "message": "音效1", 226 | "description": "" 227 | }, 228 | 229 | "OP_sound2": { 230 | "message": "音效2", 231 | "description": "" 232 | }, 233 | 234 | "OP_sound3": { 235 | "message": "音效3", 236 | "description": "" 237 | }, 238 | 239 | "OPN_sound": { 240 | "message": "[Websocket]选择一个下载完成音效", 241 | "description": "" 242 | }, 243 | 244 | "OP_advanced": { 245 | "message": "进阶选项:", 246 | "description": "" 247 | }, 248 | 249 | "OP_contextMenu": { 250 | "message": "新增右键菜单", 251 | "description": "" 252 | }, 253 | 254 | "OPN_contextMenu": { 255 | "message": "在链接、影片、音乐新增右键菜单。", 256 | "description": "" 257 | }, 258 | 259 | "OP_shutdown": { 260 | "message": "当浏览器关闭时关闭 Aria2c", 261 | "description": "" 262 | }, 263 | 264 | "OPN_shutdown": { 265 | "message": "传送 '--stop-with-process=' 命令到 aria2c。", 266 | "description": "" 267 | }, 268 | 269 | "OP_aggressive": { 270 | "message": "偏执模式", 271 | "description": "" 272 | }, 273 | 274 | "OPN_aggressive": { 275 | "message": "疯狂的侦测下载连结。可能会造成问题。", 276 | "description": "" 277 | }, 278 | 279 | "OP_winLoc": { 280 | "message": "记住窗口位置", 281 | "description": "" 282 | }, 283 | 284 | "OPN_winLoc": { 285 | "message": "下载窗口的位置会被记录 (但是Firefox有问题,无法在指定位置产生窗口)。", 286 | "description": "" 287 | }, 288 | 289 | "OP_auto": { 290 | "message": "自动启动 Aria2", 291 | "description": "" 292 | }, 293 | 294 | "OPN_auto": { 295 | "message": "按下下载按钮后自动启动 Aria2", 296 | "description": "" 297 | }, 298 | 299 | "OP_autoSet": { 300 | "message": "自动设置 AriaNg", 301 | "description": "" 302 | }, 303 | 304 | "OPN_autoSet": { 305 | "message": "按下详情按钮后自动设置 AriaNg", 306 | "description": "" 307 | }, 308 | 309 | "OP_chgLog": { 310 | "message": "显示更新日誌", 311 | "description": "" 312 | }, 313 | 314 | "OPN_chgLog": { 315 | "message": "更新后自动显示更新日誌", 316 | "description": "" 317 | }, 318 | 319 | "OP_badge": { 320 | "message": "显示目前正在下载的数量", 321 | "description": "" 322 | }, 323 | 324 | "OPN_badge": { 325 | "message": "[Websocket]在图标上显示目前正在下载的数量", 326 | "description": "" 327 | }, 328 | 329 | "OP_downPanel": { 330 | "message": "显示下载窗口", 331 | "description": "" 332 | }, 333 | 334 | "OPN_downPanel": { 335 | "message": "自动启动的下载是否要显示下载窗口", 336 | "description": "" 337 | }, 338 | 339 | "OP_cmDownPanel": { 340 | "message": "显示下载窗口 (右键菜单)", 341 | "description": "" 342 | }, 343 | 344 | "OPN_cmDownPanel": { 345 | "message": "从右键菜单启动的下载是否要显示下载窗口", 346 | "description": "" 347 | }, 348 | 349 | "OP_winWidth": { 350 | "message": "下载窗口宽度改变量", 351 | "description": "" 352 | }, 353 | 354 | "OPN_winWidth": { 355 | "message": "微调下载窗口宽度。", 356 | "description": "" 357 | }, 358 | 359 | "OP_winHeight": { 360 | "message": "下载窗口高度改变量", 361 | "description": "" 362 | }, 363 | 364 | "OPN_winHeight": { 365 | "message": "微调下载窗口高度。", 366 | "description": "" 367 | }, 368 | 369 | "OP_ua": { 370 | "message": "传送 User-Agent 到 Aria2", 371 | "description": "" 372 | }, 373 | 374 | "OPN_ua": { 375 | "message": "User-Agent 会和浏览器送出的相同", 376 | "description": "" 377 | }, 378 | 379 | "OP_fileSizeLimit": { 380 | "message": "文件大小限制:", 381 | "description": "" 382 | }, 383 | 384 | "OPN_fileSizeLimit": { 385 | "message": "可以触发下载的最小文件大小(bytes)", 386 | "description": "" 387 | }, 388 | 389 | "OP_typeFilterA": { 390 | "message": "包含的文件格式:", 391 | "description": "" 392 | }, 393 | 394 | "OP_typeFilterB": { 395 | "message": "排除的文件格式:", 396 | "description": "" 397 | }, 398 | 399 | "OPN_typeFilter": { 400 | "message": "正则表达式: 匹配 MIME 类型", 401 | "description": "" 402 | }, 403 | 404 | "OP_urlFilterA": { 405 | "message": "包含的地址:", 406 | "description": "" 407 | }, 408 | 409 | "OP_urlFilterB": { 410 | "message": "排除的地址:", 411 | "description": "" 412 | }, 413 | 414 | "OPN_urlFilter": { 415 | "message": "正则表达式: 匹配 URL", 416 | "description": "" 417 | }, 418 | 419 | "OP_title": { 420 | "message": "Aria2 下载器整合元件 选项", 421 | "description": "" 422 | }, 423 | 424 | "OP_general": { 425 | "message": "一般", 426 | "description": "" 427 | }, 428 | 429 | "OP_rpcServer": { 430 | "message": "RPC 服务器", 431 | "description": "" 432 | }, 433 | 434 | "OP_rpcDefault": { 435 | "message": "默认服务器", 436 | "description": "" 437 | }, 438 | 439 | "OP_rpc2": { 440 | "message": "RPC 服务器 2", 441 | "description": "" 442 | }, 443 | 444 | "OP_rpc3": { 445 | "message": "RPC 服务器 3", 446 | "description": "" 447 | }, 448 | 449 | "OP_exception": { 450 | "message": "例外", 451 | "description": "" 452 | }, 453 | 454 | "OP_about": { 455 | "message": "关于", 456 | "description": "" 457 | }, 458 | 459 | "OP_save": { 460 | "message": "保存", 461 | "description": "保存按钮" 462 | }, 463 | 464 | "OP_saveComplete": { 465 | "message": "保存成功", 466 | "description": "" 467 | }, 468 | 469 | "CM_title": { 470 | "message": "使用 Aria2 下载", 471 | "description": "右键菜单" 472 | }, 473 | 474 | "about_M1": { 475 | "message": "什么是 Aria2?", 476 | "description": "" 477 | }, 478 | 479 | "about_M2": { 480 | "message": "本扩展使用 Mayswind 的 AriaNg.", 481 | "description": "" 482 | }, 483 | 484 | "about_L1": { 485 | "message": "扩展主页", 486 | "description": "" 487 | }, 488 | 489 | "about_L2": { 490 | "message": "Aria2 设置范本", 491 | "description": "" 492 | }, 493 | 494 | "about_L3": { 495 | "message": "提交错误或反馈", 496 | "description": "" 497 | }, 498 | 499 | "about_L4": { 500 | "message": "发行说明", 501 | "description": "" 502 | }, 503 | 504 | "about_L5": { 505 | "message": "帮忙翻译", 506 | "description": "" 507 | } 508 | } -------------------------------------------------------------------------------- /App/_locales/zh_TW/messages.json: -------------------------------------------------------------------------------- 1 | { 2 | "extensionName": { 3 | "message": "Aria2 下載器整合元件", 4 | "description": "擴充套件的名稱" 5 | }, 6 | 7 | "extensionDescription": { 8 | "message": "取代內建的下載器。當開啟時偵測下載連結,導引到本擴充套件並傳送到Aria2", 9 | "description": "擴充套件的簡介" 10 | }, 11 | 12 | "translator": { 13 | "message": "", 14 | "description": "" 15 | }, 16 | 17 | "translatorMessage": { 18 | "message": "", 19 | "description": "you can leave it blank if you have nothing to say" 20 | }, 21 | 22 | "direction": { 23 | "message": "ltr", 24 | "description": "語言方向" 25 | }, 26 | 27 | "enabled": { 28 | "message": "已啟用", 29 | "description": "" 30 | }, 31 | 32 | "disabled": { 33 | "message": "已停用", 34 | "description": "" 35 | }, 36 | 37 | "error_setConfig": { 38 | "message": "你必須先進行設定" 39 | }, 40 | 41 | "error_connect": { 42 | "message": "出錯啦! 你可以檢查輸入、設定或Aria2的狀態然後再試一次", 43 | "description": "當對Aria2的請求超時或回覆不成功時,告知使用者" 44 | }, 45 | 46 | "error_notSupported": { 47 | "message": "不支持", 48 | "description": "" 49 | }, 50 | 51 | "success_connect": { 52 | "message": "正在下載 $NAME$", 53 | "description": "當請求成功時,告知使用者", 54 | "placeholders": { 55 | "name" : { 56 | "content" : "$1" 57 | } 58 | } 59 | }, 60 | 61 | "download_complete": { 62 | "message": "下載完成 \n\n $NAME$", 63 | "description": "當下載完成時,告知使用者", 64 | "placeholders": { 65 | "name" : { 66 | "content" : "$1" 67 | } 68 | } 69 | }, 70 | 71 | "download_error": { 72 | "message": "下載失敗 \n\n $NAME$", 73 | "description": "當下載失敗時,告知使用者", 74 | "placeholders": { 75 | "name" : { 76 | "content" : "$1" 77 | } 78 | } 79 | }, 80 | 81 | "UI_detail": { 82 | "message": "詳細", 83 | "description": "" 84 | }, 85 | 86 | "UI_download": { 87 | "message": "下載", 88 | "description": "" 89 | }, 90 | 91 | "UI_save": { 92 | "message": "儲存", 93 | "description": "" 94 | }, 95 | 96 | "UI_saveas": { 97 | "message": "另存新檔", 98 | "description": "下載視窗" 99 | }, 100 | 101 | "UI_open": { 102 | "message": "開啟", 103 | "description": "" 104 | }, 105 | 106 | 107 | "UI_adv": { 108 | "message": "進階", 109 | "description": "" 110 | }, 111 | 112 | "UI_fileName": { 113 | "message": "檔案名稱", 114 | "description": "" 115 | }, 116 | 117 | "UI_filePath": { 118 | "message": "檔案路徑", 119 | "description": "" 120 | }, 121 | 122 | "UI_from": { 123 | "message": "從", 124 | "description": "" 125 | }, 126 | 127 | "OP_message1": { 128 | "message": "你需要自行下載Aria2,完成以下的選項(協議、地址、連接埠、接口)並儲存才能開始使用", 129 | "description": "" 130 | }, 131 | 132 | "OP_message2": { 133 | "message": "如果你不想要手動啟動Aria2, 你可以自己寫一個在背景啟動Aria2的程式並註冊到系統中的 'autostart' 或 'uri scheme'", 134 | "description": "" 135 | }, 136 | 137 | 138 | "OP_message3": { 139 | "message": "你可以在這裡找到範例檔", 140 | "description": "" 141 | }, 142 | 143 | "OP_defaultPath": { 144 | "message": "預設下載路徑:", 145 | "description": "" 146 | }, 147 | 148 | 149 | "OPN_defaultPath": { 150 | "message": "只適用於Aria2,可不填。", 151 | "description": "" 152 | }, 153 | 154 | "OP_protocol": { 155 | "message": "協定:", 156 | "description": "" 157 | }, 158 | 159 | "OPN_protocol": { 160 | "message": "Aria2的RPC通訊協定。可使用ws,wss,http,https,使用WebSocket時功能較多", 161 | "description": "" 162 | }, 163 | 164 | "OP_host": { 165 | "message": "地址:", 166 | "description": "" 167 | }, 168 | 169 | "OPN_host": { 170 | "message": "Aria2的RPC地址。你可以使用ip或域名。", 171 | "description": "" 172 | }, 173 | 174 | "OP_port": { 175 | "message": "連接埠:", 176 | "description": "" 177 | }, 178 | 179 | "OPN_port": { 180 | "message": "Aria2的RPC連接埠。", 181 | "description": "" 182 | }, 183 | 184 | "OP_interface": { 185 | "message": "接口:", 186 | "description": "" 187 | }, 188 | 189 | "OPN_interface": { 190 | "message": "Aria2的RPC接口. 預設值是 'jsonrpc'。", 191 | "description": "" 192 | }, 193 | 194 | "OP_token": { 195 | "message": "金鑰:", 196 | "description": "" 197 | }, 198 | 199 | "OPN_token": { 200 | "message": "Aria2的RPC金鑰, 可不填。", 201 | "description": "" 202 | }, 203 | 204 | "OP_zoom": { 205 | "message": "縮放倍數:", 206 | "description": "" 207 | }, 208 | 209 | "OPN_zoom": { 210 | "message": "用於下載視窗的縮放倍數. 預設值是 1。", 211 | "description": "" 212 | }, 213 | 214 | "OP_sound": { 215 | "message": "下載完成音效:", 216 | "description": "" 217 | }, 218 | 219 | "OP_sound0": { 220 | "message": "無", 221 | "description": "" 222 | }, 223 | 224 | "OP_sound1": { 225 | "message": "音效1", 226 | "description": "" 227 | }, 228 | 229 | "OP_sound2": { 230 | "message": "音效2", 231 | "description": "" 232 | }, 233 | 234 | "OP_sound3": { 235 | "message": "音效3", 236 | "description": "" 237 | }, 238 | 239 | "OPN_sound": { 240 | "message": "[Websocket]選擇一個下載完成音效", 241 | "description": "" 242 | }, 243 | 244 | "OP_advanced": { 245 | "message": "進階選項:", 246 | "description": "" 247 | }, 248 | 249 | "OP_contextMenu": { 250 | "message": "新增右鍵選單", 251 | "description": "" 252 | }, 253 | 254 | "OPN_contextMenu": { 255 | "message": "在連結、影片、音樂新增右鍵選單。", 256 | "description": "" 257 | }, 258 | 259 | "OP_shutdown": { 260 | "message": "當瀏覽器關閉時關閉 Aria2c", 261 | "description": "" 262 | }, 263 | 264 | "OPN_shutdown": { 265 | "message": "傳送 '--stop-with-process=' 指令到 aria2c。", 266 | "description": "" 267 | }, 268 | 269 | "OP_aggressive": { 270 | "message": "偏執模式", 271 | "description": "" 272 | }, 273 | 274 | "OPN_aggressive": { 275 | "message": "瘋狂的偵測下載連結。可能會造成問題。", 276 | "description": "" 277 | }, 278 | 279 | "OP_winLoc": { 280 | "message": "記住視窗位置", 281 | "description": "" 282 | }, 283 | 284 | "OPN_winLoc": { 285 | "message": "下載視窗的位置會被記錄 (但是Firefox有問題,無法在指定位置產生視窗)。", 286 | "description": "" 287 | }, 288 | 289 | "OP_auto": { 290 | "message": "自動啟動 Aria2", 291 | "description": "" 292 | }, 293 | 294 | "OPN_auto": { 295 | "message": "按下下載按鈕後自動啟動 Aria2", 296 | "description": "" 297 | }, 298 | 299 | "OP_autoSet": { 300 | "message": "自動設定 AriaNg", 301 | "description": "" 302 | }, 303 | 304 | "OPN_autoSet": { 305 | "message": "按下詳細按鈕後自動設定 AriaNg", 306 | "description": "" 307 | }, 308 | 309 | "OP_chgLog": { 310 | "message": "顯示更新日誌", 311 | "description": "" 312 | }, 313 | 314 | "OPN_chgLog": { 315 | "message": "更新後自動顯示更新日誌", 316 | "description": "" 317 | }, 318 | 319 | "OP_badge": { 320 | "message": "顯示目前正在下載的數量", 321 | "description": "" 322 | }, 323 | 324 | "OPN_badge": { 325 | "message": "[Websocket]在圖標上顯示目前正在下載的數量", 326 | "description": "" 327 | }, 328 | 329 | "OP_downPanel": { 330 | "message": "顯示下載視窗", 331 | "description": "" 332 | }, 333 | 334 | "OPN_downPanel": { 335 | "message": "自動啟動的下載是否要顯示下載視窗", 336 | "description": "" 337 | }, 338 | 339 | "OP_cmDownPanel": { 340 | "message": "顯示下載視窗 (右鍵選單)", 341 | "description": "" 342 | }, 343 | 344 | "OPN_cmDownPanel": { 345 | "message": "從右鍵選單啟動的下載是否要顯示下載視窗", 346 | "description": "" 347 | }, 348 | 349 | "OP_winWidth": { 350 | "message": "下載視窗寬度改變量", 351 | "description": "" 352 | }, 353 | 354 | "OPN_winWidth": { 355 | "message": "微調下載視窗寬度。", 356 | "description": "" 357 | }, 358 | 359 | "OP_winHeight": { 360 | "message": "下載視窗高度改變量", 361 | "description": "" 362 | }, 363 | 364 | "OPN_winHeight": { 365 | "message": "微調下載視窗高度。", 366 | "description": "" 367 | }, 368 | 369 | "OP_ua": { 370 | "message": "傳送 User-Agent 到 Aria2", 371 | "description": "" 372 | }, 373 | 374 | "OPN_ua": { 375 | "message": "User-Agent 會和瀏覽器送出的相同", 376 | "description": "" 377 | }, 378 | 379 | "OP_fileSizeLimit": { 380 | "message": "檔案大小限制:", 381 | "description": "" 382 | }, 383 | 384 | "OPN_fileSizeLimit": { 385 | "message": "可以觸發下載的最小檔案大小(bytes)", 386 | "description": "" 387 | }, 388 | 389 | "OP_typeFilterA": { 390 | "message": "包含的檔案格式:", 391 | "description": "" 392 | }, 393 | 394 | "OP_typeFilterB": { 395 | "message": "排除的檔案格式:", 396 | "description": "" 397 | }, 398 | 399 | "OPN_typeFilter": { 400 | "message": "正規表達式: 匹配 MIME 類型", 401 | "description": "" 402 | }, 403 | 404 | "OP_urlFilterA": { 405 | "message": "包含的網址:", 406 | "description": "" 407 | }, 408 | 409 | "OP_urlFilterB": { 410 | "message": "排除的網址:", 411 | "description": "" 412 | }, 413 | 414 | "OPN_urlFilter": { 415 | "message": "正規表達式: 匹配 URL", 416 | "description": "" 417 | }, 418 | 419 | "OP_title": { 420 | "message": "Aria2 下載器整合元件 選項", 421 | "description": "" 422 | }, 423 | 424 | "OP_general": { 425 | "message": "一般", 426 | "description": "" 427 | }, 428 | 429 | "OP_rpcServer": { 430 | "message": "RPC 伺服器", 431 | "description": "" 432 | }, 433 | 434 | "OP_rpcDefault": { 435 | "message": "預設伺服器", 436 | "description": "" 437 | }, 438 | 439 | "OP_rpc2": { 440 | "message": "RPC 伺服器 2", 441 | "description": "" 442 | }, 443 | 444 | "OP_rpc3": { 445 | "message": "RPC 伺服器 3", 446 | "description": "" 447 | }, 448 | 449 | "OP_exception": { 450 | "message": "例外", 451 | "description": "" 452 | }, 453 | 454 | "OP_about": { 455 | "message": "關於", 456 | "description": "" 457 | }, 458 | 459 | "OP_save": { 460 | "message": "儲存", 461 | "description": "儲存按鈕" 462 | }, 463 | 464 | "OP_saveComplete": { 465 | "message": "儲存成功", 466 | "description": "" 467 | }, 468 | 469 | "CM_title": { 470 | "message": "使用 Aria2 下載", 471 | "description": "右鍵選單" 472 | }, 473 | 474 | "about_M1": { 475 | "message": "什麼是 Aria2?", 476 | "description": "" 477 | }, 478 | 479 | "about_M2": { 480 | "message": "本附加元件使用 Mayswind 的 AriaNg.", 481 | "description": "" 482 | }, 483 | 484 | "about_L1": { 485 | "message": "附加元件首頁", 486 | "description": "" 487 | }, 488 | 489 | "about_L2": { 490 | "message": "Aria2 設定範例", 491 | "description": "" 492 | }, 493 | 494 | "about_L3": { 495 | "message": "提交錯誤或回饋", 496 | "description": "" 497 | }, 498 | 499 | "about_L4": { 500 | "message": "發行說明", 501 | "description": "" 502 | }, 503 | 504 | "about_L5": { 505 | "message": "幫忙翻譯", 506 | "description": "" 507 | } 508 | } -------------------------------------------------------------------------------- /App/config.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | var config = {}; 3 | config.command = { 4 | get guess() { 5 | return { 6 | path: "", 7 | protocol: "ws", 8 | host: "127.0.0.1", 9 | port: "6800", 10 | interf: "jsonrpc", 11 | token: "", 12 | zoom: "1", 13 | sound: "3", 14 | menu: false, 15 | shutdown: false, 16 | aggressive: false, 17 | windowLoc: false, 18 | auto: true, 19 | autoSet: true, 20 | chgLog: true, 21 | badge: true, 22 | cmDownPanel: true, 23 | downPanel: true, 24 | ua: false, 25 | fileSizeLimit: 0, 26 | typeFilterA: "", 27 | urlFilterA: "", 28 | typeFilterB: "", 29 | urlFilterB: "", 30 | }; 31 | }, 32 | get s2() { 33 | return { 34 | path2: "", 35 | protocol2: "ws", 36 | host2: "127.0.0.1", 37 | port2: "6800", 38 | interf2: "jsonrpc", 39 | token2: "", 40 | }; 41 | }, 42 | get s3() { 43 | return { 44 | path3: "", 45 | protocol3: "ws", 46 | host3: "127.0.0.1", 47 | port3: "6800", 48 | interf3: "jsonrpc", 49 | token3: "", 50 | }; 51 | } 52 | }; 53 | -------------------------------------------------------------------------------- /App/data/DownloadPanel/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Download Panel 5 | 6 | 7 | 8 | 9 | 21 | 293 | 294 | 295 | 296 |
297 |
298 |
299 | 300 | 301 | 302 | 303 |

File Name 
304 | 305 |

306 |

File Path
307 | 308 |

309 |

File Size
310 | 311 |

312 |

From 
313 | 314 |

315 | 316 | 317 | 318 | 323 | 324 |
325 |
326 |
327 | 328 | 329 | 330 | 331 | 332 | 333 | 334 | -------------------------------------------------------------------------------- /App/data/DownloadPanel/index.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | var advl = false; 3 | 4 | function handleResponse(message) { 5 | //console.log(message); 6 | switch (message.response) { 7 | case "all": 8 | document.getElementById('url').value = message.url; 9 | document.getElementById('fs').textContent = message.fileSize; 10 | document.getElementById('fn').value = decodeFn(message.fileName); 11 | document.querySelector(".head").value = message.header; 12 | document.getElementById('db').focus(); 13 | break; 14 | case "send success": 15 | var getting = browser.windows.getCurrent(); 16 | getting.then(windowInfo => { 17 | browser.windows.remove(windowInfo.id) 18 | }, () => {}); 19 | break; 20 | case "saveas create": 21 | break; 22 | default: 23 | console.log("Message from the content script: " + request.get); 24 | } 25 | } 26 | 27 | function handleError(error) { 28 | browser.notifications.create({ 29 | type: 'basic', 30 | iconUrl: '/data/icons/48.png', 31 | title: browser.i18n.getMessage("extensionName"), 32 | message: error.message || error 33 | }); 34 | } 35 | ////////////////////////////////////////// 36 | /////////////////////////////////////// 37 | function init() { 38 | var sending = browser.runtime.sendMessage({ 39 | get: "all" 40 | }); 41 | sending.then(handleResponse, handleError); 42 | document.documentElement.style.transformOrigin = "left top"; 43 | browser.storage.local.get(config.command.guess, (item) => { 44 | document.documentElement.style.transform = "scale(" + item.zoom + ")"; 45 | }); 46 | document.getElementById('db').addEventListener('click', download); 47 | document.getElementById('sb').addEventListener('click', save); 48 | document.getElementById('sab').addEventListener('click', saveas); 49 | document.getElementById('advb').addEventListener('click', adv); 50 | document.querySelectorAll('[data-message]').forEach(n => { 51 | n.textContent = browser.i18n.getMessage(n.dataset.message); 52 | }); 53 | document.body.style = "direction: " + browser.i18n.getMessage("direction"); 54 | } 55 | 56 | function saveWinLoc (){ 57 | browser.storage.local.get(config.command.guess, (item) => { 58 | if (item.windowLoc) { 59 | var getting = browser.windows.getCurrent(); 60 | getting.then(windowInfo => { 61 | browser.storage.local.set({ 62 | dpTop: windowInfo.top, 63 | dpLeft: windowInfo.left 64 | }); 65 | }, () => {}); 66 | } 67 | }); 68 | } 69 | 70 | function download() { 71 | const url = document.getElementById('url').value; 72 | const fn = document.getElementById('fn').value; 73 | const fp = document.getElementById('fp').value; 74 | const head = document.querySelector(".head").value 75 | const rpc = document.querySelector(".s1").value 76 | verifyFileName(fn).then((e) => { 77 | if (e.length != 0) { 78 | document.getElementById('fn').style = "border: 1px solid red;box-shadow: red 0px 0px 4px;"; 79 | document.getElementById('fn').onchange = function() { 80 | document.getElementById('fn').style = ""; 81 | document.getElementById('fn').onchange = null; 82 | }; 83 | } 84 | else { 85 | var sending = browser.runtime.sendMessage({ 86 | get: "download", 87 | url: url, 88 | fileName: fn, 89 | filePath: fp, 90 | header: head.split(","), 91 | server: rpc, 92 | }); 93 | sending.then(handleResponse, handleError); 94 | saveWinLoc(); 95 | } 96 | }); 97 | } 98 | 99 | function save() { 100 | const url = document.getElementById('url').value; 101 | const fn = document.getElementById('fn').value; 102 | const fp = document.getElementById('fp').value; 103 | const head = document.querySelector(".head").value 104 | verifyFileName(fn).then((e) => { 105 | if (e.length != 0) { 106 | document.getElementById('fn').style = "border: 1px solid red;box-shadow: red 0px 0px 4px;"; 107 | document.getElementById('fn').onchange = function() { 108 | document.getElementById('fn').style = ""; 109 | document.getElementById('fn').onchange = null; 110 | }; 111 | } 112 | else { 113 | var getting = browser.windows.getCurrent(); 114 | getting.then((windowInfo) => { 115 | var sending = browser.runtime.sendMessage({ 116 | get: "save", 117 | url: url, 118 | fileName: fn, 119 | filePath: fp, 120 | header: head.split(","), 121 | incognito: windowInfo.incognito, 122 | }); 123 | sending.then(handleResponse, handleError); 124 | }, (e) => console.log(e)); 125 | saveWinLoc(); 126 | } 127 | }); 128 | } 129 | 130 | function saveas() { 131 | const url = document.getElementById('url').value; 132 | const fn = document.getElementById('fn').value; 133 | const fp = document.getElementById('fp').value; 134 | const head = document.querySelector(".head").value 135 | verifyFileName(fn).then((e) => { 136 | if (e.length != 0) { 137 | document.getElementById('fn').style = "border: 1px solid red;box-shadow: red 0px 0px 4px;"; 138 | document.getElementById('fn').onchange = function() { 139 | document.getElementById('fn').style = ""; 140 | document.getElementById('fn').onchange = null; 141 | }; 142 | } 143 | else { 144 | var getting = browser.windows.getCurrent(); 145 | getting.then((windowInfo) => { 146 | var sending = browser.runtime.sendMessage({ 147 | get: "saveas", 148 | url: url, 149 | fileName: fn, 150 | filePath: fp, 151 | header: head.split(","), 152 | wid: windowInfo.id, 153 | incognito: windowInfo.incognito, 154 | }); 155 | sending.then(handleResponse, handleError); 156 | }, (e) => console.log(e)); 157 | saveWinLoc(); 158 | } 159 | }); 160 | } 161 | 162 | function adv() { 163 | if (advl == false) { 164 | var getting = browser.windows.getCurrent(); 165 | getting.then((windowInfo) => { 166 | var updating = browser.windows.update(windowInfo.id, { 167 | height: windowInfo.height + 95, 168 | }); 169 | }); 170 | document.querySelector(".head").style = "display:block"; 171 | document.querySelector(".s1").style = "display:block"; 172 | advl = true; 173 | } 174 | else { 175 | var getting = browser.windows.getCurrent(); 176 | getting.then((windowInfo) => { 177 | var updating = browser.windows.update(windowInfo.id, { 178 | height: windowInfo.height - 95, 179 | }); 180 | }); 181 | document.querySelector(".head").style = "display:none"; 182 | document.querySelector(".s1").style = "display:none"; 183 | advl = false; 184 | } 185 | } 186 | 187 | function decodeFn(fn) { 188 | var res = jschardet.detect(fn).encoding; 189 | if (res != "ascii") { 190 | var decoder = new TextDecoder(res); 191 | var charcode = []; 192 | for(var i = 0, length = fn.length; i < length; i++) { 193 | var code = fn.charCodeAt(i); 194 | charcode.push(code); 195 | } 196 | var charcodeUint = new Uint8Array(); 197 | charcodeUint = Uint8Array.from(charcode); 198 | var out = decoder.decode(charcodeUint); 199 | } 200 | else { 201 | var out = fn; 202 | } 203 | return out; 204 | } 205 | 206 | document.addEventListener('DOMContentLoaded', init); -------------------------------------------------------------------------------- /App/data/Sound/complete1.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/Sound/complete1.wav -------------------------------------------------------------------------------- /App/data/Sound/complete2.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/Sound/complete2.wav -------------------------------------------------------------------------------- /App/data/Sound/complete3.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/Sound/complete3.wav -------------------------------------------------------------------------------- /App/data/action/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | action 5 | 6 | 7 | 8 | 9 | 10 | 13 | 25 | 129 | 130 | 131 | 132 | 133 | 134 |
135 |
136 |
137 | 141 | 142 |
143 |
144 |
145 | 146 | 147 | 148 | 149 | 150 | 151 | -------------------------------------------------------------------------------- /App/data/action/index.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | function handleResponse(message) { 4 | //console.log(message); 5 | switch (message.response) { 6 | case "send success": 7 | break; 8 | default: 9 | console.log("Message from the content script: " + request.get); 10 | } 11 | } 12 | 13 | function handleError(error) { 14 | console.log(error); 15 | } 16 | 17 | function sw(e) { 18 | //console.log(e); 19 | var sending = browser.runtime.sendMessage({ 20 | get: "changeState", 21 | checked: e.target.checked 22 | }); 23 | sending.then(handleResponse, handleError); 24 | } 25 | 26 | function detail() { 27 | browser.storage.local.get("initialize", item => { 28 | if (!item.initialize || (item.initialize == undefined)) { 29 | browser.runtime.openOptionsPage(); 30 | browser.notifications.create({ 31 | type: 'basic', 32 | iconUrl: '/data/icons/48.png', 33 | title: browser.i18n.getMessage("extensionName"), 34 | message: browser.i18n.getMessage("error_setConfig") 35 | }); 36 | } 37 | else { 38 | browser.storage.local.get(config.command.guess, function(item) { 39 | var ariangUrl = "../../data/ariang/index.html" 40 | if (item.autoSet) { 41 | ariangUrl += "#!/settings/rpc/set/"; 42 | ariangUrl += (item.protocol + "/" + item.host + "/" + item.port + "/" + 43 | item.interf + "/" + btoa(item.token)); 44 | } 45 | browser.tabs.create({ 46 | url: ariangUrl 47 | }); 48 | window.close(); 49 | }); 50 | } 51 | }); 52 | } 53 | 54 | function launch() { 55 | document.getElementById('switch').addEventListener('change', sw); 56 | document.getElementById('detail').addEventListener('click', detail); 57 | document.querySelectorAll('[data-message]').forEach(n => { 58 | n.textContent = browser.i18n.getMessage(n.dataset.message); 59 | }); 60 | browser.storage.local.get("enabled", function(item) { 61 | document.getElementById('switch').checked = item.enabled; 62 | }); 63 | } 64 | //document.addEventListener('WebComponentsReady', launch, false); 65 | document.addEventListener('DOMContentLoaded', launch); -------------------------------------------------------------------------------- /App/data/ariang/LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2016-2019 MaysWind (i@mayswind.net) 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /App/data/ariang/css/aria-ng-2a46099f8c.min.css: -------------------------------------------------------------------------------- 1 | /*! 2 | * AriaNg 3 | * https://github.com/mayswind/AriaNg 4 | */body,html{margin:0;padding:0}body{-ms-user-select:none;-webkit-user-select:none;-moz-user-select:none;user-select:none}td{vertical-align:middle!important}.blur{-webkit-filter:blur(5px);-moz-filter:blur(5px);-ms-filter:blur(5px);filter:blur(5px);filter:progid:DXImageTransform.Microsoft.Blur(PixelRadius=5,MakeShadow=false)}.disable-overlay{position:fixed;left:0;top:0;right:0;bottom:0;z-index:9999;cursor:not-allowed}.main-header .logo{overflow:visible}.main-header .logo .dropdown-menu{z-index:2000}.main-header .navbar .nav>li{display:inline-block}.main-header .navbar .nav>li>a{padding-left:10px;padding-right:10px}.main-header .navbar .nav>li.disabled>a{pointer-events:none!important}.main-header .navbar .navbar-nav{margin-left:5px}.main-header .navbar .navbar-searchbar{padding-top:8px;padding-right:20px;float:right}.main-header .logo .logo-mini{font-size:14px!important}.main-header .logo .logo-lg{cursor:pointer}.main-header .rpcselect-dropdown{max-height:200px;overflow-x:hidden}.main-sidebar{z-index:1010}.content-wrapper,.right-side{background-color:#fff}.content-wrapper>.content-body{overflow-y:scroll}.main-footer>.navbar{margin-bottom:0;min-height:inherit}.main-footer>.navbar>.navbar-toolbar>.nav{float:left;margin:0}.main-footer>.navbar>.navbar-toolbar>.nav>li{display:inline-block;float:left}.main-footer>.navbar>.navbar-toolbar>.nav>li>a{padding:0 10px}.main-footer>.navbar>.navbar-toolbar>.nav>li:first-child>a{padding-left:0}.dropdown-menu.right-align{left:inherit;right:0}.default-cursor{cursor:default!important}.pointer-cursor{cursor:pointer!important}.text-cursor{cursor:text!important}.allow-word-break{word-wrap:break-word;word-break:break-all}.auto-ellipsis{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@media (max-width:767px){.navbar-nav .open .dropdown-menu{position:absolute;border:1px solid #eee;background-color:#fff}.main-footer>.navbar>.navbar-toolbar>.nav>li>a{padding-left:8px;padding-right:8px}}.toolbar{cursor:pointer}.toolbar:active{-webkit-box-shadow:inset 0 2px 6px rgba(0,0,0,.125);box-shadow:inset 0 2px 6px rgba(0,0,0,.125)}.dropdown-menu small{color:#999}.dropdown-submenu{position:relative}.dropdown-submenu>.dropdown-menu{top:0;left:100%;margin-top:-6px;margin-left:-1px;border-radius:0 6px 6px 6px}.dropdown-submenu:hover>.dropdown-menu{display:block}.dropdown-submenu>a:after{display:block;content:" ";float:right;width:0;height:0;border-color:transparent;border-style:solid;border-width:5px 0 5px 5px;border-left-color:#ccc;margin-top:5px;margin-right:-10px}.dropdown-menu>li.dropdown-submenu:hover{background-color:#e1e3e9}.dropdown-submenu:hover>a:after{border-left-color:#fff}.dropdown-submenu.pull-left{float:none}.dropdown-submenu.pull-left>.dropdown-menu{left:-100%;margin-left:10px;border-radius:6px 0 6px 6px}::-webkit-scrollbar{width:10px}::-webkit-scrollbar-thumb{background-clip:padding-box;background-color:#c4d2db;min-height:28px}::-webkit-scrollbar-thumb:active,::-webkit-scrollbar-thumb:hover{background-color:#d4dfe7}@media (max-width:767px){::-webkit-scrollbar{width:6px}}.fade-in.ng-enter{-webkit-transition:all .3s linear;transition:all .3s linear;opacity:0}.fade-in.ng-enter.ng-enter-active{opacity:1}.btn-group+.btn{margin-left:4px}.progress-bar{-webkit-transition:initial!important;transition:initial!important}.input-group-addon-compact{padding:0 4px}.nav-tabs-custom .nav-tabs>li>a{display:inline-block}.nav-tabs-custom .nav-tabs>li>a.nav-tab-close{padding-left:0;margin-left:-12px}.nav-tabs-custom .nav-tabs>li.nav-tab-title-rpcname>a{max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;vertical-align:bottom}@media (max-width:991px){.nav-tabs-custom .nav-tabs>li.nav-tab-title-rpcname>a{max-width:150px}}@media (max-width:767px){.nav-tabs-custom .nav-tabs>li.nav-tab-title-rpcname>a{max-width:120px}}.input-group.input-group-multiple>.input-group-addon{border-left:0;border-right:0}.input-group.input-group-multiple>.input-group-addon-container:first-child,.input-group.input-group-multiple>.input-group-addon:first-child{border-left:1px solid #d2d6de}.input-group .input-group-addon-container{width:1%;display:table-cell}.fa-half{font-size:.5em}.fa-1_1x{font-size:1.1em}.fa-rotate-45{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=1)";-webkit-transform:rotate(45deg);transform:rotate(45deg);-webkit-filter:none;filter:none}.fa-right-bottom{right:0;bottom:-6px}.fa-order-asc,.fa-order-desc,.fa-right-bottom{position:relative}.fa-order-asc{bottom:-2px}.fa-order-desc{bottom:2px}.checkbox.checkbox-hide{padding-left:0}.checkbox.checkbox-hide>input,.checkbox.checkbox-hide>input+label:after,.checkbox.checkbox-hide>input+label:before{display:none!important}.checkbox.checkbox-hide>label{padding-left:0}.checkbox-compact{margin-top:2px;margin-bottom:2px}.checkbox-inline{display:inline-block}.icon-dir-expand+.checkbox{margin-left:6px}input-dropdown[input-class-name=form-control]>.input-dropdown{width:100%}.input-dropdown ul{border:1px solid #888}.input-dropdown ul>li.active{background-color:#e1e3e9}.input-dropdown ul>li{padding:2px 14px}.gu-mirror{cursor:grabbing;cursor:-webkit-grabbing}.global-status{cursor:pointer}.global-status>.realtime-speed{padding:0 15px}.global-status>.realtime-speed:first-child{padding-left:5px}.global-status>.realtime-speed:last-child{padding-right:5px}.global-status span.realtime-speed>i{padding-right:2px}.task-table{margin-left:15px;margin-right:15px}.task-table .task-table-title{font-size:12px;padding-top:4px;padding-bottom:4px}.task-table .task-table-title a{color:#000;cursor:pointer}.task-table>.task-table-body.draggable{cursor:move;cursor:grab;cursor:-webkit-grab}.task-table>.task-table-body>div.row{padding-top:8px;padding-bottom:8px;border-top:1px solid #ddd}.task-table>div.row:first-child{border-top:inherit}@media (max-width:767px){.task-table>.task-table-title{display:none!important}.task-table>.task-table-body>div.row:first-child{border-top:inherit}}.task-table .task-name{font-size:14px;display:block}.task-table .peer-name-wrapper{display:inline-block;width:100%}.task-table .task-files,.task-table .task-size{font-size:12px;display:block}.task-table .progress{margin-bottom:0}.task-table .task-last-time,.task-table .task-last-time+.task-download-speed,.task-table .task-seeders{color:#888;font-size:12px}.task-table .task-last-time+.task-download-speed,.task-table .task-seeders{margin-top:1px}.task-table .task-last-time+.task-download-speed{padding-left:20px}.task-table .task-download-speed,.task-table .task-peer-download-speed{font-size:12px}.task-table .checkbox,.task-table .radio{margin-top:0;margin-bottom:0}.task-table .progress{position:relative}.task-table .progress span{position:absolute;display:block;width:100%}.task-table .progress span.progress-lower{color:#000}@media (max-width:767px){.task-table .task-peer-download-speed{float:right}}.task-table .task-right-arrow{visibility:hidden;position:absolute;right:14px;margin-top:-12px}.task-table .row:hover .task-right-arrow,.task-table .row[data-selected=true] .task-right-arrow{visibility:visible}.task-table .task-right-arrow i{color:#c8c8c8;font-size:60px}.task-table .task-right-arrow i:hover{color:#d8d8d8}.settings-table{margin-left:15px;margin-right:15px}.settings-table .settings-table-title{font-size:12px;padding-top:4px;padding-bottom:4px}.settings-table .settings-table-title a{color:#000}.settings-table>div.row{padding-top:8px;padding-bottom:8px;border-top:1px solid #ddd}.settings-table>div.row:first-child{border-top:inherit}.settings-table+.settings-table>div.row:first-child{border-top:1px solid #ddd}.settings-table .input-group-addon{background-color:#eee}.settings-table .asterisk{color:red}.settings-table .description,.settings-table .description-inline{color:#888;font-size:12px;font-weight:400;font-style:normal}.settings-table .description{display:block}.settings-table .description-inline{display:inline-block}.settings-table em{color:#888;font-size:12px;font-weight:400}.settings-table .setting-value .form-group{margin-bottom:0}.settings-table .setting-value .form-group .form-control-icon{color:#3c8dbc}.settings-table .setting-value .form-group select.form-control+.form-control-icon>.form-control-feedback{right:10px}.settings-table .setting-value .input-group .form-group .form-control:focus{z-index:inherit}.settings-table .setting-value .input-group .form-control-rpcport{min-width:70px}.settings-table .setting-value .input-group .form-control-rpcinterface{min-width:100px}@media (max-width:991px){.settings-table .setting-value .input-group .form-control-rpcinterface,.settings-table .setting-value .input-group .form-control-rpcport{min-width:60px}}.settings-table .tip{font-size:12px;padding:4px 8px}.settings-table .multi-line{display:block}@media (max-width:767px){.settings-table .setting-key{font-weight:700}.settings-table .description{display:inline-block}}@media (min-width:768px){.settings-table .setting-key-without-desc{padding-top:6px}}.new-task-table{margin-left:15px;margin-right:15px}.new-task-table>div.row{padding-top:8px;padding-bottom:8px}.new-task-table>div.row:first-child{border-top:inherit}.new-task-table .new-task-toollink>a{margin-right:20px}@media (max-width:767px){.new-task-table .new-task-toollink>a{display:block}}.settings-table .new-task-filter-title{padding-top:6px}.piece-bar-wrapper{height:20px}.piece-bar{width:100%}.piece-map{padding-left:6px;padding-right:2px;line-height:11px}.piece-legends{text-align:center;margin-top:4px;margin-bottom:4px}.piece-legend{display:inline-block;margin-right:4px}.piece-legend>.piece,.piece-map .piece{width:10px;height:10px;background-color:#eef2f4;border:1px solid #dee2e5;display:inline-block;margin-right:1px}.piece-legend>.piece.piece-completed,.piece-map .piece.piece-completed{background-color:#b8dd69;border-color:#b8dd69}.piece-legend>.piece{margin-right:4px}.chart-popover{max-width:320px}.chart-popover .popover-content{padding:0}.chart-pop-wrapper{padding-left:4px;padding-right:4px;overflow-x:hidden}.chart-pop{display:table}.chart-pop .loading{width:100%;height:100%;display:table-cell;text-align:center;vertical-align:middle}.global-status-chart{width:312px;height:200px}.task-status-chart-wrapper{overflow-x:hidden}@-webkit-keyframes three-quarters{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}@keyframes three-quarters{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}.btn-spinner{font-family:sans-serif;font-weight:100}.btn-spinner:not(:required){-webkit-animation:three-quarters 1.25s infinite linear;animation:three-quarters 1.25s infinite linear;border:3px solid #8c8c8c;border-right-color:transparent;border-radius:100%;-webkit-box-sizing:border-box;box-sizing:border-box;display:inline-block;position:relative;vertical-align:middle;overflow:hidden;text-indent:-9999px;width:18px;height:18px}.btn-danger .btn-spinner:not(:required),.btn-primary .btn-spinner:not(:required){border:3px solid #efefef;border-right-color:transparent}.btn-spinner:not(:required){margin-left:-22px;opacity:0;-webkit-transition:margin .4s ease-out,opacity .2s ease-out;transition:margin .4s ease-out,opacity .2s ease-out}.is-loading .btn-spinner{-webkit-transition:margin .2s ease-in,opacity .4s ease-in;transition:margin .2s ease-in,opacity .4s ease-in;margin-left:5px;opacity:1}.skin-aria-ng{overflow-y:hidden}.skin-aria-ng,.skin-aria-ng .h1,.skin-aria-ng .h2,.skin-aria-ng .h3,.skin-aria-ng .h4,.skin-aria-ng .h5,.skin-aria-ng .h6,.skin-aria-ng .main-header .logo,.skin-aria-ng .popover,.skin-aria-ng .sweet-alert,.skin-aria-ng .tooltip,.skin-aria-ng h1,.skin-aria-ng h2,.skin-aria-ng h3,.skin-aria-ng h4,.skin-aria-ng h5,.skin-aria-ng h6{font-family:Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif}.skin-aria-ng .main-header .navbar{background-color:#f6f6f6;border-bottom:1px solid #ddd}.skin-aria-ng .main-header .navbar .nav>li>a{color:#707070;font-size:16px}.skin-aria-ng .main-header .navbar .nav .open>a,.skin-aria-ng .main-header .navbar .nav .open>a:focus,.skin-aria-ng .main-header .navbar .nav .open>a:hover,.skin-aria-ng .main-header .navbar .nav>.active>a,.skin-aria-ng .main-header .navbar .nav>li>a:active,.skin-aria-ng .main-header .navbar .nav>li>a:focus,.skin-aria-ng .main-header .navbar .nav>li>a:hover{color:#0080ff}.skin-aria-ng .main-header .navbar .nav>li.disabled>a{color:#ccc!important}.skin-aria-ng .main-header .navbar .nav>li.divider{padding:10px 0;margin-left:4px;margin-right:4px;border-right:1px solid #ccc;position:relative;top:15px}.skin-aria-ng .main-header .navbar .navbar-searchbar .form-control-icon{color:#999}@media (max-width:767px){.skin-aria-ng .main-header .navbar{padding-left:20px}.skin-aria-ng .main-header .navbar .navbar-nav{margin-left:-10px}.skin-aria-ng .main-header .navbar .nav>li.divider{margin-left:0;margin-right:0;top:5px}}.skin-aria-ng .main-header .logo{background-color:#3c4852;color:#fff;border-bottom:1px solid #59636b}.skin-aria-ng .main-header .logo .logo-lg:hover{color:#ccc}.skin-aria-ng .main-header .logo .logo-lg .logo-lg-title{margin-right:6px}.skin-aria-ng .main-header .logo .dropdown-menu{margin-top:-1px;border-top-left-radius:0;border-top-right-radius:0}.skin-aria-ng .main-header .logo .dropdown-menu>li.active>a{color:#777;background-color:#fff}.skin-aria-ng .main-header .logo .dropdown-menu>li.active:hover>a{color:#333;background-color:#e1e3e9}.skin-aria-ng .content-header{background:transparent}.skin-aria-ng .left-side,.skin-aria-ng .main-sidebar,.skin-aria-ng .wrapper{background-color:#3c4852}.skin-aria-ng .sidebar-menu>li.header{color:#707070;background-color:#2e343c;padding-top:3px;padding-bottom:3px}.skin-aria-ng .sidebar-menu>li>a{border-left:3px solid transparent;padding-top:9px;padding-bottom:9px}.skin-aria-ng .sidebar-menu>li:hover>a{color:#dfdfdf;background-color:#313a42}.skin-aria-ng .sidebar-menu>li.active>a{color:#5399e8;background-color:#252c30}.skin-aria-ng .sidebar-menu>li.treeview:hover>a{color:#a2b5b9;background-color:#3c4852}.skin-aria-ng .sidebar-menu>li.treeview.active:hover>a,.skin-aria-ng .sidebar-menu>li.treeview.active>a{color:#5399e8;background-color:#3c4852}.skin-aria-ng .sidebar-menu>li.treeview>a:hover{color:#dfdfdf;background-color:#313a42}.skin-aria-ng .sidebar-menu>li.treeview>ul.treeview-menu{margin:0;padding:0;background-color:#3c4852}.skin-aria-ng .sidebar-menu>li.treeview>ul.treeview-menu>li>a{color:#8aa4af;padding:6px 5px 6px 41px}.skin-aria-ng .sidebar-menu>li.treeview>ul.treeview-menu>li>a:hover{color:#dfdfdf;background-color:#313a42}.skin-aria-ng .sidebar-menu>li.treeview>ul.treeview-menu>li.active>a{color:#5399e8;background-color:#252c30}.skin-aria-ng .sidebar-menu i.fa{font-size:18px;margin-right:2px}.skin-aria-ng .sidebar a{color:#a2b5b9}.skin-aria-ng .sidebar a:hover{text-decoration:none}@media (max-width:767px){.skin-aria-ng .main-sidebar{margin-top:5px}}.right-side,.skin-aria-ng .content-wrapper{background-color:#fff}.skin-aria-ng .content-wrapper .form-control[type=text]{padding-left:14px}@media screen and (max-width:767px){.skin-aria-ng .content-wrapper .content{margin-top:5px}}.skin-aria-ng .main-footer{font-size:12px}.skin-aria-ng .main-footer>.navbar{border:0}.skin-aria-ng .main-footer>.navbar>.navbar-toolbar>.nav>li.divider{padding-top:16px;margin-left:4px;margin-right:4px;border-right:1px solid #ccc;position:relative;top:0}.skin-aria-ng .main-footer>.navbar>.navbar-toolbar>.nav>li>a{color:#707070;line-height:17px}.skin-aria-ng .main-footer>.navbar>.navbar-toolbar>.nav>li.open>a,.skin-aria-ng .main-footer>.navbar>.navbar-toolbar>.nav>li>a:active,.skin-aria-ng .main-footer>.navbar>.navbar-toolbar>.nav>li>a:focus,.skin-aria-ng .main-footer>.navbar>.navbar-toolbar>.nav>li>a:hover{color:#0080ff;background:none}.skin-aria-ng .global-status{margin-right:10px;color:inherit}.skin-aria-ng .global-status:hover{border:1px solid #ccc;margin-right:9px;margin-top:-1px}.skin-aria-ng .progress-bar-primary{background-color:#208fe5}.skin-aria-ng .progress-bar-warning{background-color:#f39c12}.skin-aria-ng .icon-primary{color:#3c8dbc}.skin-aria-ng .icon-download{color:#3a89e9}.skin-aria-ng .icon-upload{color:#74a329}.skin-aria-ng .icon-seeder{margin-left:4px;color:#74a329}.skin-aria-ng .icon-error{margin-left:4px;color:#dd4b39}.skin-aria-ng .icon-expand{color:#5399e8}.skin-aria-ng .icon-dir-expand{color:#999}.skin-aria-ng .nav-tabs-custom{-webkit-box-shadow:none;box-shadow:none;margin-bottom:0}.skin-aria-ng .nav-tabs-custom>.nav-tabs{border-bottom:1px dotted #ddd}.skin-aria-ng .nav-tabs-custom>.nav-tabs>li{border-top:0;margin-top:1px;margin-right:2px}.skin-aria-ng .nav-tabs-custom>.nav-tabs>li.active{border-bottom:2px solid #208fe5}.skin-aria-ng .nav-tabs-custom>.nav-tabs>li.slim>a{padding-left:5px;padding-right:5px}.skin-aria-ng .nav-tabs-custom>.nav-tabs>li.slim.active{margin-bottom:-1px;border-bottom:inherit}.skin-aria-ng .nav-tabs-custom>.nav-tabs>li.divider{padding:10px 0;margin-left:4px;margin-right:4px;margin-top:11px;border-right:1px solid #ccc}.skin-aria-ng .nav-tabs-custom>.nav-tabs>li.nav-toolbar{margin-left:15px;margin-right:5px}@media (max-width:767px){.skin-aria-ng .nav-tabs-custom>.nav-tabs>li.nav-toolbar{float:right}}.skin-aria-ng .nav-tabs-custom>.nav-tabs>li.nav-toolbar>.btn-group{margin-right:4px}.skin-aria-ng .nav-tabs-custom>.nav-tabs>li>a{color:#aaa;border:0}.skin-aria-ng .nav-tabs-custom>.nav-tabs>li.active>a,.skin-aria-ng .nav-tabs-custom>.nav-tabs>li>a:active,.skin-aria-ng .nav-tabs-custom>.nav-tabs>li>a:hover{color:#208fe5}.skin-aria-ng .nav-tabs-custom>.nav-tabs>li>a.nav-tab-close:hover{color:#dd4b39!important;margin-left:-14px}.skin-aria-ng .nav-tabs-custom>.nav-tabs>li>a.nav-tab-close:hover>.fa-times:before{content:"\f057";font-size:1.1em}.skin-aria-ng .nav-tabs-custom>.nav-tabs>li>div.btn-group{padding-top:5px;padding-bottom:5px}.skin-aria-ng .tooltip.tooltip-error.in,.skin-aria-ng .tooltip.tooltip-success.in,.skin-aria-ng .tooltip.tooltip-warning.in{filter:alpha(opacity=95);opacity:.95}.skin-aria-ng .tooltip.tooltip-success.top-left .tooltip-arrow,.skin-aria-ng .tooltip.tooltip-success.top-right .tooltip-arrow,.skin-aria-ng .tooltip.tooltip-success.top .tooltip-arrow{border-top-color:#00a65a}.skin-aria-ng .tooltip.tooltip-warning.top-left .tooltip-arrow,.skin-aria-ng .tooltip.tooltip-warning.top-right .tooltip-arrow,.skin-aria-ng .tooltip.tooltip-warning.top .tooltip-arrow{border-top-color:#f39c12}.skin-aria-ng .tooltip.tooltip-error.top-left .tooltip-arrow,.skin-aria-ng .tooltip.tooltip-error.top-right .tooltip-arrow,.skin-aria-ng .tooltip.tooltip-error.top .tooltip-arrow{border-top-color:#dd4b39}.skin-aria-ng .tooltip.tooltip-success.left .tooltip-arrow{border-left-color:#00a65a}.skin-aria-ng .tooltip.tooltip-warning.left .tooltip-arrow{border-left-color:#f39c12}.skin-aria-ng .tooltip.tooltip-error.left .tooltip-arrow{border-left-color:#dd4b39}.skin-aria-ng .tooltip.tooltip-success.right .tooltip-arrow{border-right-color:#00a65a}.skin-aria-ng .tooltip.tooltip-warning.right .tooltip-arrow{border-right-color:#f39c12}.skin-aria-ng .tooltip.tooltip-error.right .tooltip-arrow{border-right-color:#dd4b39}.skin-aria-ng .tooltip.tooltip-success.bottom-left .tooltip-arrow,.skin-aria-ng .tooltip.tooltip-success.bottom-right .tooltip-arrow,.skin-aria-ng .tooltip.tooltip-success.bottom .tooltip-arrow{border-bottom-color:#00a65a}.skin-aria-ng .tooltip.tooltip-warning.bottom-left .tooltip-arrow,.skin-aria-ng .tooltip.tooltip-warning.bottom-right .tooltip-arrow,.skin-aria-ng .tooltip.tooltip-warning.bottom .tooltip-arrow{border-bottom-color:#f39c12}.skin-aria-ng .tooltip.tooltip-error.bottom-left .tooltip-arrow,.skin-aria-ng .tooltip.tooltip-error.bottom-right .tooltip-arrow,.skin-aria-ng .tooltip.tooltip-error.bottom .tooltip-arrow{border-bottom-color:#dd4b39}.skin-aria-ng .tooltip.tooltip-success .tooltip-inner{background-color:#00a65a}.skin-aria-ng .tooltip.tooltip-warning .tooltip-inner{background-color:#f39c12}.skin-aria-ng .tooltip.tooltip-error .tooltip-inner{background-color:#dd4b39}.skin-aria-ng .input-group .form-group.has-success+.input-group-addon{border-color:#00a65a;background-color:#00a65a;color:#fff}.skin-aria-ng .input-group .form-group.has-warning+.input-group-addon{border-color:#f39c12;background-color:#f39c12;color:#fff}.skin-aria-ng .input-group .form-group.has-error+.input-group-addon{border-color:#dd4b39;background-color:#dd4b39;color:#fff}.skin-aria-ng input:-moz-placeholder,.skin-aria-ng input:-ms-input-placeholder,.skin-aria-ng input::-moz-placeholder,.skin-aria-ng input::-webkit-input-placeholder{color:#999}.skin-aria-ng select.placeholder{color:#999}.skin-aria-ng .checkbox-primary input[type=checkbox]:checked+label:before,.skin-aria-ng .checkbox-primary input[type=checkbox]:indeterminate+label:before,.skin-aria-ng .checkbox-primary input[type=radio]:checked+label:before,.skin-aria-ng .checkbox-primary input[type=radio]:indeterminate+label:before{background-color:#208fe5;border-color:#208fe5}.skin-aria-ng .task-table{background-color:#fff}.skin-aria-ng .task-table>.task-table-body>div.row:nth-of-type(odd){background-color:#f9f9f9}.skin-aria-ng .task-table>.task-table-body>div.row:hover{background-color:#f5f5f5}.skin-aria-ng .task-table .peer-client{color:#888;font-size:12px}.skin-aria-ng .settings-table{background-color:#fff}.skin-aria-ng .settings-table.striped>div.row:nth-of-type(odd){background-color:#f9f9f9}.skin-aria-ng .settings-table.striped>div.row.no-background{background-color:inherit}.skin-aria-ng .settings-table.hoverable>div.row:hover{background-color:#f5f5f5}.skin-aria-ng .settings-table.hoverable>div.row.no-hover:hover{background-color:inherit}.skin-aria-ng .settings-table.hoverable>div.row:nth-of-type(odd).no-hover:hover{background-color:#f9f9f9}.skin-aria-ng .new-task-table{background-color:#fff} -------------------------------------------------------------------------------- /App/data/ariang/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/ariang/favicon.ico -------------------------------------------------------------------------------- /App/data/ariang/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/ariang/favicon.png -------------------------------------------------------------------------------- /App/data/ariang/fonts/fontawesome-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/ariang/fonts/fontawesome-webfont.eot -------------------------------------------------------------------------------- /App/data/ariang/fonts/fontawesome-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/ariang/fonts/fontawesome-webfont.ttf -------------------------------------------------------------------------------- /App/data/ariang/fonts/fontawesome-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/ariang/fonts/fontawesome-webfont.woff -------------------------------------------------------------------------------- /App/data/ariang/fonts/fontawesome-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/ariang/fonts/fontawesome-webfont.woff2 -------------------------------------------------------------------------------- /App/data/ariang/index.html: -------------------------------------------------------------------------------- 1 | AriaNg -------------------------------------------------------------------------------- /App/data/ariang/index.manifest: -------------------------------------------------------------------------------- 1 | CACHE MANIFEST 2 | 3 | CACHE: 4 | css/aria-ng-2a46099f8c.min.css 5 | css/bootstrap-3.4.1.min.css 6 | css/plugins-acd93e5a25.min.css 7 | js/angular-packages-1.6.10.min.js 8 | js/aria-ng-902a524d58.min.js 9 | js/bootstrap-3.4.1.min.js 10 | js/echarts-common-3.8.5.min.js 11 | js/jquery-3.3.1.min.js 12 | js/moment-with-locales-2.24.0.min.js 13 | js/plugins-01928ba731.min.js 14 | fonts/fontawesome-webfont.woff2 15 | index.html 16 | 17 | NETWORK: 18 | * 19 | 20 | SETTINGS: 21 | prefer-online 22 | 23 | # hash: ee467f6354bd9bf6f4a15e30ba3e117ba650618e9198e00acf2667383181a7cb -------------------------------------------------------------------------------- /App/data/ariang/robots.txt: -------------------------------------------------------------------------------- 1 | # AriaNg 2 | 3 | User-agent: * 4 | Disallow: / 5 | -------------------------------------------------------------------------------- /App/data/ariang/tileicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/ariang/tileicon.png -------------------------------------------------------------------------------- /App/data/ariang/touchicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/ariang/touchicon.png -------------------------------------------------------------------------------- /App/data/icons/128.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/icons/128.png -------------------------------------------------------------------------------- /App/data/icons/16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/icons/16.png -------------------------------------------------------------------------------- /App/data/icons/256.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/icons/256.png -------------------------------------------------------------------------------- /App/data/icons/32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/icons/32.png -------------------------------------------------------------------------------- /App/data/icons/48.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/icons/48.png -------------------------------------------------------------------------------- /App/data/icons/64.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/icons/64.png -------------------------------------------------------------------------------- /App/data/icons/disabled/128.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/icons/disabled/128.png -------------------------------------------------------------------------------- /App/data/icons/disabled/16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/icons/disabled/16.png -------------------------------------------------------------------------------- /App/data/icons/disabled/256.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/icons/disabled/256.png -------------------------------------------------------------------------------- /App/data/icons/disabled/32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/icons/disabled/32.png -------------------------------------------------------------------------------- /App/data/icons/disabled/48.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/icons/disabled/48.png -------------------------------------------------------------------------------- /App/data/icons/disabled/64.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/App/data/icons/disabled/64.png -------------------------------------------------------------------------------- /App/data/options/about.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Options Page 6 | 20 | 21 | 22 |
23 |

Aria2 Connection Status

24 |

Default Server: ...

25 |

Server 2: ...

26 |

Server 3: ...

27 |
28 |
29 |
30 |
31 |

Author: Ross Wang

32 |
33 |
34 | 39 |
40 |
41 |
42 |

Translator: %Name%

43 |
44 |
45 | %message% 46 |
47 |
48 |
49 |

What is Aria2?

50 | 53 |

This add-on uses Mayswind's AriaNg.

54 | 57 |
58 | Add-on home page 59 | | 60 | Aria2 Settings Samples 61 | | 62 | Submit a Bug or Feedback 63 | | 64 | Release Notes 65 | | 66 | Help Translate 67 | | 68 | Third Party 69 |
70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | -------------------------------------------------------------------------------- /App/data/options/about.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | function restore() { 4 | document.querySelectorAll('[data-message]').forEach(n => { 5 | n.textContent = browser.i18n.getMessage(n.dataset.message); 6 | }); 7 | document.body.style = "direction: " + browser.i18n.getMessage("direction"); 8 | 9 | // Connection Status 10 | browser.storage.local.get(config.command.guess, function(item) { 11 | var sec = false; 12 | if (item.protocol.toLowerCase() == "https" || item.protocol.toLowerCase() == "wss") { 13 | sec = true; 14 | } 15 | var options = { 16 | host: item.host, 17 | port: item.port, 18 | secure: sec, 19 | secret: item.token, 20 | path: "/" + item.interf 21 | }; 22 | 23 | var aria2 = new Aria2(options); 24 | aria2.getVersion().then( 25 | function (res) { 26 | console.log(res); 27 | document.getElementById("server1").textContent = 'version ' + res.version + ' detected'; 28 | }, 29 | function (err) { 30 | console.log(err); 31 | document.getElementById("server1").textContent = err; 32 | } 33 | ); 34 | }); 35 | browser.storage.local.get(config.command.s2, function(item) { 36 | var sec = false; 37 | if (item.protocol2.toLowerCase() == "https" || item.protocol2.toLowerCase() == "wss") { 38 | sec = true; 39 | } 40 | var options = { 41 | host: item.host2, 42 | port: item.port2, 43 | secure: sec, 44 | secret: item.token2, 45 | path: "/" + item.interf2 46 | }; 47 | 48 | var aria2 = new Aria2(options); 49 | aria2.getVersion().then( 50 | function (res) { 51 | console.log(res); 52 | document.getElementById("server2").textContent = 'version ' + res.version + ' detected'; 53 | }, 54 | function (err) { 55 | console.log(err); 56 | document.getElementById("server2").textContent = err; 57 | } 58 | ); 59 | }); 60 | browser.storage.local.get(config.command.s3, function(item) { 61 | var sec = false; 62 | if (item.protocol3.toLowerCase() == "https" || item.protocol3.toLowerCase() == "wss") { 63 | sec = true; 64 | } 65 | var options = { 66 | host: item.host3, 67 | port: item.port3, 68 | secure: sec, 69 | secret: item.token3, 70 | path: "/" + item.interf3 71 | }; 72 | 73 | var aria2 = new Aria2(options); 74 | aria2.getVersion().then( 75 | function (res) { 76 | console.log(res); 77 | document.getElementById("server3").textContent = 'Version ' + res.version + ' detected'; 78 | }, 79 | function (err) { 80 | console.log(err); 81 | document.getElementById("server3").textContent = err; 82 | } 83 | ); 84 | }); 85 | } 86 | 87 | document.addEventListener('DOMContentLoaded', restore); -------------------------------------------------------------------------------- /App/data/options/exception.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Options Page 6 | 7 | 8 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 |
File Size Limit:
Lower limit of the file size in bytes to trigger the download
Include File Type:
Regular Expressions: Matches MIME type
Exclude File Type:
Regular Expressions: Matches MIME type
Include URL:
Regular Expressions: Matches URL
Exclude URL:
Regular Expressions: Matches URL
81 |
82 | 83 | 84 |
85 | 87 | 89 | 90 | -------------------------------------------------------------------------------- /App/data/options/exception.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | function save() { 4 | const fileSizeLimit = document.getElementById('fileSizeLimit').value; 5 | const typeFilterA = document.getElementById('typeFilterA').value; 6 | const typeFilterB = document.getElementById('typeFilterB').value; 7 | const urlFilterA = document.getElementById('urlFilterA').value; 8 | const urlFilterB = document.getElementById('urlFilterB').value; 9 | browser.storage.local.set({ 10 | fileSizeLimit, 11 | typeFilterA, 12 | typeFilterB, 13 | urlFilterA, 14 | urlFilterB, 15 | }, () => { 16 | const status = document.getElementById('status'); 17 | status.textContent = browser.i18n.getMessage("OP_saveComplete"); 18 | setTimeout(() => { 19 | status.textContent = ''; 20 | }, 750); 21 | browser.runtime.sendMessage({ 22 | get: "loadSettings", 23 | }); 24 | }); 25 | } 26 | 27 | function restore() { 28 | browser.storage.local.get(Object.assign(config.command.guess), prefs => { 29 | document.getElementById('fileSizeLimit').value = prefs.fileSizeLimit; 30 | document.getElementById('typeFilterA').value = prefs.typeFilterA; 31 | document.getElementById('typeFilterB').value = prefs.typeFilterB 32 | document.getElementById('urlFilterA').value = prefs.urlFilterA; 33 | document.getElementById('urlFilterB').value = prefs.urlFilterB; 34 | }); 35 | document.querySelectorAll('[data-message]').forEach(n => { 36 | n.textContent = browser.i18n.getMessage(n.dataset.message); 37 | }); 38 | document.body.style = "direction: " + browser.i18n.getMessage("direction"); 39 | } 40 | 41 | document.addEventListener('DOMContentLoaded', restore); 42 | document.getElementById('save').addEventListener('click', save); -------------------------------------------------------------------------------- /App/data/options/general.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Options Page 7 | 8 | 9 | 10 | 57 | 58 | 59 | 62 | 63 | 64 | 65 | 66 | 67 | 71 | 72 | 73 | 74 | 75 | 76 | 80 | 81 | 82 | 83 | 84 | 85 | 89 | 90 | 91 | 93 | 94 | 95 | 99 | 100 | 101 | 102 | 103 | 104 | 108 | 109 | 110 | 111 | 112 | 113 | 117 | 118 | 119 | 120 | 121 | 122 | 126 | 127 | 128 | 129 | 130 | 131 | 135 | 136 | 137 | 138 | 139 | 140 | 144 | 145 | 146 | 147 | 148 | 149 | 153 | 154 | 155 | 156 | 157 | 158 | 162 | 163 | 164 | 165 | 166 | 167 | 168 | 173 | 174 | 175 | 176 | 177 | 178 | 179 | 184 | 185 | 186 | 187 | 188 |
60 | 61 |
Zoom Level of Download Panel. Default value is 1.
68 | 69 | 70 |
Add Context Menus to links, videos and audios
77 | 78 | 79 |
User-Agent will be same as the browser send
86 | 87 | 88 |
Send "--stop-with-process= 92 | " command to aria2c
96 | 97 | 98 |
Detect download links aggressively. May cause some problems.
105 | 106 | 107 |
The location of Download Panel will be saved (but firefox has bug to create window)
114 | 115 | 116 |
Start Aria2 automatically when the download start
123 | 124 | 125 |
Set AriaNg automatically when the user click "details"
132 | 133 | 134 |
Display Changelog After Update
141 | 142 | 143 |
Display current active download count on top of the icon
150 | 151 | 152 |
Whether to display a download panel for the download event trigger from the auto observer
159 | 160 | 161 |
Whether to display a download panel for the download event trigger from the context menu

169 | 170 | 171 | 172 |
Fine Tune Download Window width

180 | 181 | 182 | 183 |
Fine Tune Download Window height
189 |
190 | 191 | 192 |
193 | 194 | 195 | 196 | 197 | -------------------------------------------------------------------------------- /App/data/options/general.js: -------------------------------------------------------------------------------- 1 | 2 | 'use strict'; 3 | function save() { 4 | const zoom = document.getElementById('zoom').value; 5 | const menu = document.getElementById('cm').checked; 6 | const ua = document.getElementById('ua').checked; 7 | const shutdown = document.getElementById('shut').checked; 8 | const aggressive = document.getElementById('aggre').checked; 9 | const windowLoc = document.getElementById('winLoc').checked; 10 | const auto = document.getElementById('auto').checked; 11 | const autoSet = document.getElementById('autoSet').checked; 12 | const chgLog = document.getElementById('chgLog').checked; 13 | const badge = document.getElementById('badge').checked; 14 | const downPanel = document.getElementById('downPanel').checked; 15 | const cmDownPanel = document.getElementById('cmDownPanel').checked; 16 | const dpHeight = document.getElementById('dpHeight').value; 17 | const dpWidth = document.getElementById('dpWidth').value; 18 | if (!windowLoc){ 19 | browser.storage.local.remove(['dpLeft','dpTop']); 20 | } 21 | browser.storage.local.set({ 22 | zoom, 23 | menu, 24 | ua, 25 | shutdown, 26 | aggressive, 27 | windowLoc, 28 | auto, 29 | autoSet, 30 | chgLog, 31 | badge, 32 | downPanel, 33 | cmDownPanel, 34 | dpHeight, 35 | dpWidth 36 | }, () => { 37 | const status = document.getElementById('status'); 38 | status.textContent = browser.i18n.getMessage("OP_saveComplete"); 39 | setTimeout(() => { 40 | status.textContent = ''; 41 | }, 750); 42 | browser.runtime.sendMessage({ 43 | get: "loadSettings", 44 | }); 45 | }); 46 | } 47 | 48 | function restore() { 49 | browser.storage.local.get(Object.assign(config.command.guess), prefs => { 50 | document.getElementById('zoom').value = prefs.zoom; 51 | document.getElementById('cm').checked = prefs.menu; 52 | document.getElementById('ua').checked = prefs.ua; 53 | document.getElementById('shut').checked = prefs.shutdown; 54 | document.getElementById('aggre').checked = prefs.aggressive; 55 | document.getElementById('winLoc').checked = prefs.windowLoc; 56 | document.getElementById('auto').checked = prefs.auto; 57 | document.getElementById('autoSet').checked = prefs.autoSet; 58 | document.getElementById('chgLog').checked = prefs.chgLog; 59 | document.getElementById('badge').checked = prefs.badge; 60 | document.getElementById('cmDownPanel').checked = prefs.cmDownPanel; 61 | document.getElementById('downPanel').checked = prefs.downPanel; 62 | }); 63 | browser.storage.local.get(['dpWidth', 'dpHeight'], prefs => { 64 | document.getElementById('dpWidth').value = prefs.dpWidth; 65 | document.getElementById('dpHeight').value = prefs.dpHeight; 66 | document.getElementById('dpWidthN').value = prefs.dpWidth || 0; 67 | document.getElementById('dpHeightN').value = prefs.dpHeight || 0; 68 | }); 69 | document.querySelectorAll('[data-message]').forEach(n => { 70 | n.textContent = browser.i18n.getMessage(n.dataset.message); 71 | }); 72 | document.body.style = "direction: " + browser.i18n.getMessage("direction"); 73 | } 74 | 75 | function dpHChange(e) { 76 | if (e.target.value > 5000) 77 | e.target.value = 5000; 78 | else if (e.target.value < -5000) 79 | e.target.value = -5000; 80 | else if (e.target.value == "") 81 | e.target.value = 0; 82 | console.log(e); 83 | document.getElementById('dpHeight').value = e.target.value; 84 | document.getElementById('dpHeightN').value = e.target.value; 85 | } 86 | 87 | function dpWChange(e) { 88 | if (e.target.value > 5000) 89 | e.target.value = 5000; 90 | else if (e.target.value < -5000) 91 | e.target.value = -5000; 92 | else if (e.target.value == "") 93 | e.target.value = 0; 94 | document.getElementById('dpWidth').value = e.target.value; 95 | document.getElementById('dpWidthN').value = e.target.value; 96 | } 97 | 98 | document.addEventListener('DOMContentLoaded', restore); 99 | document.getElementById('save').addEventListener('click', save); 100 | document.getElementById('dpHeight').onchange = dpHChange; 101 | document.getElementById('dpHeightN').onchange = dpHChange; 102 | document.getElementById('dpWidth').onchange = dpWChange; 103 | document.getElementById('dpWidthN').onchange = dpWChange; -------------------------------------------------------------------------------- /App/data/options/menu.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | Aria2 Integration Options 9 | 223 | 224 | 225 | 226 |

Aria2 Integration Options

227 |
228 |
229 |
230 | 255 |
256 |
257 |
258 | 259 |
260 |
261 | 262 | 263 | 264 | 265 | 266 | -------------------------------------------------------------------------------- /App/data/options/menu.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | function hashHandler(ev) { 3 | ev.preventDefault(); 4 | if (location.hash != '' && location.hash != '#') { 5 | document.querySelector('.iframe').src = location.hash.slice(1) + ".html"; 6 | document.querySelector('#general').className = ""; 7 | document.querySelector('#rpc').className = ""; 8 | document.querySelector('#exception').className = ""; 9 | document.querySelector('#about').className = ""; 10 | if (location.hash == "#rpc" || location.hash == "#rpc2" || location.hash == "#rpc3") 11 | document.querySelector("#rpc").className = "active"; 12 | else 13 | document.querySelector(location.hash).className = "active"; 14 | } 15 | document.querySelectorAll('[data-message]').forEach(n => { 16 | n.textContent = browser.i18n.getMessage(n.dataset.message); 17 | }); 18 | document.body.style = "direction: " + browser.i18n.getMessage("direction"); 19 | } 20 | window.addEventListener("hashchange", hashHandler); 21 | document.addEventListener('DOMContentLoaded', hashHandler); 22 | -------------------------------------------------------------------------------- /App/data/options/rpc.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Options Page 6 | 7 | 8 | 51 |
52 |

You need to download and start Aria2 by youself, complete at least 53 | "Protocol," "Host," "Port" and "Interface" below and then click the "Save" 54 | button.

55 |

If you don't want to start Aria2 manually, just write a program to start 56 | Aria2 in the background and register it to the system's "autostart" or "uri 57 | scheme."

58 | You can find the sample files here. 60 |
61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 125 | 126 |
Default Download Path:
Download path of Aria2(only)
Protocol:
RPC connection protocol of Aria2
Host:
RPC host of Aria2. You can use ip or domain name.
Port:
Aria2 RPC port
Interface:
Aria2 RPC path. Default value is "jsonrpc"
Token:
Aria2 RPC secret, optional.
Downlod Completed Sound: 116 | 117 | 118 | 119 | 120 | 121 | 122 | 123 | 124 |
127 |
128 | 129 | 130 |
131 | 133 | 135 | 136 | -------------------------------------------------------------------------------- /App/data/options/rpc.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | function save() { 4 | const path = document.getElementById('path').value; 5 | const protocol = document.getElementById('protocol').value; 6 | const host = document.getElementById('host').value; 7 | const port = document.getElementById('port').value; 8 | const interf = document.getElementById('interf').value; 9 | const token = document.getElementById('token').value; 10 | if (document.getElementById('sound0').checked) 11 | var sound = "0"; 12 | if (document.getElementById('sound1').checked) 13 | var sound = "1"; 14 | if (document.getElementById('sound2').checked) 15 | var sound = "2"; 16 | if (document.getElementById('sound3').checked) 17 | var sound = "3"; 18 | browser.storage.local.set({ 19 | path, 20 | protocol, 21 | host, 22 | port, 23 | interf, 24 | token, 25 | sound, 26 | }, () => { 27 | const status = document.getElementById('status'); 28 | status.textContent = browser.i18n.getMessage("OP_saveComplete"); 29 | setTimeout(() => { 30 | status.textContent = ''; 31 | }, 750); 32 | browser.storage.local.set({ 33 | initialize: true 34 | }); 35 | }); 36 | } 37 | 38 | function restore() { 39 | browser.storage.local.get(Object.assign(config.command.guess), prefs => { 40 | document.getElementById('path').value = prefs.path; 41 | document.getElementById('protocol').value = prefs.protocol; 42 | document.getElementById('host').value = prefs.host; 43 | document.getElementById('port').value = prefs.port; 44 | document.getElementById('interf').value = prefs.interf; 45 | document.getElementById('token').value = prefs.token; 46 | if (prefs.sound == "0") 47 | document.getElementById('sound0').checked = true; 48 | if (prefs.sound == "1") 49 | document.getElementById('sound1').checked = true; 50 | if (prefs.sound == "2") 51 | document.getElementById('sound2').checked = true; 52 | if (prefs.sound == "3") 53 | document.getElementById('sound3').checked = true; 54 | }); 55 | document.querySelectorAll('[data-message]').forEach(n => { 56 | n.textContent = browser.i18n.getMessage(n.dataset.message); 57 | }); 58 | document.body.style = "direction: " + browser.i18n.getMessage("direction"); 59 | } 60 | 61 | document.addEventListener('DOMContentLoaded', restore); 62 | document.getElementById('save').addEventListener('click', save); -------------------------------------------------------------------------------- /App/data/options/rpc2.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Options Page 6 | 7 | 8 | 51 |
52 |

You need to download and start Aria2 by youself, complete at least 53 | "Protocol," "Host," "Port" and "Interface" below and then click the "Save" 54 | button.

55 |

If you don't want to start Aria2 manually, just write a program to start 56 | Aria2 in the background and register it to the system's "autostart" or "uri 57 | scheme."

58 | You can find the sample files here. 60 |
61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 108 | 109 | 110 | 111 | 112 | 113 |
Default Download Path:
Download path of Aria2(only)
Protocol:
RPC connection protocol of Aria2
Host:
RPC host of Aria2. You can use ip or domain name.
Port:
Aria2 RPC port
Interface:
Aria2 RPC path. Default value is "jsonrpc"
Token:
Aria2 RPC secret, optional.
114 |
115 | 116 | 117 |
118 | 120 | 122 | 123 | -------------------------------------------------------------------------------- /App/data/options/rpc2.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | function save() { 4 | const path2 = document.getElementById('path').value; 5 | const protocol2 = document.getElementById('protocol').value; 6 | const host2 = document.getElementById('host').value; 7 | const port2 = document.getElementById('port').value; 8 | const interf2 = document.getElementById('interf').value; 9 | const token2 = document.getElementById('token').value; 10 | browser.storage.local.set({ 11 | path2, 12 | protocol2, 13 | host2, 14 | port2, 15 | interf2, 16 | token2, 17 | }, () => { 18 | const status = document.getElementById('status'); 19 | status.textContent = browser.i18n.getMessage("OP_saveComplete"); 20 | setTimeout(() => { 21 | status.textContent = ''; 22 | }, 750); 23 | }); 24 | } 25 | 26 | function restore() { 27 | browser.storage.local.get(Object.assign(config.command.s2), prefs => { 28 | document.getElementById('path').value = prefs.path2; 29 | document.getElementById('protocol').value = prefs.protocol2; 30 | document.getElementById('host').value = prefs.host2; 31 | document.getElementById('port').value = prefs.port2; 32 | document.getElementById('interf').value = prefs.interf2; 33 | document.getElementById('token').value = prefs.token2; 34 | }); 35 | document.querySelectorAll('[data-message]').forEach(n => { 36 | n.textContent = browser.i18n.getMessage(n.dataset.message); 37 | }); 38 | document.body.style = "direction: " + browser.i18n.getMessage("direction"); 39 | } 40 | 41 | document.addEventListener('DOMContentLoaded', restore); 42 | document.getElementById('save').addEventListener('click', save); -------------------------------------------------------------------------------- /App/data/options/rpc3.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Options Page 6 | 7 | 8 | 51 |
52 |

You need to download and start Aria2 by youself, complete at least 53 | "Protocol," "Host," "Port" and "Interface" below and then click the "Save" 54 | button.

55 |

If you don't want to start Aria2 manually, just write a program to start 56 | Aria2 in the background and register it to the system's "autostart" or "uri 57 | scheme."

58 | You can find the sample files here. 60 |
61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 108 | 109 | 110 | 111 | 112 | 113 |
Default Download Path:
Download path of Aria2(only)
Protocol:
RPC connection protocol of Aria2
Host:
RPC host of Aria2. You can use ip or domain name.
Port:
Aria2 RPC port
Interface:
Aria2 RPC path. Default value is "jsonrpc"
Token:
Aria2 RPC secret, optional.
114 |
115 | 116 | 117 |
118 | 120 | 122 | 123 | -------------------------------------------------------------------------------- /App/data/options/rpc3.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | function save() { 4 | const path3 = document.getElementById('path').value; 5 | const protocol3 = document.getElementById('protocol').value; 6 | const host3 = document.getElementById('host').value; 7 | const port3 = document.getElementById('port').value; 8 | const interf3 = document.getElementById('interf').value; 9 | const token3 = document.getElementById('token').value; 10 | browser.storage.local.set({ 11 | path3, 12 | protocol3, 13 | host3, 14 | port3, 15 | interf3, 16 | token3, 17 | }, () => { 18 | const status = document.getElementById('status'); 19 | status.textContent = browser.i18n.getMessage("OP_saveComplete"); 20 | setTimeout(() => { 21 | status.textContent = ''; 22 | }, 750); 23 | }); 24 | } 25 | 26 | function restore() { 27 | browser.storage.local.get(Object.assign(config.command.s3), prefs => { 28 | document.getElementById('path').value = prefs.path3; 29 | document.getElementById('protocol').value = prefs.protocol3; 30 | document.getElementById('host').value = prefs.host3; 31 | document.getElementById('port').value = prefs.port3; 32 | document.getElementById('interf').value = prefs.interf3; 33 | document.getElementById('token').value = prefs.token3; 34 | }); 35 | document.querySelectorAll('[data-message]').forEach(n => { 36 | n.textContent = browser.i18n.getMessage(n.dataset.message); 37 | }); 38 | document.body.style = "direction: " + browser.i18n.getMessage("direction"); 39 | } 40 | 41 | document.addEventListener('DOMContentLoaded', restore); 42 | document.getElementById('save').addEventListener('click', save); -------------------------------------------------------------------------------- /App/lib/aria.LICENSE: -------------------------------------------------------------------------------- 1 | ## ISC License 2 | 3 | Copyright (c) 2015, Sonny Piers 4 | 5 | Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies. 6 | 7 | THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 8 | -------------------------------------------------------------------------------- /App/lib/aria.js: -------------------------------------------------------------------------------- 1 | ;(function (global) { 2 | 'use strict' 3 | 4 | /*var WebSocket 5 | var fetch 6 | var polygoat 7 | 8 | var isNode = typeof module !== 'undefined' && module.exports 9 | 10 | if (isNode) { 11 | WebSocket = require('ws') 12 | fetch = require('node-fetch') 13 | polygoat = require('polygoat') 14 | } else { 15 | WebSocket = global.WebSocket 16 | fetch = global.fetch 17 | polygoat = global.polygoat 18 | }*/ 19 | 20 | var Aria2 = function (opts) { 21 | this.callbacks = Object.create(null) 22 | this.lastId = 0 23 | 24 | for (var i in Aria2.options) { 25 | this[i] = typeof opts === 'object' && i in opts ? opts[i] : Aria2.options[i] 26 | } 27 | } 28 | 29 | Aria2.prototype.http = function (m, fn) { 30 | var that = this 31 | var content = { 32 | method: m.method, 33 | id: m.id 34 | } 35 | 36 | if (Array.isArray(m.params) && m.params.length > 0) { 37 | content.params = m.params 38 | } 39 | 40 | var url = 'http' + (this.secure ? 's' : '') + '://' + this.host + ':' + this.port + this.path 41 | fetch(url, { 42 | method: 'POST', 43 | body: JSON.stringify(content), 44 | headers: { 45 | 'Accept': 'application/json', 46 | 'Content-Type': 'application/json' 47 | }}) 48 | .then(function (res) { 49 | return res.json() 50 | }) 51 | .then(function (msg) { 52 | that._onmessage(msg) 53 | }) 54 | .catch(fn) 55 | } 56 | 57 | Aria2.prototype.send = function (method /* [,param] [,param] [,...] [, fn] */) { 58 | var params = Array.prototype.slice.call(arguments, 1) 59 | var cb = typeof params[params.length - 1] === 'function' ? params.pop() : null 60 | return this.exec(method, params, cb) 61 | } 62 | 63 | Aria2.prototype.exec = function (method, parameters, cb) { 64 | if (typeof method !== 'string') { 65 | throw new TypeError(method + ' is not a string') 66 | } 67 | 68 | if (method.indexOf('system.') !== 0 && method.indexOf('aria2.') !== 0) { 69 | method = 'aria2.' + method 70 | } 71 | 72 | var m = { 73 | 'method': method, 74 | 'json-rpc': '2.0', 75 | 'id': this.lastId++ 76 | } 77 | 78 | var params = this.secret ? ['token:' + this.secret] : [] 79 | if (Array.isArray(parameters)) { 80 | params = params.concat(parameters) 81 | } 82 | 83 | if (params.length > 0) m.params = params 84 | 85 | this.onsend(m) 86 | 87 | var that = this 88 | 89 | // send via websocket 90 | if (this.socket && this.socket.readyState === 1) { 91 | this.socket.send(JSON.stringify(m)) 92 | // send via http 93 | } else { 94 | this.http(m, function (err) { 95 | that.callbacks[m.id](err) 96 | delete that.callbacks[m.id] 97 | }) 98 | } 99 | 100 | return polygoat(function (done) { 101 | that.callbacks[m.id] = done 102 | }, cb) 103 | } 104 | 105 | Aria2.prototype._onmessage = function (m) { 106 | this.onmessage(m) 107 | 108 | if (m.id !== undefined) { 109 | var callback = this.callbacks[m.id] 110 | if (callback) { 111 | if (m.error) { 112 | callback(m.error) 113 | } else { 114 | callback(null, m.result) 115 | } 116 | delete this.callbacks[m.id] 117 | } 118 | } else if (m.method) { 119 | var n = m.method.split('aria2.')[1] 120 | if (n.indexOf('on') === 0 && typeof this[n] === 'function' && Aria2.notifications.indexOf(n) > -1) { 121 | this[n].apply(this, m.params) 122 | } 123 | } 124 | } 125 | 126 | Aria2.prototype.open = function (fn) { 127 | var url = 'ws' + (this.secure ? 's' : '') + '://' + this.host + ':' + this.port + this.path 128 | var socket = new WebSocket(url) 129 | var that = this 130 | var called = false 131 | 132 | socket.onclose = function () { 133 | that.onclose() 134 | } 135 | socket.onmessage = function (event) { 136 | that._onmessage(JSON.parse(event.data)) 137 | } 138 | 139 | return polygoat(function (done) { 140 | socket.onopen = function () { 141 | if (!called) { 142 | done() 143 | called = true 144 | } 145 | that.onopen() 146 | } 147 | socket.onerror = function (err) { 148 | if (!called) { 149 | done(err) 150 | called = true 151 | } 152 | } 153 | }, fn) 154 | } 155 | 156 | Aria2.prototype.close = function (fn) { 157 | var socket = this.socket 158 | return polygoat(function (done) { 159 | if (!socket) { 160 | done() 161 | } else { 162 | socket.addEventListener('close', function () { 163 | done() 164 | }) 165 | socket.close() 166 | } 167 | }, fn) 168 | } 169 | 170 | // https://aria2.github.io/manual/en/html/aria2c.html#methods 171 | Aria2.methods = [ 172 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.addUri 173 | 'addUri', 174 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.addTorrent 175 | 'addTorrent', 176 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.addMetalink 177 | 'addMetalink', 178 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.remove 179 | 'remove', 180 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.forceRemove 181 | 'forceRemove', 182 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.pause 183 | 'pause', 184 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.pauseAll 185 | 'pauseAll', 186 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.forcePause 187 | 'forcePause', 188 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.forcePauseAll 189 | 'forcePauseAll', 190 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.unpause 191 | 'unpause', 192 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.unpauseAll 193 | 'unpauseAll', 194 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.tellStatus 195 | 'tellStatus', 196 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.getUris 197 | 'getUris', 198 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.getFiles 199 | 'getFiles', 200 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.getPeers 201 | 'getPeers', 202 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.getServers 203 | 'getServers', 204 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.tellActive 205 | 'tellActive', 206 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.tellWaiting 207 | 'tellWaiting', 208 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.tellStopped 209 | 'tellStopped', 210 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.changePosition 211 | 'changePosition', 212 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.changeUri 213 | 'changeUri', 214 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.getOption 215 | 'getOption', 216 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.changeOption 217 | 'changeOption', 218 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.getGlobalOption 219 | 'getGlobalOption', 220 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.changeGlobalOption 221 | 'changeGlobalOption', 222 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.getGlobalStat 223 | 'getGlobalStat', 224 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.purgeDownloadResult 225 | 'purgeDownloadResult', 226 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.removeDownloadResult 227 | 'removeDownloadResult', 228 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.getVersion 229 | 'getVersion', 230 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.getSessionInfo 231 | 'getSessionInfo', 232 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.shutdown 233 | 'shutdown', 234 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.forceShutdown 235 | 'forceShutdown', 236 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.saveSession 237 | 'saveSession', 238 | // https://aria2.github.io/manual/en/html/aria2c.html#system.multicall 239 | 'system.multicall', 240 | // https://aria2.github.io/manual/en/html/aria2c.html#system.listMethods 241 | 'system.listMethods', 242 | // https://aria2.github.io/manual/en/html/aria2c.html#system.listNotifications 243 | 'system.listNotifications' 244 | ] 245 | 246 | // https://aria2.github.io/manual/en/html/aria2c.html#notifications 247 | Aria2.notifications = [ 248 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.onDownloadStart 249 | 'onDownloadStart', 250 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.onDownloadPause 251 | 'onDownloadPause', 252 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.onDownloadStop 253 | 'onDownloadStop', 254 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.onDownloadComplete 255 | 'onDownloadComplete', 256 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.onDownloadError 257 | 'onDownloadError', 258 | // https://aria2.github.io/manual/en/html/aria2c.html#aria2.onBtDownloadComplete 259 | 'onBtDownloadComplete' 260 | ] 261 | 262 | Aria2.events = [ 263 | 'onopen', 264 | 'onclose', 265 | 'onsend', 266 | 'onmessage' 267 | ] 268 | 269 | Aria2.options = { 270 | 'secure': false, 271 | 'host': 'localhost', 272 | 'port': 6800, 273 | 'secret': '', 274 | 'path': '/jsonrpc' 275 | } 276 | 277 | Aria2.methods.forEach(function (method) { 278 | var sufix = method.indexOf('.') > -1 ? method.split('.')[1] : method 279 | Aria2.prototype[sufix] = function (/* [param] [,param] [,...] */) { 280 | return this.send.apply(this, [method].concat(Array.prototype.slice.call(arguments))) 281 | } 282 | }) 283 | 284 | Aria2.notifications.forEach(function (notification) { 285 | Aria2.prototype[notification] = function () {} 286 | }) 287 | 288 | Aria2.events.forEach(function (event) { 289 | Aria2.prototype[event] = function () {} 290 | }) 291 | 292 | global.Aria2 = Aria2 293 | 294 | }(this)) 295 | -------------------------------------------------------------------------------- /App/lib/jschardet.LICENSE: -------------------------------------------------------------------------------- 1 | GNU LESSER GENERAL PUBLIC LICENSE 2 | Version 2.1, February 1999 3 | 4 | Copyright (C) 1991, 1999 Free Software Foundation, Inc. 5 | 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 6 | Everyone is permitted to copy and distribute verbatim copies 7 | of this license document, but changing it is not allowed. 8 | 9 | (This is the first released version of the Lesser GPL. It also counts 10 | as the successor of the GNU Library Public License, version 2, hence 11 | the version number 2.1.) 12 | 13 | Preamble 14 | 15 | The licenses for most software are designed to take away your 16 | freedom to share and change it. By contrast, the GNU General Public 17 | Licenses are intended to guarantee your freedom to share and change 18 | free software--to make sure the software is free for all its users. 19 | 20 | This license, the Lesser General Public License, applies to some 21 | specially designated software packages--typically libraries--of the 22 | Free Software Foundation and other authors who decide to use it. You 23 | can use it too, but we suggest you first think carefully about whether 24 | this license or the ordinary General Public License is the better 25 | strategy to use in any particular case, based on the explanations below. 26 | 27 | When we speak of free software, we are referring to freedom of use, 28 | not price. Our General Public Licenses are designed to make sure that 29 | you have the freedom to distribute copies of free software (and charge 30 | for this service if you wish); that you receive source code or can get 31 | it if you want it; that you can change the software and use pieces of 32 | it in new free programs; and that you are informed that you can do 33 | these things. 34 | 35 | To protect your rights, we need to make restrictions that forbid 36 | distributors to deny you these rights or to ask you to surrender these 37 | rights. These restrictions translate to certain responsibilities for 38 | you if you distribute copies of the library or if you modify it. 39 | 40 | For example, if you distribute copies of the library, whether gratis 41 | or for a fee, you must give the recipients all the rights that we gave 42 | you. You must make sure that they, too, receive or can get the source 43 | code. If you link other code with the library, you must provide 44 | complete object files to the recipients, so that they can relink them 45 | with the library after making changes to the library and recompiling 46 | it. And you must show them these terms so they know their rights. 47 | 48 | We protect your rights with a two-step method: (1) we copyright the 49 | library, and (2) we offer you this license, which gives you legal 50 | permission to copy, distribute and/or modify the library. 51 | 52 | To protect each distributor, we want to make it very clear that 53 | there is no warranty for the free library. Also, if the library is 54 | modified by someone else and passed on, the recipients should know 55 | that what they have is not the original version, so that the original 56 | author's reputation will not be affected by problems that might be 57 | introduced by others. 58 | 59 | Finally, software patents pose a constant threat to the existence of 60 | any free program. We wish to make sure that a company cannot 61 | effectively restrict the users of a free program by obtaining a 62 | restrictive license from a patent holder. Therefore, we insist that 63 | any patent license obtained for a version of the library must be 64 | consistent with the full freedom of use specified in this license. 65 | 66 | Most GNU software, including some libraries, is covered by the 67 | ordinary GNU General Public License. This license, the GNU Lesser 68 | General Public License, applies to certain designated libraries, and 69 | is quite different from the ordinary General Public License. We use 70 | this license for certain libraries in order to permit linking those 71 | libraries into non-free programs. 72 | 73 | When a program is linked with a library, whether statically or using 74 | a shared library, the combination of the two is legally speaking a 75 | combined work, a derivative of the original library. The ordinary 76 | General Public License therefore permits such linking only if the 77 | entire combination fits its criteria of freedom. The Lesser General 78 | Public License permits more lax criteria for linking other code with 79 | the library. 80 | 81 | We call this license the "Lesser" General Public License because it 82 | does Less to protect the user's freedom than the ordinary General 83 | Public License. It also provides other free software developers Less 84 | of an advantage over competing non-free programs. These disadvantages 85 | are the reason we use the ordinary General Public License for many 86 | libraries. However, the Lesser license provides advantages in certain 87 | special circumstances. 88 | 89 | For example, on rare occasions, there may be a special need to 90 | encourage the widest possible use of a certain library, so that it becomes 91 | a de-facto standard. To achieve this, non-free programs must be 92 | allowed to use the library. A more frequent case is that a free 93 | library does the same job as widely used non-free libraries. In this 94 | case, there is little to gain by limiting the free library to free 95 | software only, so we use the Lesser General Public License. 96 | 97 | In other cases, permission to use a particular library in non-free 98 | programs enables a greater number of people to use a large body of 99 | free software. For example, permission to use the GNU C Library in 100 | non-free programs enables many more people to use the whole GNU 101 | operating system, as well as its variant, the GNU/Linux operating 102 | system. 103 | 104 | Although the Lesser General Public License is Less protective of the 105 | users' freedom, it does ensure that the user of a program that is 106 | linked with the Library has the freedom and the wherewithal to run 107 | that program using a modified version of the Library. 108 | 109 | The precise terms and conditions for copying, distribution and 110 | modification follow. Pay close attention to the difference between a 111 | "work based on the library" and a "work that uses the library". The 112 | former contains code derived from the library, whereas the latter must 113 | be combined with the library in order to run. 114 | 115 | GNU LESSER GENERAL PUBLIC LICENSE 116 | TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 117 | 118 | 0. This License Agreement applies to any software library or other 119 | program which contains a notice placed by the copyright holder or 120 | other authorized party saying it may be distributed under the terms of 121 | this Lesser General Public License (also called "this License"). 122 | Each licensee is addressed as "you". 123 | 124 | A "library" means a collection of software functions and/or data 125 | prepared so as to be conveniently linked with application programs 126 | (which use some of those functions and data) to form executables. 127 | 128 | The "Library", below, refers to any such software library or work 129 | which has been distributed under these terms. A "work based on the 130 | Library" means either the Library or any derivative work under 131 | copyright law: that is to say, a work containing the Library or a 132 | portion of it, either verbatim or with modifications and/or translated 133 | straightforwardly into another language. (Hereinafter, translation is 134 | included without limitation in the term "modification".) 135 | 136 | "Source code" for a work means the preferred form of the work for 137 | making modifications to it. For a library, complete source code means 138 | all the source code for all modules it contains, plus any associated 139 | interface definition files, plus the scripts used to control compilation 140 | and installation of the library. 141 | 142 | Activities other than copying, distribution and modification are not 143 | covered by this License; they are outside its scope. The act of 144 | running a program using the Library is not restricted, and output from 145 | such a program is covered only if its contents constitute a work based 146 | on the Library (independent of the use of the Library in a tool for 147 | writing it). Whether that is true depends on what the Library does 148 | and what the program that uses the Library does. 149 | 150 | 1. You may copy and distribute verbatim copies of the Library's 151 | complete source code as you receive it, in any medium, provided that 152 | you conspicuously and appropriately publish on each copy an 153 | appropriate copyright notice and disclaimer of warranty; keep intact 154 | all the notices that refer to this License and to the absence of any 155 | warranty; and distribute a copy of this License along with the 156 | Library. 157 | 158 | You may charge a fee for the physical act of transferring a copy, 159 | and you may at your option offer warranty protection in exchange for a 160 | fee. 161 | 162 | 2. You may modify your copy or copies of the Library or any portion 163 | of it, thus forming a work based on the Library, and copy and 164 | distribute such modifications or work under the terms of Section 1 165 | above, provided that you also meet all of these conditions: 166 | 167 | a) The modified work must itself be a software library. 168 | 169 | b) You must cause the files modified to carry prominent notices 170 | stating that you changed the files and the date of any change. 171 | 172 | c) You must cause the whole of the work to be licensed at no 173 | charge to all third parties under the terms of this License. 174 | 175 | d) If a facility in the modified Library refers to a function or a 176 | table of data to be supplied by an application program that uses 177 | the facility, other than as an argument passed when the facility 178 | is invoked, then you must make a good faith effort to ensure that, 179 | in the event an application does not supply such function or 180 | table, the facility still operates, and performs whatever part of 181 | its purpose remains meaningful. 182 | 183 | (For example, a function in a library to compute square roots has 184 | a purpose that is entirely well-defined independent of the 185 | application. Therefore, Subsection 2d requires that any 186 | application-supplied function or table used by this function must 187 | be optional: if the application does not supply it, the square 188 | root function must still compute square roots.) 189 | 190 | These requirements apply to the modified work as a whole. If 191 | identifiable sections of that work are not derived from the Library, 192 | and can be reasonably considered independent and separate works in 193 | themselves, then this License, and its terms, do not apply to those 194 | sections when you distribute them as separate works. But when you 195 | distribute the same sections as part of a whole which is a work based 196 | on the Library, the distribution of the whole must be on the terms of 197 | this License, whose permissions for other licensees extend to the 198 | entire whole, and thus to each and every part regardless of who wrote 199 | it. 200 | 201 | Thus, it is not the intent of this section to claim rights or contest 202 | your rights to work written entirely by you; rather, the intent is to 203 | exercise the right to control the distribution of derivative or 204 | collective works based on the Library. 205 | 206 | In addition, mere aggregation of another work not based on the Library 207 | with the Library (or with a work based on the Library) on a volume of 208 | a storage or distribution medium does not bring the other work under 209 | the scope of this License. 210 | 211 | 3. You may opt to apply the terms of the ordinary GNU General Public 212 | License instead of this License to a given copy of the Library. To do 213 | this, you must alter all the notices that refer to this License, so 214 | that they refer to the ordinary GNU General Public License, version 2, 215 | instead of to this License. (If a newer version than version 2 of the 216 | ordinary GNU General Public License has appeared, then you can specify 217 | that version instead if you wish.) Do not make any other change in 218 | these notices. 219 | 220 | Once this change is made in a given copy, it is irreversible for 221 | that copy, so the ordinary GNU General Public License applies to all 222 | subsequent copies and derivative works made from that copy. 223 | 224 | This option is useful when you wish to copy part of the code of 225 | the Library into a program that is not a library. 226 | 227 | 4. You may copy and distribute the Library (or a portion or 228 | derivative of it, under Section 2) in object code or executable form 229 | under the terms of Sections 1 and 2 above provided that you accompany 230 | it with the complete corresponding machine-readable source code, which 231 | must be distributed under the terms of Sections 1 and 2 above on a 232 | medium customarily used for software interchange. 233 | 234 | If distribution of object code is made by offering access to copy 235 | from a designated place, then offering equivalent access to copy the 236 | source code from the same place satisfies the requirement to 237 | distribute the source code, even though third parties are not 238 | compelled to copy the source along with the object code. 239 | 240 | 5. A program that contains no derivative of any portion of the 241 | Library, but is designed to work with the Library by being compiled or 242 | linked with it, is called a "work that uses the Library". Such a 243 | work, in isolation, is not a derivative work of the Library, and 244 | therefore falls outside the scope of this License. 245 | 246 | However, linking a "work that uses the Library" with the Library 247 | creates an executable that is a derivative of the Library (because it 248 | contains portions of the Library), rather than a "work that uses the 249 | library". The executable is therefore covered by this License. 250 | Section 6 states terms for distribution of such executables. 251 | 252 | When a "work that uses the Library" uses material from a header file 253 | that is part of the Library, the object code for the work may be a 254 | derivative work of the Library even though the source code is not. 255 | Whether this is true is especially significant if the work can be 256 | linked without the Library, or if the work is itself a library. The 257 | threshold for this to be true is not precisely defined by law. 258 | 259 | If such an object file uses only numerical parameters, data 260 | structure layouts and accessors, and small macros and small inline 261 | functions (ten lines or less in length), then the use of the object 262 | file is unrestricted, regardless of whether it is legally a derivative 263 | work. (Executables containing this object code plus portions of the 264 | Library will still fall under Section 6.) 265 | 266 | Otherwise, if the work is a derivative of the Library, you may 267 | distribute the object code for the work under the terms of Section 6. 268 | Any executables containing that work also fall under Section 6, 269 | whether or not they are linked directly with the Library itself. 270 | 271 | 6. As an exception to the Sections above, you may also combine or 272 | link a "work that uses the Library" with the Library to produce a 273 | work containing portions of the Library, and distribute that work 274 | under terms of your choice, provided that the terms permit 275 | modification of the work for the customer's own use and reverse 276 | engineering for debugging such modifications. 277 | 278 | You must give prominent notice with each copy of the work that the 279 | Library is used in it and that the Library and its use are covered by 280 | this License. You must supply a copy of this License. If the work 281 | during execution displays copyright notices, you must include the 282 | copyright notice for the Library among them, as well as a reference 283 | directing the user to the copy of this License. Also, you must do one 284 | of these things: 285 | 286 | a) Accompany the work with the complete corresponding 287 | machine-readable source code for the Library including whatever 288 | changes were used in the work (which must be distributed under 289 | Sections 1 and 2 above); and, if the work is an executable linked 290 | with the Library, with the complete machine-readable "work that 291 | uses the Library", as object code and/or source code, so that the 292 | user can modify the Library and then relink to produce a modified 293 | executable containing the modified Library. (It is understood 294 | that the user who changes the contents of definitions files in the 295 | Library will not necessarily be able to recompile the application 296 | to use the modified definitions.) 297 | 298 | b) Use a suitable shared library mechanism for linking with the 299 | Library. A suitable mechanism is one that (1) uses at run time a 300 | copy of the library already present on the user's computer system, 301 | rather than copying library functions into the executable, and (2) 302 | will operate properly with a modified version of the library, if 303 | the user installs one, as long as the modified version is 304 | interface-compatible with the version that the work was made with. 305 | 306 | c) Accompany the work with a written offer, valid for at 307 | least three years, to give the same user the materials 308 | specified in Subsection 6a, above, for a charge no more 309 | than the cost of performing this distribution. 310 | 311 | d) If distribution of the work is made by offering access to copy 312 | from a designated place, offer equivalent access to copy the above 313 | specified materials from the same place. 314 | 315 | e) Verify that the user has already received a copy of these 316 | materials or that you have already sent this user a copy. 317 | 318 | For an executable, the required form of the "work that uses the 319 | Library" must include any data and utility programs needed for 320 | reproducing the executable from it. However, as a special exception, 321 | the materials to be distributed need not include anything that is 322 | normally distributed (in either source or binary form) with the major 323 | components (compiler, kernel, and so on) of the operating system on 324 | which the executable runs, unless that component itself accompanies 325 | the executable. 326 | 327 | It may happen that this requirement contradicts the license 328 | restrictions of other proprietary libraries that do not normally 329 | accompany the operating system. Such a contradiction means you cannot 330 | use both them and the Library together in an executable that you 331 | distribute. 332 | 333 | 7. You may place library facilities that are a work based on the 334 | Library side-by-side in a single library together with other library 335 | facilities not covered by this License, and distribute such a combined 336 | library, provided that the separate distribution of the work based on 337 | the Library and of the other library facilities is otherwise 338 | permitted, and provided that you do these two things: 339 | 340 | a) Accompany the combined library with a copy of the same work 341 | based on the Library, uncombined with any other library 342 | facilities. This must be distributed under the terms of the 343 | Sections above. 344 | 345 | b) Give prominent notice with the combined library of the fact 346 | that part of it is a work based on the Library, and explaining 347 | where to find the accompanying uncombined form of the same work. 348 | 349 | 8. You may not copy, modify, sublicense, link with, or distribute 350 | the Library except as expressly provided under this License. Any 351 | attempt otherwise to copy, modify, sublicense, link with, or 352 | distribute the Library is void, and will automatically terminate your 353 | rights under this License. However, parties who have received copies, 354 | or rights, from you under this License will not have their licenses 355 | terminated so long as such parties remain in full compliance. 356 | 357 | 9. You are not required to accept this License, since you have not 358 | signed it. However, nothing else grants you permission to modify or 359 | distribute the Library or its derivative works. These actions are 360 | prohibited by law if you do not accept this License. Therefore, by 361 | modifying or distributing the Library (or any work based on the 362 | Library), you indicate your acceptance of this License to do so, and 363 | all its terms and conditions for copying, distributing or modifying 364 | the Library or works based on it. 365 | 366 | 10. Each time you redistribute the Library (or any work based on the 367 | Library), the recipient automatically receives a license from the 368 | original licensor to copy, distribute, link with or modify the Library 369 | subject to these terms and conditions. You may not impose any further 370 | restrictions on the recipients' exercise of the rights granted herein. 371 | You are not responsible for enforcing compliance by third parties with 372 | this License. 373 | 374 | 11. If, as a consequence of a court judgment or allegation of patent 375 | infringement or for any other reason (not limited to patent issues), 376 | conditions are imposed on you (whether by court order, agreement or 377 | otherwise) that contradict the conditions of this License, they do not 378 | excuse you from the conditions of this License. If you cannot 379 | distribute so as to satisfy simultaneously your obligations under this 380 | License and any other pertinent obligations, then as a consequence you 381 | may not distribute the Library at all. For example, if a patent 382 | license would not permit royalty-free redistribution of the Library by 383 | all those who receive copies directly or indirectly through you, then 384 | the only way you could satisfy both it and this License would be to 385 | refrain entirely from distribution of the Library. 386 | 387 | If any portion of this section is held invalid or unenforceable under any 388 | particular circumstance, the balance of the section is intended to apply, 389 | and the section as a whole is intended to apply in other circumstances. 390 | 391 | It is not the purpose of this section to induce you to infringe any 392 | patents or other property right claims or to contest validity of any 393 | such claims; this section has the sole purpose of protecting the 394 | integrity of the free software distribution system which is 395 | implemented by public license practices. Many people have made 396 | generous contributions to the wide range of software distributed 397 | through that system in reliance on consistent application of that 398 | system; it is up to the author/donor to decide if he or she is willing 399 | to distribute software through any other system and a licensee cannot 400 | impose that choice. 401 | 402 | This section is intended to make thoroughly clear what is believed to 403 | be a consequence of the rest of this License. 404 | 405 | 12. If the distribution and/or use of the Library is restricted in 406 | certain countries either by patents or by copyrighted interfaces, the 407 | original copyright holder who places the Library under this License may add 408 | an explicit geographical distribution limitation excluding those countries, 409 | so that distribution is permitted only in or among countries not thus 410 | excluded. In such case, this License incorporates the limitation as if 411 | written in the body of this License. 412 | 413 | 13. The Free Software Foundation may publish revised and/or new 414 | versions of the Lesser General Public License from time to time. 415 | Such new versions will be similar in spirit to the present version, 416 | but may differ in detail to address new problems or concerns. 417 | 418 | Each version is given a distinguishing version number. If the Library 419 | specifies a version number of this License which applies to it and 420 | "any later version", you have the option of following the terms and 421 | conditions either of that version or of any later version published by 422 | the Free Software Foundation. If the Library does not specify a 423 | license version number, you may choose any version ever published by 424 | the Free Software Foundation. 425 | 426 | 14. If you wish to incorporate parts of the Library into other free 427 | programs whose distribution conditions are incompatible with these, 428 | write to the author to ask for permission. For software which is 429 | copyrighted by the Free Software Foundation, write to the Free 430 | Software Foundation; we sometimes make exceptions for this. Our 431 | decision will be guided by the two goals of preserving the free status 432 | of all derivatives of our free software and of promoting the sharing 433 | and reuse of software generally. 434 | 435 | NO WARRANTY 436 | 437 | 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO 438 | WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. 439 | EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR 440 | OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY 441 | KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE 442 | IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 443 | PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE 444 | LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME 445 | THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 446 | 447 | 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN 448 | WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY 449 | AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU 450 | FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR 451 | CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE 452 | LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING 453 | RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A 454 | FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF 455 | SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH 456 | DAMAGES. 457 | 458 | END OF TERMS AND CONDITIONS 459 | 460 | How to Apply These Terms to Your New Libraries 461 | 462 | If you develop a new library, and you want it to be of the greatest 463 | possible use to the public, we recommend making it free software that 464 | everyone can redistribute and change. You can do so by permitting 465 | redistribution under these terms (or, alternatively, under the terms of the 466 | ordinary General Public License). 467 | 468 | To apply these terms, attach the following notices to the library. It is 469 | safest to attach them to the start of each source file to most effectively 470 | convey the exclusion of warranty; and each file should have at least the 471 | "copyright" line and a pointer to where the full notice is found. 472 | 473 | {description} 474 | Copyright (C) {year} {fullname} 475 | 476 | This library is free software; you can redistribute it and/or 477 | modify it under the terms of the GNU Lesser General Public 478 | License as published by the Free Software Foundation; either 479 | version 2.1 of the License, or (at your option) any later version. 480 | 481 | This library is distributed in the hope that it will be useful, 482 | but WITHOUT ANY WARRANTY; without even the implied warranty of 483 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 484 | Lesser General Public License for more details. 485 | 486 | You should have received a copy of the GNU Lesser General Public 487 | License along with this library; if not, write to the Free Software 488 | Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 489 | USA 490 | 491 | Also add information on how to contact you by electronic and paper mail. 492 | 493 | You should also get your employer (if you work as a programmer) or your 494 | school, if any, to sign a "copyright disclaimer" for the library, if 495 | necessary. Here is a sample; alter the names: 496 | 497 | Yoyodyne, Inc., hereby disclaims all copyright interest in the 498 | library `Frob' (a library for tweaking knobs) written by James Random 499 | Hacker. 500 | 501 | {signature of Ty Coon}, 1 April 1990 502 | Ty Coon, President of Vice 503 | 504 | That's all there is to it! 505 | -------------------------------------------------------------------------------- /App/lib/polygoat.LICENSE: -------------------------------------------------------------------------------- 1 | ISC License 2 | 3 | Copyright (c) 2016, Sonny Piers 4 | 5 | Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies. 6 | 7 | THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -------------------------------------------------------------------------------- /App/lib/polygoat.js: -------------------------------------------------------------------------------- 1 | ;(function (global) { 2 | 'use strict' 3 | 4 | function polygoat (fn, cb, Promise) { 5 | if (cb) { 6 | fn(function (err, res) { 7 | cb(err, res) 8 | }) 9 | } else { 10 | var P = Promise || global.Promise 11 | return new P(function (resolve, reject) { 12 | fn(function (err, res) { 13 | if (err !== null && err !== undefined) { 14 | reject(err) 15 | } else { 16 | resolve(res) 17 | } 18 | }) 19 | }) 20 | } 21 | } 22 | 23 | if (typeof module !== 'undefined' && module.exports) { 24 | module.exports = polygoat 25 | } else { 26 | global.polygoat = polygoat 27 | } 28 | }(typeof global !== 'undefined' ? global : this)) 29 | -------------------------------------------------------------------------------- /App/lib/tools.js: -------------------------------------------------------------------------------- 1 | 2 | 'use strict'; 3 | async function verifyFileName(name) { 4 | var tmp = []; 5 | await browser.runtime.getPlatformInfo().then( (e) => { 6 | if (name.match(/[<>:"\/\\|?*\x00-\x1F]/g) != null) { 7 | tmp = name.match(/[<>:"\/\\|?*\x00-\x1F]/g); 8 | } 9 | if (e.os == "win") { 10 | if (name.search(/^(con|prn|aux|nul|com[0-9]|lpt[0-9])$/i) != -1) 11 | tmp = tmp.concat(name); 12 | if (name[name.length - 1] == ' ' || name[name.length - 1] == '.') 13 | tmp = tmp.concat("Filenames cannot end in a space or dot."); 14 | } 15 | }); 16 | console.log(tmp); 17 | return tmp; 18 | } 19 | 20 | async function correctFileName(name) { 21 | var tmp = name; 22 | await browser.runtime.getPlatformInfo().then( (e) => { 23 | tmp = tmp.replace(/[<>:"\/\\|?*\x00-\x1F]/g, '_'); 24 | if (e.os == "win") { 25 | if (tmp.search(/^(con|prn|aux|nul|com[0-9]|lpt[0-9])$/i) != -1) 26 | tmp = '_' + tmp; 27 | if (tmp[tmp.length - 1] == ' ' || tmp[tmp.length - 1] == '.') 28 | tmp = tmp.slice(0, tmp.length - 1); 29 | } 30 | }); 31 | console.log(tmp); 32 | return tmp; 33 | } 34 | 35 | function monitor(options, gid) { 36 | if (mon == undefined) { 37 | mon = new Worker("/lib/worker.js"); 38 | mon.onmessage = function(e) { 39 | console.log(e.data); 40 | browser.storage.local.get(config.command.guess, function(item) { 41 | if (e.data[0] == "complete") { 42 | notify(browser.i18n.getMessage("download_complete", e.data[1] )); 43 | if (item.sound != "0") { 44 | var audio = new Audio('/data/Sound/complete' + item.sound + '.wav'); 45 | audio.play(); 46 | } 47 | } 48 | else if (e.data[0] == "badge" && item.badge){ 49 | if(e.data[1] == 0){ 50 | browser.browserAction.setBadgeText({text: ""}); 51 | mon = null; 52 | } 53 | else { 54 | browser.browserAction.setBadgeText({text: e.data[1].toString()}); 55 | } 56 | } 57 | else if (e.data[0] == "error"){ 58 | notify(browser.i18n.getMessage("download_error", e.data[1] )); 59 | } 60 | }); 61 | } 62 | } 63 | mon.postMessage([options, gid]); 64 | } 65 | 66 | function notify(message) { 67 | browser.notifications.create({ 68 | type: 'basic', 69 | iconUrl: '/data/icons/48.png', 70 | title: browser.i18n.getMessage("extensionName"), 71 | message: message.message || message 72 | }).then((id) => { 73 | setTimeout(() => { 74 | browser.notifications.clear(id.toString()); 75 | }, 2000); 76 | }); 77 | } 78 | 79 | function humanFileSize(bytes, si) { 80 | var thresh = si ? 1000 : 1024; 81 | if(Math.abs(bytes) < thresh) { 82 | return bytes + ' B'; 83 | } 84 | var units = si 85 | ? ['kB','MB','GB','TB','PB','EB','ZB','YB'] 86 | : ['KiB','MiB','GiB','TiB','PiB','EiB','ZiB','YiB']; 87 | var u = -1; 88 | do { 89 | bytes /= thresh; 90 | ++u; 91 | } while(Math.abs(bytes) >= thresh && u < units.length - 1); 92 | return bytes.toFixed(1)+' '+units[u]; 93 | } 94 | 95 | function isRunning(item, aria2) { 96 | //check whether aria2 is runnning 97 | var xhttp = new XMLHttpRequest(); 98 | var url = "aria2://" 99 | if (item.shutdown) 100 | url += "stop-with-process"; 101 | if (item.protocol.toLowerCase() == "ws" || item.protocol.toLowerCase() == "wss") { 102 | aria2.open().then( 103 | function (res) { 104 | aria2.close(); 105 | }, 106 | function (err) { 107 | if (item.auto) { 108 | var creating = browser.windows.create({ 109 | url: url, 110 | type: "popup", 111 | width: 50, 112 | height: 50, 113 | }); 114 | creating.then(windowInfo => { 115 | browser.windows.remove(windowInfo.id); 116 | }, () => {}); 117 | } 118 | } 119 | ); 120 | } 121 | else { 122 | aria2.getVersion().then( 123 | function (res) { 124 | console.log('result', res); 125 | }, 126 | function (err) { 127 | if (item.auto) { 128 | var creating = browser.windows.create({ 129 | url: url, 130 | type: "popup", 131 | width: 50, 132 | height: 50, 133 | }); 134 | creating.then(windowInfo => { 135 | browser.windows.remove(windowInfo.id); 136 | }, () => {}); 137 | } 138 | } 139 | ); 140 | } 141 | } 142 | 143 | function downloadPanel(d) { 144 | globalD.push(d); 145 | //get incognito 146 | var getting = browser.windows.getCurrent(); 147 | getting.then((windowInfo) => { 148 | browser.storage.local.get(['dpTop', 'dpLeft', 'dpWidth', 'dpHeight'], item1 => { 149 | var creating = browser.windows.create({ 150 | top: item1.dpTop, 151 | left: item1.dpLeft, 152 | url: "data/DownloadPanel/index.html", 153 | type: "popup", 154 | width: 412 + parseInt((screen.width / 5000) * parseInt(item1.dpWidth || 0)), 155 | height: 200 + parseInt(33 * window.devicePixelRatio + (screen.height / 5000) * parseInt(item1.dpHeight || 0)) , 156 | incognito: windowInfo.incognito, 157 | //titlePreface: "Aria2", 158 | //state: "fullscreen", 159 | }); 160 | creating.then((wInfo) => { 161 | function handleZoomed(zoomChangeInfo){ 162 | browser.storage.local.get(config.command.guess, (item) => { 163 | if (zoomChangeInfo.tabId == wInfo.tabs[0].id) { 164 | var updating = browser.windows.update(wInfo.id, { 165 | focused: true, 166 | top: item1.dpTop, 167 | left: item1.dpLeft, 168 | width: parseInt(412 * zoomChangeInfo.newZoomFactor * item.zoom 169 | + (screen.width / 5000) * parseInt(item1.dpWidth || 0)), 170 | height: parseInt(200 * zoomChangeInfo.newZoomFactor * item.zoom 171 | + 33 * window.devicePixelRatio 172 | + (screen.height / 5000) * parseInt(item1.dpHeight || 0)), 173 | }); 174 | browser.tabs.onZoomChange.removeListener(handleZoomed); 175 | } 176 | }); 177 | } 178 | browser.tabs.onZoomChange.addListener(handleZoomed); 179 | }, () => {}); 180 | }); 181 | }, () => {}); 182 | } -------------------------------------------------------------------------------- /App/lib/worker.js: -------------------------------------------------------------------------------- 1 | 'use strict' 2 | 3 | postMessage("init"); 4 | importScripts("aria.js"); 5 | importScripts("polygoat.js"); 6 | var aria2; 7 | var gids = []; 8 | 9 | onmessage = function(e) { 10 | gids.push(e.data[1]); 11 | if (aria2 == undefined){ 12 | connect(e.data[0]); 13 | postMessage("connect"); 14 | }; 15 | /*aria2.tellActive(["gid"]).then((info) => { 16 | postMessage(["badge", info.length]); 17 | if(info.length == 0) { 18 | aria2.close(); 19 | close(); 20 | } 21 | });*/ 22 | 23 | } 24 | 25 | function connect(options) { 26 | aria2 = new Aria2(options); 27 | aria2.onclose = function () { 28 | aria2 = null; 29 | } 30 | aria2.onDownloadStart = function(d) { 31 | aria2.tellActive(["gid"]).then((info) => { 32 | postMessage(["badge", info.length]); 33 | if(info.length == 0) { 34 | aria2.close(); 35 | postMessage("close"); 36 | close(); 37 | } 38 | }); 39 | }; 40 | aria2.onDownloadComplete = function(d) { 41 | if (gids.includes(d.gid)) { 42 | aria2.getFiles(d.gid).then((info) => { 43 | postMessage(["complete", info[0].path]); 44 | }); 45 | gids = gids.filter(gid => gid != d.gid); 46 | } 47 | aria2.tellActive(["gid"]).then((info) => { 48 | postMessage(["badge", info.length]); 49 | if(info.length == 0) { 50 | aria2.close(); 51 | postMessage("close"); 52 | close(); 53 | } 54 | }); 55 | }; 56 | aria2.onDownloadPause = aria2.onDownloadStop = function(d) { 57 | aria2.tellActive(["gid"]).then((info) => { 58 | postMessage(["badge", info.length]); 59 | if(info.length == 0) { 60 | aria2.close(); 61 | postMessage("close"); 62 | close(); 63 | } 64 | }); 65 | }; 66 | aria2.onDownloadError = function(d) { 67 | aria2.getUris(d.gid).then((info) => { 68 | postMessage(["error", info[0].uri]); 69 | }); 70 | aria2.tellActive(["gid"]).then((info) => { 71 | postMessage(["badge", info.length]); 72 | if(info.length == 0) { 73 | aria2.close(); 74 | postMessage("close"); 75 | close(); 76 | } 77 | }); 78 | }; 79 | aria2.open().then(() => { 80 | aria2.tellActive(["gid"]).then((info) => { 81 | postMessage(["badge", info.length]); 82 | if(info.length == 0) { 83 | aria2.close(); 84 | postMessage("close"); 85 | close(); 86 | } 87 | }); 88 | }); 89 | } -------------------------------------------------------------------------------- /App/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "__MSG_extensionName__", 3 | "description": "__MSG_extensionDescription__", 4 | "version": "0.4.5", 5 | "default_locale": "en", 6 | "manifest_version": 2, 7 | "permissions": [ 8 | "storage", 9 | "tabs", 10 | "notifications", 11 | "downloads", 12 | "downloads.open", 13 | "contextMenus", 14 | "webRequest", 15 | "webRequestBlocking", 16 | "cookies", 17 | "" 18 | ], 19 | "background": { 20 | "scripts": [ 21 | "config.js", 22 | "common.js", 23 | "/lib/aria.js", 24 | "/lib/tools.js", 25 | "/lib/polygoat.js" 26 | ] 27 | }, 28 | "browser_action": { 29 | "default_popup": "data/action/index.html", 30 | "default_icon": { 31 | "16": "data/icons/disabled/16.png", 32 | "32": "data/icons/disabled/32.png", 33 | "64": "data/icons/disabled/64.png", 34 | "128": "data/icons/disabled/128.png", 35 | "256": "data/icons/disabled/256.png" 36 | } 37 | }, 38 | "icons": { 39 | "16": "data/icons/16.png", 40 | "32": "data/icons/32.png", 41 | "64": "data/icons/64.png", 42 | "128": "data/icons/128.png", 43 | "256": "data/icons/256.png" 44 | }, 45 | "homepage_url": "https://addons.mozilla.org/firefox/addon/aria2-integration", 46 | "options_ui": { 47 | "page": "data/options/menu.html", 48 | "open_in_tab": true 49 | }, 50 | "applications": { 51 | "gecko": { 52 | "id": "{e2488817-3d73-4013-850d-b66c5e42d505}", 53 | "strict_min_version": "57.0" 54 | } 55 | } 56 | } 57 | -------------------------------------------------------------------------------- /Bin/Aria2-uriScheme.reg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/Bin/Aria2-uriScheme.reg -------------------------------------------------------------------------------- /Bin/HideRun.vbs: -------------------------------------------------------------------------------- 1 | CreateObject("WScript.Shell").Run "aria2c.exe --conf-path=aria2.conf",0 -------------------------------------------------------------------------------- /Bin/Readme.txt: -------------------------------------------------------------------------------- 1 | If you don't know how to do, simply follow the step below. 2 | 3 | 1. download "aria2.zip", 4 | 2. unzip "aria" folder to your download folder 5 | 3. run "add_Aria2-uriScheme.bat" as administrator 6 | 7 | ------------------------------------------------------------------ 8 | You can refer to: 9 | https://aria2.github.io/manual/en/html/index.html 10 | http://ariang.mayswind.net/ 11 | 12 | ------------------------------------------------------------------ 13 | (These files are sample settings of aria2) -------------------------------------------------------------------------------- /Bin/add_Aria2-uriScheme.bat: -------------------------------------------------------------------------------- 1 | @Echo Off 2 | Title Add Uri Scheme 3 | set "current=%~dp0" 4 | call :IsAdmin 5 | 6 | Reg.exe add "HKCR\Aria2" /ve /t REG_SZ /d "URL:Aria2 Startup Protocol" /f 7 | Reg.exe add "HKCR\Aria2" /v "URL Protocol" /t REG_SZ /d "" /f 8 | Reg.exe add "HKCR\Aria2\DefaultIcon" /ve /t REG_SZ /d "\"%current%aria2Hide.exe\"" /f 9 | Reg.exe add "HKCR\Aria2\shell\open\command" /ve /t REG_SZ /d "\"%current%aria2Hide.exe\" \"%%1\"" /f 10 | pause 11 | Exit 12 | 13 | :IsAdmin 14 | Reg.exe query "HKU\S-1-5-19\Environment" 15 | If Not %ERRORLEVEL% EQU 0 ( 16 | cls 17 | Echo You must have administrator rights to continue ... 18 | Pause 19 | Exit 20 | ) 21 | Cls 22 | goto:eof 23 | -------------------------------------------------------------------------------- /Bin/aria2.conf: -------------------------------------------------------------------------------- 1 | dir=../../ 2 | #log=Aria2.log 3 | log= 4 | input-file=aria2.session 5 | save-session=aria2.session 6 | dht-file-path6=dht6.dat 7 | dht-file-path=dht.dat 8 | #load-cookies="cookies.sqlite" 9 | 10 | 11 | #----------------------- 12 | disk-cache=32M 13 | file-allocation=falloc 14 | continue=true 15 | max-concurrent-downloads=10 16 | max-connection-per-server=16 17 | min-split-size=10M 18 | split=5 19 | disable-ipv6=true 20 | save-session-interval=60 21 | enable-rpc=true 22 | #rpc-secret= 23 | rpc-listen-port=6800 24 | rpc-allow-origin-all=true 25 | #rpc-listen-all=true 26 | follow-torrent=true 27 | listen-port=51413 28 | bt-max-peers=100 29 | enable-dht=true 30 | enable-dht6=true 31 | dht-listen-port=6966 32 | enable-peer-exchange=true 33 | peer-id-prefix=-TR2770- 34 | peer-agent=Transmission/2.77 35 | user-agent=Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:56.0) Gecko/20100101 Firefox/56.0 36 | seed-ratio=0 37 | bt-hash-check-seed=true 38 | bt-seed-unverified=true 39 | bt-save-metadata=false -------------------------------------------------------------------------------- /Bin/aria2.session: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/Bin/aria2.session -------------------------------------------------------------------------------- /Bin/aria2.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/Bin/aria2.zip -------------------------------------------------------------------------------- /Bin/aria2Hide.c: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | 5 | int main (int argc, char **argv){ 6 | 7 | // get parent pid 8 | int ppid = -1; 9 | int pid = -1; 10 | HANDLE h = CreateToolhelp32Snapshot(TH32CS_SNAPPROCESS, 0); 11 | PROCESSENTRY32 pe = { 0 }; 12 | pe.dwSize = sizeof(PROCESSENTRY32); 13 | 14 | pid = GetCurrentProcessId(); 15 | 16 | if( Process32First(h, &pe)) { 17 | do { 18 | if (pe.th32ProcessID == pid) { 19 | ppid = pe.th32ParentProcessID; 20 | } 21 | } while( Process32Next(h, &pe)); 22 | } 23 | 24 | CloseHandle(h); 25 | 26 | // start aria2c 27 | PROCESS_INFORMATION pi; 28 | STARTUPINFO si; 29 | ZeroMemory(&si, sizeof(si)); 30 | ZeroMemory(&pi, sizeof(pi)); 31 | char cmd[65535] = {0}; 32 | sprintf(cmd, "%s\\..\\", argv[0]); 33 | chdir(cmd); 34 | if (strcmp(argv[1], "aria2://stop-with-process/") == 0){ 35 | sprintf(cmd, "aria2c.exe -D --conf-path=aria2.conf --stop-with-process=%d", ppid); 36 | CreateProcess(NULL,cmd,NULL,NULL,0,CREATE_NO_WINDOW,NULL,NULL,&si,&pi); 37 | } 38 | else{ 39 | sprintf(cmd, "aria2c.exe -D --conf-path=aria2.conf"); 40 | CreateProcess(NULL,cmd,NULL,NULL,0,CREATE_NO_WINDOW,NULL,NULL,&si,&pi); 41 | } 42 | return 0 ; 43 | } 44 | -------------------------------------------------------------------------------- /Bin/aria2Hide.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/Bin/aria2Hide.exe -------------------------------------------------------------------------------- /Bin/aria2c.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/Bin/aria2c.exe -------------------------------------------------------------------------------- /Bin/aria2start.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | 3 | aria2c.exe -D --conf-path=aria2.conf -------------------------------------------------------------------------------- /Bin/del_Aria2-uriScheme.bat: -------------------------------------------------------------------------------- 1 | reg delete "HKEY_CLASSES_ROOT\Aria2" /f -------------------------------------------------------------------------------- /Bin/dht.dat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/Bin/dht.dat -------------------------------------------------------------------------------- /Bin/dht6.dat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/RossWang/Aria2-Integration/8ffb9305e32394b275ded29fa197a479d2315285/Bin/dht6.dat -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- 1 | ## [0.4.5](https://github.com/RossWang/Aria2-Integration/compare/0.4.4...0.4.5) (2019-06-14) 2 | 3 | 4 | ### Bug Fixes 5 | 6 | * fix a issue with Aggressive Mode ([8cc77c1](https://github.com/RossWang/Aria2-Integration/commit/8cc77c1)) 7 | 8 | 9 | ### Features 10 | 11 | * update AriaNg to 1.1.1 ([15451d1](https://github.com/RossWang/Aria2-Integration/commit/15451d1)) 12 | 13 | 14 | 15 | ## [0.4.4](https://github.com/RossWang/Aria2-Integration/compare/0.4.3...0.4.4) (2019-04-05) 16 | 17 | 18 | 19 | ## [0.4.3](https://github.com/RossWang/Aria2-Integration/compare/0.4.2...0.4.3) (2019-04-05) 20 | 21 | 22 | ### Bug Fixes 23 | 24 | * Fix a file name parsing issue ([098091f](https://github.com/RossWang/Aria2-Integration/commit/098091f)), closes [#53](https://github.com/RossWang/Aria2-Integration/issues/53) 25 | 26 | 27 | 28 | ## [0.4.2](https://github.com/RossWang/Aria2-Integration/compare/0.4.1...0.4.2) (2019-03-19) 29 | 30 | 31 | ### Bug Fixes 32 | 33 | * Fix a display issue ([4398338](https://github.com/RossWang/Aria2-Integration/commit/4398338)) 34 | 35 | 36 | ### Features 37 | 38 | * Update AriaNg to Version 1.0.1 ([9d42f8e](https://github.com/RossWang/Aria2-Integration/commit/9d42f8e)) 39 | * Update jschardet to Version 2.1.0 ([9370b78](https://github.com/RossWang/Aria2-Integration/commit/9370b78)) 40 | 41 | 42 | 43 | ## [0.4.1](https://github.com/RossWang/Aria2-Integration/compare/0.4.0...0.4.1) (2018-12-22) 44 | 45 | 46 | ### Bug Fixes 47 | 48 | * Fix an encoding issue ([#8](https://github.com/RossWang/Aria2-Integration/issues/8)) ([5210146](https://github.com/RossWang/Aria2-Integration/commit/5210146)) 49 | 50 | 51 | 52 | # [0.4.0](https://github.com/RossWang/Aria2-Integration/compare/0.3.6...0.4.0) (2018-12-20) 53 | 54 | 55 | ### Bug Fixes 56 | 57 | * automatically close browser action popup ([#47](https://github.com/RossWang/Aria2-Integration/issues/47)) ([2a7a4cd](https://github.com/RossWang/Aria2-Integration/commit/2a7a4cd)) 58 | * Download url not urlencoding parentheses ([a8fbdf3](https://github.com/RossWang/Aria2-Integration/commit/a8fbdf3)), closes [#36](https://github.com/RossWang/Aria2-Integration/issues/36) 59 | * Fix a file name encoding issue ([989912b](https://github.com/RossWang/Aria2-Integration/commit/989912b)), closes [#8](https://github.com/RossWang/Aria2-Integration/issues/8) 60 | * Fix link in about page ([311701f](https://github.com/RossWang/Aria2-Integration/commit/311701f)), closes [#38](https://github.com/RossWang/Aria2-Integration/issues/38) 61 | * It will no longer trigger notification from other sources ([cf9660e](https://github.com/RossWang/Aria2-Integration/commit/cf9660e)), closes [#42](https://github.com/RossWang/Aria2-Integration/issues/42) 62 | 63 | 64 | ### Features 65 | 66 | * Downloads trigger from context menu can now display the file name ([#45](https://github.com/RossWang/Aria2-Integration/issues/45)) ([383280e](https://github.com/RossWang/Aria2-Integration/commit/383280e)) 67 | * update AriaNg to 1.0.0 ([ccb10aa](https://github.com/RossWang/Aria2-Integration/commit/ccb10aa)) 68 | 69 | 70 | 71 | ## [0.3.6](https://github.com/RossWang/Aria2-Integration/compare/0.3.5...0.3.6) (2018-07-17) 72 | 73 | 74 | ### Bug Fixes 75 | 76 | * filter setting cannot be saved([#31](https://github.com/RossWang/Aria2-Integration/issues/31)) ([6957f35](https://github.com/RossWang/Aria2-Integration/commit/6957f35)) 77 | * Fix a file name encoding issue on baidupcs.com ([#8](https://github.com/RossWang/Aria2-Integration/issues/8)) ([b675908](https://github.com/RossWang/Aria2-Integration/commit/b675908)) 78 | 79 | 80 | ### Features 81 | 82 | * Add Aria2 Status in About Page ([#22](https://github.com/RossWang/Aria2-Integration/issues/22)) ([a253dd9](https://github.com/RossWang/Aria2-Integration/commit/a253dd9)) 83 | * Optionally Skip Confirmation Window ([#30](https://github.com/RossWang/Aria2-Integration/issues/30)) ([b1eaa3e](https://github.com/RossWang/Aria2-Integration/commit/b1eaa3e)) 84 | 85 | 86 | 87 | ## [0.3.5](https://github.com/RossWang/Aria2-Integration/compare/0.3.4...0.3.5) (2018-06-27) 88 | 89 | 90 | ### Bug Fixes 91 | 92 | * filter setting cannot be saved([#31](https://github.com/RossWang/Aria2-Integration/issues/31)) ([1a37956](https://github.com/RossWang/Aria2-Integration/commit/1a37956)) 93 | 94 | 95 | 96 | ## [0.3.4](https://github.com/RossWang/Aria2-Integration/compare/0.3.3...0.3.4) (2018-03-10) 97 | 98 | 99 | ### Bug Fixes 100 | 101 | * Fix an issue that prevents triggering the download([#22](https://github.com/RossWang/Aria2-Integration/issues/22)) ([3bedcd2](https://github.com/RossWang/Aria2-Integration/commit/3bedcd2)) 102 | 103 | 104 | ### Features 105 | 106 | * update AriaNg to 0.4.0 ([3fafaf1](https://github.com/RossWang/Aria2-Integration/commit/3fafaf1)) 107 | 108 | 109 | 110 | ## [0.3.3](https://github.com/RossWang/Aria2-Integration/compare/0.3.2...0.3.3) (2018-02-24) 111 | 112 | 113 | ### Bug Fixes 114 | 115 | * Fix a mistake that make https and wss protocols unusable ([9db649e](https://github.com/RossWang/Aria2-Integration/commit/9db649e)), closes [#20](https://github.com/RossWang/Aria2-Integration/issues/20) 116 | 117 | 118 | ### Features 119 | 120 | * Context menu now has sub-menu to select the RPC server. ([06687f9](https://github.com/RossWang/Aria2-Integration/commit/06687f9)) 121 | 122 | 123 | 124 | ## [0.3.2](https://github.com/RossWang/Aria2-Integration/compare/0.3.1...0.3.2) (2018-01-24) 125 | 126 | 127 | ### Bug Fixes 128 | 129 | * Fix "Save" and "Save as" buttons. ([1728fc2](https://github.com/RossWang/Aria2-Integration/commit/1728fc2)) 130 | * parameterized-uri --> false(force) ([ec035d4](https://github.com/RossWang/Aria2-Integration/commit/ec035d4)), closes [#12](https://github.com/RossWang/Aria2-Integration/issues/12) 131 | 132 | 133 | 134 | ## [0.3.1](https://github.com/RossWang/Aria2-Integration/compare/0.3.0...0.3.1) (2018-01-22) 135 | 136 | 137 | ### Bug Fixes 138 | 139 | * Fix a problem that prevents the download from Context Menu when "Display Download Panel" in settings turn off. ([2e76e0b](https://github.com/RossWang/Aria2-Integration/commit/2e76e0b)) 140 | 141 | 142 | 143 | # [0.3.0](https://github.com/RossWang/Aria2-Integration/compare/0.2.4...0.3.0) (2018-01-22) 144 | 145 | 146 | ### Bug Fixes 147 | 148 | * RSS will not trigger the download anymore ([ab6ff78](https://github.com/RossWang/Aria2-Integration/commit/ab6ff78)), closes [#15](https://github.com/RossWang/Aria2-Integration/issues/15) 149 | 150 | 151 | ### Features 152 | 153 | * Exception Support ([01f8902](https://github.com/RossWang/Aria2-Integration/commit/01f8902)) 154 | * Incognito Download Support ([1bc9483](https://github.com/RossWang/Aria2-Integration/commit/1bc9483)) 155 | * Simple Multiple Server Support ([19d4b4f](https://github.com/RossWang/Aria2-Integration/commit/19d4b4f)), closes [#2](https://github.com/RossWang/Aria2-Integration/issues/2) 156 | * User Agent Support ([bd335a7](https://github.com/RossWang/Aria2-Integration/commit/bd335a7)) 157 | * User-Agent Settings ([2eb03df](https://github.com/RossWang/Aria2-Integration/commit/2eb03df)) 158 | 159 | 160 | 161 | ## [0.2.4](https://github.com/RossWang/Aria2-Integration/compare/0.2.3...0.2.4) (2017-12-13) 162 | 163 | 164 | ### Bug Fixes 165 | 166 | * Fix a font-size issue on Linux ([feecd9b](https://github.com/RossWang/Aria2-Integration/commit/feecd9b)), closes [#9](https://github.com/RossWang/Aria2-Integration/issues/9) 167 | * Verify the file name before download. ([463db18](https://github.com/RossWang/Aria2-Integration/commit/463db18)), closes [#10](https://github.com/RossWang/Aria2-Integration/issues/10) 168 | 169 | 170 | 171 | ## [0.2.3](https://github.com/RossWang/Aria2-Integration/compare/0.2.2...0.2.3) (2017-12-02) 172 | 173 | 174 | ### Bug Fixes 175 | 176 | * Fix a mistake about the download completed sound ([1f386ed](https://github.com/RossWang/Aria2-Integration/commit/1f386ed)) 177 | 178 | 179 | 180 | ## [0.2.2](https://github.com/RossWang/Aria2-Integration/compare/0.2.1...0.2.2) (2017-11-22) 181 | 182 | 183 | ### Bug Fixes 184 | 185 | * Fix A File Name Parsing Issue ([98c07f5](https://github.com/RossWang/Aria2-Integration/commit/98c07f5)) 186 | 187 | 188 | ### Features 189 | 190 | * 'Authorization' Header Support For Auto Observer ([3cff2a2](https://github.com/RossWang/Aria2-Integration/commit/3cff2a2)) 191 | * Add an option to disable Download Panel for the context menu downloads. ([b4e6a40](https://github.com/RossWang/Aria2-Integration/commit/b4e6a40)), closes [#7](https://github.com/RossWang/Aria2-Integration/issues/7) 192 | * Add download complete notification ([628bfc5](https://github.com/RossWang/Aria2-Integration/commit/628bfc5)) 193 | * Close notifications after two seconds ([3acedbc](https://github.com/RossWang/Aria2-Integration/commit/3acedbc)) 194 | * Display Changelog After Update ([71ffefd](https://github.com/RossWang/Aria2-Integration/commit/71ffefd)) 195 | 196 | 197 | 198 | ## [0.2.1](https://github.com/RossWang/Aria2-Integration/compare/0.2.0...0.2.1) (2017-11-17) 199 | 200 | 201 | ### Bug Fixes 202 | 203 | * fix "AriaNg's RPC config lost after clear browser history" ([b5e8dd8](https://github.com/RossWang/Aria2-Integration/commit/b5e8dd8)), closes [#4](https://github.com/RossWang/Aria2-Integration/issues/4) 204 | 205 | 206 | ### Features 207 | 208 | * Add cookie support for context menu download ([6437d01](https://github.com/RossWang/Aria2-Integration/commit/6437d01)), closes [#5](https://github.com/RossWang/Aria2-Integration/issues/5) 209 | * Add WebSocket Support ([3ed829f](https://github.com/RossWang/Aria2-Integration/commit/3ed829f)) 210 | 211 | 212 | 213 | # [0.2.0](https://github.com/RossWang/Aria2-Integration/compare/426de63...0.2.0) (2017-11-01) 214 | 215 | 216 | ### Bug Fixes 217 | 218 | * exclude xhtml ([426de63](https://github.com/RossWang/Aria2-Integration/commit/426de63)) 219 | * fix for addons.mozilla.org ([7c03ef3](https://github.com/RossWang/Aria2-Integration/commit/7c03ef3)) 220 | 221 | 222 | 223 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2017 RossWang 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Aria2 Download Manager Integration 2 | a Firefox Add-on to integrate with Aria2 3 | 4 | https://addons.mozilla.org/firefox/addon/aria2-integration/ 5 | 6 | ## Reference 7 | https://github.com/aria2/aria2 8 | 9 | https://github.com/mayswind/AriaNg 10 | -------------------------------------------------------------------------------- /THIRDPARTY.md: -------------------------------------------------------------------------------- 1 | # Third Party Legal Notices 2 | 3 | Aria2 Download Manager Integration use Third Party code for certain functions. The Licenses for such code are listed below. 4 | 5 | ## AriaNg 6 | 7 | 8 | 9 | ## jschardet 10 | 11 | 12 | 13 | ## aria2.js 14 | 15 | 16 | 17 | ## polygoat 18 | 19 | 20 | --------------------------------------------------------------------------------