[Q] Turn off Home Button Wake - Galaxy S 5 Q&A, Help & Troubleshooting

I looked through the older threads and couldn't instructions what to modify to turn the Home Button Wake Feature off on a rooted S5. If someone could tell me how to do this it would be greatly appreciated. Thanks.

If anyone can point me in the right direction it would be greatly appreciated. I have tried editing the file specified for other S series phones without success. Thanks.

I was able to do it on the S4 when it first came out. It was trial and error though. I edited every file I could find in the system folder that said "home Wake". I deleted the word "wake".
I agree it's annoying though. I have to keep a pin code lock because my phone constantly calls people from my pocket even with swipe to unlock turned on
Sent from my Galaxy S5

there is option in Wanam expose to do that, i didnt tried it yet so cant really tell it work or not.

Needed to bump this thread. I have done some serious pocket dialing. The ex and 911 are 2 examples.
I have a pin for the lock screen, but sometimes it work.

Thanks for the suggestions. I tried Wanam and it did not work on my ATT S5. I also went through some of the files in the key layout folder and only found two instances of Home Wake. I tired deleting Wake on both of them and that didn't solve the issue. If anyone has any other ideas I would be glad to try them.

So far the only solution I have is to not put it in my pocket. I have a gear2 for notifications and to let me know when I have a call, otherwise it sits on my desk, or in my briefcase.
Couldn't they make it a gesture using the gyroscope and pedometer?
My not so smartphone goes upside down in my pocket and it's counting my steps. I think the would be a simple solution.

Find this method in phonestatusbar.smali in android.policy.jar....
.method private isWakeKeyWhenScreenOff(I)Z
Find :sswitch_2
And put....
return v1
So in full....
Code:
.method private isWakeKeyWhenScreenOff(I)Z
.locals 3
.parameter "keyCode"
.prologue
const/4 v0, 0x1
const/4 v1, 0x0
.line 6699
sparse-switch p1, :sswitch_data_0
.line 6723
:cond_0
:goto_0
return v0
.line 6704
:sswitch_0
iget v2, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mDockMode:I
if-nez v2, :cond_0
move v0, v1
goto :goto_0
:sswitch_1
move v0, v1
.line 6721
goto :goto_0
:sswitch_2
return v1
nop
.line 6699
:sswitch_data_0
.sparse-switch
0x3 -> :sswitch_2
0x18 -> :sswitch_0
0x19 -> :sswitch_0
0x1b -> :sswitch_1
0x4f -> :sswitch_1
0x50 -> :sswitch_1
0x55 -> :sswitch_1
0x56 -> :sswitch_1
0x57 -> :sswitch_1
0x58 -> :sswitch_1
0x59 -> :sswitch_1
0x5a -> :sswitch_1
0x5b -> :sswitch_1
0x7e -> :sswitch_1
0x7f -> :sswitch_1
0x82 -> :sswitch_1
0xa4 -> :sswitch_0
0xde -> :sswitch_1
.end sparse-switch
.end method
That should stop home from ever waking device
Sent from my SM-G900F using Tapatalk

Goldie said:
Find this method in phonestatusbar.smali in android.policy.jar....
That should stop home from ever waking device
Sent from my SM-G900F using Tapatalk
Click to expand...
Click to collapse
Thanks. I think this solution is slightly above my technical ability right now. I did some looking and understand what needs to be done to modify the jar file, but not exactly what programs I need. Can you point me in the right direction to the noob guide to decompiling and recompiling the jar file?

Does anyone have another way to disable the home button wake? Thanks.

I put my phone in a larger case. And it has prevented some of the home button wakes, but now am having issues with the screen locking up, as if my finger was held in one spot on the screen. I have to pop the battery out and restart the phone.

ampm325 said:
I put my phone in a larger case. And it has prevented some of the home button wakes, but now am having issues with the screen locking up, as if my finger was held in one spot on the screen. I have to pop the battery out and restart the phone.
Click to expand...
Click to collapse
My phone is also pocket calling 911. Gets past my lock setup, too. Haven't found a forum yet stating that rooting my ATT G900A is possible.

