[Guides & Links] TOUCHWIZ UNIFIED MODS THREAD

Search This thread

Frozen27

Senior Member
Dec 21, 2013
1,441
1,801
0
Cairo
I need to remove this confirmation pop-up with every restart and make it enable by default
051bbb27ae3324edfbc30378d785d3a1.jpg


Sent from my SM-N930F using Tapatalk
 
Last edited:

josephpatrick

Senior Member
Jan 24, 2012
1,178
233
83
Bangalore
Provide your stock services.jar too please so I can see the differences.



Will share the file once i reach home, please note that the file i am using already incorporates the 5 way reboot, as per the guide this should not be an issue, will share original smal i file and also the 5 way reboot enabled smal i, will also try the guide and 120 on the original smal i file
 

tdunham

Recognized Contributor
Jun 21, 2008
13,686
36,462
0
TampaBay
Got it tnx.
You did not match surrounding code for register v12 in this part.
Change v11 to v12 in new code.

Code:
    :cond_15
    const-string v4, "emergencymode"

    invoke-virtual {v4, [COLOR="red"]v12[/COLOR]}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v4

    if-eqz v4, :cond_16

    move-object/from16 v0, p0

    iget-object v4, v0, Lcom/android/server/policy/GlobalActions;->mItems:Ljava/util/ArrayList;

    move-object/from16 v0, p0

    iget-object v5, v0, Lcom/android/server/policy/GlobalActions;->mEmergency:Lcom/android/server/policy/GlobalActions$ToggleAction;

    invoke-virtual {v4, v5}, Ljava/util/ArrayList;->add(Ljava/lang/Object;)Z

    goto/16 :goto_8

    :cond_16
    const-string/jumbo v4, "rebootrecovery"

    invoke-virtual {v4, v[COLOR="Red"]11[/COLOR]}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v4

    if-eqz v4, :cond_17

    move-object/from16 v0, p0

    iget-object v4, v0, Lcom/android/server/policy/GlobalActions;->mItems:Ljava/util/ArrayList;

    move-object/from16 v0, p0

    iget-object v5, v0, Lcom/android/server/policy/GlobalActions;->mRebootRecovery:Lcom/android/server/policy/GlobalActions$SinglePressAction;

    invoke-virtual {v4, v5}, Ljava/util/ArrayList;->add(Ljava/lang/Object;)Z

    goto/16 :goto_8

    :cond_17
 
Last edited:
  • Like
Reactions: josephpatrick

josephpatrick

Senior Member
Jan 24, 2012
1,178
233
83
Bangalore
Got it tnx.
You did not match surrounding code for register v12 in this part.
Change v11 to v12 in new code.

Code:
    :cond_15
    const-string v4, "emergencymode"

    invoke-virtual {v4, [COLOR="red"]v12[/COLOR]}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v4

    if-eqz v4, :cond_16

    move-object/from16 v0, p0

    iget-object v4, v0, Lcom/android/server/policy/GlobalActions;->mItems:Ljava/util/ArrayList;

    move-object/from16 v0, p0

    iget-object v5, v0, Lcom/android/server/policy/GlobalActions;->mEmergency:Lcom/android/server/policy/GlobalActions$ToggleAction;

    invoke-virtual {v4, v5}, Ljava/util/ArrayList;->add(Ljava/lang/Object;)Z

    goto/16 :goto_8

    :cond_16
    const-string/jumbo v4, "rebootrecovery"

    invoke-virtual {v4, v[COLOR="Red"]11[/COLOR]}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v4

    if-eqz v4, :cond_17

    move-object/from16 v0, p0

    iget-object v4, v0, Lcom/android/server/policy/GlobalActions;->mItems:Ljava/util/ArrayList;

    move-object/from16 v0, p0

    iget-object v5, v0, Lcom/android/server/policy/GlobalActions;->mRebootRecovery:Lcom/android/server/policy/GlobalActions$SinglePressAction;

    invoke-virtual {v4, v5}, Ljava/util/ArrayList;->add(Ljava/lang/Object;)Z

    goto/16 :goto_8

    :cond_17
nice catch, makes sense now that i see code around it, though technically have no clue, thanks again, let me test this out.

update: it still crash reboots even after the change, let me try again from scratch...
does it matter it is const-string/jumbo v4, "rebootrecovery" or const-string v4, "rebootrecovery"
 
Last edited:

tdunham

Recognized Contributor
Jun 21, 2008
13,686
36,462
0
TampaBay
nice catch, makes sense now that i see code around it, though technically have no clue, thanks again, let me test this out.

update: it still crash reboots even after the change, let me try again from scratch...
does it matter it is const-string/jumbo v4, "rebootrecovery" or const-string v4, "rebootrecovery"
I don't think the construct matters but you never know.
If you want to do it again that's fine or send me another log of the new error maybe its different.
 

