pax_global_header00006660000000000000000000000064136121305130014505gustar00rootroot0000000000000052 comment=a7f1e9823734107ef85ba973e716602d091a0ef3 eiskaltdcpp-web-1.0.1/000077500000000000000000000000001361213051300145625ustar00rootroot00000000000000eiskaltdcpp-web-1.0.1/.gitignore000066400000000000000000000000101361213051300165410ustar00rootroot00000000000000build*/ eiskaltdcpp-web-1.0.1/CMakeLists.txt000066400000000000000000000027421361213051300173270ustar00rootroot00000000000000project (eiskaltdcpp-web) cmake_minimum_required (VERSION 3.0) if (UNIX AND NOT APPLE AND NOT HAIKU) # Launcher, desktop file, etc. install (FILES linux/${PROJECT_NAME} DESTINATION "${CMAKE_INSTALL_PREFIX}/bin" PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE) install (FILES linux/${PROJECT_NAME}.png DESTINATION "${CMAKE_INSTALL_PREFIX}/share/pixmaps") install (FILES linux/${PROJECT_NAME}.desktop DESTINATION "${CMAKE_INSTALL_PREFIX}/share/applications") # Config install (FILES config.js DESTINATION "${CMAKE_INSTALL_PREFIX}/share/eiskaltdcpp/web") # Web UI files and directories install (FILES index.html style.css favicon.ico DESTINATION "${CMAKE_INSTALL_PREFIX}/share/eiskaltdcpp/web") install (DIRECTORY images js DESTINATION "${CMAKE_INSTALL_PREFIX}/share/eiskaltdcpp/web") else () # Web UI files and directories install (FILES config.js index.html style.css favicon.ico DESTINATION "${CMAKE_INSTALL_PREFIX}/web-ui") install (DIRECTORY images js DESTINATION "${CMAKE_INSTALL_PREFIX}/web-ui") # Documentation if (WIN32) install (FILES README.html windows/help.html DESTINATION "${CMAKE_INSTALL_PREFIX}/web-ui") endif (WIN32) endif () add_custom_target (uninstall COMMAND xargs -a "${CMAKE_CURRENT_BINARY_DIR}/install_manifest.txt" rm ) eiskaltdcpp-web-1.0.1/INSTALL000066400000000000000000000044241361213051300156170ustar00rootroot00000000000000### Local usage ### 1) Make sure that eiskaltdcpp-daemon is built with JSON-RPC support (see -DJSONRPC_DAEMON=ON configuration option). Then check that you launch daemon on correct network interface. For example: $ eiskaltdcpp-daemon -L 192.168.0.132 -d Or, if you want to use all available interfaces: $ eiskaltdcpp-daemon -L 0.0.0.0 -d But this is less secure. 2) Clone eiskaltdcpp-web into any directory. For example: $ cd /home/user/ $ git clone https://github.com/eiskaltdcpp/eiskaltdcpp-web 3) Edit config.js file. For example: $ cd /home/user/eiskaltdcpp-web/ $ nano config.js Here your should set the IP address of remote computer where eiskaltdcpp-daemon is launched. Related string will look like this: "host" : "192.168.0.132", 4) Open index.html file in any modern web browser which you like. For example, in Mozilla Firefox or Google Chrome. ### Remote usage ### 1) Make sure that eiskaltdcpp-daemon is built with JSON-RPC support (see -DJSONRPC_DAEMON=ON configuration option). Then check that you launch daemon on correct network interface. For example: $ eiskaltdcpp-daemon -L 192.168.0.132 -d Or, if you want to use all available interfaces: $ eiskaltdcpp-daemon -L 0.0.0.0 -d But this is less secure. 2) Clone eiskaltdcpp-web into any directory. For example: $ git clone https://github.com/eiskaltdcpp/eiskaltdcpp-web $ sudo mv eiskaltdcpp-web /usr/share/ 3) Edit config.js file. For example: $ cd /usr/share/eiskaltdcpp-web/ $ sudo nano config.js Here your should set the IP address of remote computer where eiskaltdcpp-daemon is launched. Related string will look like this: "host" : "192.168.0.132", 4) Install any web-server which you like and configure it. For example: $ sudo nano /etc/nginx/sites-enabled/default Content may look like this: server { listen 80 default; listen [::]:80 default; location / { root /usr/share/eiskaltdcpp-web; index index.html; } } $ sudo systemctl restart nginx.service 5) Now EiskaltDC++ Web UI should be reachable at: http:/// If you use the same remote computer for eiskaltdcpp-web and for eiskaltdcpp-daemon, in our example above it will be: http://192.168.0.132/ eiskaltdcpp-web-1.0.1/LICENSE000066400000000000000000001045151361213051300155750ustar00rootroot00000000000000 GNU GENERAL PUBLIC LICENSE Version 3, 29 June 2007 Copyright (C) 2007 Free Software Foundation, Inc. Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. Preamble The GNU General Public License is a free, copyleft license for software and other kinds of works. The licenses for most software and other practical works are designed to take away your freedom to share and change the works. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change all versions of a program--to make sure it remains free software for all its users. We, the Free Software Foundation, use the GNU General Public License for most of our software; it applies also to any other work released this way by its authors. You can apply it to your programs, too. When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for them if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs, and that you know you can do these things. To protect your rights, we need to prevent others from denying you these rights or asking you to surrender the rights. Therefore, you have certain responsibilities if you distribute copies of the software, or if you modify it: responsibilities to respect the freedom of others. For example, if you distribute copies of such a program, whether gratis or for a fee, you must pass on to the recipients the same freedoms that you received. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights. Developers that use the GNU GPL protect your rights with two steps: (1) assert copyright on the software, and (2) offer you this License giving you legal permission to copy, distribute and/or modify it. For the developers' and authors' protection, the GPL clearly explains that there is no warranty for this free software. For both users' and authors' sake, the GPL requires that modified versions be marked as changed, so that their problems will not be attributed erroneously to authors of previous versions. Some devices are designed to deny users access to install or run modified versions of the software inside them, although the manufacturer can do so. This is fundamentally incompatible with the aim of protecting users' freedom to change the software. The systematic pattern of such abuse occurs in the area of products for individuals to use, which is precisely where it is most unacceptable. Therefore, we have designed this version of the GPL to prohibit the practice for those products. If such problems arise substantially in other domains, we stand ready to extend this provision to those domains in future versions of the GPL, as needed to protect the freedom of users. Finally, every program is threatened constantly by software patents. States should not allow patents to restrict development and use of software on general-purpose computers, but in those that do, we wish to avoid the special danger that patents applied to a free program could make it effectively proprietary. To prevent this, the GPL assures that patents cannot be used to render the program non-free. The precise terms and conditions for copying, distribution and modification follow. TERMS AND CONDITIONS 0. Definitions. "This License" refers to version 3 of the GNU General Public License. "Copyright" also means copyright-like laws that apply to other kinds of works, such as semiconductor masks. "The Program" refers to any copyrightable work licensed under this License. Each licensee is addressed as "you". "Licensees" and "recipients" may be individuals or organizations. To "modify" a work means to copy from or adapt all or part of the work in a fashion requiring copyright permission, other than the making of an exact copy. The resulting work is called a "modified version" of the earlier work or a work "based on" the earlier work. A "covered work" means either the unmodified Program or a work based on the Program. To "propagate" a work means to do anything with it that, without permission, would make you directly or secondarily liable for infringement under applicable copyright law, except executing it on a computer or modifying a private copy. Propagation includes copying, distribution (with or without modification), making available to the public, and in some countries other activities as well. To "convey" a work means any kind of propagation that enables other parties to make or receive copies. Mere interaction with a user through a computer network, with no transfer of a copy, is not conveying. An interactive user interface displays "Appropriate Legal Notices" to the extent that it includes a convenient and prominently visible feature that (1) displays an appropriate copyright notice, and (2) tells the user that there is no warranty for the work (except to the extent that warranties are provided), that licensees may convey the work under this License, and how to view a copy of this License. If the interface presents a list of user commands or options, such as a menu, a prominent item in the list meets this criterion. 1. Source Code. The "source code" for a work means the preferred form of the work for making modifications to it. "Object code" means any non-source form of a work. A "Standard Interface" means an interface that either is an official standard defined by a recognized standards body, or, in the case of interfaces specified for a particular programming language, one that is widely used among developers working in that language. The "System Libraries" of an executable work include anything, other than the work as a whole, that (a) is included in the normal form of packaging a Major Component, but which is not part of that Major Component, and (b) serves only to enable use of the work with that Major Component, or to implement a Standard Interface for which an implementation is available to the public in source code form. A "Major Component", in this context, means a major essential component (kernel, window system, and so on) of the specific operating system (if any) on which the executable work runs, or a compiler used to produce the work, or an object code interpreter used to run it. The "Corresponding Source" for a work in object code form means all the source code needed to generate, install, and (for an executable work) run the object code and to modify the work, including scripts to control those activities. However, it does not include the work's System Libraries, or general-purpose tools or generally available free programs which are used unmodified in performing those activities but which are not part of the work. For example, Corresponding Source includes interface definition files associated with source files for the work, and the source code for shared libraries and dynamically linked subprograms that the work is specifically designed to require, such as by intimate data communication or control flow between those subprograms and other parts of the work. The Corresponding Source need not include anything that users can regenerate automatically from other parts of the Corresponding Source. The Corresponding Source for a work in source code form is that same work. 2. Basic Permissions. All rights granted under this License are granted for the term of copyright on the Program, and are irrevocable provided the stated conditions are met. This License explicitly affirms your unlimited permission to run the unmodified Program. The output from running a covered work is covered by this License only if the output, given its content, constitutes a covered work. This License acknowledges your rights of fair use or other equivalent, as provided by copyright law. You may make, run and propagate covered works that you do not convey, without conditions so long as your license otherwise remains in force. You may convey covered works to others for the sole purpose of having them make modifications exclusively for you, or provide you with facilities for running those works, provided that you comply with the terms of this License in conveying all material for which you do not control copyright. Those thus making or running the covered works for you must do so exclusively on your behalf, under your direction and control, on terms that prohibit them from making any copies of your copyrighted material outside their relationship with you. Conveying under any other circumstances is permitted solely under the conditions stated below. Sublicensing is not allowed; section 10 makes it unnecessary. 3. Protecting Users' Legal Rights From Anti-Circumvention Law. No covered work shall be deemed part of an effective technological measure under any applicable law fulfilling obligations under article 11 of the WIPO copyright treaty adopted on 20 December 1996, or similar laws prohibiting or restricting circumvention of such measures. When you convey a covered work, you waive any legal power to forbid circumvention of technological measures to the extent such circumvention is effected by exercising rights under this License with respect to the covered work, and you disclaim any intention to limit operation or modification of the work as a means of enforcing, against the work's users, your or third parties' legal rights to forbid circumvention of technological measures. 4. Conveying Verbatim Copies. You may convey verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice; keep intact all notices stating that this License and any non-permissive terms added in accord with section 7 apply to the code; keep intact all notices of the absence of any warranty; and give all recipients a copy of this License along with the Program. You may charge any price or no price for each copy that you convey, and you may offer support or warranty protection for a fee. 5. Conveying Modified Source Versions. You may convey a work based on the Program, or the modifications to produce it from the Program, in the form of source code under the terms of section 4, provided that you also meet all of these conditions: a) The work must carry prominent notices stating that you modified it, and giving a relevant date. b) The work must carry prominent notices stating that it is released under this License and any conditions added under section 7. This requirement modifies the requirement in section 4 to "keep intact all notices". c) You must license the entire work, as a whole, under this License to anyone who comes into possession of a copy. This License will therefore apply, along with any applicable section 7 additional terms, to the whole of the work, and all its parts, regardless of how they are packaged. This License gives no permission to license the work in any other way, but it does not invalidate such permission if you have separately received it. d) If the work has interactive user interfaces, each must display Appropriate Legal Notices; however, if the Program has interactive interfaces that do not display Appropriate Legal Notices, your work need not make them do so. A compilation of a covered work with other separate and independent works, which are not by their nature extensions of the covered work, and which are not combined with it such as to form a larger program, in or on a volume of a storage or distribution medium, is called an "aggregate" if the compilation and its resulting copyright are not used to limit the access or legal rights of the compilation's users beyond what the individual works permit. Inclusion of a covered work in an aggregate does not cause this License to apply to the other parts of the aggregate. 6. Conveying Non-Source Forms. You may convey a covered work in object code form under the terms of sections 4 and 5, provided that you also convey the machine-readable Corresponding Source under the terms of this License, in one of these ways: a) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by the Corresponding Source fixed on a durable physical medium customarily used for software interchange. b) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by a written offer, valid for at least three years and valid for as long as you offer spare parts or customer support for that product model, to give anyone who possesses the object code either (1) a copy of the Corresponding Source for all the software in the product that is covered by this License, on a durable physical medium customarily used for software interchange, for a price no more than your reasonable cost of physically performing this conveying of source, or (2) access to copy the Corresponding Source from a network server at no charge. c) Convey individual copies of the object code with a copy of the written offer to provide the Corresponding Source. This alternative is allowed only occasionally and noncommercially, and only if you received the object code with such an offer, in accord with subsection 6b. d) Convey the object code by offering access from a designated place (gratis or for a charge), and offer equivalent access to the Corresponding Source in the same way through the same place at no further charge. You need not require recipients to copy the Corresponding Source along with the object code. If the place to copy the object code is a network server, the Corresponding Source may be on a different server (operated by you or a third party) that supports equivalent copying facilities, provided you maintain clear directions next to the object code saying where to find the Corresponding Source. Regardless of what server hosts the Corresponding Source, you remain obligated to ensure that it is available for as long as needed to satisfy these requirements. e) Convey the object code using peer-to-peer transmission, provided you inform other peers where the object code and Corresponding Source of the work are being offered to the general public at no charge under subsection 6d. A separable portion of the object code, whose source code is excluded from the Corresponding Source as a System Library, need not be included in conveying the object code work. A "User Product" is either (1) a "consumer product", which means any tangible personal property which is normally used for personal, family, or household purposes, or (2) anything designed or sold for incorporation into a dwelling. In determining whether a product is a consumer product, doubtful cases shall be resolved in favor of coverage. For a particular product received by a particular user, "normally used" refers to a typical or common use of that class of product, regardless of the status of the particular user or of the way in which the particular user actually uses, or expects or is expected to use, the product. A product is a consumer product regardless of whether the product has substantial commercial, industrial or non-consumer uses, unless such uses represent the only significant mode of use of the product. "Installation Information" for a User Product means any methods, procedures, authorization keys, or other information required to install and execute modified versions of a covered work in that User Product from a modified version of its Corresponding Source. The information must suffice to ensure that the continued functioning of the modified object code is in no case prevented or interfered with solely because modification has been made. If you convey an object code work under this section in, or with, or specifically for use in, a User Product, and the conveying occurs as part of a transaction in which the right of possession and use of the User Product is transferred to the recipient in perpetuity or for a fixed term (regardless of how the transaction is characterized), the Corresponding Source conveyed under this section must be accompanied by the Installation Information. But this requirement does not apply if neither you nor any third party retains the ability to install modified object code on the User Product (for example, the work has been installed in ROM). The requirement to provide Installation Information does not include a requirement to continue to provide support service, warranty, or updates for a work that has been modified or installed by the recipient, or for the User Product in which it has been modified or installed. Access to a network may be denied when the modification itself materially and adversely affects the operation of the network or violates the rules and protocols for communication across the network. Corresponding Source conveyed, and Installation Information provided, in accord with this section must be in a format that is publicly documented (and with an implementation available to the public in source code form), and must require no special password or key for unpacking, reading or copying. 7. Additional Terms. "Additional permissions" are terms that supplement the terms of this License by making exceptions from one or more of its conditions. Additional permissions that are applicable to the entire Program shall be treated as though they were included in this License, to the extent that they are valid under applicable law. If additional permissions apply only to part of the Program, that part may be used separately under those permissions, but the entire Program remains governed by this License without regard to the additional permissions. When you convey a copy of a covered work, you may at your option remove any additional permissions from that copy, or from any part of it. (Additional permissions may be written to require their own removal in certain cases when you modify the work.) You may place additional permissions on material, added by you to a covered work, for which you have or can give appropriate copyright permission. Notwithstanding any other provision of this License, for material you add to a covered work, you may (if authorized by the copyright holders of that material) supplement the terms of this License with terms: a) Disclaiming warranty or limiting liability differently from the terms of sections 15 and 16 of this License; or b) Requiring preservation of specified reasonable legal notices or author attributions in that material or in the Appropriate Legal Notices displayed by works containing it; or c) Prohibiting misrepresentation of the origin of that material, or requiring that modified versions of such material be marked in reasonable ways as different from the original version; or d) Limiting the use for publicity purposes of names of licensors or authors of the material; or e) Declining to grant rights under trademark law for use of some trade names, trademarks, or service marks; or f) Requiring indemnification of licensors and authors of that material by anyone who conveys the material (or modified versions of it) with contractual assumptions of liability to the recipient, for any liability that these contractual assumptions directly impose on those licensors and authors. All other non-permissive additional terms are considered "further restrictions" within the meaning of section 10. If the Program as you received it, or any part of it, contains a notice stating that it is governed by this License along with a term that is a further restriction, you may remove that term. If a license document contains a further restriction but permits relicensing or conveying under this License, you may add to a covered work material governed by the terms of that license document, provided that the further restriction does not survive such relicensing or conveying. If you add terms to a covered work in accord with this section, you must place, in the relevant source files, a statement of the additional terms that apply to those files, or a notice indicating where to find the applicable terms. Additional terms, permissive or non-permissive, may be stated in the form of a separately written license, or stated as exceptions; the above requirements apply either way. 8. Termination. You may not propagate or modify a covered work except as expressly provided under this License. Any attempt otherwise to propagate or modify it is void, and will automatically terminate your rights under this License (including any patent licenses granted under the third paragraph of section 11). However, if you cease all violation of this License, then your license from a particular copyright holder is reinstated (a) provisionally, unless and until the copyright holder explicitly and finally terminates your license, and (b) permanently, if the copyright holder fails to notify you of the violation by some reasonable means prior to 60 days after the cessation. Moreover, your license from a particular copyright holder is reinstated permanently if the copyright holder notifies you of the violation by some reasonable means, this is the first time you have received notice of violation of this License (for any work) from that copyright holder, and you cure the violation prior to 30 days after your receipt of the notice. Termination of your rights under this section does not terminate the licenses of parties who have received copies or rights from you under this License. If your rights have been terminated and not permanently reinstated, you do not qualify to receive new licenses for the same material under section 10. 9. Acceptance Not Required for Having Copies. You are not required to accept this License in order to receive or run a copy of the Program. Ancillary propagation of a covered work occurring solely as a consequence of using peer-to-peer transmission to receive a copy likewise does not require acceptance. However, nothing other than this License grants you permission to propagate or modify any covered work. These actions infringe copyright if you do not accept this License. Therefore, by modifying or propagating a covered work, you indicate your acceptance of this License to do so. 10. Automatic Licensing of Downstream Recipients. Each time you convey a covered work, the recipient automatically receives a license from the original licensors, to run, modify and propagate that work, subject to this License. You are not responsible for enforcing compliance by third parties with this License. An "entity transaction" is a transaction transferring control of an organization, or substantially all assets of one, or subdividing an organization, or merging organizations. If propagation of a covered work results from an entity transaction, each party to that transaction who receives a copy of the work also receives whatever licenses to the work the party's predecessor in interest had or could give under the previous paragraph, plus a right to possession of the Corresponding Source of the work from the predecessor in interest, if the predecessor has it or can get it with reasonable efforts. You may not impose any further restrictions on the exercise of the rights granted or affirmed under this License. For example, you may not impose a license fee, royalty, or other charge for exercise of rights granted under this License, and you may not initiate litigation (including a cross-claim or counterclaim in a lawsuit) alleging that any patent claim is infringed by making, using, selling, offering for sale, or importing the Program or any portion of it. 11. Patents. A "contributor" is a copyright holder who authorizes use under this License of the Program or a work on which the Program is based. The work thus licensed is called the contributor's "contributor version". A contributor's "essential patent claims" are all patent claims owned or controlled by the contributor, whether already acquired or hereafter acquired, that would be infringed by some manner, permitted by this License, of making, using, or selling its contributor version, but do not include claims that would be infringed only as a consequence of further modification of the contributor version. For purposes of this definition, "control" includes the right to grant patent sublicenses in a manner consistent with the requirements of this License. Each contributor grants you a non-exclusive, worldwide, royalty-free patent license under the contributor's essential patent claims, to make, use, sell, offer for sale, import and otherwise run, modify and propagate the contents of its contributor version. In the following three paragraphs, a "patent license" is any express agreement or commitment, however denominated, not to enforce a patent (such as an express permission to practice a patent or covenant not to sue for patent infringement). To "grant" such a patent license to a party means to make such an agreement or commitment not to enforce a patent against the party. If you convey a covered work, knowingly relying on a patent license, and the Corresponding Source of the work is not available for anyone to copy, free of charge and under the terms of this License, through a publicly available network server or other readily accessible means, then you must either (1) cause the Corresponding Source to be so available, or (2) arrange to deprive yourself of the benefit of the patent license for this particular work, or (3) arrange, in a manner consistent with the requirements of this License, to extend the patent license to downstream recipients. "Knowingly relying" means you have actual knowledge that, but for the patent license, your conveying the covered work in a country, or your recipient's use of the covered work in a country, would infringe one or more identifiable patents in that country that you have reason to believe are valid. If, pursuant to or in connection with a single transaction or arrangement, you convey, or propagate by procuring conveyance of, a covered work, and grant a patent license to some of the parties receiving the covered work authorizing them to use, propagate, modify or convey a specific copy of the covered work, then the patent license you grant is automatically extended to all recipients of the covered work and works based on it. A patent license is "discriminatory" if it does not include within the scope of its coverage, prohibits the exercise of, or is conditioned on the non-exercise of one or more of the rights that are specifically granted under this License. You may not convey a covered work if you are a party to an arrangement with a third party that is in the business of distributing software, under which you make payment to the third party based on the extent of your activity of conveying the work, and under which the third party grants, to any of the parties who would receive the covered work from you, a discriminatory patent license (a) in connection with copies of the covered work conveyed by you (or copies made from those copies), or (b) primarily for and in connection with specific products or compilations that contain the covered work, unless you entered into that arrangement, or that patent license was granted, prior to 28 March 2007. Nothing in this License shall be construed as excluding or limiting any implied license or other defenses to infringement that may otherwise be available to you under applicable patent law. 12. No Surrender of Others' Freedom. If conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot convey a covered work so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not convey it at all. For example, if you agree to terms that obligate you to collect a royalty for further conveying from those to whom you convey the Program, the only way you could satisfy both those terms and this License would be to refrain entirely from conveying the Program. 13. Use with the GNU Affero General Public License. Notwithstanding any other provision of this License, you have permission to link or combine any covered work with a work licensed under version 3 of the GNU Affero General Public License into a single combined work, and to convey the resulting work. The terms of this License will continue to apply to the part which is the covered work, but the special requirements of the GNU Affero General Public License, section 13, concerning interaction through a network will apply to the combination as such. 14. Revised Versions of this License. The Free Software Foundation may publish revised and/or new versions of the GNU General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. Each version is given a distinguishing version number. If the Program specifies that a certain numbered version of the GNU General Public License "or any later version" applies to it, you have the option of following the terms and conditions either of that numbered version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of the GNU General Public License, you may choose any version ever published by the Free Software Foundation. If the Program specifies that a proxy can decide which future versions of the GNU General Public License can be used, that proxy's public statement of acceptance of a version permanently authorizes you to choose that version for the Program. Later license versions may give you additional or different permissions. However, no additional obligations are imposed on any author or copyright holder as a result of your choosing to follow a later version. 15. Disclaimer of Warranty. THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 16. Limitation of Liability. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. 17. Interpretation of Sections 15 and 16. If the disclaimer of warranty and limitation of liability provided above cannot be given local legal effect according to their terms, reviewing courts shall apply local law that most closely approximates an absolute waiver of all civil liability in connection with the Program, unless a warranty or assumption of liability accompanies a copy of the Program in return for a fee. END OF TERMS AND CONDITIONS How to Apply These Terms to Your New Programs If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms. To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively state the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found. Copyright (C) This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Also add information on how to contact you by electronic and paper mail. If the program does terminal interaction, make it output a short notice like this when it starts in an interactive mode: Copyright (C) This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. This is free software, and you are welcome to redistribute it under certain conditions; type `show c' for details. The hypothetical commands `show w' and `show c' should show the appropriate parts of the General Public License. Of course, your program's commands might be different; for a GUI interface, you would use an "about box". You should also get your employer (if you work as a programmer) or school, if any, to sign a "copyright disclaimer" for the program, if necessary. For more information on this, and how to apply and follow the GNU GPL, see . The GNU General Public License does not permit incorporating your program into proprietary programs. If your program is a subroutine library, you may consider it more useful to permit linking proprietary applications with the library. If this is what you want to do, use the GNU Lesser General Public License instead of this License. But first, please read . eiskaltdcpp-web-1.0.1/README.html000066400000000000000000000052031361213051300164050ustar00rootroot00000000000000

