├── LICENSE ├── Lang ├── en │ ├── en1.txt │ ├── en2.txt │ ├── en3.txt │ ├── en4.txt │ ├── en5.txt │ ├── en6.txt │ ├── en7.txt │ ├── en8.txt │ └── en9.txt ├── es │ ├── es1.txt │ ├── es2.txt │ ├── es3.txt │ ├── es4.txt │ ├── es5.txt │ ├── es6.txt │ ├── es7.txt │ ├── es8.txt │ └── es9.txt ├── it │ ├── it1.txt │ ├── it2.txt │ ├── it3.txt │ ├── it4.txt │ ├── it5.txt │ ├── it6.txt │ ├── it7.txt │ ├── it8.txt │ └── it9.txt ├── pt │ ├── pt1.txt │ ├── pt2.txt │ ├── pt3.txt │ ├── pt4.txt │ ├── pt5.txt │ ├── pt6.txt │ ├── pt7.txt │ ├── pt8.txt │ └── pt9.txt ├── ru │ ├── ru1.txt │ ├── ru2.txt │ ├── ru3.txt │ ├── ru4.txt │ ├── ru5.txt │ ├── ru6.txt │ ├── ru7.txt │ ├── ru8.txt │ └── ru9.txt └── zh │ ├── zh1.txt │ ├── zh2.txt │ ├── zh3.txt │ ├── zh4.txt │ ├── zh5.txt │ ├── zh6.txt │ ├── zh7.txt │ ├── zh8.txt │ └── zh9.txt ├── META-INF └── com │ └── google │ └── android │ ├── update-binary │ └── updater-script ├── Mods ├── DBGQ │ └── system.prop ├── HKB │ └── HKB.apk ├── HP │ └── pillhide.apk ├── MIUI │ └── AndroidManifest.xml ├── Q │ └── dummy ├── QS │ ├── AndroidManifest.xml │ └── res │ │ └── values │ │ ├── bools.xml │ │ ├── dimens.xml │ │ ├── integers.xml │ │ └── strings.xml └── Qtmp │ └── dummy ├── OC.md ├── README.md ├── common ├── addon │ └── Volume-Key-Selector │ │ ├── README.md │ │ ├── a │ │ ├── install.sh │ │ └── tools │ │ ├── arm │ │ └── keycheck │ │ └── x86 │ │ └── keycheck ├── functions.sh └── install.sh ├── customize.sh ├── module.prop ├── service.sh └── tools ├── META-INF └── com │ └── google │ └── android │ ├── update-binary │ └── updater-script ├── aapt ├── aapt64 ├── customize.sh ├── dalvikvm64 ├── hn ├── hnr ├── service.sh ├── zip ├── zipsigner ├── zipsigner-3.0-dexed.jar └── zipsignero /LICENSE: -------------------------------------------------------------------------------- 1 | GNU GENERAL PUBLIC LICENSE 2 | Version 3, 29 June 2007 3 | 4 | Copyright (C) 2007 Free Software Foundation, Inc. 5 | Everyone is permitted to copy and distribute verbatim copies 6 | of this license document, but changing it is not allowed. 7 | 8 | Preamble 9 | 10 | The GNU General Public License is a free, copyleft license for 11 | software and other kinds of works. 12 | 13 | The licenses for most software and other practical works are designed 14 | to take away your freedom to share and change the works. By contrast, 15 | the GNU General Public License is intended to guarantee your freedom to 16 | share and change all versions of a program--to make sure it remains free 17 | software for all its users. We, the Free Software Foundation, use the 18 | GNU General Public License for most of our software; it applies also to 19 | any other work released this way by its authors. You can apply it to 20 | your programs, too. 21 | 22 | When we speak of free software, we are referring to freedom, not 23 | price. Our General Public Licenses are designed to make sure that you 24 | have the freedom to distribute copies of free software (and charge for 25 | them if you wish), that you receive source code or can get it if you 26 | want it, that you can change the software or use pieces of it in new 27 | free programs, and that you know you can do these things. 28 | 29 | To protect your rights, we need to prevent others from denying you 30 | these rights or asking you to surrender the rights. Therefore, you have 31 | certain responsibilities if you distribute copies of the software, or if 32 | you modify it: responsibilities to respect the freedom of others. 33 | 34 | For example, if you distribute copies of such a program, whether 35 | gratis or for a fee, you must pass on to the recipients the same 36 | freedoms that you received. You must make sure that they, too, receive 37 | or can get the source code. And you must show them these terms so they 38 | know their rights. 39 | 40 | Developers that use the GNU GPL protect your rights with two steps: 41 | (1) assert copyright on the software, and (2) offer you this License 42 | giving you legal permission to copy, distribute and/or modify it. 43 | 44 | For the developers' and authors' protection, the GPL clearly explains 45 | that there is no warranty for this free software. For both users' and 46 | authors' sake, the GPL requires that modified versions be marked as 47 | changed, so that their problems will not be attributed erroneously to 48 | authors of previous versions. 49 | 50 | Some devices are designed to deny users access to install or run 51 | modified versions of the software inside them, although the manufacturer 52 | can do so. This is fundamentally incompatible with the aim of 53 | protecting users' freedom to change the software. The systematic 54 | pattern of such abuse occurs in the area of products for individuals to 55 | use, which is precisely where it is most unacceptable. Therefore, we 56 | have designed this version of the GPL to prohibit the practice for those 57 | products. If such problems arise substantially in other domains, we 58 | stand ready to extend this provision to those domains in future versions 59 | of the GPL, as needed to protect the freedom of users. 60 | 61 | Finally, every program is threatened constantly by software patents. 62 | States should not allow patents to restrict development and use of 63 | software on general-purpose computers, but in those that do, we wish to 64 | avoid the special danger that patents applied to a free program could 65 | make it effectively proprietary. To prevent this, the GPL assures that 66 | patents cannot be used to render the program non-free. 67 | 68 | The precise terms and conditions for copying, distribution and 69 | modification follow. 70 | 71 | TERMS AND CONDITIONS 72 | 73 | 0. Definitions. 74 | 75 | "This License" refers to version 3 of the GNU General Public License. 76 | 77 | "Copyright" also means copyright-like laws that apply to other kinds of 78 | works, such as semiconductor masks. 79 | 80 | "The Program" refers to any copyrightable work licensed under this 81 | License. Each licensee is addressed as "you". "Licensees" and 82 | "recipients" may be individuals or organizations. 83 | 84 | To "modify" a work means to copy from or adapt all or part of the work 85 | in a fashion requiring copyright permission, other than the making of an 86 | exact copy. The resulting work is called a "modified version" of the 87 | earlier work or a work "based on" the earlier work. 88 | 89 | A "covered work" means either the unmodified Program or a work based 90 | on the Program. 91 | 92 | To "propagate" a work means to do anything with it that, without 93 | permission, would make you directly or secondarily liable for 94 | infringement under applicable copyright law, except executing it on a 95 | computer or modifying a private copy. Propagation includes copying, 96 | distribution (with or without modification), making available to the 97 | public, and in some countries other activities as well. 98 | 99 | To "convey" a work means any kind of propagation that enables other 100 | parties to make or receive copies. Mere interaction with a user through 101 | a computer network, with no transfer of a copy, is not conveying. 102 | 103 | An interactive user interface displays "Appropriate Legal Notices" 104 | to the extent that it includes a convenient and prominently visible 105 | feature that (1) displays an appropriate copyright notice, and (2) 106 | tells the user that there is no warranty for the work (except to the 107 | extent that warranties are provided), that licensees may convey the 108 | work under this License, and how to view a copy of this License. If 109 | the interface presents a list of user commands or options, such as a 110 | menu, a prominent item in the list meets this criterion. 111 | 112 | 1. Source Code. 113 | 114 | The "source code" for a work means the preferred form of the work 115 | for making modifications to it. "Object code" means any non-source 116 | form of a work. 117 | 118 | A "Standard Interface" means an interface that either is an official 119 | standard defined by a recognized standards body, or, in the case of 120 | interfaces specified for a particular programming language, one that 121 | is widely used among developers working in that language. 122 | 123 | The "System Libraries" of an executable work include anything, other 124 | than the work as a whole, that (a) is included in the normal form of 125 | packaging a Major Component, but which is not part of that Major 126 | Component, and (b) serves only to enable use of the work with that 127 | Major Component, or to implement a Standard Interface for which an 128 | implementation is available to the public in source code form. A 129 | "Major Component", in this context, means a major essential component 130 | (kernel, window system, and so on) of the specific operating system 131 | (if any) on which the executable work runs, or a compiler used to 132 | produce the work, or an object code interpreter used to run it. 133 | 134 | The "Corresponding Source" for a work in object code form means all 135 | the source code needed to generate, install, and (for an executable 136 | work) run the object code and to modify the work, including scripts to 137 | control those activities. However, it does not include the work's 138 | System Libraries, or general-purpose tools or generally available free 139 | programs which are used unmodified in performing those activities but 140 | which are not part of the work. For example, Corresponding Source 141 | includes interface definition files associated with source files for 142 | the work, and the source code for shared libraries and dynamically 143 | linked subprograms that the work is specifically designed to require, 144 | such as by intimate data communication or control flow between those 145 | subprograms and other parts of the work. 146 | 147 | The Corresponding Source need not include anything that users 148 | can regenerate automatically from other parts of the Corresponding 149 | Source. 150 | 151 | The Corresponding Source for a work in source code form is that 152 | same work. 153 | 154 | 2. Basic Permissions. 155 | 156 | All rights granted under this License are granted for the term of 157 | copyright on the Program, and are irrevocable provided the stated 158 | conditions are met. This License explicitly affirms your unlimited 159 | permission to run the unmodified Program. The output from running a 160 | covered work is covered by this License only if the output, given its 161 | content, constitutes a covered work. This License acknowledges your 162 | rights of fair use or other equivalent, as provided by copyright law. 163 | 164 | You may make, run and propagate covered works that you do not 165 | convey, without conditions so long as your license otherwise remains 166 | in force. You may convey covered works to others for the sole purpose 167 | of having them make modifications exclusively for you, or provide you 168 | with facilities for running those works, provided that you comply with 169 | the terms of this License in conveying all material for which you do 170 | not control copyright. Those thus making or running the covered works 171 | for you must do so exclusively on your behalf, under your direction 172 | and control, on terms that prohibit them from making any copies of 173 | your copyrighted material outside their relationship with you. 174 | 175 | Conveying under any other circumstances is permitted solely under 176 | the conditions stated below. Sublicensing is not allowed; section 10 177 | makes it unnecessary. 178 | 179 | 3. Protecting Users' Legal Rights From Anti-Circumvention Law. 180 | 181 | No covered work shall be deemed part of an effective technological 182 | measure under any applicable law fulfilling obligations under article 183 | 11 of the WIPO copyright treaty adopted on 20 December 1996, or 184 | similar laws prohibiting or restricting circumvention of such 185 | measures. 186 | 187 | When you convey a covered work, you waive any legal power to forbid 188 | circumvention of technological measures to the extent such circumvention 189 | is effected by exercising rights under this License with respect to 190 | the covered work, and you disclaim any intention to limit operation or 191 | modification of the work as a means of enforcing, against the work's 192 | users, your or third parties' legal rights to forbid circumvention of 193 | technological measures. 194 | 195 | 4. Conveying Verbatim Copies. 196 | 197 | You may convey verbatim copies of the Program's source code as you 198 | receive it, in any medium, provided that you conspicuously and 199 | appropriately publish on each copy an appropriate copyright notice; 200 | keep intact all notices stating that this License and any 201 | non-permissive terms added in accord with section 7 apply to the code; 202 | keep intact all notices of the absence of any warranty; and give all 203 | recipients a copy of this License along with the Program. 204 | 205 | You may charge any price or no price for each copy that you convey, 206 | and you may offer support or warranty protection for a fee. 207 | 208 | 5. Conveying Modified Source Versions. 209 | 210 | You may convey a work based on the Program, or the modifications to 211 | produce it from the Program, in the form of source code under the 212 | terms of section 4, provided that you also meet all of these conditions: 213 | 214 | a) The work must carry prominent notices stating that you modified 215 | it, and giving a relevant date. 216 | 217 | b) The work must carry prominent notices stating that it is 218 | released under this License and any conditions added under section 219 | 7. This requirement modifies the requirement in section 4 to 220 | "keep intact all notices". 221 | 222 | c) You must license the entire work, as a whole, under this 223 | License to anyone who comes into possession of a copy. This 224 | License will therefore apply, along with any applicable section 7 225 | additional terms, to the whole of the work, and all its parts, 226 | regardless of how they are packaged. This License gives no 227 | permission to license the work in any other way, but it does not 228 | invalidate such permission if you have separately received it. 229 | 230 | d) If the work has interactive user interfaces, each must display 231 | Appropriate Legal Notices; however, if the Program has interactive 232 | interfaces that do not display Appropriate Legal Notices, your 233 | work need not make them do so. 234 | 235 | A compilation of a covered work with other separate and independent 236 | works, which are not by their nature extensions of the covered work, 237 | and which are not combined with it such as to form a larger program, 238 | in or on a volume of a storage or distribution medium, is called an 239 | "aggregate" if the compilation and its resulting copyright are not 240 | used to limit the access or legal rights of the compilation's users 241 | beyond what the individual works permit. Inclusion of a covered work 242 | in an aggregate does not cause this License to apply to the other 243 | parts of the aggregate. 244 | 245 | 6. Conveying Non-Source Forms. 246 | 247 | You may convey a covered work in object code form under the terms 248 | of sections 4 and 5, provided that you also convey the 249 | machine-readable Corresponding Source under the terms of this License, 250 | in one of these ways: 251 | 252 | a) Convey the object code in, or embodied in, a physical product 253 | (including a physical distribution medium), accompanied by the 254 | Corresponding Source fixed on a durable physical medium 255 | customarily used for software interchange. 256 | 257 | b) Convey the object code in, or embodied in, a physical product 258 | (including a physical distribution medium), accompanied by a 259 | written offer, valid for at least three years and valid for as 260 | long as you offer spare parts or customer support for that product 261 | model, to give anyone who possesses the object code either (1) a 262 | copy of the Corresponding Source for all the software in the 263 | product that is covered by this License, on a durable physical 264 | medium customarily used for software interchange, for a price no 265 | more than your reasonable cost of physically performing this 266 | conveying of source, or (2) access to copy the 267 | Corresponding Source from a network server at no charge. 268 | 269 | c) Convey individual copies of the object code with a copy of the 270 | written offer to provide the Corresponding Source. This 271 | alternative is allowed only occasionally and noncommercially, and 272 | only if you received the object code with such an offer, in accord 273 | with subsection 6b. 274 | 275 | d) Convey the object code by offering access from a designated 276 | place (gratis or for a charge), and offer equivalent access to the 277 | Corresponding Source in the same way through the same place at no 278 | further charge. You need not require recipients to copy the 279 | Corresponding Source along with the object code. If the place to 280 | copy the object code is a network server, the Corresponding Source 281 | may be on a different server (operated by you or a third party) 282 | that supports equivalent copying facilities, provided you maintain 283 | clear directions next to the object code saying where to find the 284 | Corresponding Source. Regardless of what server hosts the 285 | Corresponding Source, you remain obligated to ensure that it is 286 | available for as long as needed to satisfy these requirements. 287 | 288 | e) Convey the object code using peer-to-peer transmission, provided 289 | you inform other peers where the object code and Corresponding 290 | Source of the work are being offered to the general public at no 291 | charge under subsection 6d. 292 | 293 | A separable portion of the object code, whose source code is excluded 294 | from the Corresponding Source as a System Library, need not be 295 | included in conveying the object code work. 296 | 297 | A "User Product" is either (1) a "consumer product", which means any 298 | tangible personal property which is normally used for personal, family, 299 | or household purposes, or (2) anything designed or sold for incorporation 300 | into a dwelling. In determining whether a product is a consumer product, 301 | doubtful cases shall be resolved in favor of coverage. For a particular 302 | product received by a particular user, "normally used" refers to a 303 | typical or common use of that class of product, regardless of the status 304 | of the particular user or of the way in which the particular user 305 | actually uses, or expects or is expected to use, the product. A product 306 | is a consumer product regardless of whether the product has substantial 307 | commercial, industrial or non-consumer uses, unless such uses represent 308 | the only significant mode of use of the product. 309 | 310 | "Installation Information" for a User Product means any methods, 311 | procedures, authorization keys, or other information required to install 312 | and execute modified versions of a covered work in that User Product from 313 | a modified version of its Corresponding Source. The information must 314 | suffice to ensure that the continued functioning of the modified object 315 | code is in no case prevented or interfered with solely because 316 | modification has been made. 317 | 318 | If you convey an object code work under this section in, or with, or 319 | specifically for use in, a User Product, and the conveying occurs as 320 | part of a transaction in which the right of possession and use of the 321 | User Product is transferred to the recipient in perpetuity or for a 322 | fixed term (regardless of how the transaction is characterized), the 323 | Corresponding Source conveyed under this section must be accompanied 324 | by the Installation Information. But this requirement does not apply 325 | if neither you nor any third party retains the ability to install 326 | modified object code on the User Product (for example, the work has 327 | been installed in ROM). 328 | 329 | The requirement to provide Installation Information does not include a 330 | requirement to continue to provide support service, warranty, or updates 331 | for a work that has been modified or installed by the recipient, or for 332 | the User Product in which it has been modified or installed. Access to a 333 | network may be denied when the modification itself materially and 334 | adversely affects the operation of the network or violates the rules and 335 | protocols for communication across the network. 336 | 337 | Corresponding Source conveyed, and Installation Information provided, 338 | in accord with this section must be in a format that is publicly 339 | documented (and with an implementation available to the public in 340 | source code form), and must require no special password or key for 341 | unpacking, reading or copying. 342 | 343 | 7. Additional Terms. 344 | 345 | "Additional permissions" are terms that supplement the terms of this 346 | License by making exceptions from one or more of its conditions. 347 | Additional permissions that are applicable to the entire Program shall 348 | be treated as though they were included in this License, to the extent 349 | that they are valid under applicable law. If additional permissions 350 | apply only to part of the Program, that part may be used separately 351 | under those permissions, but the entire Program remains governed by 352 | this License without regard to the additional permissions. 353 | 354 | When you convey a copy of a covered work, you may at your option 355 | remove any additional permissions from that copy, or from any part of 356 | it. (Additional permissions may be written to require their own 357 | removal in certain cases when you modify the work.) You may place 358 | additional permissions on material, added by you to a covered work, 359 | for which you have or can give appropriate copyright permission. 360 | 361 | Notwithstanding any other provision of this License, for material you 362 | add to a covered work, you may (if authorized by the copyright holders of 363 | that material) supplement the terms of this License with terms: 364 | 365 | a) Disclaiming warranty or limiting liability differently from the 366 | terms of sections 15 and 16 of this License; or 367 | 368 | b) Requiring preservation of specified reasonable legal notices or 369 | author attributions in that material or in the Appropriate Legal 370 | Notices displayed by works containing it; or 371 | 372 | c) Prohibiting misrepresentation of the origin of that material, or 373 | requiring that modified versions of such material be marked in 374 | reasonable ways as different from the original version; or 375 | 376 | d) Limiting the use for publicity purposes of names of licensors or 377 | authors of the material; or 378 | 379 | e) Declining to grant rights under trademark law for use of some 380 | trade names, trademarks, or service marks; or 381 | 382 | f) Requiring indemnification of licensors and authors of that 383 | material by anyone who conveys the material (or modified versions of 384 | it) with contractual assumptions of liability to the recipient, for 385 | any liability that these contractual assumptions directly impose on 386 | those licensors and authors. 387 | 388 | All other non-permissive additional terms are considered "further 389 | restrictions" within the meaning of section 10. If the Program as you 390 | received it, or any part of it, contains a notice stating that it is 391 | governed by this License along with a term that is a further 392 | restriction, you may remove that term. If a license document contains 393 | a further restriction but permits relicensing or conveying under this 394 | License, you may add to a covered work material governed by the terms 395 | of that license document, provided that the further restriction does 396 | not survive such relicensing or conveying. 397 | 398 | If you add terms to a covered work in accord with this section, you 399 | must place, in the relevant source files, a statement of the 400 | additional terms that apply to those files, or a notice indicating 401 | where to find the applicable terms. 402 | 403 | Additional terms, permissive or non-permissive, may be stated in the 404 | form of a separately written license, or stated as exceptions; 405 | the above requirements apply either way. 406 | 407 | 8. Termination. 408 | 409 | You may not propagate or modify a covered work except as expressly 410 | provided under this License. Any attempt otherwise to propagate or 411 | modify it is void, and will automatically terminate your rights under 412 | this License (including any patent licenses granted under the third 413 | paragraph of section 11). 414 | 415 | However, if you cease all violation of this License, then your 416 | license from a particular copyright holder is reinstated (a) 417 | provisionally, unless and until the copyright holder explicitly and 418 | finally terminates your license, and (b) permanently, if the copyright 419 | holder fails to notify you of the violation by some reasonable means 420 | prior to 60 days after the cessation. 421 | 422 | Moreover, your license from a particular copyright holder is 423 | reinstated permanently if the copyright holder notifies you of the 424 | violation by some reasonable means, this is the first time you have 425 | received notice of violation of this License (for any work) from that 426 | copyright holder, and you cure the violation prior to 30 days after 427 | your receipt of the notice. 428 | 429 | Termination of your rights under this section does not terminate the 430 | licenses of parties who have received copies or rights from you under 431 | this License. If your rights have been terminated and not permanently 432 | reinstated, you do not qualify to receive new licenses for the same 433 | material under section 10. 434 | 435 | 9. Acceptance Not Required for Having Copies. 436 | 437 | You are not required to accept this License in order to receive or 438 | run a copy of the Program. Ancillary propagation of a covered work 439 | occurring solely as a consequence of using peer-to-peer transmission 440 | to receive a copy likewise does not require acceptance. However, 441 | nothing other than this License grants you permission to propagate or 442 | modify any covered work. These actions infringe copyright if you do 443 | not accept this License. Therefore, by modifying or propagating a 444 | covered work, you indicate your acceptance of this License to do so. 445 | 446 | 10. Automatic Licensing of Downstream Recipients. 447 | 448 | Each time you convey a covered work, the recipient automatically 449 | receives a license from the original licensors, to run, modify and 450 | propagate that work, subject to this License. You are not responsible 451 | for enforcing compliance by third parties with this License. 452 | 453 | An "entity transaction" is a transaction transferring control of an 454 | organization, or substantially all assets of one, or subdividing an 455 | organization, or merging organizations. If propagation of a covered 456 | work results from an entity transaction, each party to that 457 | transaction who receives a copy of the work also receives whatever 458 | licenses to the work the party's predecessor in interest had or could 459 | give under the previous paragraph, plus a right to possession of the 460 | Corresponding Source of the work from the predecessor in interest, if 461 | the predecessor has it or can get it with reasonable efforts. 462 | 463 | You may not impose any further restrictions on the exercise of the 464 | rights granted or affirmed under this License. For example, you may 465 | not impose a license fee, royalty, or other charge for exercise of 466 | rights granted under this License, and you may not initiate litigation 467 | (including a cross-claim or counterclaim in a lawsuit) alleging that 468 | any patent claim is infringed by making, using, selling, offering for 469 | sale, or importing the Program or any portion of it. 470 | 471 | 11. Patents. 472 | 473 | A "contributor" is a copyright holder who authorizes use under this 474 | License of the Program or a work on which the Program is based. The 475 | work thus licensed is called the contributor's "contributor version". 476 | 477 | A contributor's "essential patent claims" are all patent claims 478 | owned or controlled by the contributor, whether already acquired or 479 | hereafter acquired, that would be infringed by some manner, permitted 480 | by this License, of making, using, or selling its contributor version, 481 | but do not include claims that would be infringed only as a 482 | consequence of further modification of the contributor version. For 483 | purposes of this definition, "control" includes the right to grant 484 | patent sublicenses in a manner consistent with the requirements of 485 | this License. 486 | 487 | Each contributor grants you a non-exclusive, worldwide, royalty-free 488 | patent license under the contributor's essential patent claims, to 489 | make, use, sell, offer for sale, import and otherwise run, modify and 490 | propagate the contents of its contributor version. 491 | 492 | In the following three paragraphs, a "patent license" is any express 493 | agreement or commitment, however denominated, not to enforce a patent 494 | (such as an express permission to practice a patent or covenant not to 495 | sue for patent infringement). To "grant" such a patent license to a 496 | party means to make such an agreement or commitment not to enforce a 497 | patent against the party. 498 | 499 | If you convey a covered work, knowingly relying on a patent license, 500 | and the Corresponding Source of the work is not available for anyone 501 | to copy, free of charge and under the terms of this License, through a 502 | publicly available network server or other readily accessible means, 503 | then you must either (1) cause the Corresponding Source to be so 504 | available, or (2) arrange to deprive yourself of the benefit of the 505 | patent license for this particular work, or (3) arrange, in a manner 506 | consistent with the requirements of this License, to extend the patent 507 | license to downstream recipients. "Knowingly relying" means you have 508 | actual knowledge that, but for the patent license, your conveying the 509 | covered work in a country, or your recipient's use of the covered work 510 | in a country, would infringe one or more identifiable patents in that 511 | country that you have reason to believe are valid. 512 | 513 | If, pursuant to or in connection with a single transaction or 514 | arrangement, you convey, or propagate by procuring conveyance of, a 515 | covered work, and grant a patent license to some of the parties 516 | receiving the covered work authorizing them to use, propagate, modify 517 | or convey a specific copy of the covered work, then the patent license 518 | you grant is automatically extended to all recipients of the covered 519 | work and works based on it. 520 | 521 | A patent license is "discriminatory" if it does not include within 522 | the scope of its coverage, prohibits the exercise of, or is 523 | conditioned on the non-exercise of one or more of the rights that are 524 | specifically granted under this License. You may not convey a covered 525 | work if you are a party to an arrangement with a third party that is 526 | in the business of distributing software, under which you make payment 527 | to the third party based on the extent of your activity of conveying 528 | the work, and under which the third party grants, to any of the 529 | parties who would receive the covered work from you, a discriminatory 530 | patent license (a) in connection with copies of the covered work 531 | conveyed by you (or copies made from those copies), or (b) primarily 532 | for and in connection with specific products or compilations that 533 | contain the covered work, unless you entered into that arrangement, 534 | or that patent license was granted, prior to 28 March 2007. 535 | 536 | Nothing in this License shall be construed as excluding or limiting 537 | any implied license or other defenses to infringement that may 538 | otherwise be available to you under applicable patent law. 539 | 540 | 12. No Surrender of Others' Freedom. 541 | 542 | If conditions are imposed on you (whether by court order, agreement or 543 | otherwise) that contradict the conditions of this License, they do not 544 | excuse you from the conditions of this License. If you cannot convey a 545 | covered work so as to satisfy simultaneously your obligations under this 546 | License and any other pertinent obligations, then as a consequence you may 547 | not convey it at all. For example, if you agree to terms that obligate you 548 | to collect a royalty for further conveying from those to whom you convey 549 | the Program, the only way you could satisfy both those terms and this 550 | License would be to refrain entirely from conveying the Program. 551 | 552 | 13. Use with the GNU Affero General Public License. 553 | 554 | Notwithstanding any other provision of this License, you have 555 | permission to link or combine any covered work with a work licensed 556 | under version 3 of the GNU Affero General Public License into a single 557 | combined work, and to convey the resulting work. The terms of this 558 | License will continue to apply to the part which is the covered work, 559 | but the special requirements of the GNU Affero General Public License, 560 | section 13, concerning interaction through a network will apply to the 561 | combination as such. 562 | 563 | 14. Revised Versions of this License. 564 | 565 | The Free Software Foundation may publish revised and/or new versions of 566 | the GNU General Public License from time to time. Such new versions will 567 | be similar in spirit to the present version, but may differ in detail to 568 | address new problems or concerns. 569 | 570 | Each version is given a distinguishing version number. If the 571 | Program specifies that a certain numbered version of the GNU General 572 | Public License "or any later version" applies to it, you have the 573 | option of following the terms and conditions either of that numbered 574 | version or of any later version published by the Free Software 575 | Foundation. If the Program does not specify a version number of the 576 | GNU General Public License, you may choose any version ever published 577 | by the Free Software Foundation. 578 | 579 | If the Program specifies that a proxy can decide which future 580 | versions of the GNU General Public License can be used, that proxy's 581 | public statement of acceptance of a version permanently authorizes you 582 | to choose that version for the Program. 583 | 584 | Later license versions may give you additional or different 585 | permissions. However, no additional obligations are imposed on any 586 | author or copyright holder as a result of your choosing to follow a 587 | later version. 588 | 589 | 15. Disclaimer of Warranty. 590 | 591 | THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY 592 | APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT 593 | HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY 594 | OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, 595 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 596 | PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM 597 | IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF 598 | ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 599 | 600 | 16. Limitation of Liability. 601 | 602 | IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING 603 | WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS 604 | THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY 605 | GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE 606 | USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF 607 | DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD 608 | PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), 609 | EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF 610 | SUCH DAMAGES. 611 | 612 | 17. Interpretation of Sections 15 and 16. 613 | 614 | If the disclaimer of warranty and limitation of liability provided 615 | above cannot be given local legal effect according to their terms, 616 | reviewing courts shall apply local law that most closely approximates 617 | an absolute waiver of all civil liability in connection with the 618 | Program, unless a warranty or assumption of liability accompanies a 619 | copy of the Program in return for a fee. 620 | 621 | END OF TERMS AND CONDITIONS 622 | 623 | How to Apply These Terms to Your New Programs 624 | 625 | If you develop a new program, and you want it to be of the greatest 626 | possible use to the public, the best way to achieve this is to make it 627 | free software which everyone can redistribute and change under these terms. 628 | 629 | To do so, attach the following notices to the program. It is safest 630 | to attach them to the start of each source file to most effectively 631 | state the exclusion of warranty; and each file should have at least 632 | the "copyright" line and a pointer to where the full notice is found. 633 | 634 | 635 | Copyright (C) 636 | 637 | This program is free software: you can redistribute it and/or modify 638 | it under the terms of the GNU General Public License as published by 639 | the Free Software Foundation, either version 3 of the License, or 640 | (at your option) any later version. 641 | 642 | This program is distributed in the hope that it will be useful, 643 | but WITHOUT ANY WARRANTY; without even the implied warranty of 644 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 645 | GNU General Public License for more details. 646 | 647 | You should have received a copy of the GNU General Public License 648 | along with this program. If not, see . 649 | 650 | Also add information on how to contact you by electronic and paper mail. 651 | 652 | If the program does terminal interaction, make it output a short 653 | notice like this when it starts in an interactive mode: 654 | 655 | Copyright (C) 656 | This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. 657 | This is free software, and you are welcome to redistribute it 658 | under certain conditions; type `show c' for details. 659 | 660 | The hypothetical commands `show w' and `show c' should show the appropriate 661 | parts of the General Public License. Of course, your program's commands 662 | might be different; for a GUI interface, you would use an "about box". 663 | 664 | You should also get your employer (if you work as a programmer) or school, 665 | if any, to sign a "copyright disclaimer" for the program, if necessary. 666 | For more information on this, and how to apply and follow the GNU GPL, see 667 | . 668 | 669 | The GNU General Public License does not permit incorporating your program 670 | into proprietary programs. If your program is a subroutine library, you 671 | may consider it more useful to permit linking proprietary applications with 672 | the library. If this is what you want to do, use the GNU Lesser General 673 | Public License instead of this License. But first, please read 674 | . 675 | -------------------------------------------------------------------------------- /Lang/en/en1.txt: -------------------------------------------------------------------------------- 1 | ----- Fullscreen/Immersive Gestures ------ 2 | 3 | Choose your gestures mode 4 | 5 | Vol+ = Fullscreen, Vol- = Immersive 6 | -------------------------------------------------------------------------------- /Lang/en/en2.txt: -------------------------------------------------------------------------------- 1 | Hide pill and keep keyboard height/space? 2 | 3 | Vol+ = Yes , Vol- = No (default) 4 | -------------------------------------------------------------------------------- /Lang/en/en3.txt: -------------------------------------------------------------------------------- 1 | Reduce the size of the keyboard bar? 2 | 3 | Vol+ = Yes , Vol- = No (default) 4 | -------------------------------------------------------------------------------- /Lang/en/en4.txt: -------------------------------------------------------------------------------- 1 | Pick the gesture sensitivity. 2 | 3 | Vol+ = Low (Module Default) , Vol- = High (Android's Default) 4 | 5 | -------------------------------------------------------------------------------- /Lang/en/en5.txt: -------------------------------------------------------------------------------- 1 | Wish to disable the back gesture? 2 | 3 | Vol+ = Yes , Vol- = No 4 | 5 | -------------------------------------------------------------------------------- /Lang/en/en6.txt: -------------------------------------------------------------------------------- 1 | Which side to disable the back gesture? 2 | 3 | Vol+ = Left only (for side menus) , Vol- = Left and Right (for gesture apps) 4 | 5 | -------------------------------------------------------------------------------- /Lang/en/en7.txt: -------------------------------------------------------------------------------- 1 | 2 | To reenable the back gestures 3 | choose no to disabling them 4 | -------------------------------------------------------------------------------- /Lang/en/en8.txt: -------------------------------------------------------------------------------- 1 | Hide keyboard buttons (Back/Switch keyboard)? 2 | 3 | Vol+ = Yes , Vol- = No 4 | -------------------------------------------------------------------------------- /Lang/en/en9.txt: -------------------------------------------------------------------------------- 1 | 2 | Enable Gcam fix? 3 | May cause navbar to be visible 4 | On certain devices 5 | 6 | Vol+ = Yes , Vol- = No 7 | -------------------------------------------------------------------------------- /Lang/es/es1.txt: -------------------------------------------------------------------------------- 1 | ----- Gestos de pantalla completa / Gestos inmersivos ------ 2 | 3 | Elige tu modo de gestos 4 | 5 | Vol + = Pantalla completa, Vol - = Inmersivo 6 | -------------------------------------------------------------------------------- /Lang/es/es2.txt: -------------------------------------------------------------------------------- 1 | Ocultar la "pildora" de navegacion y mantener la altura / el espacio del teclado? 2 | 3 | Vol + = Si, Vol - = No (predeterminado) 4 | -------------------------------------------------------------------------------- /Lang/es/es3.txt: -------------------------------------------------------------------------------- 1 | Reducir la altura de la barra del teclado? 2 | 3 | Vol + = Si, Vol - = No (predeterminado) 4 | -------------------------------------------------------------------------------- /Lang/es/es4.txt: -------------------------------------------------------------------------------- 1 | Elija la sensibilidad del gesto 2 | 3 | Vol + = Bajo (Predeterminado), Vol - = Alto 4 | -------------------------------------------------------------------------------- /Lang/es/es5.txt: -------------------------------------------------------------------------------- 1 | Desea desactivar el gesto de retroceso? 2 | 3 | Vol + = Si, Vol - = No 4 | -------------------------------------------------------------------------------- /Lang/es/es6.txt: -------------------------------------------------------------------------------- 1 | De que lado deshabilitar el gesto de retroceso? 2 | 3 | Vol + = Solo izquierda (para menus laterales), Vol - = Izquierda y derecha 4 | -------------------------------------------------------------------------------- /Lang/es/es7.txt: -------------------------------------------------------------------------------- 1 | 2 | Para volver a habilitar los gestos de retroceso 3 | elige no deshabilitarlos -------------------------------------------------------------------------------- /Lang/es/es8.txt: -------------------------------------------------------------------------------- 1 | Ocultar los botones del teclado (Atrás/Cambiar teclado)? 2 | 3 | Vol + = Si, Vol- = No 4 | -------------------------------------------------------------------------------- /Lang/es/es9.txt: -------------------------------------------------------------------------------- 1 | 2 | Enable Gcam fix? 3 | May cause navbar to be visible 4 | On certain devices 5 | 6 | Vol+ = Yes , Vol- = No 7 | -------------------------------------------------------------------------------- /Lang/it/it1.txt: -------------------------------------------------------------------------------- 1 | 2 | ----- Schermo intero/Gesti immersivi ------ 3 | 4 | Scegli la modalità dei gesti 5 | 6 | Vol+ = Schermo intero, Vol- = Gesti immersivi 7 | -------------------------------------------------------------------------------- /Lang/it/it2.txt: -------------------------------------------------------------------------------- 1 | 2 | Nascondere la pillola e mantenere altezza/spazio della tastiera? 3 | 4 | Vol+ = Si , Vol- = No (predefinito) 5 | -------------------------------------------------------------------------------- /Lang/it/it3.txt: -------------------------------------------------------------------------------- 1 | 2 | Ridurre le dimensioni della barra della tastiera? 3 | 4 | Vol+ = Si , Vol- = No (predefinito) 5 | -------------------------------------------------------------------------------- /Lang/it/it4.txt: -------------------------------------------------------------------------------- 1 | 2 | Imposta la sensibilità del gesto. 3 | 4 | Vol+ = Bassa (Predefinita del modulo) , Vol- = Alta (Predefinita Android) 5 | -------------------------------------------------------------------------------- /Lang/it/it5.txt: -------------------------------------------------------------------------------- 1 | 2 | Desideri disattivare il gesto indietro? 3 | 4 | Vol+ = Si , Vol- = No 5 | -------------------------------------------------------------------------------- /Lang/it/it6.txt: -------------------------------------------------------------------------------- 1 | 2 | Da quale lato disabilitare il gesto indietro? 3 | 4 | Vol+ = Solo a sinistra (per menù laterali) , Vol- = Sinistra e Destra (per le app gestuali) 5 | -------------------------------------------------------------------------------- /Lang/it/it7.txt: -------------------------------------------------------------------------------- 1 | 2 | Per riabilitare i gesti indietro 3 | scegli no per disabilitarli -------------------------------------------------------------------------------- /Lang/it/it8.txt: -------------------------------------------------------------------------------- 1 | 2 | Nascondere i pulsanti della tastiera (Indietro/Cambia tastiera)? 3 | 4 | Vol+ = Si , Vol- = No 5 | -------------------------------------------------------------------------------- /Lang/it/it9.txt: -------------------------------------------------------------------------------- 1 | 2 | Enable Gcam fix? 3 | May cause navbar to be visible 4 | On certain devices 5 | 6 | Vol+ = Yes , Vol- = No 7 | -------------------------------------------------------------------------------- /Lang/pt/pt1.txt: -------------------------------------------------------------------------------- 1 | ----- Gesto Tela cheia / Imersivos ------ 2 | 3 | Escolha o seu modo de gestos 4 | 5 | Vol + = Tela Cheia, Vol- = Imersivo 6 | -------------------------------------------------------------------------------- /Lang/pt/pt2.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Magisk-Modules-Repo/HideNavBar/e6d70759acbcac55a7bc83ed0ee1cc64304a834f/Lang/pt/pt2.txt -------------------------------------------------------------------------------- /Lang/pt/pt3.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Magisk-Modules-Repo/HideNavBar/e6d70759acbcac55a7bc83ed0ee1cc64304a834f/Lang/pt/pt3.txt -------------------------------------------------------------------------------- /Lang/pt/pt4.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Magisk-Modules-Repo/HideNavBar/e6d70759acbcac55a7bc83ed0ee1cc64304a834f/Lang/pt/pt4.txt -------------------------------------------------------------------------------- /Lang/pt/pt5.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Magisk-Modules-Repo/HideNavBar/e6d70759acbcac55a7bc83ed0ee1cc64304a834f/Lang/pt/pt5.txt -------------------------------------------------------------------------------- /Lang/pt/pt6.txt: -------------------------------------------------------------------------------- 1 | De que lado desativar o gesto de voltar? 2 | 3 | Vol + = Esquerda apenas (para menus laterais), Vol- = Esquerda e Direita (para aplicativos de gestos) 4 | -------------------------------------------------------------------------------- /Lang/pt/pt7.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Magisk-Modules-Repo/HideNavBar/e6d70759acbcac55a7bc83ed0ee1cc64304a834f/Lang/pt/pt7.txt -------------------------------------------------------------------------------- /Lang/pt/pt8.txt: -------------------------------------------------------------------------------- 1 | Esconder botoes do teclado (Voltar/Trocar teclado) ? 2 | 3 | Vol+ = Sim , Vol- = Não 4 | -------------------------------------------------------------------------------- /Lang/pt/pt9.txt: -------------------------------------------------------------------------------- 1 | 2 | Enable Gcam fix? 3 | May cause navbar to be visible 4 | On certain devices 5 | 6 | Vol+ = Yes , Vol- = No 7 | -------------------------------------------------------------------------------- /Lang/ru/ru1.txt: -------------------------------------------------------------------------------- 1 | ----- Полноэкранные/Иммерсивные жесты ------ 2 | 3 | Выберите режим жестов 4 | 5 | Vol+ = Полноэкранные, Vol- = Иммерсивные -------------------------------------------------------------------------------- /Lang/ru/ru2.txt: -------------------------------------------------------------------------------- 1 | Скрыть панель жестов и сохранить высоту/пространство клавиатуры? 2 | 3 | Vol+ = Да , Vol- = Нет (по умолчанию) -------------------------------------------------------------------------------- /Lang/ru/ru3.txt: -------------------------------------------------------------------------------- 1 | Уменьшить размер панели клавиатуры? 2 | 3 | Vol+ = Да , Vol- = Нет (по умолчанию) -------------------------------------------------------------------------------- /Lang/ru/ru4.txt: -------------------------------------------------------------------------------- 1 | Выберите чувствительность жестов. 2 | 3 | Vol+ = Низкая (по умолчанию в модуле) , Vol- = Высокая (по умолчанию в Android) 4 | -------------------------------------------------------------------------------- /Lang/ru/ru5.txt: -------------------------------------------------------------------------------- 1 | Хотите отключить жест "Назад"? 2 | 3 | Vol+ = Да , Vol- = Нет 4 | -------------------------------------------------------------------------------- /Lang/ru/ru6.txt: -------------------------------------------------------------------------------- 1 | С какой стороны отключить жест "Назад"? 2 | 3 | Vol+ = Только слева (для боковых меню) , Vol- = Влево и вправо (для приложений, использующих жесты) 4 | -------------------------------------------------------------------------------- /Lang/ru/ru7.txt: -------------------------------------------------------------------------------- 1 | 2 | Если Вы хотите снова включить жест "Назад", 3 | пожалуйста, выберите "Нет" -------------------------------------------------------------------------------- /Lang/ru/ru8.txt: -------------------------------------------------------------------------------- 1 | Скрыть кнопки клавиатуры (Назад/Переключение клавиатуры)? 2 | 3 | Vol+ = Да , Vol- = Нет -------------------------------------------------------------------------------- /Lang/ru/ru9.txt: -------------------------------------------------------------------------------- 1 | 2 | Включить исправление Gcam? 3 | Может привести к отображению панели навигации 4 | 5 | Vol+ = Да , Vol- = Нет 6 | -------------------------------------------------------------------------------- /Lang/zh/zh1.txt: -------------------------------------------------------------------------------- 1 | ----- 全面屏/沉浸式手势 ------ 2 | 3 | 选择你的手势模式 4 | 5 | 音量+ = 全面屏, 音量- = 沉浸式 6 | -------------------------------------------------------------------------------- /Lang/zh/zh2.txt: -------------------------------------------------------------------------------- 1 | 隐藏手势提示线的同时保持键盘高度(底部间距)? 2 | 3 | 音量+ = 是 , 音量- = 否 (默认) 4 | -------------------------------------------------------------------------------- /Lang/zh/zh3.txt: -------------------------------------------------------------------------------- 1 | 减小键盘栏的大小? 2 | 3 | 音量+ = 是 , 音量- = 否 (默认) 4 | -------------------------------------------------------------------------------- /Lang/zh/zh4.txt: -------------------------------------------------------------------------------- 1 | 选择手势灵敏度. 2 | 3 | 音量+ = 低 (模块默认) , 音量- = 高 (安卓系统默认) 4 | 5 | -------------------------------------------------------------------------------- /Lang/zh/zh5.txt: -------------------------------------------------------------------------------- 1 | 是否需要禁用返回手势? 2 | 3 | 音量+ = 是 , 音量- = 否 4 | 5 | -------------------------------------------------------------------------------- /Lang/zh/zh6.txt: -------------------------------------------------------------------------------- 1 | 需要禁用哪一侧的返回手势? 2 | 3 | 音量+ = 仅左侧 (用于侧边菜单) , 音量- = 左侧和右侧 (用于手势应用) 4 | 5 | -------------------------------------------------------------------------------- /Lang/zh/zh7.txt: -------------------------------------------------------------------------------- 1 | 2 | 如果要重新启用返回手势 3 | 请选择“否”以禁用它们 4 | -------------------------------------------------------------------------------- /Lang/zh/zh8.txt: -------------------------------------------------------------------------------- 1 | 隐藏键盘按钮(收起或切换键盘按键)? 2 | 3 | 音量+ = 是 , 音量- = 否 4 | -------------------------------------------------------------------------------- /Lang/zh/zh9.txt: -------------------------------------------------------------------------------- 1 | 2 | Enable Gcam fix? 3 | May cause navbar to be visible 4 | On certain devices 5 | 6 | Vol+ = Yes , Vol- = No 7 | -------------------------------------------------------------------------------- /META-INF/com/google/android/update-binary: -------------------------------------------------------------------------------- 1 | #!/sbin/sh 2 | 3 | ################# 4 | # Initialization 5 | ################# 6 | 7 | umask 022 8 | 9 | # echo before loading util_functions 10 | ui_print() { echo "$1"; } 11 | 12 | require_new_magisk() { 13 | ui_print "*******************************" 14 | ui_print " Please install Magisk v20.0+! " 15 | ui_print "*******************************" 16 | exit 1 17 | } 18 | 19 | ######################### 20 | # Load util_functions.sh 21 | ######################### 22 | 23 | OUTFD=$2 24 | ZIPFILE=$3 25 | 26 | mount /data 2>/dev/null 27 | 28 | [ -f /data/adb/magisk/util_functions.sh ] || require_new_magisk 29 | . /data/adb/magisk/util_functions.sh 30 | [ $MAGISK_VER_CODE -lt 20000 ] && require_new_magisk 31 | 32 | if [ $MAGISK_VER_CODE -ge 20400 ]; then 33 | # New Magisk have complete installation logic within util_functions.sh 34 | install_module 35 | exit 0 36 | fi 37 | 38 | ################# 39 | # Legacy Support 40 | ################# 41 | 42 | TMPDIR=/dev/tmp 43 | PERSISTDIR=/sbin/.magisk/mirror/persist 44 | 45 | is_legacy_script() { 46 | unzip -l "$ZIPFILE" install.sh | grep -q install.sh 47 | return $? 48 | } 49 | 50 | print_modname() { 51 | local len 52 | len=`echo -n $MODNAME | wc -c` 53 | len=$((len + 2)) 54 | local pounds=`printf "%${len}s" | tr ' ' '*'` 55 | ui_print "$pounds" 56 | ui_print " $MODNAME " 57 | ui_print "$pounds" 58 | ui_print "*******************" 59 | ui_print " Powered by Magisk " 60 | ui_print "*******************" 61 | } 62 | 63 | # Override abort as old scripts have some issues 64 | abort() { 65 | ui_print "$1" 66 | $BOOTMODE || recovery_cleanup 67 | [ -n $MODPATH ] && rm -rf $MODPATH 68 | rm -rf $TMPDIR 69 | exit 1 70 | } 71 | 72 | rm -rf $TMPDIR 2>/dev/null 73 | mkdir -p $TMPDIR 74 | 75 | # Preperation for flashable zips 76 | setup_flashable 77 | 78 | # Mount partitions 79 | mount_partitions 80 | 81 | # Detect version and architecture 82 | api_level_arch_detect 83 | 84 | # Setup busybox and binaries 85 | $BOOTMODE && boot_actions || recovery_actions 86 | 87 | ############## 88 | # Preparation 89 | ############## 90 | 91 | # Extract prop file 92 | unzip -o "$ZIPFILE" module.prop -d $TMPDIR >&2 93 | [ ! -f $TMPDIR/module.prop ] && abort "! Unable to extract zip file!" 94 | 95 | $BOOTMODE && MODDIRNAME=modules_update || MODDIRNAME=modules 96 | MODULEROOT=$NVBASE/$MODDIRNAME 97 | MODID=`grep_prop id $TMPDIR/module.prop` 98 | MODPATH=$MODULEROOT/$MODID 99 | MODNAME=`grep_prop name $TMPDIR/module.prop` 100 | 101 | # Create mod paths 102 | rm -rf $MODPATH 2>/dev/null 103 | mkdir -p $MODPATH 104 | 105 | ########## 106 | # Install 107 | ########## 108 | 109 | if is_legacy_script; then 110 | unzip -oj "$ZIPFILE" module.prop install.sh uninstall.sh 'common/*' -d $TMPDIR >&2 111 | 112 | # Load install script 113 | . $TMPDIR/install.sh 114 | 115 | # Callbacks 116 | print_modname 117 | on_install 118 | 119 | # Custom uninstaller 120 | [ -f $TMPDIR/uninstall.sh ] && cp -af $TMPDIR/uninstall.sh $MODPATH/uninstall.sh 121 | 122 | # Skip mount 123 | $SKIPMOUNT && touch $MODPATH/skip_mount 124 | 125 | # prop file 126 | $PROPFILE && cp -af $TMPDIR/system.prop $MODPATH/system.prop 127 | 128 | # Module info 129 | cp -af $TMPDIR/module.prop $MODPATH/module.prop 130 | 131 | # post-fs-data scripts 132 | $POSTFSDATA && cp -af $TMPDIR/post-fs-data.sh $MODPATH/post-fs-data.sh 133 | 134 | # service scripts 135 | $LATESTARTSERVICE && cp -af $TMPDIR/service.sh $MODPATH/service.sh 136 | 137 | ui_print "- Setting permissions" 138 | set_permissions 139 | else 140 | print_modname 141 | 142 | unzip -o "$ZIPFILE" customize.sh -d $MODPATH >&2 143 | 144 | if ! grep -q '^SKIPUNZIP=1$' $MODPATH/customize.sh 2>/dev/null; then 145 | ui_print "- Extracting module files" 146 | unzip -o "$ZIPFILE" -x 'META-INF/*' -d $MODPATH >&2 147 | 148 | # Default permissions 149 | set_perm_recursive $MODPATH 0 0 0755 0644 150 | fi 151 | 152 | # Load customization script 153 | [ -f $MODPATH/customize.sh ] && . $MODPATH/customize.sh 154 | fi 155 | 156 | # Handle replace folders 157 | for TARGET in $REPLACE; do 158 | ui_print "- Replace target: $TARGET" 159 | mktouch $MODPATH$TARGET/.replace 160 | done 161 | 162 | if $BOOTMODE; then 163 | # Update info for Magisk Manager 164 | mktouch $NVBASE/modules/$MODID/update 165 | cp -af $MODPATH/module.prop $NVBASE/modules/$MODID/module.prop 166 | fi 167 | 168 | # Copy over custom sepolicy rules 169 | if [ -f $MODPATH/sepolicy.rule -a -e $PERSISTDIR ]; then 170 | ui_print "- Installing custom sepolicy patch" 171 | PERSISTMOD=$PERSISTDIR/magisk/$MODID 172 | mkdir -p $PERSISTMOD 173 | cp -af $MODPATH/sepolicy.rule $PERSISTMOD/sepolicy.rule 174 | fi 175 | 176 | # Remove stuffs that don't belong to modules 177 | rm -rf \ 178 | $MODPATH/system/placeholder $MODPATH/customize.sh \ 179 | $MODPATH/README.md $MODPATH/.git* 2>/dev/null 180 | 181 | ############# 182 | # Finalizing 183 | ############# 184 | 185 | cd / 186 | $BOOTMODE || recovery_cleanup 187 | rm -rf $TMPDIR 188 | 189 | ui_print "- Done" 190 | exit 0 191 | -------------------------------------------------------------------------------- /META-INF/com/google/android/updater-script: -------------------------------------------------------------------------------- 1 | #MAGISK 2 | -------------------------------------------------------------------------------- /Mods/DBGQ/system.prop: -------------------------------------------------------------------------------- 1 | qemu.hw.mainkeys=1 2 | -------------------------------------------------------------------------------- /Mods/HKB/HKB.apk: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Magisk-Modules-Repo/HideNavBar/e6d70759acbcac55a7bc83ed0ee1cc64304a834f/Mods/HKB/HKB.apk -------------------------------------------------------------------------------- /Mods/HP/pillhide.apk: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Magisk-Modules-Repo/HideNavBar/e6d70759acbcac55a7bc83ed0ee1cc64304a834f/Mods/HP/pillhide.apk -------------------------------------------------------------------------------- /Mods/MIUI/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /Mods/Q/dummy: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /Mods/QS/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /Mods/QS/res/values/bools.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | true 4 | true 5 | false 6 | true 7 | 8 | -------------------------------------------------------------------------------- /Mods/QS/res/values/dimens.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 24.0dp 4 | 0.1dp 5 | 0.2dp 6 | 0.3dip 7 | 0.3dip 8 | 0.3dp 9 | 0.0dp 10 | 0.1dp 11 | 12 | -------------------------------------------------------------------------------- /Mods/QS/res/values/integers.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 2 4 | 2 5 | 6 | -------------------------------------------------------------------------------- /Mods/QS/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | Gestural Navigation Bar 4 | 5 | -------------------------------------------------------------------------------- /Mods/Qtmp/dummy: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /OC.md: -------------------------------------------------------------------------------- 1 | ### v8.4 2 | - Fixed an issue that was causing hide pill to be installed regardless of user preference 3 | - Cleaner install code (again) 4 | ### v8.3 5 | - Remove Android 11 specific overlays (no longer necessary as the standard ones work just fine on 11) 6 | - Clean up install code even more 7 | ### v8.2 8 | - Fix immersive sensitivity options 9 | - Clean up installer code significantly 10 | ### v8.1 11 | - Fix for Immersive+default sensitivity not getting properly installed 12 | ### v8.0 13 | - Allow changing gesture sensitivity (for users who may prefer Android's default gesture sensitivity) 14 | ### v7.2 15 | - Fix fullscreen gestures installation (apologies for the inconvenience) 16 | ### v7.1 17 | - Added new options during install 18 | - Small keyboard bar (for immersive mode): Allows you to have less spacing underneath the keyboard 19 | - Hide Pill (for immersive mode): Allows you to have a near fullscreen experience while still keeping the spacing underneath the keyboard 20 | ### v7.0 21 | - Switch to the MMT-EX template and added immersive gestures by [samchugit](https://github.com/samchugit/Immersive_Gestural_Nav_Bar) as an option 22 | ### v6.7 23 | - Fix gesture option disappearing on later Android 11 builds 24 | ### v6.6 25 | - Hotfix for Android 11 beta 26 | ### v6.5 27 | - Lowered gesture area to 18dp to reduce conflicts with apps 28 | ### v6.4 29 | - Fix Android 11 support 30 | ### v6.2 31 | - Add support for Android 11/R (untested as Magisk isn't avaliable for Android R yet) 32 | ### v6.1 33 | - Block installation on MIUI as it's incompatible with the module 34 | ### v6.0 35 | - Added support for ROMs that use /vendor/overlays for their gesture overlays 36 | ### v5.0 37 | - Update to the latest Magisk module template and some minor clean ups in the code 38 | ### v4.0 39 | - Hopefully fixed the issue that made so uninstalling the module made gestures completely unavailable on some ROMs 40 | ### v3.0 41 | - Reduced conflict with some apps (like Gboard) by slightly lowering the gesture trigger area 42 | ### v2.0 43 | - Hide gesture bar correctly in landscape 44 | ### v1.0 45 | - Initial release 46 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Fullscreen/Immersive Gesture Tweaks for Android 10-13 2 | 3 | THIS REPO HAS BEEN MOSTLY DISCONTINUED AS OF MAGISK'S DISABLING OF THE REPO FEATURE, TO ALWAYS DOWNLOAD MY UPDATED MODULE USE [FOX MODULE MANAGER](https://github.com/Fox2Code/FoxMagiskModuleManager/releases) AS MY MODULE IS NOW BEING DEVELOPED ON THE [ALT-REPO](https://github.com/Magisk-Modules-Alt-Repo/HideNavBar) 4 | 5 | ![](https://i.imgur.com/vcXAreJ.png) 6 | 7 | This Magisk Module lets you tweak Android 10-13's gestures. 8 | 9 | ## Requirements 10 | - Android 10-13 11 | - Magisk 20+ 12 | 13 | ## Installation 14 | 1. Flash the module 15 | 2. Select the desired options on the volume selector 16 | 3. Reboot 17 | 4. Enjoy! 18 | 19 | ## Terminal Setup 20 | Run on a terminal app the following command 21 | su -c hn 22 | 23 | ## Disclaimer 24 | - Any option not working is due to incompatibility with your current ROM (there's little i can do about it) 25 | - GSI compabitility isn't guaranteed due to Magisk's inconsistent GSI support 26 | - For issues related to GCam after installing the module you may use the terminal setup tool to increase the navbar size slightly to workaround the issue 27 | - Automatic navbar coloring doesn't work on Android 11+ 28 | 29 | ## Links 30 | - [GitHub](https://github.com/Magisk-Modules-Repo/HideNavBar) 31 | - [Telegram Channel](https://t.me/danmgk) 32 | 33 | ## Options 34 | 35 | - Android Default 36 | 37 |