josephpatrick

Senior Member
Jan 24, 2012
1,178
233
83
Bangalore
I don't think the construct matters but you never know.
If you want to do it again that's fine or send me another log of the new error maybe its different.

the guide was recently updated, i finally got it working, i now see the reboot recovery option on long press and also it works perfect.

the only difference between globalactions$47 and globalactions$rrecovery is the following

.method public showConditional()Z
.locals 4

const/4 v0, 0x1 this is 0 in 47

const/4 v1, 0x0 this is 1 in 47


It seems to work as this only:

.method public showConditional()Z
.locals 4

const/4 v0, 0x0

const/4 v1, 0x1
 
Last edited:
  • Like
Reactions: tdunham

josephpatrick

Senior Member
Jan 24, 2012
1,178
233
83
Bangalore
Anyone has any idea on upsm settings, in some roms if upsm+ is installed and launched, the option "override upsm default apps" shows up as enabled by default and i need to disable this option to be able to see dialer and sms apps when switching to max power saving mode.

In another rom, this option in upsm+ is disabled by default and so no additional change is required to get the dialer and sms apps working when doing the switch to max power saving mode.

Any one knows how and where this setting is controlled in the rom, had posted this on another forum but have not received a definite answer
 

tdunham

Recognized Contributor
Jun 21, 2008
13,686
36,462
0
TampaBay
Anyone has any idea on upsm settings, in some roms if upsm+ is installed and launched, the option "override upsm default apps" shows up as enabled by default and i need to disable this option to be able to see dialer and sms apps when switching to max power saving mode.

In another rom, this option in upsm+ is disabled by default and so no additional change is required to get the dialer and sms apps working when doing the switch to max power saving mode.

Any one knows how and where this setting is controlled in the rom, had posted this on another forum but have not received a definite answer
I use this app. The android.manifest.xml needs to be edited so it will show in the app drawer, I have mine hidden and launch it from Rom Control.
 

Attachments

  • UPSM_Manager.apk
    191.4 KB · Views: 24
Last edited:
  • Like
Reactions: carlosggb

josephpatrick

Senior Member
Jan 24, 2012
1,178
233
83
Bangalore
I use this app. The android.manifest.xml needs to be edited so it will show in the app drawer, I have mine hidden and launch it from Rom Control.

thanks for the app, if i use this upsm app, the disabling of the override option does not seem to really work on the ROM's i have using, they are ported ROM. UPSM+ works well but it is just that I am curious to find out what happens when i disable the option in the tool and want to hard code it without having to use an app
 

tdunham

Recognized Contributor
Jun 21, 2008
13,686
36,462
0
TampaBay
thanks for the app, if i use this upsm app, the disabling of the override option does not seem to really work on the ROM's i have using, they are ported ROM. UPSM+ works well but it is just that I am curious to find out what happens when i disable the option in the tool and want to hard code it without having to use an app
I'm not sure, I only work with stock touchwiz. Maybe someone else has the answer.
 

stangdriver44

Recognized Themer
Nov 16, 2006
3,015
9,401
0
Cali
It seems there has been interest for this so here is the

GUIDE to change SIGNALBAR COUNT AND DATA SYMBOL LTE or 4g VIA RC

So the method I used for this is csc xml edits via script execution with RC.

This is tested and works for my Tmo S6 running MM.

NOTE: you made need to adapt the xml location from other.xml to features.xml depending on your system.

So here is the script you need to add to your assets folder in RC.

4 or 5 signalbar looks like this (the scripts will be attatched below for downloading)

4 bars
Code:
#!/system/bin/sh

if [ -f /system/csc/others.xml ] ; then
   sed -i 's/<CscFeature_SystemUI_ConfigMaxRssiLevel>5/<CscFeature_SystemUI_ConfigMaxRssiLevel>4/g' /system/csc/others.xml
    chown 0:0 /system/csc/others.xml
    chmod 644 /system/csc/others.xml
    chcon u:object_r:system_file:s0 /system/csc/others.xml
fi

5 bars
Code:
#!/system/bin/sh

if [ -f /system/csc/others.xml ] ; then
   sed -i 's/<CscFeature_SystemUI_ConfigMaxRssiLevel>4/<CscFeature_SystemUI_ConfigMaxRssiLevel>5/g' /system/csc/others.xml
    chown 0:0 /system/csc/others.xml
    chmod 644 /system/csc/others.xml
    chcon u:object_r:system_file:s0 /system/csc/others.xml
fi

And here is for data icon LTE or 4g style

LTE
Code:
#!/system/bin/sh