EiskaltDC++ Web UI

Official Web User Interface for eiskaltdcpp-daemon. It is designed for using on embedded devices (for example in NAS) in your home network.

Features:

  • Searching of files and directories
  • List of current/queued downloads
  • Status of connected hubs and basic statistics

License

GNU GPLv3 or later

Some files are distributed under other licenses, see copyrights file for details.

Screenshots

Installation and usage

See INSTALL file is you are GNU/Linux or *BSD user.

For MS Windows users it is enough to read help file for understanding how to use Web UI. All necessary files are already included in installer and in archive with portable build.

Contribution

  • Patches are welcome!
  • If you need to add extra library, then:
    • check the license of that library very carefully
    • check if that library is actively maintained (for fixing possible bugs in it)
    • copy only source version of javascript file into this repo (if you prefer using of minified versions of javascript files, you may generate them automatically during Web UI installation)

Versions history

  • 1.0.1 (2020-01-22):
    • Fix desktop file for Linux.
    • Add manual page for eiskaltdcpp-web script in Linux.
    • Updated embedded copies of javascript libraries: jquery-3.4.1, tablesorter-2.31.2, requirejs-2.3.6.
  • 1.0 (2019-06-01):
    • First stable release.
    • Compatible with eiskaltdcpp-daemon 2.4.0.