38 | 39 |

40 | 41 | - Fullscreen 42 | 43 |

44 | 45 |

46 | 47 | - Immersive (With the Pill + Default Keyboard Spacing) 48 | 49 |

50 | 51 |

52 | 53 |

54 | 55 |

56 | 57 | - Immersive (With the Pill + Small Keyboard Spacing) 58 | 59 |

60 | 61 |

62 | 63 | - Immersive (Without the Pill + Default Keyboard Spacing) 64 | 65 |

66 | 67 |

68 | 69 |

70 | 71 |

72 | 73 | - Immersive (Without the Pill + Small Spacing under the Keyboard) 74 | 75 |

76 | 77 |

78 | 79 | 80 | - Additionally back gestures can be disabled on Android 11-12 for either left side only (to access side menus on apps) or both sides (if one wishes to remap the back gestures with other apps) 81 | 82 | ### Translation 83 | If you wish to have the installer translated to your language send me a text file containing all lines (inside ui_print in common/install.sh) either on Github or my Email, omit special symbols such as á,ã 84 | 85 | ## Special Thanks 86 | - [skittles9823](https://github.com/skittles9823) for his help with the initial install script 87 | 88 | - [Nebulart](https://t.me/nebulart) for the banner 89 | 90 | - [Samchugit](https://github.com/samchugit) for making the original immersive gestures module 91 | 92 | - [Zackptg5](https://github.com/Zackptg5) for the MMT-Ex template 93 | 94 | - [Topjohnwu](https://github.com/topjohnwu) for making Magisk 95 | 96 | - [RKBDI](https://t.me/RKBDI) for the Rboard module 97 | 98 | - [Gnonymous7](https://github.com/Gnonymous7) for some general inspiration, if you want more visual tweaks make sure to check out their module [G-VisualMod](https://github.com/Magisk-Modules-Repo/G-VisualMod) 99 | 100 | - All Custom ROMs who made my module an official feature in their ROM (AOSIP, Havoc & etc) 101 | 102 | ## Changelog 103 | ### v21.0 104 | - Rewrite installer for Android 12+ to use fabricated overlays for higher compatibility 105 | - Added Gcam lag fix as install option (12+ atm) 106 | 107 | Translations needed for the Gcam fix option 108 | 109 | ### v20.0-hotfix 110 | - Fix terminal setup tool 111 | ### v20.0 112 | - Fix Android 10 support (which was broken since v14.0) 113 | ### v19.0 114 | - Reworked Terminal config tool (su -c hn), should avoid issues related to zipsigner 115 | - Properly support Rboard Theme Manager v3 to avoid conflicts 116 | ### v18.0 117 | - Added Samsung A12 support 118 | ### v17.0 119 | - Proper MIUI detection/install logic (should provide compatibility to MIUI based on Android 10, not tested) 120 | ### v16.4 121 | - Removed unnecessary waiting during module install 122 | ### v16.3 123 | - Added Fox Manager Extension support (support link shortcut when installing the module) 124 | - Try and improve the volume selector delay a bit 125 | ### v16.1 126 | - Fix the Terminal Config tool 127 | ### v16.0 128 | - Proper MIUI 13 support 129 | ### v15.0 130 | - Added MIUI support (confirmed working on MIUI 13) 131 | - Fixed Terminal Script not working on devices with pseudo/fake xbin folders 132 | ### v14.0 133 | - Fixed miscelaneous error messages 134 | - Fixed Terminal config tool on Android 13 (Google's fault this time lol) 135 | - Tablet support (it works inconsisntently) 136 | ### v13.0 137 | - Full AAPT rewrite 138 | - Added terminal config tool for changing each navbar parameter 139 | (To use it run the following on a terminal app su -c hn) 140 | ### v12.0 141 | - Fixed the Gcam lag when switching modes 142 | ### v11.0 143 | - Preemptive Android 13 support (untested) 144 | ### v10.0 145 | - Added Support for Android 12L, and thank you all very much for your support over these 2 years of development 146 | ### v9.9 147 | - Allow hiding the buttons underneath the keyboard in Immersive mode 148 | ### v9.8 149 | - Fix Rboard checking for the keyboard spacing removal feature (apologies to RKBDI for the troubles) 150 | ### v9.7 151 | - Automatically removes conflicting overlays during install (AKA some theme modules that include gesture overlays for no reason at all) 152 | ### v9.6 153 | - More reliable language detection (should prevent issues where the installer shows no text) 154 | ### v9.5 155 | - Added support for translations in the installer (currently included languages are English, Portuguese and Spanish) 156 | ### v9.4 157 | - Allow disabling back gesture also on Android 10 (due to way A10 handles the back gesture it's only possible to disable them completely and on fullscreen mode only, if you have Xposed on A10 and wishes to disable only the left back gesture use this Xposed module https://github.com/kuba2k2/NoLeftBackGesture/releases/tag/v1.0) 158 | ### v9.3-hotfix 159 | - Fix install (sorry for the inconvenience) 160 | ### v9.3 161 | - Updated Volume selector (from MMT-EX), should resolve install issues on some devices 162 | - Increased the timeout to 10s to give users time to read the options 163 | ### v9.2 164 | - Reenable back gestures on NO (on the whether to disable back gestures or not) option 165 | ### v9.1 166 | - Reenable back gesture on uninstall (if user is unable to change the device's back gesture sensitivy from settings) 167 | ### v9.0 168 | - Allow disabling back gesture on A11-12 (Left only for side menus and Left & Right for gesture apps) 169 | ### v8.8 170 | - Update MAXAPI to 31 to support the eventual stable A12 release 171 | ### v8.7 172 | - Update Volume selector 173 | - Revised install logic 174 | - Disable the Gboard spacing some Android 11 ROMs were using by default (users are still free to change/reenable the spacing with Rboard as I've made sure my code won't overlap with it) 175 | ### v8.6 176 | - Fix and go back to using the new install logic on Android 11 177 | ### v8.5 178 | - Revert to old install logic on Android 11 (attempts to bug fix module not installing correctly on some devices) 179 | 180 | 181 | (if you notice any issues on Android 11 due to the new install logic report to me immediatelly) 182 | 183 | 184 | For older changelogs check [here](https://github.com/Magisk-Modules-Alt-Repo/HideNavBar/blob/master/OC.md) 185 | -------------------------------------------------------------------------------- /common/addon/Volume-Key-Selector/README.md: -------------------------------------------------------------------------------- 1 | # Volume Key Selector - Addon that allows the use of the volume keys to select option in the installer 2 | 3 | ## Instructions: 4 | * Call chooseport whenever you want to call to use volume key check. The function returns true if user selected vol up and false if vol down. It'll wait 3 seconds for input by default 5 | Ex: 6 | ``` 7 | if chooseport; then 8 | echo "true" 9 | else 10 | echo "false" 11 | fi 12 | ``` 13 | * You can customize how many settings you want to wait for input. For example: 14 | * ``` 15 | if chooseport 5; then 16 | echo "true" 17 | fi 18 | ``` 19 | Will wait 5 seconds rather than the default of 3 20 | * If you want to use the bixby button on samsung galaxy devices, [check out this post here](https://forum.xda-developers.com/showpost.php?p=77908805&postcount=16) and modify the install.sh functions accordingly 21 | 22 | ## Notes: 23 | * Each volume key selector method will timeout after 3 seconds in the event of incompatibility or error 24 | 25 | ## Included Binaries/Credits: 26 | * [keycheck binary](https://github.com/sonyxperiadev/device-sony-common-init/tree/master/keycheck) compiled by me [here](https://github.com/Zackptg5/Keycheck) 27 | -------------------------------------------------------------------------------- /common/addon/Volume-Key-Selector/a: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /common/addon/Volume-Key-Selector/install.sh: -------------------------------------------------------------------------------- 1 | # External Tools 2 | chmod -R 0755 $MODPATH/common/addon/Volume-Key-Selector/tools 3 | 4 | chooseport_legacy() { 5 | # Keycheck binary by someone755 @Github, idea for code below by Zappo @xda-developers 6 | # Calling it first time detects previous input. Calling it second time will do what we want 7 | [ "$1" ] && local delay=$1 || local delay=19 8 | local error=false 9 | while true; do 10 | timeout 0 $MODPATH/common/addon/Volume-Key-Selector/tools/$ARCH32/keycheck 11 | timeout $delay $MODPATH/common/addon/Volume-Key-Selector/tools/$ARCH32/keycheck 12 | local sel=$? 13 | if [ $sel -eq 42 ]; then 14 | return 0 15 | elif [ $sel -eq 41 ]; then 16 | return 1 17 | elif $error; then 18 | abort "Volume key not detected!" 19 | else 20 | error=true 21 | echo "Volume key not detected. Try again" 22 | fi 23 | done 24 | } 25 | 26 | chooseport() { 27 | # Original idea by chainfire and ianmacd @xda-developers 28 | [ "$1" ] && local delay=$1 || local delay=19 29 | local error=false 30 | while true; do 31 | local count=0 32 | while true; do 33 | timeout $delay /system/bin/getevent -lqc 1 2>&1 > $TMPDIR/events & 34 | sleep 0.5; count=$((count + 1)) 35 | if (`grep -q 'KEY_VOLUMEUP *DOWN' $TMPDIR/events`); then 36 | return 0 37 | elif (`grep -q 'KEY_VOLUMEDOWN *DOWN' $TMPDIR/events`); then 38 | return 1 39 | fi 40 | [ $count -gt 6 ] && break 41 | done 42 | if $error; then 43 | # abort "Volume key not detected!" 44 | echo "Volume key not detected. Trying keycheck method" 45 | export chooseport=chooseport_legacy VKSEL=chooseport_legacy 46 | chooseport_legacy $delay 47 | return $? 48 | else 49 | error=true 50 | echo "Volume key not detected. Try again" 51 | fi 52 | done 53 | } 54 | 55 | # Keep old variable from previous versions of this 56 | VKSEL=chooseport 57 | -------------------------------------------------------------------------------- /common/addon/Volume-Key-Selector/tools/arm/keycheck: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Magisk-Modules-Repo/HideNavBar/e6d70759acbcac55a7bc83ed0ee1cc64304a834f/common/addon/Volume-Key-Selector/tools/arm/keycheck -------------------------------------------------------------------------------- /common/addon/Volume-Key-Selector/tools/x86/keycheck: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Magisk-Modules-Repo/HideNavBar/e6d70759acbcac55a7bc83ed0ee1cc64304a834f/common/addon/Volume-Key-Selector/tools/x86/keycheck -------------------------------------------------------------------------------- /common/functions.sh: -------------------------------------------------------------------------------- 1 | ########################################################################################## 2 | # 3 | # MMT Extended Utility Functions 4 | # 5 | ########################################################################################## 6 | 7 | abort() { 8 | ui_print "$1" 9 | rm -rf $MODPATH 2>/dev/null 10 | cleanup 11 | rm -rf $TMPDIR 2>/dev/null 12 | exit 1 13 | } 14 | 15 | cleanup() { 16 | rm -rf $MODPATH/common 2>/dev/null 17 | } 18 | 19 | device_check() { 20 | local opt=`getopt -o dm -- "$@"` type=device 21 | eval set -- "$opt" 22 | while true; do 23 | case "$1" in 24 | -d) local type=device; shift;; 25 | -m) local type=manufacturer; shift;; 26 | --) shift; break;; 27 | *) abort "Invalid device_check argument $1! Aborting!";; 28 | esac 29 | done 30 | local prop=$(echo "$1" | tr '[:upper:]' '[:lower:]') 31 | for i in /system /vendor /odm /product; do 32 | if [ -f $i/build.prop ]; then 33 | for j in "ro.product.$type" "ro.build.$type" "ro.product.vendor.$type" "ro.vendor.product.$type"; do 34 | [ "$(sed -n "s/^$j=//p" $i/build.prop 2>/dev/null | head -n 1 | tr '[:upper:]' '[:lower:]')" == "$prop" ] && return 0 35 | done 36 | [ "$type" == "device" ] && [ "$(sed -n "s/^"ro.build.product"=//p" $i/build.prop 2>/dev/null | head -n 1 | tr '[:upper:]' '[:lower:]')" == "$prop" ] && return 0 37 | fi 38 | done 39 | return 1 40 | } 41 | 42 | cp_ch() { 43 | local opt=`getopt -o nr -- "$@"` BAK=true UBAK=true FOL=false 44 | eval set -- "$opt" 45 | while true; do 46 | case "$1" in 47 | -n) UBAK=false; shift;; 48 | -r) FOL=true; shift;; 49 | --) shift; break;; 50 | *) abort "Invalid cp_ch argument $1! Aborting!";; 51 | esac 52 | done 53 | local SRC="$1" DEST="$2" OFILES="$1" 54 | $FOL && local OFILES=$(find $SRC -type f 2>/dev/null) 55 | [ -z $3 ] && PERM=0644 || PERM=$3 56 | case "$DEST" in 57 | $TMPDIR/*|$MODULEROOT/*|$NVBASE/modules/$MODID/*) BAK=false;; 58 | esac 59 | for OFILE in ${OFILES}; do 60 | if $FOL; then 61 | if [ "$(basename $SRC)" == "$(basename $DEST)" ]; then 62 | local FILE=$(echo $OFILE | sed "s|$SRC|$DEST|") 63 | else 64 | local FILE=$(echo $OFILE | sed "s|$SRC|$DEST/$(basename $SRC)|") 65 | fi 66 | else 67 | [ -d "$DEST" ] && local FILE="$DEST/$(basename $SRC)" || local FILE="$DEST" 68 | fi 69 | if $BAK && $UBAK; then 70 | [ ! "$(grep "$FILE$" $INFO 2>/dev/null)" ] && echo "$FILE" >> $INFO 71 | [ -f "$FILE" -a ! -f "$FILE~" ] && { mv -f $FILE $FILE~; echo "$FILE~" >> $INFO; } 72 | elif $BAK; then 73 | [ ! "$(grep "$FILE$" $INFO 2>/dev/null)" ] && echo "$FILE" >> $INFO 74 | fi 75 | install -D -m $PERM "$OFILE" "$FILE" 76 | done 77 | } 78 | 79 | install_script() { 80 | case "$1" in 81 | -l) shift; local INPATH=$NVBASE/service.d;; 82 | -p) shift; local INPATH=$NVBASE/post-fs-data.d;; 83 | *) local INPATH=$NVBASE/service.d;; 84 | esac 85 | [ "$(grep "#!/system/bin/sh" $1)" ] || sed -i "1i #!/system/bin/sh" $1 86 | local i; for i in "MODPATH" "LIBDIR" "MODID" "INFO" "MODDIR"; do 87 | case $i in 88 | "MODPATH") sed -i "1a $i=$NVBASE/modules/$MODID" $1;; 89 | "MODDIR") sed -i "1a $i=\${0%/*}" $1;; 90 | *) sed -i "1a $i=$(eval echo \$$i)" $1;; 91 | esac 92 | done 93 | [ "$1" == "$MODPATH/uninstall.sh" ] && return 0 94 | case $(basename $1) in 95 | post-fs-data.sh|service.sh) ;; 96 | *) cp_ch -n $1 $INPATH/$(basename $1) 0755;; 97 | esac 98 | } 99 | 100 | prop_process() { 101 | sed -i -e "/^#/d" -e "/^ *$/d" $1 102 | [ -f $MODPATH/system.prop ] || mktouch $MODPATH/system.prop 103 | while read LINE; do 104 | echo "$LINE" >> $MODPATH/system.prop 105 | done < $1 106 | } 107 | 108 | # Credits 109 | ui_print "**************************************" 110 | ui_print "* MMT Extended by Zackptg5 @ XDA *" 111 | ui_print "**************************************" 112 | ui_print " " 113 | 114 | # Check for min/max api version 115 | [ -z $MINAPI ] || { [ $API -lt $MINAPI ] && abort "! Your system API of $API is less than the minimum api of $MINAPI! Aborting!"; } 116 | [ -z $MAXAPI ] || { [ $API -gt $MAXAPI ] && abort "! Your system API of $API is greater than the maximum api of $MAXAPI! Aborting!"; } 117 | 118 | # Set variables 119 | [ $API -lt 26 ] && DYNLIB=false 120 | [ -z $DYNLIB ] && DYNLIB=false 121 | [ -z $DEBUG ] && DEBUG=false 122 | INFO=$NVBASE/modules/.$MODID-files 123 | ORIGDIR="$MAGISKTMP/mirror" 124 | if $DYNLIB; then 125 | LIBPATCH="\/vendor" 126 | LIBDIR=/system/vendor 127 | else 128 | LIBPATCH="\/system" 129 | LIBDIR=/system 130 | fi 131 | if ! $BOOTMODE; then 132 | ui_print "- Only uninstall is supported in recovery" 133 | ui_print " Uninstalling!" 134 | touch $MODPATH/remove 135 | [ -s $INFO ] && install_script $MODPATH/uninstall.sh || rm -f $INFO $MODPATH/uninstall.sh 136 | recovery_cleanup 137 | cleanup 138 | rm -rf $NVBASE/modules_update/$MODID $TMPDIR 2>/dev/null 139 | exit 0 140 | fi 141 | 142 | # Debug 143 | if $DEBUG; then 144 | ui_print "- Debug mode" 145 | ui_print " Module install log will include debug info" 146 | ui_print " Be sure to save it after module install" 147 | set -x 148 | fi 149 | 150 | # Extract files 151 | ui_print "- Extracting module files" 152 | unzip -o "$ZIPFILE" -x 'META-INF/*' 'common/functions.sh' -d $MODPATH >&2 153 | [ -f "$MODPATH/common/addon.tar.xz" ] && tar -xf $MODPATH/common/addon.tar.xz -C $MODPATH/common 2>/dev/null 154 | 155 | # Run addons 156 | if [ "$(ls -A $MODPATH/common/addon/*/install.sh 2>/dev/null)" ]; then 157 | ui_print " "; ui_print "- Running Addons -" 158 | for i in $MODPATH/common/addon/*/install.sh; do 159 | ui_print " Running $(echo $i | sed -r "s|$MODPATH/common/addon/(.*)/install.sh|\1|")..." 160 | . $i 161 | done 162 | fi 163 | 164 | # Remove files outside of module directory 165 | ui_print "- Removing old files" 166 | 167 | if [ -f $INFO ]; then 168 | while read LINE; do 169 | if [ "$(echo -n $LINE | tail -c 1)" == "~" ]; then 170 | continue 171 | elif [ -f "$LINE~" ]; then 172 | mv -f $LINE~ $LINE 173 | else 174 | rm -f $LINE 175 | while true; do 176 | LINE=$(dirname $LINE) 177 | [ "$(ls -A $LINE 2>/dev/null)" ] && break 1 || rm -rf $LINE 178 | done 179 | fi 180 | done < $INFO 181 | rm -f $INFO 182 | fi 183 | 184 | ### Install 185 | ui_print "- Installing" 186 | 187 | [ -f "$MODPATH/common/install.sh" ] && . $MODPATH/common/install.sh 188 | 189 | #ui_print " Installing for $ARCH SDK $API device..." 190 | # Remove comments from files and place them, add blank line to end if not already present 191 | for i in $(find $MODPATH -type f -name "*.sh" -o -name "*.prop" -o -name "*.rule"); do 192 | [ -f $i ] && { sed -i -e "/^#/d" -e "/^ *$/d" $i; [ "$(tail -1 $i)" ] && echo "" >> $i; } || continue 193 | case $i in 194 | "$MODPATH/service.sh") install_script -l $i;; 195 | "$MODPATH/post-fs-data.sh") install_script -p $i;; 196 | "$MODPATH/uninstall.sh") if [ -s $INFO ] || [ "$(head -n1 $MODPATH/uninstall.sh)" != "# Don't modify anything after this" ]; then 197 | install_script $MODPATH/uninstall.sh 198 | else 199 | rm -f $INFO $MODPATH/uninstall.sh 200 | fi;; 201 | esac 202 | done 203 | 204 | $IS64BIT || for i in $(find $MODPATH/system -type d -name "lib64"); do rm -rf $i 2>/dev/null; done 205 | [ -d "/system/priv-app" ] || mv -f $MODPATH/system/priv-app $MODPATH/system/app 2>/dev/null 206 | [ -d "/system/xbin" ] || mv -f $MODPATH/system/xbin $MODPATH/system/bin 2>/dev/null 207 | if $DYNLIB; then 208 | for FILE in $(find $MODPATH/system/lib* -type f 2>/dev/null | sed "s|$MODPATH/system/||"); do 209 | [ -s $MODPATH/system/$FILE ] || continue 210 | case $FILE in 211 | lib*/modules/*) continue;; 212 | esac 213 | mkdir -p $(dirname $MODPATH/system/vendor/$FILE) 214 | mv -f $MODPATH/system/$FILE $MODPATH/system/vendor/$FILE 215 | [ "$(ls -A `dirname $MODPATH/system/$FILE`)" ] || rm -rf `dirname $MODPATH/system/$FILE` 216 | done 217 | # Delete empty lib folders (busybox find doesn't have this capability) 218 | toybox find $MODPATH/system/lib* -type d -empty -delete >/dev/null 2>&1 219 | fi 220 | 221 | # Set permissions 222 | #ui_print " " 223 | #ui_print "- Setting Permissions" 224 | set_perm_recursive $MODPATH 0 0 0755 0644 225 | if [ -d $MODPATH/system/vendor ]; then 226 | set_perm_recursive $MODPATH/system/vendor 0 0 0755 0644 u:object_r:vendor_file:s0 227 | [ -d $MODPATH/system/vendor/app ] && set_perm_recursive $MODPATH/system/vendor/app 0 0 0755 0644 u:object_r:vendor_app_file:s0 228 | [ -d $MODPATH/system/vendor/etc ] && set_perm_recursive $MODPATH/system/vendor/etc 0 0 0755 0644 u:object_r:vendor_configs_file:s0 229 | [ -d $MODPATH/system/vendor/overlay ] && set_perm_recursive $MODPATH/system/vendor/overlay 0 0 0755 0644 u:object_r:vendor_overlay_file:s0 230 | for FILE in $(find $MODPATH/system/vendor -type f -name *".apk"); do 231 | [ -f $FILE ] && chcon u:object_r:vendor_app_file:s0 $FILE 232 | done 233 | fi 234 | set_permissions 235 | 236 | # Complete install 237 | cleanup 238 | -------------------------------------------------------------------------------- /common/install.sh: -------------------------------------------------------------------------------- 1 | ########################################################################################## 2 | # Custom Logic 3 | ########################################################################################## 4 | 5 | #Detect and use compatible AAPT 6 | chmod +x "$MODPATH"/tools/* 7 | [ "$($MODPATH/tools/aapt v)" ] && AAPT=aapt 8 | [ "$($MODPATH/tools/aapt64 v)" ] && AAPT=aapt64 9 | cp -af "$MODPATH"/tools/$AAPT "$MODPATH"/aapt 10 | cp -rf "$MODPATH"/Mods/QS/* "$MODPATH"/Mods/Qtmp/ 11 | mkdir -p "$MODPATH"/Mods/Q/NavigationBarModeGestural/ 12 | mkdir -p "$MODPATH"/Mods/Qtmp/ 13 | cp -rf "$MODPATH"/tools/service.sh "$MODPATH" 14 | 15 | if [ -d /system/xbin/ ] && [ ! -f /system/xbin/empty ] ; then 16 | mkdir -p "$MODPATH"/system/xbin/ 17 | cp -rf "$MODPATH"/tools/hn "$MODPATH"/system/xbin/ 18 | cp -rf "$MODPATH"/tools/hnr "$MODPATH"/system/xbin/ 19 | else 20 | mkdir -p "$MODPATH"/system/bin/ 21 | cp -rf "$MODPATH"/tools/hn "$MODPATH"/system/bin/ 22 | cp -rf "$MODPATH"/tools/hnr "$MODPATH"/system/bin/ 23 | fi 24 | 25 | #Find and delete conflicting overlays 26 | find /data/adb/modules -type d -not -path "*HideNavBar/system*" -iname "*navigationbarmodegestural*" -exec rm -rf {} \; 2>/dev/null 27 | 28 | #Detect system language for translation 29 | LANG=$(settings get system system_locales) 30 | LANGS=$(echo "${LANG:0:2}" ) 31 | if [ -f "$MODPATH"/Lang/"$LANGS"/"$LANGS"1.txt ]; then 32 | : 33 | else 34 | LANGS=en 35 | fi 36 | 37 | LNG="$MODPATH"/Lang/"$LANGS"/"$LANGS" 38 | 39 | #Standard volume selector stuff but with translations 40 | #Fullscreen or immersive selection 41 | cat "$LNG"1.txt 42 | if $VKSEL; then 43 | BH=0.0 44 | FBH=0 45 | FFH=0 46 | FH=0.0 47 | SS=true 48 | VAR3=a 49 | VAR4=a 50 | else 51 | FH=48.0 52 | FBH=0 53 | FFH=9500 54 | BH=0.0 55 | SS=true 56 | fi 57 | 58 | #Hide pill 59 | if [ "$FH" = 48.0 ] ; then 60 | cat "$LNG"2.txt 61 | if $VKSEL; then 62 | VAR3=HP 63 | HD=true 64 | else 65 | VAR3=a 66 | fi 67 | fi 68 | 69 | if [ "$API" -le 30 ] ; then 70 | if [ "$FH" = 48.0 ] ; then 71 | cat "$LNG"8.txt 72 | if $VKSEL; then 73 | VAR4=HKB 74 | else 75 | VAR4=a 76 | fi 77 | fi 78 | else 79 | : 80 | fi 81 | 82 | #Small keyboard bar 83 | if [ "$FH" = 48.0 ] ; then 84 | cat "$LNG"3.txt 85 | if $VKSEL; then 86 | FH=16.0 87 | FFH=4000 88 | else 89 | : 90 | fi 91 | fi 92 | 93 | #Gesture sensitivity 94 | if [ "$SS" = true ] ; then 95 | cat "$LNG"4.txt 96 | if $VKSEL; then 97 | GS=18.0 98 | FGS=4000 99 | else 100 | GS=32.0 101 | FGS=9000 102 | fi 103 | fi 104 | 105 | if [ "$SS" = true ] ; then 106 | cat "$LNG"9.txt 107 | if $VKSEL; then 108 | if [ "$FFH" = 0 ] ; then 109 | FBH=300 110 | FFH=300 111 | else 112 | FBH=300 113 | fi 114 | else 115 | : 116 | fi 117 | fi 118 | 119 | #Disable back gesture on Q 120 | if [ "$API" -eq 29 ] && [ "$FH" = 0.0 ] ; then 121 | cat "$LNG"5.txt 122 | if $VKSEL; then 123 | cp -rf "$MODPATH"/Mods/DBGQ/* "$MODPATH" 124 | else 125 | : 126 | fi 127 | fi 128 | 129 | #Disable back gesture on R+ 130 | #Reenable back gesture if no is selected 131 | if [ "$API" -ge 30 ] ; then 132 | cat "$LNG"5.txt 133 | if $VKSEL; then 134 | DBG=true 135 | else 136 | DBG=false 137 | settings delete secure back_gesture_inset_scale_left &>/dev/null 138 | settings delete secure back_gesture_inset_scale_right &>/dev/null 139 | fi 140 | fi 141 | 142 | #Left or both sides 143 | if [ "$DBG" = true ] ; then 144 | cat "$LNG"6.txt 145 | if $VKSEL; then 146 | settings put secure back_gesture_inset_scale_left -1 &>/dev/null 147 | else 148 | settings put secure back_gesture_inset_scale_left -1 &>/dev/null 149 | settings put secure back_gesture_inset_scale_right -1 &>/dev/null 150 | fi 151 | fi 152 | 153 | #Back gesture warning 154 | if [ "$DBG" = true ] ; then 155 | cat "$LNG"7.txt 156 | fi 157 | 158 | #Write to overlay resources 159 | RES="$MODPATH"/Mods/Qtmp/res/values/dimens.xml 160 | FOL="$MODPATH"/service.sh 161 | 162 | if [ "$API" -ge 31 ] ; then 163 | sed -i s/03/"$FBH"/g "$FOL" 164 | sed -i s/01/"$FFH"/g "$FOL" 165 | sed -i s/9000/"$FGS"/g "$FOL" 166 | if [ "$HD" = true ] ; then 167 | : 168 | else 169 | cat "$MODPATH"/service.sh | head -16 > "$MODPATH"/services.sh && mv "$MODPATH"/services.sh "$MODPATH"/service.sh 170 | fi 171 | fi 172 | 173 | if [ "$API" -le 30 ] ; then 174 | sed -i s/0.3/"$BH"/g "$RES" 175 | sed -i s/0.1/"$FH"/g "$RES" 176 | sed -i s/0.2/"$GS"/g "$RES" 177 | mkdir -p "$MODPATH"/Mods/MIUIc/ 178 | mkdir -p "$MODPATH"/system/vendor/overlay/ 179 | mkdir -p "$MODPATH"/Mods/Qtmp/res/values-sw900dp/ 180 | mkdir -p "$MODPATH"/Mods/Qtmp/res/values-sw600dp/ 181 | mkdir -p "$MODPATH"/Mods/Qtmp/res/values-440dpi/ 182 | mkdir -p "$MODPATH"/Mods/Qtmp/res/values-xhdpi/ 183 | mkdir -p "$MODPATH"/Mods/Qtmp/res/values-xxhdpi/ 184 | mkdir -p "$MODPATH"/Mods/Qtmp/res/values-xxxhdpi/ 185 | mkdir -p "$MODPATH"/Mods/MIUI/res/values/ 186 | mkdir -p "$MODPATH"/Mods/MIUI/res/values-440dpi/ 187 | mkdir -p "$MODPATH"/Mods/MIUI/res/values-xxhdpi/ 188 | cp -rf "$MODPATH"/Mods/Qtmp/res/values/dimens.xml "$MODPATH"/Mods/Qtmp/res/values-sw900dp/ 189 | cp -rf "$MODPATH"/Mods/Qtmp/res/values/dimens.xml "$MODPATH"/Mods/Qtmp/res/values-sw600dp/ 190 | cp -rf "$MODPATH"/Mods/Qtmp/res/values/dimens.xml "$MODPATH"/Mods/Qtmp/res/values-440dpi/ 191 | cp -rf "$MODPATH"/Mods/Qtmp/res/values/dimens.xml "$MODPATH"/Mods/Qtmp/res/values-xhdpi/ 192 | cp -rf "$MODPATH"/Mods/Qtmp/res/values/dimens.xml "$MODPATH"/Mods/Qtmp/res/values-xxhdpi/ 193 | cp -rf "$MODPATH"/Mods/Qtmp/res/values/dimens.xml "$MODPATH"/Mods/Qtmp/res/values-xxxhdpi/ 194 | cp -rf "$MODPATH"/Mods/Qtmp/res/values/* "$MODPATH"/Mods/MIUI/res/values-xxhdpi/ 195 | cp -rf "$MODPATH"/Mods/Qtmp/res/values/* "$MODPATH"/Mods/MIUI/res/values-440dpi/ 196 | cp -rf "$MODPATH"/Mods/Qtmp/res/values/* "$MODPATH"/Mods/MIUI/res/values/ 197 | fi 198 | 199 | 200 | 201 | 202 | #Detect original overlay location 203 | OP=$(find /system/overlay /product/overlay /vendor/overlay /system_ext/overlay -type d -iname "navigationbarmodegestural" | cut -d 'N' -f1) 204 | 205 | 206 | #Building overlays (A11 and below) 207 | if [ "$API" -le 30 ] ; then 208 | "$MODPATH"/aapt p -f -v -M "$MODPATH/Mods/Qtmp/AndroidManifest.xml" -I /system/framework/framework-res.apk -S "$MODPATH/Mods/Qtmp/res" -F "$MODPATH"/unsigned.apk >/dev/null 209 | "$MODPATH"/aapt p -f -v -M "$MODPATH/Mods/MIUI/AndroidManifest.xml" -I /system/framework/framework-res.apk -S "$MODPATH/Mods/MIUI/res" -F "$MODPATH"/miui.apk >/dev/null 210 | fi 211 | 212 | if [ "$API" -eq 30 ] ; then 213 | "$MODPATH"/tools/zipsigner "$MODPATH"/unsigned.apk "$MODPATH"/Mods/Q/NavigationBarModeGestural/NavigationBarModeGesturalOverlay.apk 214 | "$MODPATH"/tools/zipsigner "$MODPATH"/miui.apk "$MODPATH"/Mods/MIUIc/GestureLineOverlay.apk 215 | elif [ "$API" -eq 29 ] ; then 216 | "$MODPATH"/tools/zipsignero "$MODPATH"/unsigned.apk "$MODPATH"/Mods/Q/NavigationBarModeGestural/NavigationBarModeGesturalOverlay.apk 217 | "$MODPATH"/tools/zipsignero "$MODPATH"/miui.apk "$MODPATH"/Mods/MIUIc/GestureLineOverlay.apk 218 | fi 219 | 220 | #Install overlays (A11 and below) 221 | if [ "$API" -le 30 ] ; then 222 | mkdir -p "$MODPATH"/system"$OP" 223 | cp -rf "$MODPATH"/Mods/Q/* "$MODPATH"/Mods/"$VAR3"/* "$MODPATH"/Mods/"$VAR4"/* "$MODPATH"/system"$OP" 224 | fi 225 | 226 | if [ "$API" -le 30 ] ; then 227 | if [ -f /product/overlay/GestureLineOverlay.apk ] ; then 228 | cp -rf "$MODPATH"/Mods/MIUIc/GestureLineOverlay.apk "$MODPATH"/system/product/overlay/ 229 | elif [ -f /vendor/overlay/GestureLineOverlay.apk ] ; then 230 | cp -rf "$MODPATH"/Mods/MIUIc/GestureLineOverlay.apk "$MODPATH"/system/vendor/overlay/ 231 | else 232 | : 233 | fi 234 | fi 235 | 236 | echo "Done" 237 | -------------------------------------------------------------------------------- /customize.sh: -------------------------------------------------------------------------------- 1 | ########################################################################################## 2 | # 3 | # MMT Extended Config Script 4 | # 5 | ########################################################################################## 6 | 7 | ########################################################################################## 8 | # Config Flags 9 | ########################################################################################## 10 | 11 | # Uncomment and change 'MINAPI' and 'MAXAPI' to the minimum and maximum android version for your mod 12 | # Uncomment DYNLIB if you want libs installed to vendor for oreo+ and system for anything older 13 | # Uncomment DEBUG if you want full debug logs (saved to /sdcard) 14 | MINAPI=29 15 | MAXAPI=33 16 | #DYNLIB=true 17 | #DEBUG=true 18 | 19 | ########################################################################################## 20 | # Replace list 21 | ########################################################################################## 22 | 23 | # List all directories you want to directly replace in the system 24 | # Check the documentations for more info why you would need this 25 | 26 | # Construct your list in the following format 27 | # This is an example 28 | REPLACE_EXAMPLE=" 29 | /system/app/Youtube 30 | /system/priv-app/SystemUI 31 | /system/priv-app/Settings 32 | /system/framework 33 | " 34 | 35 | # Construct your own list here 36 | REPLACE=" 37 | " 38 | ########################################################################################## 39 | # Permissions 40 | ########################################################################################## 41 | 42 | set_permissions() { 43 | set_perm_recursive $MODPATH/tools 0 0 0755 0755 44 | set_perm_recursive $MODPATH/system/bin 0 0 0755 0755 45 | set_perm_recursive $MODPATH/system/xbin 0 0 0755 0755 46 | } 47 | 48 | ########################################################################################## 49 | # MMT Extended Logic - Don't modify anything after this 50 | ########################################################################################## 51 | 52 | SKIPUNZIP=1 53 | unzip -qjo "$ZIPFILE" 'common/functions.sh' -d $TMPDIR >&2 54 | . $TMPDIR/functions.sh 55 | -------------------------------------------------------------------------------- /module.prop: -------------------------------------------------------------------------------- 1 | id=HideNavBar 2 | name=Fullscreen/Immersive Gestures (Q-T) 3 | version=v21.0 4 | versionCode=55 5 | author=DanGLES3 6 | description=Customize Android 10-13's navigation gestures 7 | support=https://t.me/dnmgsk 8 | donate=https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=GHAYUFKDHUCSU&source=url 9 | -------------------------------------------------------------------------------- /service.sh: -------------------------------------------------------------------------------- 1 | #!/system/bin/sh 2 | APIE=$(cat /system/build.prop | grep ro.build.version.sdk | cut -d '='-f2) 3 | if [ -f /data/adb/modules/rboard-themes_addon/system.prop ] || [ -f /data/adb/modules/gboardnavbar/system.prop ] || [ -f /data/adb/modules/rboard-themes/system.prop ]; then 4 | printf 'do nothing' 5 | else 6 | resetprop ro.com.google.ime.kb_pad_port_b 1.0 7 | fi 8 | 9 | while [ "$(getprop sys.boot_completed | tr -d '\r')" != "1" ]; do sleep 1; done 10 | sleep 1 11 | cmd overlay fabricate --target android --name test2 android:dimen/navigation_bar_height 0x05 0x03 12 | cmd overlay enable com.android.shell:test2 13 | cmd overlay fabricate --target android --name test android:dimen/navigation_bar_frame_height 0x05 0x01 14 | cmd overlay enable com.android.shell:test 15 | cmd overlay fabricate --target android --name test3 android:dimen/navigation_bar_gesture_height 0x05 0x9000 16 | cmd overlay enable com.android.shell:test3 17 | cmd overlay fabricate --target com.android.systemui --name test4 com.android.systemui:dimen/navigation_handle_radius 0x05 0x0 18 | cmd overlay fabricate --target com.android.systemui --name test5 com.android.systemui:dimen/navigation_home_handle_width 0x05 0x0 19 | cmd overlay enable com.android.shell:test4 20 | cmd overlay enable com.android.shell:test5 21 | killall com.android.systemui -------------------------------------------------------------------------------- /tools/META-INF/com/google/android/update-binary: -------------------------------------------------------------------------------- 1 | #!/sbin/sh 2 | 3 | ################# 4 | # Initialization 5 | ################# 6 | 7 | umask 022 8 | 9 | # echo before loading util_functions 10 | ui_print() { echo "$1"; } 11 | 12 | require_new_magisk() { 13 | ui_print "*******************************" 14 | ui_print " Please install Magisk v20.0+! " 15 | ui_print "*******************************" 16 | exit 1 17 | } 18 | 19 | ######################### 20 | # Load util_functions.sh 21 | ######################### 22 | 23 | OUTFD=$2 24 | ZIPFILE=$3 25 | 26 | mount /data 2>/dev/null 27 | 28 | [ -f /data/adb/magisk/util_functions.sh ] || require_new_magisk 29 | . /data/adb/magisk/util_functions.sh 30 | [ $MAGISK_VER_CODE -lt 20000 ] && require_new_magisk 31 | 32 | if [ $MAGISK_VER_CODE -ge 20400 ]; then 33 | # New Magisk have complete installation logic within util_functions.sh 34 | install_module 35 | exit 0 36 | fi 37 | 38 | ################# 39 | # Legacy Support 40 | ################# 41 | 42 | TMPDIR=/dev/tmp 43 | PERSISTDIR=/sbin/.magisk/mirror/persist 44 | 45 | is_legacy_script() { 46 | unzip -l "$ZIPFILE" install.sh | grep -q install.sh 47 | return $? 48 | } 49 | 50 | print_modname() { 51 | local len 52 | len=`echo -n $MODNAME | wc -c` 53 | len=$((len + 2)) 54 | local pounds=`printf "%${len}s" | tr ' ' '*'` 55 | ui_print "$pounds" 56 | ui_print " $MODNAME " 57 | ui_print "$pounds" 58 | ui_print "*******************" 59 | ui_print " Powered by Magisk " 60 | ui_print "*******************" 61 | } 62 | 63 | # Override abort as old scripts have some issues 64 | abort() { 65 | ui_print "$1" 66 | $BOOTMODE || recovery_cleanup 67 | [ -n $MODPATH ] && rm -rf $MODPATH 68 | rm -rf $TMPDIR 69 | exit 1 70 | } 71 | 72 | rm -rf $TMPDIR 2>/dev/null 73 | mkdir -p $TMPDIR 74 | 75 | # Preperation for flashable zips 76 | setup_flashable 77 | 78 | # Mount partitions 79 | mount_partitions 80 | 81 | # Detect version and architecture 82 | api_level_arch_detect 83 | 84 | # Setup busybox and binaries 85 | $BOOTMODE && boot_actions || recovery_actions 86 | 87 | ############## 88 | # Preparation 89 | ############## 90 | 91 | # Extract prop file 92 | unzip -o "$ZIPFILE" module.prop -d $TMPDIR >&2 93 | [ ! -f $TMPDIR/module.prop ] && abort "! Unable to extract zip file!" 94 | 95 | $BOOTMODE && MODDIRNAME=modules_update || MODDIRNAME=modules 96 | MODULEROOT=$NVBASE/$MODDIRNAME 97 | MODID=`grep_prop id $TMPDIR/module.prop` 98 | MODPATH=$MODULEROOT/$MODID 99 | MODNAME=`grep_prop name $TMPDIR/module.prop` 100 | 101 | # Create mod paths 102 | rm -rf $MODPATH 2>/dev/null 103 | mkdir -p $MODPATH 104 | 105 | ########## 106 | # Install 107 | ########## 108 | 109 | if is_legacy_script; then 110 | unzip -oj "$ZIPFILE" module.prop install.sh uninstall.sh 'common/*' -d $TMPDIR >&2 111 | 112 | # Load install script 113 | . $TMPDIR/install.sh 114 | 115 | # Callbacks 116 | print_modname 117 | on_install 118 | 119 | # Custom uninstaller 120 | [ -f $TMPDIR/uninstall.sh ] && cp -af $TMPDIR/uninstall.sh $MODPATH/uninstall.sh 121 | 122 | # Skip mount 123 | $SKIPMOUNT && touch $MODPATH/skip_mount 124 | 125 | # prop file 126 | $PROPFILE && cp -af $TMPDIR/system.prop $MODPATH/system.prop 127 | 128 | # Module info 129 | cp -af $TMPDIR/module.prop $MODPATH/module.prop 130 | 131 | # post-fs-data scripts 132 | $POSTFSDATA && cp -af $TMPDIR/post-fs-data.sh $MODPATH/post-fs-data.sh 133 | 134 | # service scripts 135 | $LATESTARTSERVICE && cp -af $TMPDIR/service.sh $MODPATH/service.sh 136 | 137 | ui_print "- Setting permissions" 138 | set_permissions 139 | else 140 | print_modname 141 | 142 | unzip -o "$ZIPFILE" customize.sh -d $MODPATH >&2 143 | 144 | if ! grep -q '^SKIPUNZIP=1$' $MODPATH/customize.sh 2>/dev/null; then 145 | ui_print "- Extracting module files" 146 | unzip -o "$ZIPFILE" -x 'META-INF/*' -d $MODPATH >&2 147 | 148 | # Default permissions 149 | set_perm_recursive $MODPATH 0 0 0755 0644 150 | fi 151 | 152 | # Load customization script 153 | [ -f $MODPATH/customize.sh ] && . $MODPATH/customize.sh 154 | fi 155 | 156 | # Handle replace folders 157 | for TARGET in $REPLACE; do 158 | ui_print "- Replace target: $TARGET" 159 | mktouch $MODPATH$TARGET/.replace 160 | done 161 | 162 | if $BOOTMODE; then 163 | # Update info for Magisk Manager 164 | mktouch $NVBASE/modules/$MODID/update 165 | cp -af $MODPATH/module.prop $NVBASE/modules/$MODID/module.prop 166 | fi 167 | 168 | # Copy over custom sepolicy rules 169 | if [ -f $MODPATH/sepolicy.rule -a -e $PERSISTDIR ]; then 170 | ui_print "- Installing custom sepolicy patch" 171 | PERSISTMOD=$PERSISTDIR/magisk/$MODID 172 | mkdir -p $PERSISTMOD 173 | cp -af $MODPATH/sepolicy.rule $PERSISTMOD/sepolicy.rule 174 | fi 175 | 176 | # Remove stuffs that don't belong to modules 177 | rm -rf \ 178 | $MODPATH/system/placeholder $MODPATH/customize.sh \ 179 | $MODPATH/README.md $MODPATH/.git* 2>/dev/null 180 | 181 | ############# 182 | # Finalizing 183 | ############# 184 | 185 | cd / 186 | $BOOTMODE || recovery_cleanup 187 | rm -rf $TMPDIR 188 | 189 | ui_print "- Done" 190 | exit 0 191 | -------------------------------------------------------------------------------- /tools/META-INF/com/google/android/updater-script: -------------------------------------------------------------------------------- 1 | #MAGISK 2 | -------------------------------------------------------------------------------- /tools/aapt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Magisk-Modules-Repo/HideNavBar/e6d70759acbcac55a7bc83ed0ee1cc64304a834f/tools/aapt -------------------------------------------------------------------------------- /tools/aapt64: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Magisk-Modules-Repo/HideNavBar/e6d70759acbcac55a7bc83ed0ee1cc64304a834f/tools/aapt64 -------------------------------------------------------------------------------- /tools/customize.sh: -------------------------------------------------------------------------------- 1 | chmod +x "$MODPATH"/tools/* 2 | [ "$($MODPATH/tools/aapt v)" ] && AAPT=aapt 3 | [ "$($MODPATH/tools/aapt64 v)" ] && AAPT=aapt64 4 | cp -af "$MODPATH"/tools/$AAPT "$MODPATH"/aapt 5 | 6 | if [ -d /system/xbin/ ] && [ ! -f /system/xbin/empty ] ; then 7 | mkdir -p "$MODPATH"/system/xbin/ 8 | cp -rf "$MODPATH"/tools/hn "$MODPATH"/system/xbin/ 9 | else 10 | mkdir -p "$MODPATH"/system/bin/ 11 | cp -rf "$MODPATH"/tools/hn "$MODPATH"/system/bin/ 12 | fi 13 | 14 | #Detect original overlay location 15 | OP=$(find /system/overlay /product/overlay /vendor/overlay /system_ext/overlay -type d -iname "navigationbarmodegestural" | cut -d 'N' -f1) 16 | mkdir -p "$MODPATH"/system"$OP" 17 | 18 | #Build and sign overlays 19 | "$MODPATH"/aapt p -f -v -M "$MODPATH/Mods/Qtmp/AndroidManifest.xml" -I /system/framework/framework-res.apk -S "$MODPATH/Mods/Qtmp/res" -F "$MODPATH"/unsigned.apk >/dev/null 20 | "$MODPATH"/aapt p -f -v -M "$MODPATH/Mods/MIUI/AndroidManifest.xml" -I /system/framework/framework-res.apk -S "$MODPATH/Mods/MIUI/res" -F "$MODPATH"/miui.apk >/dev/null 21 | "$MODPATH"/tools/zipsigner "$MODPATH"/unsigned.apk "$MODPATH"/Mods/Q/NavigationBarModeGestural/NavigationBarModeGesturalOverlay.apk 22 | "$MODPATH"/tools/zipsigner "$MODPATH"/miui.apk "$MODPATH"/Mods/MIUIc/GestureLineOverlay.apk 23 | 24 | 25 | #Install overlays 26 | cp -rf "$MODPATH"/Mods/Q/* "$MODPATH"/opt/* "$MODPATH"/system"$OP" 27 | 28 | if [ -f /product/overlay/GestureLineOverlay.apk ] ; then 29 | cp -rf "$MODPATH"/Mods/MIUIc/GestureLineOverlay.apk "$MODPATH"/system/product/overlay/ 30 | elif [ -f /vendor/overlay/GestureLineOverlay.apk ] ; then 31 | cp -rf "$MODPATH"/Mods/MIUIc/GestureLineOverlay.apk "$MODPATH"/system/vendor/overlay/ 32 | else 33 | : 34 | fi 35 | 36 | echo "To apply changes make sure to reboot" 37 | -------------------------------------------------------------------------------- /tools/dalvikvm64: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Magisk-Modules-Repo/HideNavBar/e6d70759acbcac55a7bc83ed0ee1cc64304a834f/tools/dalvikvm64 -------------------------------------------------------------------------------- /tools/hn: -------------------------------------------------------------------------------- 1 | #!/system/bin/sh 2 | 3 | HNV=/data/adb/modules/HideNavBar 4 | chmod +x "$HNV"/tools/* 5 | RES="$HNV"/Mods/Qtmp/res/values/dimens.xml 6 | FOL="$HNV"/service.sh 7 | cp -rf "$HNV"/tools/service.sh "$HNV" 8 | cp -rf "$HNV"/Mods/QS/* "$HNV"/Mods/Qtmp/ 9 | rm -rf "$HNV"/Mods/Q/* 10 | mkdir -p "$HNV"/Mods/Q/NavigationBarModeGestural/ 11 | mkdir -p "$HNV"/opt/ 12 | 13 | # Grep prop 14 | grep_prop() { 15 | local REGEX="s/^$1=//p" 16 | shift 17 | local FILES=$@ 18 | [ -z "$FILES" ] && FILES='/system/build.prop' 19 | sed -n "$REGEX" $FILES 2>/dev/null | head -n 1 20 | } 21 | 22 | 23 | API=$(grep_prop ro.build.version.sdk) 24 | echo $API 25 | 26 | echo "Fullscreen/Immersive module setup" 27 | 28 | echo "Enter Gesture Sensitivity" 29 | if [ "$API" -ge 31 ] ; then 30 | echo "(Min 3000, Default 9000, Module default 4000)" 31 | else 32 | echo "(Min 10.0, default 32.0, Module default 18.0)" 33 | fi 34 | read -r GS 35 | if [ "$GS" = "" ]; then 36 | # $var is empty 37 | echo " " 38 | else 39 | if [ "$API" -ge 31 ] ; then 40 | sed -i s/9000/"$GS"/g "$FOL" 41 | else 42 | sed -i s/0.2/"$GS"/g "$RES" 43 | fi 44 | fi 45 | 46 | echo "What Navbar height?" 47 | if [ "$API" -ge 31 ] ; then 48 | echo "(0 Module default, 4000 Android default)" 49 | else 50 | echo "(0.0 Module default, 18.0 Android default)" 51 | fi 52 | read -r BH 53 | if [ "$BH" = "" ]; then 54 | # $var is empty 55 | echo " " 56 | else 57 | if [ "$API" -ge 31 ] ; then 58 | sed -i s/03/"$BH"/g "$FOL" 59 | else 60 | sed -i s/0.3/"$BH"/g "$RES" 61 | fi 62 | fi 63 | 64 | echo "What Keyboard bar height?" 65 | if [ "$API" -ge 31 ] ; then 66 | echo "(0 Fullscreen, 9500 immersive)" 67 | echo "(4000 Immersive+Small keyboard bar)" 68 | else 69 | echo "(0.0 Fullscreen, 48.0 immersive)" 70 | echo "(18.0 Immersive+Small keyboard bar)" 71 | fi 72 | read -r FH 73 | if [ "$FH" = "" ]; then 74 | # $var is empty 75 | echo " " 76 | else 77 | if [ "$API" -ge 31 ] ; then 78 | sed -i s/01/"$FH"/g "$FOL" 79 | else 80 | sed -i s/0.1/"$FH"/g "$RES" 81 | fi 82 | fi 83 | 84 | if [ "$FH" = 0.0 ] ; then 85 | : 86 | else 87 | echo "Hide pill? (yes or no, in lowercase)" 88 | read -r HB 89 | if [ "$HB" = yes ] ; then 90 | if [ "$API" -ge 31 ] ; then 91 | : 92 | else 93 | cp -rf "$HNV"/Mods/HP/. "$HNV"/opt 94 | fi 95 | else 96 | if [ "$API" -ge 31 ] ; then 97 | cat "$HNV"/service.sh | head -16 > "$HNV"/services.sh && mv "$HNV"/services.sh "$HNV"/service.sh 98 | else 99 | rm -rf "$HNV"/opt/pillhide.apk 100 | fi 101 | fi 102 | fi 103 | 104 | 105 | if [ "$API" -ge 31 ] ; then 106 | : 107 | else 108 | if [ "$FH" = 0.0 ] ; then 109 | : 110 | else 111 | echo "Hide keyboard buttons? (yes or no, in lowercase)" 112 | read -r HKB 113 | if [ "$HKB" = yes ] ; then 114 | cp -rf "$HNV"/Mods/HKB/. "$HNV"/opt/ 115 | else 116 | rm -rf "$HNV"/opt/HKN.apk 117 | fi 118 | fi 119 | fi 120 | 121 | echo "Disable the back gesture? (yes or no, in lowercase)" 122 | read -r DB 123 | if [ "$DB" = yes ] ; then 124 | : 125 | else 126 | settings delete secure back_gesture_inset_scale_left 127 | settings delete secure back_gesture_inset_scale_right 128 | fi 129 | 130 | if [ "$DB" = yes ] ; then 131 | echo "Left only (type l) Both sides (type b)" 132 | read -r SD 133 | if [ "$SD" = l ] ; then 134 | settings put secure back_gesture_inset_scale_left -1 135 | else 136 | settings put secure back_gesture_inset_scale_left -1 137 | settings put secure back_gesture_inset_scale_right -1 138 | fi 139 | else 140 | : 141 | fi 142 | 143 | if [ "$API" -le 30 ] ; then 144 | cp -rf "$HNV"/Mods/Qtmp/res/values/dimens.xml "$HNV"/Mods/Qtmp/res/values-sw900dp/ 145 | cp -rf "$HNV"/Mods/Qtmp/res/values/dimens.xml "$HNV"/Mods/Qtmp/res/values-sw600dp/ 146 | cp -rf "$HNV"/Mods/Qtmp/res/values/dimens.xml "$HNV"/Mods/Qtmp/res/values-440dpi/ 147 | cp -rf "$HNV"/Mods/Qtmp/res/values/dimens.xml "$HNV"/Mods/Qtmp/res/values-xhdpi/ 148 | cp -rf "$HNV"/Mods/Qtmp/res/values/dimens.xml "$HNV"/Mods/Qtmp/res/values-xxhdpi/ 149 | cp -rf "$HNV"/Mods/Qtmp/res/values/dimens.xml "$HNV"/Mods/Qtmp/res/values-xxxhdpi/ 150 | cp -rf "$HNV"/Mods/Qtmp/res/values/* "$HNV"/Mods/MIUI/res/values-xxhdpi/ 151 | cp -rf "$HNV"/Mods/Qtmp/res/values/* "$HNV"/Mods/MIUI/res/values-440dpi/ 152 | cp -rf "$HNV"/Mods/Qtmp/res/values/* "$HNV"/Mods/MIUI/res/values/ 153 | 154 | 155 | mkdir "$HNV"/ti 156 | cp -rf "$HNV"/tools "$HNV"/Mods "$HNV"/module.prop "$HNV"/tools/customize.sh "$HNV"/tools/META-INF/ "$HNV"/service.sh "$HNV"/ti 157 | cd "$HNV"/ti 158 | rm -rf "$HNV"/ti/test.zip 159 | "$HNV"/tools/zip -r test.zip . 160 | 161 | magisk --install-module "$HNV"/ti/test.zip 162 | 163 | else 164 | : 165 | fi 166 | 167 | echo "reboot for changes to apply" 168 | 169 | 170 | -------------------------------------------------------------------------------- /tools/hnr: -------------------------------------------------------------------------------- 1 | #!/system/bin/sh 2 | 3 | rm -rf /data/adb/service.d/ol2.sh 4 | rm -rf /data/adb/modules/HideNavBar/ 5 | cmd overlay disable com.android.shell:test 6 | cmd overlay disable com.android.shell:test2 7 | cmd overlay disable com.android.shell:test3 8 | cmd overlay disable com.android.shell:test4 9 | cmd overlay disable com.android.shell:test5 10 | echo "Module Removed" 11 | -------------------------------------------------------------------------------- /tools/service.sh: -------------------------------------------------------------------------------- 1 | #!/system/bin/sh 2 | APIE=$(cat /system/build.prop | grep ro.build.version.sdk | cut -d '='-f2) 3 | if [ -f /data/adb/modules/rboard-themes_addon/system.prop ] || [ -f /data/adb/modules/gboardnavbar/system.prop ] || [ -f /data/adb/modules/rboard-themes/system.prop ]; then 4 | printf 'do nothing' 5 | else 6 | resetprop ro.com.google.ime.kb_pad_port_b 1.0 7 | fi 8 | 9 | while [ "$(getprop sys.boot_completed | tr -d '\r')" != "1" ]; do sleep 1; done 10 | sleep 1 11 | cmd overlay fabricate --target android --name test2 android:dimen/navigation_bar_height 0x05 0x03 12 | cmd overlay enable com.android.shell:test2 13 | cmd overlay fabricate --target android --name test android:dimen/navigation_bar_frame_height 0x05 0x01 14 | cmd overlay enable com.android.shell:test 15 | cmd overlay fabricate --target android --name test3 android:dimen/navigation_bar_gesture_height 0x05 0x9000 16 | cmd overlay enable com.android.shell:test3 17 | cmd overlay fabricate --target com.android.systemui --name test4 com.android.systemui:dimen/navigation_handle_radius 0x05 0x0 18 | cmd overlay fabricate --target com.android.systemui --name test5 com.android.systemui:dimen/navigation_home_handle_width 0x05 0x0 19 | cmd overlay enable com.android.shell:test4 20 | cmd overlay enable com.android.shell:test5 21 | killall com.android.systemui -------------------------------------------------------------------------------- /tools/zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Magisk-Modules-Repo/HideNavBar/e6d70759acbcac55a7bc83ed0ee1cc64304a834f/tools/zip -------------------------------------------------------------------------------- /tools/zipsigner: -------------------------------------------------------------------------------- 1 | #!/system/bin/sh 2 | # zipsigner: wrapper to run zipsigner.jar from terminal 3 | # osm0sis @ xda-developers 4 | 5 | dir="$(cd "$(dirname "$0")"; pwd)"; 6 | 7 | /apex/com.android.art/bin/dalvikvm -Djava.io.tmpdir=. -Xnodex2oat -Xnoimage-dex2oat -cp $dir/zipsigner-*.jar com.topjohnwu.utils.ZipSigner "$@" 2>/dev/null \ 8 | || /apex/com.android.art/bin/dalvikvm -Djava.io.tmpdir=. -Xnoimage-dex2oat -cp $dir/zipsigner-*.jar com.topjohnwu.utils.ZipSigner "$@"; 9 | -------------------------------------------------------------------------------- /tools/zipsigner-3.0-dexed.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Magisk-Modules-Repo/HideNavBar/e6d70759acbcac55a7bc83ed0ee1cc64304a834f/tools/zipsigner-3.0-dexed.jar -------------------------------------------------------------------------------- /tools/zipsignero: -------------------------------------------------------------------------------- 1 | #!/system/bin/sh 2 | # zipsigner: wrapper to run zipsigner.jar from terminal 3 | # osm0sis @ xda-developers 4 | 5 | dir="$(cd "$(dirname "$0")"; pwd)"; 6 | 7 | dalvikvm -Djava.io.tmpdir=. -Xnodex2oat -Xnoimage-dex2oat -cp $dir/zipsigner-*.jar com.topjohnwu.utils.ZipSigner "$@" 2>/dev/null \ 8 | || dalvikvm -Djava.io.tmpdir=. -Xnoimage-dex2oat -cp $dir/zipsigner-*.jar com.topjohnwu.utils.ZipSigner "$@"; --------------------------------------------------------------------------------