if [ -f /system/csc/others.xml ] ; then
   sed -i 's/<CscFeature_SystemUI_ConfigOpBrandingForIndicatorIcon>TMB/<CscFeature_SystemUI_ConfigOpBrandingForIndicatorIcon>LTE/g' /system/csc/others.xml
    chown 0:0 /system/csc/others.xml
    chmod 644 /system/csc/others.xml
    chcon u:object_r:system_file:s0 /system/csc/others.xml
fi

4g style
Code:
#!/system/bin/sh

if [ -f /system/csc/others.xml ] ; then
   sed -i 's/<CscFeature_SystemUI_ConfigOpBrandingForIndicatorIcon>LTE/<CscFeature_SystemUI_ConfigOpBrandingForIndicatorIcon>TMB/g' /system/csc/others.xml
    chown 0:0 /system/csc/others.xml
    chmod 644 /system/csc/others.xml
    chcon u:object_r:system_file:s0 /system/csc/others.xml
fi

Then we add the following script in RC to execute with a promt to reboot now or later (full reboot is required)

RC edit to pref xml of your choice
Code:
        <PreferenceCategory android:title="Data Icon Style\n4g LTE or just LTE style" />
        <com.wubydax.romcontrol.v2.prefs.RunScriptPreference android:title="LTE data icon" app:scriptFileName="csc_lte_icon_enable.sh" app:showConfirmDialog="false" app:rebootOptions="optional" />
        <com.wubydax.romcontrol.v2.prefs.RunScriptPreference android:title="4G data icon" app:scriptFileName="csc_lte_icon_disable.sh" app:showConfirmDialog="false" app:rebootOptions="optional" />
        <PreferenceCategory  android:title="Signalbar Icon Style\n5 Bars or 4 Bars" />
        <com.wubydax.romcontrol.v2.prefs.RunScriptPreference android:title="5 Bar" app:scriptFileName="csc_5bar_enable.sh" app:showConfirmDialog="false" app:rebootOptions="optional" />
        <com.wubydax.romcontrol.v2.prefs.RunScriptPreference android:title="4 Bars" app:scriptFileName="csc_4bar_enable.sh" app:showConfirmDialog="false" app:rebootOptions="optional" />
I can provide screenshot later as well. No longer have a Samsung device to take screenshot live.

Enjoy
 

Attachments

  • RC_signalbar_data_style_scripts.zip
    1.2 KB · Views: 120
Last edited:

tdunham

Recognized Contributor
Jun 21, 2008
13,686
36,462
0
TampaBay
[How-To] Use Snapchat on a rooted phone

I'm getting a lot of requests for using SnapChat on a rooted rom.
SnapChat by default will not run on a rooted phone. There are ways around this, I see reference to using xposed and root cloak. Then I read that SnapChat doesn't necessary work any longer with root cloak (not sure how current that is). No matter what, I don't condone or support Xposed on any of my builds; the users are on their own in that respect... :silly:

The fix is simple, remove root:
Remove root through the superSU app, not restoring stock kernel when it asks, then it will allow login. Select Full Unroot in the SuperSU app settings.
After logging in or creating a new account to SnapChat you can now reinstall SuperSU to get root back.

SuperSU sytemless root flashable zip (download twrp flashable version)
 

carlosggb

Senior Member
Oct 18, 2012
2,119
4,232
0
Santiago
Shared this with a few people now so i thought i'd share it with everyone.

How to allow fingerprint unlock after a reboot:

Decompile SystemUI.

Go to smali/com/android/keygaurd/KeyguardUpdateMonitor.smali


Search for:
Code:
.method public isUnlockingWithFingerprintAllowed()Z

At the very end of the method you will see

Code:
:cond_2
const/4 v0, 0x0

goto :goto_0

Change the 0x0 to 0x1
Recompile!



I need help on this for the note 4.
my method is as follows:
Code:
.method public isUnlockingWithFingerprintAllowed()Z
    .locals 1

    .prologue
    .line 726
    iget-boolean v0, p0, Lcom/android/keyguard/KeyguardUpdateMonitor;->mUserHasAuthenticatedSinceBoot:Z

    return v0
.end method
How is it done in this case?
Thanks in advance
 

tdunham

Recognized Contributor
Jun 21, 2008
13,686
36,462
0
TampaBay
I need help on this for the note 4.
my method is as follows:
Code:
.method public isUnlockingWithFingerprintAllowed()Z
    .locals 1

    .prologue
    .line 726
    iget-boolean v0, p0, Lcom/android/keyguard/KeyguardUpdateMonitor;->mUserHasAuthenticatedSinceBoot:Z

    return v0
.end method
How is it done in this case?
Thanks in advance
Just add
const/4 v0, 0x1
Before return v0 to force it on.
 
  • Like
Reactions: carlosggb

Top Liked Posts

Our Apps
Get our official app!
The best way to access XDA on your phone
Nav Gestures
Add swipe gestures to any Android
One Handed Mode
Eases uses one hand with your phone