eiskaltdcpp-web-1.0.1/README.md000066400000000000000000000045011361213051300160410ustar00rootroot00000000000000# EiskaltDC++ Web UI Official Web User Interface for [eiskaltdcpp-daemon](https://github.com/eiskaltdcpp/eiskaltdcpp). It is designed for using on embedded devices (for example in NAS) in your home network. Features: * Searching of files and directories * List of current/queued downloads * Status of connected hubs and basic statistics ## License [GNU GPLv3 or later](https://github.com/eiskaltdcpp/eiskaltdcpp-web/blob/master/LICENSE) Some files are distributed under other licenses, see [copyrights](https://github.com/eiskaltdcpp/eiskaltdcpp-web/blob/master/full.copyrights.info.in.Debian.style) file for details. ## Screenshots ## Installation and usage See [INSTALL](https://github.com/eiskaltdcpp/eiskaltdcpp-web/blob/master/INSTALL) file is you are GNU/Linux or *BSD user. For MS Windows users it is enough to read [help](https://github.com/eiskaltdcpp/eiskaltdcpp-web/blob/master/windows/help.md) file for understanding how to use Web UI. All necessary files are already included in installer and in archive with portable build. ## Contribution * Patches are welcome! * If you need to add extra library, then: * check the license of that library very carefully * check if that library is actively maintained (for fixing possible bugs in it) * copy only **source version** of javascript file into this repo (if you prefer using of minified versions of javascript files, you may generate them automatically during Web UI installation) ## Versions history * 1.0.1 (2020-01-22): * Fix desktop file for Linux. * Add manual page for eiskaltdcpp-web script in Linux. * Updated embedded copies of javascript libraries: jquery-3.4.1, tablesorter-2.31.2, requirejs-2.3.6. * 1.0 (2019-06-01): * First stable release. * Compatible with eiskaltdcpp-daemon 2.4.0. eiskaltdcpp-web-1.0.1/config.js000066400000000000000000000003161361213051300163650ustar00rootroot00000000000000/*global define */ define([], function () { 'use strict'; return { "jsonrpc" : { "host" : "127.0.0.1", "port" : "3121" }, "debugLevel" : 3 }; }); eiskaltdcpp-web-1.0.1/favicon.ico000066400000000000000000000021761361213051300167110ustar00rootroot00000000000000h(  QOaEcdk ffcNFQcq u HDpѵѴ٨rXUJ0c|Ǚ#%υ4ؽɦxn dWJ 2*ֺ80͕t_-&2,}q dVGӬo#H8I@zr߻ֱ'!~p aa" |Cs҅0UJ_T^Rwnј`X5-%zjeSy\˰ݞ\[rfqdi]^SPFA70(r g `eӼrtwuzlk_[PJ@80&xi b\y캋ɞ闊⢘mbPF=5*#|lU 綈ĝϬ翹SI@7,%vl$ ]QʫﯥwjtiRG>6+$vE +xw鑄繳^SLB:2_*sU#y嵈Ʀ⟔{n֡D;ʁCz'u0 o0 bU⯍tj嵇TJH>=2z!%  PENAC:80+??eiskaltdcpp-web-1.0.1/full.copyrights.info.in.Debian.style000066400000000000000000000137371361213051300235330ustar00rootroot00000000000000Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: EiskaltDC++ Web UI Upstream-Contact: Dorian Scholz Boris Pek Source: https://github.com/eiskaltdcpp/eiskaltdcpp-web Files: * Copyright: 2013 Dorian Scholz (https://github.com/DorianScholz) 2013-2019 Boris Pek License: GPL-3+ Files: images/* Copyright: 2010 Oxygen icons theme team (see http://www.oxygen-icons.org/) License: LGPL-3 Files: get-js-dependecies.sh Copyright: not-applicable Comment: Author: 2013-2017 Boris Pek License: public-domain Files: js/lib/require.js Copyright: 2010-2017 jQuery Foundation and other contributors License: Expat Files: js/lib/jquery.timer.js js/lib/jquery.plugin.js Copyright: 2011 Cyntax Technologies (http://cyntaxtech.com) Comment: https://web.archive.org/web/http://code.cyntaxtech.com:80/licenses/cyntax-open-technology License: Cyntax-Open-Technology-License Files: js/lib/jquery.tablesorter.js Copyright: 2007 Christian Bach License: Expat or GPL-3+ Files: js/lib/jquery.jsonrpc.js Copyright: not-applicable Comment: https://github.com/datagraph/jquery-jsonrpc/blob/master/UNLICENSE License: public-domain Files: js/lib/jquery.js Copyright: 2006-2016 jQuery Foundation and other contributors Comment: http://jquery.org/license License: Expat Files: js/lib/jquery.hashchange.js Copyright: 2010 "Cowboy" Ben Alman Comment: http://benalman.com/about/license/ License: Expat or GPL-2 Files: js/lib/jquery.easytabs.js Copyright: 2010-2011 Steve Schwartz (JangoSteve) License: Expat or GPL-3+ License: public-domain No license required for any purpose; the work is not subject to copyright in any jurisdiction. License: Expat Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: . The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. . THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. License: Cyntax-Open-Technology-License Permission is hereby granted, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish and distribute free of charge, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: . The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. . THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. License: GPL-2 This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License. . This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. . You should have received a copy of the GNU General Public License along with this program. If not, see . . On Debian systems, the complete text of the GNU General Public License can be found in `/usr/share/common-licenses/GPL-2'. License: GPL-3+ This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. . This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. . You should have received a copy of the GNU General Public License along with this program. If not, see . . On Debian systems, the complete text of the GNU General Public License can be found in `/usr/share/common-licenses/GPL-3'. License: LGPL-3 This program is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License. . This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. . You should have received a copy of the GNU General Public License along with this program. If not, see . . On Debian systems, the complete text of the GNU Lesser General Public License can be found in `/usr/share/common-licenses/LGPL-3'. eiskaltdcpp-web-1.0.1/get-js-dependecies.sh000077500000000000000000000023631361213051300205640ustar00rootroot00000000000000#!/bin/sh # Author: Boris Pek # License: Public Domain # Created: 2013-10-19 # Updated: 2020-01-22 # Version: N/A # Dependencies: wget set -e [ -z "${MAIN_DIR}" ] && export MAIN_DIR="$(realpath -s $(dirname ${0}))" cd "${MAIN_DIR}" rm -rf js/lib mkdir -p js/lib cd js/lib wget -nv -c https://code.jquery.com/jquery-3.4.1.js -O jquery.js wget -nv -c https://raw.github.com/JangoSteve/jQuery-EasyTabs/v3.2.0/lib/jquery.easytabs.js -O jquery.easytabs.js wget -nv -c https://raw.github.com/pandell/jquery-hashchange/v1.3c/jquery.ba-hashchange.js -O jquery.hashchange.js wget -nv -c https://raw.github.com/datagraph/jquery-jsonrpc/0.1.1/jquery.jsonrpc.js -O jquery.jsonrpc.js wget -nv -c https://raw.github.com/Cyntax/jquery-timer/0.1.1/jquery.plugin.js -O jquery.plugin.js wget -nv -c https://raw.github.com/Cyntax/jquery-timer/0.1.1/jquery.timer.js -O jquery.timer.js wget -nv -c https://raw.github.com/Mottie/tablesorter/v2.31.2/dist/js/jquery.tablesorter.js -O jquery.tablesorter.js wget -nv -c http://requirejs.org/docs/release/2.3.6/comments/require.js -O require.js eiskaltdcpp-web-1.0.1/http_server000077500000000000000000000002741361213051300170600ustar00rootroot00000000000000#!/bin/sh echo This server is just for testing, it is not secure! echo Only argument is the server port, it defaults to 8000. echo Stop server with ctrl-c... python -m SimpleHTTPServer $1 eiskaltdcpp-web-1.0.1/images/000077500000000000000000000000001361213051300160275ustar00rootroot00000000000000eiskaltdcpp-web-1.0.1/images/ball_green.png000066400000000000000000000056431361213051300206370ustar00rootroot00000000000000PNG  IHDR$x vpAgXbKGD X CIDATxEyTua DprIr$5в\bS斔[%^L4R-dDaEggg{<9/sfv;{H8S¦:v / ^1ЄBXyٟ'4g/g"`t- lc6C %/%OAHa8 +$!R.8Yk'uOޭo`NnsԾ73L8=nˏF~ɼML˔?\:=wq3`WԋA "P@k䅞O=y_ ^iy~GX#Gs2긑z>O~Tвkb;xY~RηC^_&IIvѼsf1]W+O=[AȹKwC%.z,#zs y gIM b=f26!C?f늜;`xȱG+ m'asojwP/E ĸ9iLTEs[G!/KBx{T>ϊO Y>R7$u[ykz56}@?,@hZՊgk99/J9YifP]k4z:z^x豍<_QF^`uJ?ԋWuKj q1%%hbr:4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HUbfXO?04bmu|;!:`;mljg'ς> 9إ &EbҼqHm  4Hۨ 0 " B"\Oo/U,oQyҳW!47 9DUhL7 ,#J=r.ח38uh m= J{*Uͼ^6KKM 4{NpkSꬑy!+ufĉ\)99>!r7?>ܹ];o @.G{IENDB`eiskaltdcpp-web-1.0.1/images/web_search.png000066400000000000000000000132321361213051300206400ustar00rootroot00000000000000PNG  IHDR00WsRGBbKGD pHYspMBtIME +IDAThݚip\umݯF7$ E,E-bK-ɢcy4IĥhfD.Wjj2 `#C癞^bKw3gr*CXEj+ K-m5Trɦ/eS2V7T ~U<(?~=zw8w5r)[JPUh@ qioOһ x@{kU;@}2L08F14\EU 5#AI** D$ ;񞂸&}C__cPX.T:?Lفse,GE`RAm-1,Gy.?yGOqI-S$rBi"A:+:- nm;W]!}Atlozk".>n (قցRSezp=Ip [+hI@* * P04\)6n hj ݕD!|p1cq|'/Osdh+vtQ,('AEUee.׈}N)h,AUTO.U]Ch*Yی'%j&0坰Kh 4vX0`P'O\rPUx> Ј 4Me!]`c">h lQ4CCh *RUP4P4Y oF] ݯţuP8.dr<v$"(BA7T>b5t]%.*BSD}|6vգ*BW RQ'TbQ!4Kz @u2!І:t۞M;8+x"8~zRl|$=PU~eBQqFLhBSAUQ5 xhQ(W HOx29AT^92ö L,i $~ ϥ9;d*) 6BU ESQ Ptp!.QBp|"纸UеED#PscS$kB؎pR )Wl~<@T&RYAژI$ ~|70M + +*b M_@r)8;WjYha9<`Z.WU k(&f>vPǕk94:GC"ZdrH Q#fd*b#фDjBħ3^D@EX M? !Z`rjqF+$BvlLrמnS>|:NMg5UU  EGk38Wtjh?E;vO|d`⦎Lq,w0sZ ͝ }+$ >U,W721<=Ǐ377.He l pOkXG?oLoO'nj')uW23g.C( ()Ӆϯ3<p rߠMhnj8 2pï*OG7tk~x,ן_ad!Hӄ1?EkXBrÿ;8*9>1tMq&bK.gذ0mh *~ E5o(/"Μ["2hJp]"xp6_8~,J"T נ*ɉ?CW fg#}><-m /~UhJqTRSs.[mu;ZX446# Ǹ[y'r~Y_mݦٺ6ijRK+DaOp̀ɏ~bnIͦ(J% sK4p)LO:,-e{hii '5/N|3C[ #p~(o24MǓ^| ߇a膁Urd9bB]7h`C_/۷n"bra$ ǑRb6Hin&*bX⮻r7_mGs-Hl CG@cSo:8 "ҕDu4MCz2f$ҭ 8. 4MCqYS)U8u4s(BcShtK*GlY$۹tI16~_ޏ3B]2iș;>!k:B EJ2i瑾T(f5DCaBqnbd2073LGzi`Sr_KEfu;{3R<0@4Qmd2,,..i+:`:^L3<4U7}s)!533 /RII\" ӹz5B4M194|ku{]*P,~}%?۾o)qo{-r=\zvA}}#a d)DX\.HXN/`Ajf 0 HCU\ömҙ PD2ڵkM ٵs9u~igW?q\'CǶjbq ;U(W@y4Q\4U0 q k%uyE\*g[}vq=\c'[lattOΎٙ;\v.N~O|~5\e ' q-8r'~4O<^C}}-gihg 0=}E(T-jͰ,#044L>cƍdtl\ȵW]NKlI%4_o߫<w7퓟vc~[ rairUg#ѱ |ܱ^@iliGJIOO{oP(aP+;9?sv ]p-(Lә &#.ߵ*d )>+VͣVrrY$STHłrh`~?}fUB~VA{C隚@l$JH$;I%e|d9ʎGwhhlѱ_ &)RKw{X-]f9ЙI ErJ Iϑe z t&_Tjև`R,4u6q 9J '3erI$ɯ1k]mx2[f'u㺔A-ʜ U;n"_C++n;S R)WzY9+v)u4TT>rhx߿+fLmٱ㼈Fg(7^7122Ն'N,,,.Vm8}W3 6l512%O!l畹cG8r=~{Vb=B-Y[W?7;[~7<B>q^#+m6766gF^I͞ߛ?ϭ}2%g>IENDB`eiskaltdcpp-web-1.0.1/index.html000066400000000000000000000074061361213051300165660ustar00rootroot00000000000000 EiskaltDC++ Web Frontend