Related

Calendar notification not working

Just recently noticed that my calendar music notifications aren't triggering, the alert shows but the tone i selected doesn't play
anyone?
I've logged a call with HTC as I''m still running stock ROM but thought someone here would have a few ideas..
mtrax said:
anyone?
I've logged a call with HTC as I''m still running stock ROM but thought someone here would have a few ideas..
Click to expand...
Click to collapse
I created a test event can copied the system log
Can any one compare with a working phone.
D/AlertReceiver( 323): beginStartingService
D/AlertService( 323): allDay:false instanceBegin=1282114948000 minutes=5 alarmTime=1282114648000
D/BT HS/HF( 146): gsmAsuToSignal=19
D/dalvikvm( 323): GC freed 7567 objects / 442728 bytes in 107ms
D/AlertService( 323): >>>>>>> makeNewAlertNotification <<<<<<<
D/AlertService( 323): >>>>>>> eventId:296 <<<<<<<
D/AlertService( 323): >>>>>>> title:Hello <<<<<<<
I/AlertService( 323): get calendarId:5
I/AlertService( 323): Type:0 Vibrate:true Ringtone:content://media/internal/audio/media/23 <<< New Setting
D/NotificationFlashLightUtility getIncomingCall( 323): load success~~~~~~~~~~
V/AlertService( 323): changeNotificationSound: false
V/AlertService( 323): notification.sound != null: null
V/AlertService( 323): reminderType: 0
I/ActivityManager( 80): Starting activity: Intent { flg=0x10000000 cmp=com.htc.calendar/.AlertActivity }
Click to expand...
Click to collapse
Hi there pal!
I've got the same problem, my notifications don't show up in a notification bar ... any reminding whatsoever ...
I'm running stock rom as well ... if you figure out more I'd be glad for more info.
The think is, I'm just new to the android platform, so I can't really think of anything
latorante said:
Hi there pal!
I've got the same problem, my notifications don't show up in a notification bar ... any reminding whatsoever ...
I'm running stock rom as well ... if you figure out more I'd be glad for more info.
The think is, I'm just new to the android platform, so I can't really think of anything
Click to expand...
Click to collapse
yours might be a different problem as I see the notifications but it doesn't play the ringtone.
I extracted the syslog using the following App ( http://www.appbrain.com/app/org.jtb.alogcat) you might try using this immediately after you expect your calendar alarm.. to see what message show..
Tell you what, I've done some research on my Legend and it seems, that all calendrs work except the facebook one - the birthday notifications. And thats the one I was interested in...
I'll try the program you posted ...
cheers
Can someone run a quick test for me please?
Set a ringtone on a Calender alert
1. Open the Calendar application.
2. Press Menu then More then Settings.
3. Tap on Reminder settings.
4. Make sure that there is a tick mark on “All calendars.”
5. Tap on Set alerts & notifications and select Alert.
6. Tap on Select ringtone and tap the ring tone that you prefer.
Then set a calender event and when it triggers the ringtone should play.
If could send me the snippet of the system log so I can compare with mine,
thanks
I got a working one:
/AudioHardwareMSM72XX( 57): AUDIO_START: start kernel pcm_out driver.
D/AlertReceiver(12956): beginStartingService
D/AlertService(12956): allDay:false instanceBegin=1282455968000 minutes=5 alarmTime=1282455668000
D/AlertService(12956): >>>>>>> makeNewAlertNotification <<<<<<<
D/AlertService(12956): >>>>>>> eventId:721 <<<<<<<
D/AlertService(12956): >>>>>>> title:Test <<<<<<<
I/AlertService(12956): get calendarId:1
I/AlertService(12956): Type:0 Vibrate:true Ringtone:content://media/internal/audio/media/49 <<< New Setting
D/NotificationFlashLightUtility getIncomingCall(12956): load fail~~~~~~~~~~
V/AlertService(12956): changeNotificationSound: false
V/AlertService(12956): notification.sound != null: content://media/internal/audio/media/49
V/AlertService(12956): reminderType: 0
I/ActivityManager( 79): Starting activity: Intent { flg=0x10000000 cmp=com.htc.calendar/.AlertActivity }
D/MediaPlayer( 79): setDataSource(291, 0, 576460752303423487) pid = 79
D/PVPlayer( 57): setDataSource(31, 0, 11183)
I/AlertActivity(12956): mCursor.count: 1
I/PlayerDriver( 57): OpenCore enable firewall payload
I/ ( 57): OpenCore codec name PVMFOMXAudioDecNode , OMX.PV.mp3dec
W/MediaPlayer( 79): info/warning (1, 44)
I/AudioPolicyService( 57): startOutput(): before lock
W/NotificationService( 79): Notification sound delayed by 1211msecs
I/ActivityManager( 79): Displayed activity com.htc.calendar/.AlertActivity: 1401 ms (total 1401 ms)
I/AudioPolicyService( 57): stopOutput(): before lock
D/BT HS/HF_S( 153): gsmAsuToSignal=5
Click to expand...
Click to collapse
my log seems to vary slightly yours has:
V/AlertService(12956): notification.sound != null: content://media/internal/audio/media/49
where as mine has:
V/AlertService( 323): notification.sound != null: null

[INFO] Auto-Backlight Settings for Cyanogenmod ROMs

Some of you would already know that the lightsensor filter in the Evo kernels is now working ( I would say atleast 80% working ) and responds best to Desire builds.
I have it working just fine for the last few hours on the AndroidMedaUltimate 1.3 version. Here are my settings in case you wanna try out.
CAUTION : If you change the values too many times, lightsensor stops responding and you will not see any changes in values. I believe thats CM related.
My Setup
Build : AndroidMedaUltimate 1.3
Kernel : StockEvo Autobuild dated Oct 29
(No SetCpU/taskkillers/etc)
1. Make sure Auto Brightness is disabled under Settings->Display
2. Goto Settings->Cyanogenmod Settings->User Interface->Automatic Backlight
3. Under Light Sensor filter, make sure Enabled is unchecked (No filters!)
4. Under Light levels, check "Allow Light Decrease" and set "Decrease hysteresis" to 0% (Yes thats no typo, for some reason sensor responds faster this way )
5. Check "Use Custom"
6. Tap on Edit Other Levels...
7. Now set values as in below screenshot and table
Lower ....... Upper ............Screen...........Buttons
0 ____________ 169 _______________ 85 _____________ 255
170 __________ 279 _______________ 120 ____________ 255
280 __________ 749 _______________ 170 ____________ 255
800 __________ () _______________ 254 ____________ 255
Note - The last value is 254, for some reason when I had it as 255 and went outside, brightness got stuck at max and sensor stopped responding
Click to expand...
Click to collapse
8. Tap Save & Apply
9. Wait for few seconds and try covering and changing light, you should see the sensor values change on top
10. Once that starts happening, enable Auto Brightness under Display settings
11. Reboot (Best Practice )
---------------
You can add more levels and adjust the lower/upper range alongwith the Screen values (30-255) to suit you better. However, the more you change it the more its likely to end up not working. Dont know why.
Interesting, will be testing this today with Shubcraft 2.0 and post my findings.
thanks, done the changes and testing with Htcclays V1.4.
edit: it is working very well for me.no lightsensor issue for me.
many thanks for your tip.
Thank you works grat
v-b-n said:
1. Make sure Auto Brightness is disabled under Settings->Display
2. Goto Settings->Cyanogenmod Settings->User Interface->Automatic Backlight
3. Under Light Sensor filter, make sure Enabled is unchecked (No filters!)
4. Under Light levels, check "Allow Light Decrease" and set "Decrease hysteresis" to 0% (Yes thats no typo, for some reason sensor responds faster this way )
5. Check "Use Custom"
6. Tap on Edit Other Levels...
7. Now set values as in below screenshot and table
8. Tap Save & Apply
9. Wait for few seconds and try covering and changing light, you should see the sensor values change on top
10. Once that starts happening, enable Auto Brightness under Display settings
11. Reboot (Best Practice )
---------------
You can add more levels and adjust the lower/upper range alongwith the Screen values (30-255) to suit you better. However, the more you change it the more its likely to end up not working. Dont know why.
Click to expand...
Click to collapse
Thanks very much for this, a few questions if you please.....
I'm using Typhoon 3.8.0.
I'm finding these settings under
Settings->Cyanogenmod Settings->Display->Automatic Backlight
not
Settings->Cyanogenmod Settings->User Interface->Automatic Backlight
And I don't know if that has any underlying significance - like it not being implemented in the same way in Typhoon?
Secondly you don't mention the "screen dim level" setting I see in the same "Display" menu. I've wound it down to 6 (default is 20), but not seeing much difference?
Thirdly, I've used the settings in the "other levels" as your table shows, but I wonder why you used those settings, what drove you to pick those numbers?
Finally, you talk about changing it too much stopping it working....when that happens what do you do to revert? Reboot? Or return to defaults and reboot? or something else?
Thanks, I'm hoping this will help balance out the fact that up to now I've not used auto-brightness so as to keep the battery life up but it's a bit of a pain in bright light to see the screen....
Thanks

Need help changing font size options in Reader.apk

I would like to change the font size options that come with the Nook Reader.
The reader.apk comes with seven different font sizes : from 7.0 to 27.0
The smaller at 7.0 is too small to be useful
and the largest at 27.0 is too large
and the jump from the fifth size (13.0) to the sixth size (20) is too big a jump.
I have used apktool to take apart the apk as in this post http://forum.xda-developers.com/showthread.php?t=1735858
The font size options appear to be set in /com/bn/nook/reader/commonui/ReaderCommonUIConstants.smali
lines 117 to 129
I changed the font sizes to 11.0, 12.0, 14.0, 16.0, 18.0, 20.0 and 22.0.
Saved the .smali file.
I then used apktool to put it all back into a newreader.apk
signed newreader.apk
deleted the existing reader.apk from my nook
adb pushed this apk to /system/app/reader.apk
But when I open a book, the font size options are just the same as before my changes. It is as if no changes were made at all
Any suggestions?
ladykayaker said:
I would like to change the font size options that come with the Nook Reader.
The font size options appear to be set in /com/bn/nook/reader/commonui/ReaderCommonUIConstants.smali
lines 117 to 129
Click to expand...
Click to collapse
For those who don't feel like taking apart the apk, the lines referenced are:
Code:
.field public static final FONT_SIZE_1:D = 7.0
.field public static final FONT_SIZE_2:D = 8.5
.field public static final FONT_SIZE_3:D = 9.75
.field public static final FONT_SIZE_4:D = 11.0
.field public static final FONT_SIZE_5:D = 13.0
.field public static final FONT_SIZE_6:D = 20.0
.field public static final FONT_SIZE_7:D = 27.0
Which looks like a pretty reasonable place to make the changes, right?
To understand why this doesn't work, you need to know a little bit more about the Java compiler, specifically what it means to declare a value as static final.
Consider the following Java code:
Code:
private static final double TEST = 9.75;
private static void test() {
double myVal;
myVal = 1.23;
if (myVal != TEST)
myVal = TEST;
}
Since you've flagged the TEST value as static final, you're making a promise to the compiler. And that promise is: "I promise to never, ever change the value of TEST. It's 9.75 now and it's going to be 9.75 every time you run this program no matter what."
When the compiler hears you make that promise, it's just going to go ahead and substitute the value 9.75 every single time it comes across a reference to TEST.
So, to the compiler, the above code "pre-compiles" to:
Code:
private static final double TEST = 9.75;
private static void test() {
double myVal;
myVal = 1.23;
if (myVal != 9.75)
myVal = 9.75;
}
which we can verify against the resulting smali code:
Code:
# static fields
.field private static final TEST:D = 9.75
.method private static test()V
.registers 4
.prologue
.line 6
const-wide v0, 0x3ff3ae147ae147aeL
.line 8
.local v0, myVal:D
const-wide v2, 0x4023800000000000L
cmpl-double v2, v0, v2
if-eqz v2, :cond_13
.line 9
const-wide v0, 0x4023800000000000L
.line 10
:cond_13
return-void
.end method
(0x4023800000000000L is the hexadecimal representation of the double value 9.75)
Notice that there is still a static definition of TEST as 9.75. But in the code, there are no more references to TEST, just references to the value of TEST at the time the code was compiled.
In this example, if you were trying to replace 9.75 with 12.0, you would need to find the value 0x4023800000000000L and replace it with 0x4023800000000000L each place in the code. Of course, you need to be careful: since the constant labels have been stripped, you have no way of knowing if the original code referenced TEST, or 9.75 or OTHER_DEFINITION that also happened to be 9.75 and you don't want to change it in places where it may be referring to 9.75 as the price of a book instead of 9.75 as the size of a font.
Fortunately, 9.75 is a pretty unique value so a quick search through the Reader code results in only one result:
Code:
D:\nook\Reader>grep -ir 0x4023800000000000 *
smali/com/bn/nook/reader/commonui/ReaderCommonUIConstants$5.smali: const-wide v1, 0x4023800000000000L
Looking at the file, we can see in the Init() function is basically preparing a hashmap with the following values
Code:
1 => 0x401c (7.0)
2 => 0x4021 (9.0)
3 => 0x4023800000000000L (9.75)
4 => 0x4026 (11.0)
5 => 0x402a (13.0)
6 => 0x4034 (20.0)
7 => 0x403b (27.0)
Which is funny, because it's actually using 9.0 instead of 8.5 as the second font size despite the defined value and all of the values except 9.75 are defined as integers rather than Doubles. It looks like some B&N programmer ignored the FONT_SIZE_X definitions and just hard coded the values herself. Anyhow, this creates that mapping that is (most likely) used internally by the reader to find the proper sizing to use for each of the 7 font size options.
I don't have Reader.apk installed on my Nook so I can't actually test this out. But I'm pretty sure if you change the values in ReaderCommonUIConstants$5.smali you'll end up with the results you want.
If that doesn't work, let me make a plug for Cool Reader, which among many other advantages versus the stock Reader has a much larger range of font sizes to choose from.
Yes, that did it. I didn't consider that the values would actually be hard-coded!

[Q] Change Font in Stock Reader

Some people have expressed a need to read foreign language media on their nook, with the stock reader.
I am trying to work out how to make the necessary changes to the stock reader so that the user can select their own font family, such as thai, hebrew, korean, etc.
Using apktool to extract the smali files - I have changed the following lines
(changing from Amasis30.ttf to Hebrew.ttf)
com\bn\nook\reader\activities\ReaderActivity$34.smali
.field public static final FONT_FAMILY_AMASIS:Ljava/lang/String; = "Amasis30"
.field public static final FONT_FAMILY_AMASIS_PATH:Ljava/lang/String; = "/system/fonts/Amasis30.ttf"
com\bn\nook\reader\commonui\ReaderCommonUIConstants$6.smali
const-string v1, "Amasis30"
com\bn\nook\reader\commonui\ReaderCommonUIConstants.smali
.field public static final FONT_FAMILY_AMASIS:Ljava/lang/String; = "Amasis30"
.field public static final FONT_FAMILY_AMASIS_PATH:Ljava/lang/String; = "/system/fonts/Amasis30.ttf"
com\bn\nook\reader\commonui\TextSettingsView.smali
const-string v1, "/system/fonts/Amasis30.ttf"
But, this doesn't seem to be enough.
The font name in the list of six options still says Amasis, but it is in the new font type.
The font in the book has defaulted to Malabar font.
The preferences.xml gives the new font type.
Where else is should I look to find the references to the font file?
Quick answer: replace the two in-code references below with /system/fonts/Hebrew.ttf (assuming this is the correct path and capitalizaton for the font file)
Code:
smali/com/bn/nook/reader/activities/ReaderActivity$34.smali: const-string v3, "/system/fonts/Amasis30.ttf"
smali/com/bn/nook/reader/commonui/TextSettingsView.smali: const-string v1, "/system/fonts/Amasis30.ttf"
Leave everything else untouched. Don't worry about the "static final" definitions.
This line
smali/com/bn/nook/reader/commonui/TextSettingsView.smali: const-string v1, const-string v1, "/system/fonts/Amasis30.ttf"
sets the font for font name in the popup window where the user selects the font.
This line at first doesn't appear to make a change,
smali/com/bn/nook/reader/activities/ReaderActivity$34.smali: const-string v3, "/system/fonts/Amasis30.ttf"
the book hasn't changed to hebrew font, but on closer look the book is now in Malabar font(the one in the list above Amasis)
after digging around it appears the font may be stored in FONTFAMILY_MAP
but then again, I go round in circles following this, and it might only be used to write the ReaderPrefences.xml file.
It seems the font file names are being stored somewhere, perhaps not in Reader.apk
but I can't find where.
You might find the info in this blog:
http://phanquochuy.me/?p=114
and this thread
http://bookclubs.barnesandnoble.com...n-t-display-Vietnamese-characters/td-p/494819
helpful re: some other approaches to adding alternative fonts.
My idea is to make it easier for a user to change font in the stock reader.
I think this is done in com\bn\nook\reader\activities\ReaderActivity$34.smali
If I change the lines referring to Amasis font, to the new font name (spelling, uppercase, etc checked to be correct)
then it doesn't use the new font, it also doesn't use Amasis, but uses the previous in the list, that is Malabar.

Way to change Long-Press duration on stock Samsung Keyboard?

I currently use Swiftkey, but really would love to use the stock Samsung keyboard mainly because of the numbers above the letter keys. The only reason I am sticking with Swiftkey is because you can change the long-press duration for selecting special charactors/punctuations - if I stuck with the samsung keyboard it would slow me down greatly and annoy the crap out of me because the long-press take so long.
Is there anyway to change the long-press duration? Any files you can edit to affect it? or something?
Thanks!
ItsTommyGun said:
I currently use Swiftkey, but really would love to use the stock Samsung keyboard mainly because of the numbers above the letter keys. The only reason I am sticking with Swiftkey is because you can change the long-press duration for selecting special charactors/punctuations - if I stuck with the samsung keyboard it would slow me down greatly and annoy the crap out of me because the long-press take so long.
Is there anyway to change the long-press duration? Any files you can edit to affect it? or something?
Thanks!
Click to expand...
Click to collapse
Yes, there is:
1. To change the long press delay
In PointerTracker:
Code:
###################################################
# Change the long press delay to 200ms from 500ms #
###################################################
.line 498
const/16 v0, 0xc8
.line 499
.local v0, delay:I
packed-switch p1, switch_data_0
.line 504
const/16 v0, 0xc8
.line 507
:goto_0
int-to-long v1, v0
return-wide v1
.line 501
switch_0
const/16 v0, 0xc8
Check out this thread for more info: http://forum.xda-developers.com/showthread.php?t=2093588
unkellsam said:
Yes, there is:
1. To change the long press delay
In PointerTracker:
Code:
###################################################
# Change the long press delay to 200ms from 500ms #
###################################################
.line 498
const/16 v0, 0xc8
.line 499
.local v0, delay:I
packed-switch p1, switch_data_0
.line 504
const/16 v0, 0xc8
.line 507
:goto_0
int-to-long v1, v0
return-wide v1
.line 501
switch_0
const/16 v0, 0xc8
Check out this thread for more info: http://forum.xda-developers.com/showthread.php?t=2093588
Click to expand...
Click to collapse
I can't find anywhere Pointertracker to edit it. I even copied the .apk onto my computer and browsed it. Am I missing it??
I'm also a little worried about installing the apk listed since it's for a different device.
Do you know the location of PointerTracker?

Categories

Resources