• Introducing XDA Computing: Discussion zones for Hardware, Software, and more!    Check it out!

[MOD][MIUI4] Volume+ Mod for MIUI4 v2.7.20 (Hold volume to skip tracks)

Search This thread

CosmicDan

Senior Member
Jun 19, 2009
5,868
7,720
34
Sydney
Google Pixel 3 XL
The prebuilt android.policy.jar ZIP attached is only for MIUI v2.7.20 for the Arc S (and unofficial ports based on that build, as long as the porter didn't already mess with that jar file). If you want it for other devices, get the 'Source Info' file and port it yourself.

You all know it. Roots in Cyanogenmod, ported to MIUI Gingerbread and many other ROM's over time... but new MIUI4 ROM's have missed out for too long. So here it is. Hold Volume-Up to skip forward a track, Down for back. Only works while music is playing and while screen is off and locked. Apparently it will also change FM channel if playing Radio, don't know and don't care.

It is based on MIUI UK's MIUI v2.7.20 for the Arc S, with the source info it should be easy to port to any other device. Might work on older/newer versions of MIUI too, don't know. This took me half an hour to do, it wouldn't have been possible without 7OH's original mod for Xperia's on Stock ICS. I just ported it to MIUI.

This is not a flashable ZIP, sort it out yourself. Extract, push android.policy.jar to /system/framework/ (overwrite old one) and optionally chmod it to 644.

Integrate it in your ROM if you wish, credit would be appreciated. Don't be an ass and claim it as your own. Just say "Volume+ Mod by CosmicDan and 7OH" in the credits.

Also attached is some info on the smali changes (a unified diff and two new files).

Bye!
 
Last edited:

lenny_kano

Senior Member
Oct 1, 2011
644
677
Adelaide
i tried this on my galaxy siii but i just get bootloops

Just fyi, now that miui is based on stock firmwares, this will only work on devices it comes from (I.e the arc s). Miui gb was compiled from source, which is why stuff like this worked on all roms. Now they just patch some miui stuff into the original jar file, so the chances of a one-jar-fits-all are non-existant. The same patch will work, just that it needs to be done specifically for each rom. Too many framework changes between e.g. sense, touchwiz, Xperia etc.
 
  • Like
Reactions: CosmicDan

CosmicDan

Senior Member
Jun 19, 2009
5,868
7,720
34
Sydney
Google Pixel 3 XL
Just fyi, now that miui is based on stock firmwares, this will only work on devices it comes from (I.e the arc s). Miui gb was compiled from source, which is why stuff like this worked on all roms. Now they just patch some miui stuff into the original jar file, so the chances of a one-jar-fits-all are non-existant. The same patch will work, just that it needs to be done specifically for each rom. Too many framework changes between e.g. sense, touchwiz, Xperia etc.

Ahhhh OK fair enough, thanks for the info! I guess I will post in the Arc S section then. I will leave this here though because the other ZIP has a diff of the smali changes. and the MIUI port maintainers can take care of it. Still relevant for this section, also this is a first (at time of writing, no other site/ROM has it in MIUIv4 except for mine).

First post updated.
 
Last edited:
  • Like
Reactions: wielku

CosmicDan

Senior Member
Jun 19, 2009
5,868
7,720
34
Sydney
Google Pixel 3 XL
Dan can you please provide me any information about how to use the diff file?

With a program like WinMerge or patch binary compiled for win32. But you will need to edit variables, labels and line numbers where necessary. If you don't know how, don't bother. Basically if it's v0 on mine it might be v1 on yours, you can compare similar code around my changes to get an idea of what it should be.
 

Top Liked Posts

  • There are no posts matching your filters.
  • 4
    The prebuilt android.policy.jar ZIP attached is only for MIUI v2.7.20 for the Arc S (and unofficial ports based on that build, as long as the porter didn't already mess with that jar file). If you want it for other devices, get the 'Source Info' file and port it yourself.

    You all know it. Roots in Cyanogenmod, ported to MIUI Gingerbread and many other ROM's over time... but new MIUI4 ROM's have missed out for too long. So here it is. Hold Volume-Up to skip forward a track, Down for back. Only works while music is playing and while screen is off and locked. Apparently it will also change FM channel if playing Radio, don't know and don't care.

    It is based on MIUI UK's MIUI v2.7.20 for the Arc S, with the source info it should be easy to port to any other device. Might work on older/newer versions of MIUI too, don't know. This took me half an hour to do, it wouldn't have been possible without 7OH's original mod for Xperia's on Stock ICS. I just ported it to MIUI.

    This is not a flashable ZIP, sort it out yourself. Extract, push android.policy.jar to /system/framework/ (overwrite old one) and optionally chmod it to 644.

    Integrate it in your ROM if you wish, credit would be appreciated. Don't be an ass and claim it as your own. Just say "Volume+ Mod by CosmicDan and 7OH" in the credits.

    Also attached is some info on the smali changes (a unified diff and two new files).

    Bye!
    2
    i tried this on my galaxy siii but i just get bootloops

    Galaxy S III is an unofficial MIUI device, contact your ROM developer to make the changes or try a different port. Also tell us which MIUI version it is and where you downloaded it from so others know. Thank you.
    1
    i tried this on my galaxy siii but i just get bootloops

    Just fyi, now that miui is based on stock firmwares, this will only work on devices it comes from (I.e the arc s). Miui gb was compiled from source, which is why stuff like this worked on all roms. Now they just patch some miui stuff into the original jar file, so the chances of a one-jar-fits-all are non-existant. The same patch will work, just that it needs to be done specifically for each rom. Too many framework changes between e.g. sense, touchwiz, Xperia etc.
    1
    Just fyi, now that miui is based on stock firmwares, this will only work on devices it comes from (I.e the arc s). Miui gb was compiled from source, which is why stuff like this worked on all roms. Now they just patch some miui stuff into the original jar file, so the chances of a one-jar-fits-all are non-existant. The same patch will work, just that it needs to be done specifically for each rom. Too many framework changes between e.g. sense, touchwiz, Xperia etc.

    Ahhhh OK fair enough, thanks for the info! I guess I will post in the Arc S section then. I will leave this here though because the other ZIP has a diff of the smali changes. and the MIUI port maintainers can take care of it. Still relevant for this section, also this is a first (at time of writing, no other site/ROM has it in MIUIv4 except for mine).

    First post updated.