EiskaltDC++ Web Frontend

Not connected yet...

Download Queue

Remove Filename Size Progress Status

Statistics

Statistics are not yet known...

Connected Hubs

Connected Address Hub name Users Total share

Debug Output


            
eiskaltdcpp-web-1.0.1/js/000077500000000000000000000000001361213051300151765ustar00rootroot00000000000000eiskaltdcpp-web-1.0.1/js/app/000077500000000000000000000000001361213051300157565ustar00rootroot00000000000000eiskaltdcpp-web-1.0.1/js/app/eiskaltdcpp.debug.js000066400000000000000000000020201361213051300216760ustar00rootroot00000000000000/* Copyright (c) 2013 Dorian Scholz */ /* License: GPLv3 or later */ /*jslint browser: true */ /*global define */ define( ['jquery', 'app/eiskaltdcpp', 'config.js'], function ($, eiskaltdcpp, config) { 'use strict'; var my = { levels: { FATAL : 1, ERROR : 2, WARN : 3, INFO : 4, DEBUG : 5 }, print: function (debugLevel, text) { if (debugLevel <= config.debugLevel) { $('#debugdiv').show(); $('#debugout').prepend((new Date()).toLocaleTimeString() + ': ' + text + '\n'); } }, onError: function (data) { my.print(my.levels.ERROR, 'Error: ' + data.error.message); }, onSuccess: function (data) { my.print(my.levels.INFO, 'Success: ' + (data.result === 0)); } }; eiskaltdcpp.debug = my; return my; } ); eiskaltdcpp-web-1.0.1/js/app/eiskaltdcpp.js000066400000000000000000000042121361213051300206160ustar00rootroot00000000000000/* Copyright (c) 2013 Dorian Scholz */ /* License: GPLv3 or later */ /*jslint browser: true */ /*global define */ define( ['jquery', 'config.js', 'jquery.tablesorter', 'jquery.easytabs', 'jquery.jsonrpc'], function ($, config) { 'use strict'; var my = { getURLParameter: function (name) { return decodeURIComponent( (new RegExp('[?|&]' + name + '=' + '([^&;]+?)(&|#|;|$)').exec(location.search) || ['', ''])[1].replace(/\+/g, '%20') ) || null; }, onLoad: function () { $('#tab-container').easytabs(); // determine jsonrpc host in this order: config -> http host -> localhost if (!config.jsonrpc.host) { config.jsonrpc.host = location.hostname; if (!config.jsonrpc.host) { config.jsonrpc.host = 'localhost'; } } $.jsonRPC.setup({ endPoint : 'http://' + config.jsonrpc.host + ':' + config.jsonrpc.port, namespace : '' }); $.tablesorter.addParser({ id: 'filesize', is: function (s) { return s.match(new RegExp(/[0-9]+(\.[0-9]+)?\s*(K|M|G|T|P|E|Z|Y)?i?B/i)); }, format: function (s) { var parts, suffix, num, exponent = 0; parts = s.match(new RegExp(/([0-9]+(\.[0-9]+)?)\s*((K|M|G|T|P|E|Z|Y)?i?B)?/i)); if (parts === null) { return 0; } suffix = parts[3]; if (suffix !== undefined) { exponent = Math.max(0, 'bkmgtpey'.indexOf(suffix[0].toLowerCase())); } num = parseFloat(parts[1]); return num * Math.pow(1024, exponent, 0); }, type: 'numeric' }); } }; return my; } ); eiskaltdcpp-web-1.0.1/js/app/eiskaltdcpp.queue.js000066400000000000000000000102211361213051300217360ustar00rootroot00000000000000/* Copyright (c) 2013 Dorian Scholz */ /* License: GPLv3 or later */ /*jslint browser: true */ /*global define */ define( ['jquery', 'app/eiskaltdcpp', 'app/eiskaltdcpp.debug', 'app/eiskaltdcpp.status', 'app/eiskaltdcpp.search', 'jquery.tablesorter', 'jquery.timer'], function ($, eiskaltdcpp) { 'use strict'; var my = { downloadQueue: {}, downloadQueueTTH: {}, onRemoveClicked: function () { $.jsonRPC.request('queue.remove', { params : {'target': $(this).attr('target')}, error : eiskaltdcpp.debug.onError }); my.downloadQueue[$(this).attr('target')].row.remove(); }, addDownloadQueue: function (entry) { var table, row, headers, key, removeLink, removeImage; table = $('table#downloadqueue'); headers = table.find('th'); if (!my.downloadQueue.hasOwnProperty(entry.Target)) { row = $(''); headers.each(function (i, header) { row.append($('')); }); removeImage = $(''); removeLink = $('').append(removeImage); removeLink.on('click', my.onRemoveClicked); $(row.children()[0]).append(removeLink); table.find('tbody').append(row); my.downloadQueue[entry.Target] = {'row': row, 'data': entry}; my.downloadQueueTTH[entry.TTH] = my.downloadQueue[entry.Target]; } else { row = my.downloadQueue[entry.Target].row; } headers.each(function (i, header) { key = $(header).attr('key'); if (key !== undefined) { $(row.find('td')[i]).text(entry[key]); } }); }, updateDownloadQueue: function (data) { var tth; eiskaltdcpp.status.showConnectionStatus(false); if (data.result !== null) { $.each(data.result, function (target, entry) { my.addDownloadQueue(entry); }); } $.each(my.downloadQueue, function (target, entryInfo) { tth = entryInfo.data.TTH; if (data.result === null || !data.result.hasOwnProperty(target)) { entryInfo.row.remove(); delete my.downloadQueue[target]; delete my.downloadQueueTTH[tth]; } eiskaltdcpp.search.updateSearchResultIcon(tth); }); $('table#downloadqueue').trigger('update'); }, onDownloadQueueError: function (data) { eiskaltdcpp.status.showConnectionStatus(true); $.each(my.downloadQueue, function (target, entry) { entry.row.remove(); }); my.downloadQueue = {}; }, requestDownloadQueue: function () { $.jsonRPC.request('queue.list', { success : my.updateDownloadQueue, error : my.onDownloadQueueError }); }, onLoad: function () { // init table sorting and set initial sorting column by key $('table#downloadqueue').tablesorter(); $('table#downloadqueue').find('th').each(function (i, header) { if ($(header).attr('key') === 'Filename') { $('table#downloadqueue').trigger('sorton', [[[i, 0]]]); return; } }); $('table#downloadqueue').timer({ callback: my.requestDownloadQueue, delay: 1000, repeat: true }); } }; eiskaltdcpp.queue = my; return my; } ); eiskaltdcpp-web-1.0.1/js/app/eiskaltdcpp.search.js000066400000000000000000000233401361213051300220650ustar00rootroot00000000000000/* Copyright (c) 2013 Dorian Scholz */ /* Copyright (c) 2017 Boris Pek */ /* License: GPLv3 or later */ /*jslint browser: true */ /*global define */ define( ['jquery', 'app/eiskaltdcpp', 'config.js', 'app/eiskaltdcpp.queue', 'app/eiskaltdcpp.debug', 'jquery.tablesorter', 'jquery.timer'], function ($, eiskaltdcpp, config) { 'use strict'; var my = { searchTypes: { 'Any': 0, 'Audio': 1, 'Compressed': 2, 'Document': 3, 'Executable': 4, 'Picture': 5, 'Video': 6, 'Directory': 7, 'TTH': 8, 'CD image': 9 }, searchResults: {}, groupedResults: {}, clearSearchResults: function () { $.jsonRPC.request('search.clear', { error : eiskaltdcpp.debug.onError }); $('table#searchresults tbody > tr').remove(); my.groupedResults = {}; my.searchResults = {}; }, updateSearchResultIcon: function (tth) { var downloadLink, removeLink; downloadLink = $('#download_' + tth); removeLink = $('#remove_' + tth); if (eiskaltdcpp.queue.downloadQueueTTH.hasOwnProperty(tth)) { downloadLink.hide(); removeLink.show(); removeLink.attr('target', eiskaltdcpp.queue.downloadQueueTTH[tth].data.Target); } else { downloadLink.show(); removeLink.hide(); } }, getUserLink: function (result) { var image, url, userlink; image = 'images/web_search.png'; url = 'https://duckduckgo.com/?q=%Filename%'; userlink = ''; var filter, re, matches; filter = function (text) { return text.replace(/\.\w{2,}$/, '').replace(/[-._+]/g, ' ').replace(/\(.*\)/g, ' ').replace(/\[.*\]/g, ' ').replace(/\d{3,}.*/, ''); } re = new RegExp(/%\w+%/gi); matches = userlink.match(re); if (matches !== null) { $.each(matches, function (index, match) { userlink = userlink.replace(match, filter(result[match.replace(/%/g, '')])); }); } return userlink; }, getMagnetLink: function (result) { var image, url, magnetlink; image = 'images/magnet.png'; url = 'magnet:?xt=urn:tree:tiger:' + result.TTH + '&xl=' + result['Real Size'] + '&dn=' + encodeURI(result.Filename); magnetlink = ''; return magnetlink; }, addSearchResult: function (result) { var table, row, tth, headers, downloadLink, downloadImage, removeLink, removeImage; table = $('table#searchresults'); tth = result.TTH; if (!my.groupedResults.hasOwnProperty(tth)) { row = $(''); downloadImage = $(''); downloadLink = $('').append(downloadImage); downloadLink.on('click', my.onDownloadClicked); removeImage = $(''); removeLink = $('').append(removeImage); removeLink.on('click', eiskaltdcpp.queue.onRemoveClicked); removeLink.hide(); result.UserLink = my.getUserLink(result); result.MagnetLink = my.getMagnetLink(result); result.DownloadLink = downloadLink.add(removeLink); headers = table.find('th'); headers.each(function (i, header) { var key = $(header).attr('key'); if (key !== undefined) { row.append($('').append(result[key])); } }); table.find('tbody').append(row); my.groupedResults[tth] = {'row': row, 'results': []}; my.updateSearchResultIcon(tth); } my.groupedResults[tth].results.push(result); my.groupedResults[tth].row.find('td[key=UserCount]').text(my.groupedResults[tth].results.length); }, updateSearchResults: function (data) { if (data.result === null) { eiskaltdcpp.debug.print(eiskaltdcpp.debug.levels.INFO, 'search results: ' + data.result); } else { data.result.forEach(function (result) { var resultId = result.CID + result.TTH; if (!my.searchResults.hasOwnProperty(resultId)) { my.searchResults[resultId] = result; my.addSearchResult(result); } }); $('table#searchresults').trigger('update'); } }, requestSearchResults: function () { $.jsonRPC.request('search.getresults', { success : my.updateSearchResults, error : eiskaltdcpp.debug.onError }); }, onSearchSendSuccess: function (data) { var searchIsValid = (data.result === 0); eiskaltdcpp.debug.print(eiskaltdcpp.debug.levels.DEBUG, 'searchIsValid: ' + searchIsValid); if (searchIsValid) { $('input#searchstring').timer('start'); } }, onSearchClicked: function () { $('input#searchstring').timer('stop'); my.clearSearchResults(); $.jsonRPC.request('search.send', { params : { 'searchstring': $('input#searchstring').val(), 'searchtype': Number($('#searchtype option:selected').val()) }, success : my.onSearchSendSuccess, error : eiskaltdcpp.debug.onError }); }, onDownloadClicked: function () { // add file to the download queue $.jsonRPC.request('queue.add', { params : { 'filename': $(this).attr('filename'), 'size': Number($(this).attr('size')), 'tth': $(this).attr('tth'), 'directory': '' }, error : eiskaltdcpp.debug.onError }); // start TTH search for the newly added file to get download sources $('input#searchstring').timer('stop'); $.jsonRPC.request('search.send', { params : { 'searchstring': $(this).attr('tth'), 'searchtype': Number(my.searchTypes.TTH) }, error : eiskaltdcpp.debug.onError }); }, onLoad: function () { var searchString, searchType; $.each(my.searchTypes, function (typename, typeval) { $('#searchtype').append( $('').val(typeval).html(typename) ); }); // init table sorting and set initial sorting column by key $('table#searchresults').tablesorter(); $('table#searchresults').find('th').each(function (i, header) { if ($(header).attr('key') === 'UserCount') { $('table#searchresults').trigger('sorton', [[[i, 1]]]); return; } }); $('input#search').on('click', my.onSearchClicked); $('input#searchstring').keypress(function (event) { if (event.which === 13) { event.preventDefault(); my.onSearchClicked(); return false; } }); $('input#searchstring').timer({ callback: my.requestSearchResults, delay: 500, repeat: 50, autostart: false }); searchType = eiskaltdcpp.getURLParameter('searchtype'); if (searchType !== null) { $.each(my.searchTypes, function (typename, typeval) { if (typename.toLowerCase() === String(searchType).toLowerCase()) { $('#searchtype option[value="' + typeval + '"]').attr('selected', true); return false; } }); } searchString = eiskaltdcpp.getURLParameter('searchstring'); if (searchString !== null) { $('#tab-container').easytabs('select', '#tab-search'); $('input#searchstring').val(searchString); my.onSearchClicked(); } } }; eiskaltdcpp.search = my; return my; } ); eiskaltdcpp-web-1.0.1/js/app/eiskaltdcpp.status.js000066400000000000000000000114421361213051300221430ustar00rootroot00000000000000/* Copyright (c) 2013 Dorian Scholz */ /* License: GPLv3 or later */ /*jslint browser: true */ /*global define */ define( ['jquery', 'app/eiskaltdcpp', 'config.js', 'jquery.tablesorter', 'jquery.timer', 'jquery.easytabs', 'jquery.jsonrpc'], function ($, eiskaltdcpp, config) { 'use strict'; var my = { connectedHubs: [], statisticalData: [], showConnectionStatus: function (error) { if (error) { $('#connectionerror').attr('class', 'error'); $('#connectionerror').text('Connection to EiskaltDC++ daemon failed on ' + 'http://' + config.jsonrpc.host + ':' + config.jsonrpc.port); } else { $('#connectionerror').attr('class', 'hidden'); $('#connectionerror').text(''); } }, addConnectedHub: function (hubAddress, entry) { var table, row, headers, image; table = $('table#connectedhubs'); headers = table.find('th'); if (!my.connectedHubs.hasOwnProperty(hubAddress)) { row = $(''); row.append($('')); row.append($('')); row.append($('')); row.append($('')); row.append($('')); table.find('tbody').append(row); my.connectedHubs[hubAddress] = {'row': row}; } else { row = my.connectedHubs[hubAddress].row; } if (entry.connected === '1') { image = 'images/ball_green.png'; } else { image = 'images/ball_red.png'; } $(row.find('td')[0]).html($('')); $(row.find('td')[1]).text(hubAddress); $(row.find('td')[2]).html($('
') .append(entry.hubname)); $(row.find('td')[3]).text(entry.users); $(row.find('td')[4]).text(entry['totalshare preformatted']); }, updateConnectedHubs: function (data) { if (data.result !== null) { $.each(data.result, function (hubAddress, entry) { my.addConnectedHub(hubAddress, entry); }); } $.each(my.connectedHubs, function (hubAddress, entry) { if (data.result === null || !data.result.hasOwnProperty(hubAddress)) { entry.row.remove(); } }); $('table#connectedhubs').trigger('update'); }, onConnectedHubsError: function (data) { $.each(my.connectedHubs, function (hubAddress, entry) { entry.row.remove(); }); my.connectedHubs = {}; }, requestConnectedHubs: function () { $.jsonRPC.request('hub.listfulldesc', { success : my.updateConnectedHubs, error : my.onConnectedHubsError }); }, updateStatisticalData: function (data) { var statisticalData = data.result; if (my.statisticalData !== statisticalData) { my.statisticalData = statisticalData; $('#statisticaldata').attr('class', ''); $('#statisticaldata').html('Downloaded: ' + statisticalData.down + '
Uploaded: ' + statisticalData.up + '
Ratio: ' + statisticalData.ratio); } }, onStatisticalDataError: function (data) { $('#statisticaldata').text('Error retrieving statistical data...'); }, requestStatisticalData: function () { $.jsonRPC.request('show.ratio', { success : my.updateStatisticalData, error: my.onStatisticalDataError }); }, onLoad: function () { $('table#connectedhubs').tablesorter({ sortList: [[3, 1]] }); $('#connectedhubs').timer({ callback: my.requestConnectedHubs, delay: 3000, repeat: true }); $('#statisticaldata').timer({ callback: my.requestStatisticalData, delay: 10000, repeat: true }); } }; eiskaltdcpp.status = my; return my; } ); eiskaltdcpp-web-1.0.1/js/lib/000077500000000000000000000000001361213051300157445ustar00rootroot00000000000000eiskaltdcpp-web-1.0.1/js/lib/jquery.easytabs.js000066400000000000000000000642561361213051300214500ustar00rootroot00000000000000/* * jQuery EasyTabs plugin 3.2.0 * * Copyright (c) 2010-2011 Steve Schwartz (JangoSteve) * * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-license.php * http://www.gnu.org/licenses/gpl.html * * Date: Thu May 09 17:30:00 2013 -0500 */ ( function($) { $.easytabs = function(container, options) { // Attach to plugin anything that should be available via // the $container.data('easytabs') object var plugin = this, $container = $(container), defaults = { animate: true, panelActiveClass: "active", tabActiveClass: "active", defaultTab: "li:first-child", animationSpeed: "normal", tabs: "> ul > li", updateHash: true, cycle: false, collapsible: false, collapsedClass: "collapsed", collapsedByDefault: true, uiTabs: false, transitionIn: 'fadeIn', transitionOut: 'fadeOut', transitionInEasing: 'swing', transitionOutEasing: 'swing', transitionCollapse: 'slideUp', transitionUncollapse: 'slideDown', transitionCollapseEasing: 'swing', transitionUncollapseEasing: 'swing', containerClass: "", tabsClass: "", tabClass: "", panelClass: "", cache: true, event: 'click', panelContext: $container }, // Internal instance variables // (not available via easytabs object) $defaultTab, $defaultTabLink, transitions, lastHash, skipUpdateToHash, animationSpeeds = { fast: 200, normal: 400, slow: 600 }, // Shorthand variable so that we don't need to call // plugin.settings throughout the plugin code settings; // ============================================================= // Functions available via easytabs object // ============================================================= plugin.init = function() { plugin.settings = settings = $.extend({}, defaults, options); settings.bind_str = settings.event+".easytabs"; // Add jQuery UI's crazy class names to markup, // so that markup will match theme CSS if ( settings.uiTabs ) { settings.tabActiveClass = 'ui-tabs-selected'; settings.containerClass = 'ui-tabs ui-widget ui-widget-content ui-corner-all'; settings.tabsClass = 'ui-tabs-nav ui-helper-reset ui-helper-clearfix ui-widget-header ui-corner-all'; settings.tabClass = 'ui-state-default ui-corner-top'; settings.panelClass = 'ui-tabs-panel ui-widget-content ui-corner-bottom'; } // If collapsible is true and defaultTab specified, assume user wants defaultTab showing (not collapsed) if ( settings.collapsible && options.defaultTab !== undefined && options.collpasedByDefault === undefined ) { settings.collapsedByDefault = false; } // Convert 'normal', 'fast', and 'slow' animation speed settings to their respective speed in milliseconds if ( typeof(settings.animationSpeed) === 'string' ) { settings.animationSpeed = animationSpeeds[settings.animationSpeed]; } $('a.anchor').remove().prependTo('body'); // Store easytabs object on container so we can easily set // properties throughout $container.data('easytabs', {}); plugin.setTransitions(); plugin.getTabs(); addClasses(); setDefaultTab(); bindToTabClicks(); initHashChange(); initCycle(); // Append data-easytabs HTML attribute to make easy to query for // easytabs instances via CSS pseudo-selector $container.attr('data-easytabs', true); }; // Set transitions for switching between tabs based on options. // Could be used to update transitions if settings are changes. plugin.setTransitions = function() { transitions = ( settings.animate ) ? { show: settings.transitionIn, hide: settings.transitionOut, speed: settings.animationSpeed, collapse: settings.transitionCollapse, uncollapse: settings.transitionUncollapse, halfSpeed: settings.animationSpeed / 2 } : { show: "show", hide: "hide", speed: 0, collapse: "hide", uncollapse: "show", halfSpeed: 0 }; }; // Find and instantiate tabs and panels. // Could be used to reset tab and panel collection if markup is // modified. plugin.getTabs = function() { var $matchingPanel; // Find the initial set of elements matching the setting.tabs // CSS selector within the container plugin.tabs = $container.find(settings.tabs), // Instantiate panels as empty jquery object plugin.panels = $(), plugin.tabs.each(function(){ var $tab = $(this), $a = $tab.children('a'), // targetId is the ID of the panel, which is either the // `href` attribute for non-ajax tabs, or in the // `data-target` attribute for ajax tabs since the `href` is // the ajax URL targetId = $tab.children('a').data('target'); $tab.data('easytabs', {}); // If the tab has a `data-target` attribute, and is thus an ajax tab if ( targetId !== undefined && targetId !== null ) { $tab.data('easytabs').ajax = $a.attr('href'); } else { targetId = $a.attr('href'); } targetId = targetId.match(/#([^\?]+)/)[1]; $matchingPanel = settings.panelContext.find("#" + targetId); // If tab has a matching panel, add it to panels if ( $matchingPanel.length ) { // Store panel height before hiding $matchingPanel.data('easytabs', { position: $matchingPanel.css('position'), visibility: $matchingPanel.css('visibility') }); // Don't hide panel if it's active (allows `getTabs` to be called manually to re-instantiate tab collection) $matchingPanel.not(settings.panelActiveClass).hide(); plugin.panels = plugin.panels.add($matchingPanel); $tab.data('easytabs').panel = $matchingPanel; // Otherwise, remove tab from tabs collection } else { plugin.tabs = plugin.tabs.not($tab); if ('console' in window) { console.warn('Warning: tab without matching panel for selector \'#' + targetId +'\' removed from set'); } } }); }; // Select tab and fire callback plugin.selectTab = function($clicked, callback) { var url = window.location, hash = url.hash.match(/^[^\?]*/)[0], $targetPanel = $clicked.parent().data('easytabs').panel, ajaxUrl = $clicked.parent().data('easytabs').ajax; // Tab is collapsible and active => toggle collapsed state if( settings.collapsible && ! skipUpdateToHash && ($clicked.hasClass(settings.tabActiveClass) || $clicked.hasClass(settings.collapsedClass)) ) { plugin.toggleTabCollapse($clicked, $targetPanel, ajaxUrl, callback); // Tab is not active and panel is not active => select tab } else if( ! $clicked.hasClass(settings.tabActiveClass) || ! $targetPanel.hasClass(settings.panelActiveClass) ){ activateTab($clicked, $targetPanel, ajaxUrl, callback); // Cache is disabled => reload (e.g reload an ajax tab). } else if ( ! settings.cache ){ activateTab($clicked, $targetPanel, ajaxUrl, callback); } }; // Toggle tab collapsed state and fire callback plugin.toggleTabCollapse = function($clicked, $targetPanel, ajaxUrl, callback) { plugin.panels.stop(true,true); if( fire($container,"easytabs:before", [$clicked, $targetPanel, settings]) ){ plugin.tabs.filter("." + settings.tabActiveClass).removeClass(settings.tabActiveClass).children().removeClass(settings.tabActiveClass); // If panel is collapsed, uncollapse it if( $clicked.hasClass(settings.collapsedClass) ){ // If ajax panel and not already cached if( ajaxUrl && (!settings.cache || !$clicked.parent().data('easytabs').cached) ) { $container.trigger('easytabs:ajax:beforeSend', [$clicked, $targetPanel]); $targetPanel.load(ajaxUrl, function(response, status, xhr){ $clicked.parent().data('easytabs').cached = true; $container.trigger('easytabs:ajax:complete', [$clicked, $targetPanel, response, status, xhr]); }); } // Update CSS classes of tab and panel $clicked.parent() .removeClass(settings.collapsedClass) .addClass(settings.tabActiveClass) .children() .removeClass(settings.collapsedClass) .addClass(settings.tabActiveClass); $targetPanel .addClass(settings.panelActiveClass) [transitions.uncollapse](transitions.speed, settings.transitionUncollapseEasing, function(){ $container.trigger('easytabs:midTransition', [$clicked, $targetPanel, settings]); if(typeof callback == 'function') callback(); }); // Otherwise, collapse it } else { // Update CSS classes of tab and panel $clicked.addClass(settings.collapsedClass) .parent() .addClass(settings.collapsedClass); $targetPanel .removeClass(settings.panelActiveClass) [transitions.collapse](transitions.speed, settings.transitionCollapseEasing, function(){ $container.trigger("easytabs:midTransition", [$clicked, $targetPanel, settings]); if(typeof callback == 'function') callback(); }); } } }; // Find tab with target panel matching value plugin.matchTab = function(hash) { return plugin.tabs.find("[href='" + hash + "'],[data-target='" + hash + "']").first(); }; // Find panel with `id` matching value plugin.matchInPanel = function(hash) { return ( hash && plugin.validId(hash) ? plugin.panels.filter(':has(' + hash + ')').first() : [] ); }; // Make sure hash is a valid id value (admittedly strict in that HTML5 allows almost anything without a space) // but jQuery has issues with such id values anyway, so we can afford to be strict here. plugin.validId = function(id) { return id.substr(1).match(/^[A-Za-z]+[A-Za-z0-9\-_:\.].$/); }; // Select matching tab when URL hash changes plugin.selectTabFromHashChange = function() { var hash = window.location.hash.match(/^[^\?]*/)[0], $tab = plugin.matchTab(hash), $panel; if ( settings.updateHash ) { // If hash directly matches tab if( $tab.length ){ skipUpdateToHash = true; plugin.selectTab( $tab ); } else { $panel = plugin.matchInPanel(hash); // If panel contains element matching hash if ( $panel.length ) { hash = '#' + $panel.attr('id'); $tab = plugin.matchTab(hash); skipUpdateToHash = true; plugin.selectTab( $tab ); // If default tab is not active... } else if ( ! $defaultTab.hasClass(settings.tabActiveClass) && ! settings.cycle ) { // ...and hash is blank or matches a parent of the tab container or // if the last tab (before the hash updated) was one of the other tabs in this container. if ( hash === '' || plugin.matchTab(lastHash).length || $container.closest(hash).length ) { skipUpdateToHash = true; plugin.selectTab( $defaultTabLink ); } } } } }; // Cycle through tabs plugin.cycleTabs = function(tabNumber){ if(settings.cycle){ tabNumber = tabNumber % plugin.tabs.length; $tab = $( plugin.tabs[tabNumber] ).children("a").first(); skipUpdateToHash = true; plugin.selectTab( $tab, function() { setTimeout(function(){ plugin.cycleTabs(tabNumber + 1); }, settings.cycle); }); } }; // Convenient public methods plugin.publicMethods = { select: function(tabSelector){ var $tab; // Find tab container that matches selector (like 'li#tab-one' which contains tab link) if ( ($tab = plugin.tabs.filter(tabSelector)).length === 0 ) { // Find direct tab link that matches href (like 'a[href="#panel-1"]') if ( ($tab = plugin.tabs.find("a[href='" + tabSelector + "']")).length === 0 ) { // Find direct tab link that matches selector (like 'a#tab-1') if ( ($tab = plugin.tabs.find("a" + tabSelector)).length === 0 ) { // Find direct tab link that matches data-target (lik 'a[data-target="#panel-1"]') if ( ($tab = plugin.tabs.find("[data-target='" + tabSelector + "']")).length === 0 ) { // Find direct tab link that ends in the matching href (like 'a[href$="#panel-1"]', which would also match http://example.com/currentpage/#panel-1) if ( ($tab = plugin.tabs.find("a[href$='" + tabSelector + "']")).length === 0 ) { $.error('Tab \'' + tabSelector + '\' does not exist in tab set'); } } } } } else { // Select the child tab link, since the first option finds the tab container (like
  • ) $tab = $tab.children("a").first(); } plugin.selectTab($tab); } }; // ============================================================= // Private functions // ============================================================= // Triggers an event on an element and returns the event result var fire = function(obj, name, data) { var event = $.Event(name); obj.trigger(event, data); return event.result !== false; } // Add CSS classes to markup (if specified), called by init var addClasses = function() { $container.addClass(settings.containerClass); plugin.tabs.parent().addClass(settings.tabsClass); plugin.tabs.addClass(settings.tabClass); plugin.panels.addClass(settings.panelClass); }; // Set the default tab, whether from hash (bookmarked) or option, // called by init var setDefaultTab = function(){ var hash = window.location.hash.match(/^[^\?]*/)[0], $selectedTab = plugin.matchTab(hash).parent(), $panel; // If hash directly matches one of the tabs, active on page-load if( $selectedTab.length === 1 ){ $defaultTab = $selectedTab; settings.cycle = false; } else { $panel = plugin.matchInPanel(hash); // If one of the panels contains the element matching the hash, // make it active on page-load if ( $panel.length ) { hash = '#' + $panel.attr('id'); $defaultTab = plugin.matchTab(hash).parent(); // Otherwise, make the default tab the one that's active on page-load } else { $defaultTab = plugin.tabs.parent().find(settings.defaultTab); if ( $defaultTab.length === 0 ) { $.error("The specified default tab ('" + settings.defaultTab + "') could not be found in the tab set ('" + settings.tabs + "') out of " + plugin.tabs.length + " tabs."); } } } $defaultTabLink = $defaultTab.children("a").first(); activateDefaultTab($selectedTab); }; // Activate defaultTab (or collapse by default), called by setDefaultTab var activateDefaultTab = function($selectedTab) { var defaultPanel, defaultAjaxUrl; if ( settings.collapsible && $selectedTab.length === 0 && settings.collapsedByDefault ) { $defaultTab .addClass(settings.collapsedClass) .children() .addClass(settings.collapsedClass); } else { defaultPanel = $( $defaultTab.data('easytabs').panel ); defaultAjaxUrl = $defaultTab.data('easytabs').ajax; if ( defaultAjaxUrl && (!settings.cache || !$defaultTab.data('easytabs').cached) ) { $container.trigger('easytabs:ajax:beforeSend', [$defaultTabLink, defaultPanel]); defaultPanel.load(defaultAjaxUrl, function(response, status, xhr){ $defaultTab.data('easytabs').cached = true; $container.trigger('easytabs:ajax:complete', [$defaultTabLink, defaultPanel, response, status, xhr]); }); } $defaultTab.data('easytabs').panel .show() .addClass(settings.panelActiveClass); $defaultTab .addClass(settings.tabActiveClass) .children() .addClass(settings.tabActiveClass); } // Fire event when the plugin is initialised $container.trigger("easytabs:initialised", [$defaultTabLink, defaultPanel]); }; // Bind tab-select funtionality to namespaced click event, called by // init var bindToTabClicks = function() { plugin.tabs.children("a").bind(settings.bind_str, function(e) { // Stop cycling when a tab is clicked settings.cycle = false; // Hash will be updated when tab is clicked, // don't cause tab to re-select when hash-change event is fired skipUpdateToHash = false; // Select the panel for the clicked tab plugin.selectTab( $(this) ); // Don't follow the link to the anchor e.preventDefault ? e.preventDefault() : e.returnValue = false; }); }; // Activate a given tab/panel, called from plugin.selectTab: // // * fire `easytabs:before` hook // * get ajax if new tab is an uncached ajax tab // * animate out previously-active panel // * fire `easytabs:midTransition` hook // * update URL hash // * animate in newly-active panel // * update CSS classes for inactive and active tabs/panels // // TODO: This could probably be broken out into many more modular // functions var activateTab = function($clicked, $targetPanel, ajaxUrl, callback) { plugin.panels.stop(true,true); if( fire($container,"easytabs:before", [$clicked, $targetPanel, settings]) ){ var $visiblePanel = plugin.panels.filter(":visible"), $panelContainer = $targetPanel.parent(), targetHeight, visibleHeight, heightDifference, showPanel, hash = window.location.hash.match(/^[^\?]*/)[0]; if (settings.animate) { targetHeight = getHeightForHidden($targetPanel); visibleHeight = $visiblePanel.length ? setAndReturnHeight($visiblePanel) : 0; heightDifference = targetHeight - visibleHeight; } // Set lastHash to help indicate if defaultTab should be // activated across multiple tab instances. lastHash = hash; // TODO: Move this function elsewhere showPanel = function() { // At this point, the previous panel is hidden, and the new one will be selected $container.trigger("easytabs:midTransition", [$clicked, $targetPanel, settings]); // Gracefully animate between panels of differing heights, start height change animation *after* panel change if panel needs to contract, // so that there is no chance of making the visible panel overflowing the height of the target panel if (settings.animate && settings.transitionIn == 'fadeIn') { if (heightDifference < 0) $panelContainer.animate({ height: $panelContainer.height() + heightDifference }, transitions.halfSpeed ).css({ 'min-height': '' }); } if ( settings.updateHash && ! skipUpdateToHash ) { //window.location = url.toString().replace((url.pathname + hash), (url.pathname + $clicked.attr("href"))); // Not sure why this behaves so differently, but it's more straight forward and seems to have less side-effects window.location.hash = '#' + $targetPanel.attr('id'); } else { skipUpdateToHash = false; } $targetPanel [transitions.show](transitions.speed, settings.transitionInEasing, function(){ $panelContainer.css({height: '', 'min-height': ''}); // After the transition, unset the height $container.trigger("easytabs:after", [$clicked, $targetPanel, settings]); // callback only gets called if selectTab actually does something, since it's inside the if block if(typeof callback == 'function'){ callback(); } }); }; if ( ajaxUrl && (!settings.cache || !$clicked.parent().data('easytabs').cached) ) { $container.trigger('easytabs:ajax:beforeSend', [$clicked, $targetPanel]); $targetPanel.load(ajaxUrl, function(response, status, xhr){ $clicked.parent().data('easytabs').cached = true; $container.trigger('easytabs:ajax:complete', [$clicked, $targetPanel, response, status, xhr]); }); } // Gracefully animate between panels of differing heights, start height change animation *before* panel change if panel needs to expand, // so that there is no chance of making the target panel overflowing the height of the visible panel if( settings.animate && settings.transitionOut == 'fadeOut' ) { if( heightDifference > 0 ) { $panelContainer.animate({ height: ( $panelContainer.height() + heightDifference ) }, transitions.halfSpeed ); } else { // Prevent height jumping before height transition is triggered at midTransition $panelContainer.css({ 'min-height': $panelContainer.height() }); } } // Change the active tab *first* to provide immediate feedback when the user clicks plugin.tabs.filter("." + settings.tabActiveClass).removeClass(settings.tabActiveClass).children().removeClass(settings.tabActiveClass); plugin.tabs.filter("." + settings.collapsedClass).removeClass(settings.collapsedClass).children().removeClass(settings.collapsedClass); $clicked.parent().addClass(settings.tabActiveClass).children().addClass(settings.tabActiveClass); plugin.panels.filter("." + settings.panelActiveClass).removeClass(settings.panelActiveClass); $targetPanel.addClass(settings.panelActiveClass); if( $visiblePanel.length ) { $visiblePanel [transitions.hide](transitions.speed, settings.transitionOutEasing, showPanel); } else { $targetPanel [transitions.uncollapse](transitions.speed, settings.transitionUncollapseEasing, showPanel); } } }; // Get heights of panels to enable animation between panels of // differing heights, called by activateTab var getHeightForHidden = function($targetPanel){ if ( $targetPanel.data('easytabs') && $targetPanel.data('easytabs').lastHeight ) { return $targetPanel.data('easytabs').lastHeight; } // this is the only property easytabs changes, so we need to grab its value on each tab change var display = $targetPanel.css('display'), outerCloak, height; // Workaround with wrapping height, because firefox returns wrong // height if element itself has absolute positioning. // but try/catch block needed for IE7 and IE8 because they throw // an "Unspecified error" when trying to create an element // with the css position set. try { outerCloak = $('
    ', {'position': 'absolute', 'visibility': 'hidden', 'overflow': 'hidden'}); } catch (e) { outerCloak = $('
    ', {'visibility': 'hidden', 'overflow': 'hidden'}); } height = $targetPanel .wrap(outerCloak) .css({'position':'relative','visibility':'hidden','display':'block'}) .outerHeight(); $targetPanel.unwrap(); // Return element to previous state $targetPanel.css({ position: $targetPanel.data('easytabs').position, visibility: $targetPanel.data('easytabs').visibility, display: display }); // Cache height $targetPanel.data('easytabs').lastHeight = height; return height; }; // Since the height of the visible panel may have been manipulated due to interaction, // we want to re-cache the visible height on each tab change, called // by activateTab var setAndReturnHeight = function($visiblePanel) { var height = $visiblePanel.outerHeight(); if( $visiblePanel.data('easytabs') ) { $visiblePanel.data('easytabs').lastHeight = height; } else { $visiblePanel.data('easytabs', {lastHeight: height}); } return height; }; // Setup hash-change callback for forward- and back-button // functionality, called by init var initHashChange = function(){ // enabling back-button with jquery.hashchange plugin // http://benalman.com/projects/jquery-hashchange-plugin/ if(typeof $(window).hashchange === 'function'){ $(window).hashchange( function(){ plugin.selectTabFromHashChange(); }); } else if ($.address && typeof $.address.change === 'function') { // back-button with jquery.address plugin http://www.asual.com/jquery/address/docs/ $.address.change( function(){ plugin.selectTabFromHashChange(); }); } }; // Begin cycling if set in options, called by init var initCycle = function(){ var tabNumber; if (settings.cycle) { tabNumber = plugin.tabs.index($defaultTab); setTimeout( function(){ plugin.cycleTabs(tabNumber + 1); }, settings.cycle); } }; plugin.init(); }; $.fn.easytabs = function(options) { var args = arguments; return this.each(function() { var $this = $(this), plugin = $this.data('easytabs'); // Initialization was called with $(el).easytabs( { options } ); if (undefined === plugin) { plugin = new $.easytabs(this, options); $this.data('easytabs', plugin); } // User called public method if ( plugin.publicMethods[options] ){ return plugin.publicMethods[options](Array.prototype.slice.call( args, 1 )); } }); }; })(jQuery); eiskaltdcpp-web-1.0.1/js/lib/jquery.hashchange.js000066400000000000000000000375421361213051300217240ustar00rootroot00000000000000/* @license * * jQuery hashchange event - v1.3c - 2014-04-10 * http://benalman.com/projects/jquery-hashchange-plugin/ * * Copyright (c) 2010 "Cowboy" Ben Alman * Dual licensed under the MIT and GPL licenses. * http://benalman.com/about/license/ */ // Script: jQuery hashchange event // // *Version: 1.3c, Last updated: 2014-04-10* // // Project Home - http://benalman.com/projects/jquery-hashchange-plugin/ // GitHub - https://github.com/pandell/jquery-hashchange/ // Source - https://github.com/pandell/jquery-hashchange/raw/master/jquery.ba-hashchange.js // (Minified) - https://github.com/pandell/jquery-hashchange/raw/master/jquery.ba-hashchange.min.js (0.8kb gzipped) // // About: License // // Copyright (c) 2010 "Cowboy" Ben Alman, // Dual licensed under the MIT and GPL licenses. // http://benalman.com/about/license/ // // About: Examples // // These working examples, complete with fully commented code, illustrate a few // ways in which this plugin can be used. // // hashchange event - http://benalman.com/code/projects/jquery-hashchange/examples/hashchange/ // document.domain - http://benalman.com/code/projects/jquery-hashchange/examples/document_domain/ // // About: Support and Testing // // Information about what version or versions of jQuery this plugin has been // tested with, what browsers it has been tested in, and where the unit tests // reside (so you can test it yourself). // // jQuery Versions - 1.2.6, 1.3.2, 1.4.1, 1.4.2, 1.11.0 // Browsers Tested - Internet Explorer 6-8, Firefox 2-4, Chrome 5-6, Safari 3.2-5, // Opera 9.6-10.60, iPhone 3.1, Android 1.6-2.2, BlackBerry 4.6-5. // Unit Tests - http://benalman.com/code/projects/jquery-hashchange/unit/ // // About: Known issues // // While this jQuery hashchange event implementation is quite stable and // robust, there are a few unfortunate browser bugs surrounding expected // hashchange event-based behaviors, independent of any JavaScript // window.onhashchange abstraction. See the following examples for more // information: // // Chrome: Back Button - http://benalman.com/code/projects/jquery-hashchange/examples/bug-chrome-back-button/ // Firefox: Remote XMLHttpRequest - http://benalman.com/code/projects/jquery-hashchange/examples/bug-firefox-remote-xhr/ // WebKit: Back Button in an Iframe - http://benalman.com/code/projects/jquery-hashchange/examples/bug-webkit-hash-iframe/ // Safari: Back Button from a different domain - http://benalman.com/code/projects/jquery-hashchange/examples/bug-safari-back-from-diff-domain/ // // Also note that should a browser natively support the window.onhashchange // event, but not report that it does, the fallback polling loop will be used. // // About: Release History // // 1.3b - (4/04/2014) Remove 'window' redefinition // 1.3a - (3/18/2014) Remove explicit browser detection // 1.3 - (7/21/2010) Reorganized IE6/7 Iframe code to make it more // "removable" for mobile-only development. Added IE6/7 document.title // support. Attempted to make Iframe as hidden as possible by using // techniques from http://www.paciellogroup.com/blog/?p=604. Added // support for the "shortcut" format $(window).hashchange( fn ) and // $(window).hashchange() like jQuery provides for built-in events. // Renamed jQuery.hashchangeDelay to and // lowered its default value to 50. Added // and properties plus document-domain.html // file to address access denied issues when setting document.domain in // IE6/7. // 1.2 - (2/11/2010) Fixed a bug where coming back to a page using this plugin // from a page on another domain would cause an error in Safari 4. Also, // IE6/7 Iframe is now inserted after the body (this actually works), // which prevents the page from scrolling when the event is first bound. // Event can also now be bound before DOM ready, but it won't be usable // before then in IE6/7. // 1.1 - (1/21/2010) Incorporated document.documentMode test to fix IE8 bug // where browser version is incorrectly reported as 8.0, despite // inclusion of the X-UA-Compatible IE=EmulateIE7 meta tag. // 1.0 - (1/9/2010) Initial Release. Broke out the jQuery BBQ event.special // window.onhashchange functionality into a separate plugin for users // who want just the basic event & back button support, without all the // extra awesomeness that BBQ provides. This plugin will be included as // part of jQuery BBQ, but also be available separately. (function($,undefined){ '$:nomunge'; // Used by YUI compressor. // Reused string. var str_hashchange = 'hashchange', // Method / object references. doc = document, fake_onhashchange, special = $.event.special, // Does the browser support window.onhashchange? Note that IE8 running in // IE7 compatibility mode reports true for 'onhashchange' in window, even // though the event isn't supported, so also test document.documentMode. doc_mode = doc.documentMode, supports_onhashchange = 'on' + str_hashchange in window && ( doc_mode === undefined || doc_mode > 7 ); // Get location.hash (or what you'd expect location.hash to be) sans any // leading #. Thanks for making this necessary, Firefox! function get_fragment( url ) { url = url || location.href; return '#' + url.replace( /^[^#]*#?(.*)$/, '$1' ); }; // Method: jQuery.fn.hashchange // // Bind a handler to the window.onhashchange event or trigger all bound // window.onhashchange event handlers. This behavior is consistent with // jQuery's built-in event handlers. // // Usage: // // > jQuery(window).hashchange( [ handler ] ); // // Arguments: // // handler - (Function) Optional handler to be bound to the hashchange // event. This is a "shortcut" for the more verbose form: // jQuery(window).bind( 'hashchange', handler ). If handler is omitted, // all bound window.onhashchange event handlers will be triggered. This // is a shortcut for the more verbose // jQuery(window).trigger( 'hashchange' ). These forms are described in // the section. // // Returns: // // (jQuery) The initial jQuery collection of elements. // Allow the "shortcut" format $(elem).hashchange( fn ) for binding and // $(elem).hashchange() for triggering, like jQuery does for built-in events. $.fn[ str_hashchange ] = function( fn ) { return fn ? this.bind( str_hashchange, fn ) : this.trigger( str_hashchange ); }; // Property: jQuery.fn.hashchange.delay // // The numeric interval (in milliseconds) at which the // polling loop executes. Defaults to 50. // Property: jQuery.fn.hashchange.domain // // If you're setting document.domain in your JavaScript, and you want hash // history to work in IE6/7, not only must this property be set, but you must // also set document.domain BEFORE jQuery is loaded into the page. This // property is only applicable if you are supporting IE6/7 (or IE8 operating // in "IE7 compatibility" mode). // // In addition, the property must be set to the // path of the included "document-domain.html" file, which can be renamed or // modified if necessary (note that the document.domain specified must be the // same in both your main JavaScript as well as in this file). // // Usage: // // jQuery.fn.hashchange.domain = document.domain; // Property: jQuery.fn.hashchange.src // // If, for some reason, you need to specify an Iframe src file (for example, // when setting document.domain as in ), you can // do so using this property. Note that when using this property, history // won't be recorded in IE6/7 until the Iframe src file loads. This property // is only applicable if you are supporting IE6/7 (or IE8 operating in "IE7 // compatibility" mode). // // Usage: // // jQuery.fn.hashchange.src = 'path/to/file.html'; $.fn[ str_hashchange ].delay = 50; /* $.fn[ str_hashchange ].domain = null; $.fn[ str_hashchange ].src = null; */ // Event: hashchange event // // Fired when location.hash changes. In browsers that support it, the native // HTML5 window.onhashchange event is used, otherwise a polling loop is // initialized, running every milliseconds to // see if the hash has changed. In IE6/7 (and IE8 operating in "IE7 // compatibility" mode), a hidden Iframe is created to allow the back button // and hash-based history to work. // // Usage as described in : // // > // Bind an event handler. // > jQuery(window).hashchange( function(e) { // > var hash = location.hash; // > ... // > }); // > // > // Manually trigger the event handler. // > jQuery(window).hashchange(); // // A more verbose usage that allows for event namespacing: // // > // Bind an event handler. // > jQuery(window).bind( 'hashchange', function(e) { // > var hash = location.hash; // > ... // > }); // > // > // Manually trigger the event handler. // > jQuery(window).trigger( 'hashchange' ); // // Additional Notes: // // * The polling loop and Iframe are not created until at least one handler // is actually bound to the 'hashchange' event. // * If you need the bound handler(s) to execute immediately, in cases where // a location.hash exists on page load, via bookmark or page refresh for // example, use jQuery(window).hashchange() or the more verbose // jQuery(window).trigger( 'hashchange' ). // * The event can be bound before DOM ready, but since it won't be usable // before then in IE6/7 (due to the necessary Iframe), recommended usage is // to bind it inside a DOM ready handler. // Override existing $.event.special.hashchange methods (allowing this plugin // to be defined after jQuery BBQ in BBQ's source code). special[ str_hashchange ] = $.extend( special[ str_hashchange ], { // Called only when the first 'hashchange' event is bound to window. setup: function() { // If window.onhashchange is supported natively, there's nothing to do.. if ( supports_onhashchange ) { return false; } // Otherwise, we need to create our own. And we don't want to call this // until the user binds to the event, just in case they never do, since it // will create a polling loop and possibly even a hidden Iframe. $( fake_onhashchange.start ); }, // Called only when the last 'hashchange' event is unbound from window. teardown: function() { // If window.onhashchange is supported natively, there's nothing to do.. if ( supports_onhashchange ) { return false; } // Otherwise, we need to stop ours (if possible). $( fake_onhashchange.stop ); } }); // fake_onhashchange does all the work of triggering the window.onhashchange // event for browsers that don't natively support it, including creating a // polling loop to watch for hash changes and in IE 6/7 creating a hidden // Iframe to enable back and forward. fake_onhashchange = (function(){ var self = {}, timeout_id, // Remember the initial hash so it doesn't get triggered immediately. last_hash = get_fragment(), fn_retval = function(val){ return val; }, history_set = fn_retval, history_get = fn_retval; // Start the polling loop. self.start = function() { timeout_id || poll(); }; // Stop the polling loop. self.stop = function() { timeout_id && clearTimeout( timeout_id ); timeout_id = undefined; }; // This polling loop checks every $.fn.hashchange.delay milliseconds to see // if location.hash has changed, and triggers the 'hashchange' event on // window when necessary. function poll() { var hash = get_fragment(), history_hash = history_get( last_hash ); if ( hash !== last_hash ) { history_set( last_hash = hash, history_hash ); $(window).trigger( str_hashchange ); } else if ( history_hash !== last_hash ) { location.href = location.href.replace( /#.*/, '' ) + history_hash; } timeout_id = setTimeout( poll, $.fn[ str_hashchange ].delay ); }; // vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv // vvvvvvvvvvvvvvvvvvv REMOVE IF NOT SUPPORTING IE6/7/8 vvvvvvvvvvvvvvvvvvv // vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv !supports_onhashchange && (function(){ // Not only do IE6/7 need the "magical" Iframe treatment, but so does IE8 // when running in "IE7 compatibility" mode. var iframe, iframe_src; // When the event is bound and polling starts in IE 6/7, create a hidden // Iframe for history handling. self.start = function(){ if ( !iframe ) { iframe_src = $.fn[ str_hashchange ].src; iframe_src = iframe_src && iframe_src + get_fragment(); // Create hidden Iframe. Attempt to make Iframe as hidden as possible // by using techniques from http://www.paciellogroup.com/blog/?p=604. iframe = $('