Android OS Forum banner
1 - 7 of 7 Posts

111 Posts
Discussion Starter · #1 ·
This is a brief tutorial on how to disable the paginated scrolling in the Sense launcher. The same concept can be applied to both Sense 2.1 and 3.0. It is a fairly simple mod, but requires knowledge of baksmali. This tutorial will not cover how to use baksmali.
  1. Decompile
  2. Open /com/htc/widget/PagedGridView.smali
  3. Find three instances of mEnableScrollByPage where the line begins with iput
  4. Change the local variable on each line to one declared as 0x0
    <br />
    const/4 v0, 0x1<br />
    <br />
    const/4 v2, 0x0<br />
    <br />
    const/4 v1, 0x0<br />
    <br />
    Original:<br />
    iput-boolean [B][COLOR="Red"]v0[/COLOR][/B], p0, Lcom/htc/widget/PagedGridView;->mEnableScrollByPage:Z<br />
    <br />
    Changed:<br />
    iput-boolean [COLOR="Red"][B]v1[/B][/COLOR], p0, Lcom/htc/widget/PagedGridView;->mEnableScrollByPage:Z
  5. There should be three; one in each constructor
  6. Recompile and push to /system/framework
  7. Reboot

Android Apprentice
66 Posts
can anybody give me simple instructions line for line on how to decompile a jar, where to place and how to use smali etc. im new to this and never used these type of things before. thanks
1. The instructions below are for a deodexed Rom. You need apk tool. (adb too obviously). Follow the installation instructions from here.

2. connect your phone to the computer and extract the required files
adb pull /system/framework/<br />
		  adb pull /system/framework/framework-res.apk<br />
		  adb pull /system/framework/
2a. Extract the META-INF folder from the jar file using 7 zip or better zip (mac). This is the signature file and you'd need this to put it back into it after you make the edits. This way you are not bothering with re-signing the jar file.

3. Start using apk tool to first install the framework files.
 apktool if<br />
			apktool if framework-res.apk
4. Decompile the jar file using apk tool
 apktool d
5. This will create a folder in the current directory. This is the decompiled output of the jar file.

6. In that directory, navigate to /com/htc/widget/

7. Use any editor to edit the PageGridView.smali file. Open it up with notepad or any other.

8. Do a ctr+f to find mEnableScrollByPage

9. At every instance.. change the iput boolean v0 to v1. There are 3 instances where you'd have to change this.. which is where step number 8 above comes in handy. Save this file and close it.

10. Recompile all of this.

 apktool b [the output file directory name here]
11. When you navigate back in the directory.. you'll see the distro folder (or something like that).. which is where the recompiled file is.

12. Open this up using 7zip or better zip (in mac).. and put the META-INF folder from the original jar file into this.. and save it.

13. push the whole thing back into your phone after making a backup of the original
<br />
adb shell<br />
mount system<br />
cd /system/framework<br />
mv<br />
exit<br />
adb push /system/framework<br />
adb reboot<br />
14. That's it.
1 - 7 of 7 Posts