[Guides & Links] TOUCHWIZ UNIFIED MODS THREAD

Search This thread

josephpatrick

Senior Member
Jan 24, 2012
1,178
233
83
Bangalore
@JoHnNYBlaZE716
The clock in the center + flashing separator + the date at the bottom + lock button.



SystemUI\res\layout\status_bar.xml
after the strings
Code:
<com.android.systemui.statusbar.phone.IconMerger android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/notificationIcons" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_alignParentStart="true" />
 </com.android.keyguard.AlphaOptimizedLinearLayout>
add
Code:
<RelativeLayout android:gravity="center" android:layout_gravity="center" android:layout_width="45.0dip" android:layout_height="fill_parent" android:layout_marginLeft="0.0dip" android:layout_marginRight="0.0dip" android:singleLine="false" android:layout_alignParentRight="true">
			<LinearLayout android:gravity="center" android:orientation="horizontal" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginTop="0.0dip" android:singleLine="false" android:layout_alignParentRight="true">
				<TextClock android:textSize="10.0dip" android:textStyle="bold" android:textColor="#ffffffff" android:paddingLeft="2.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginTop="8.0dip" android:includeFontPadding="true" android:shadowColor="#fe000000" android:shadowDx="3.0" android:shadowDy="3.0" android:shadowRadius="3.0" android:fontFamily="sans-serif" android:format24Hour="EE" />
				<TextView android:textSize="10.0dip" android:textStyle="normal" android:textColor="#ffffffff" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginTop="9.0dip" android:layout_marginBottom="4.0dip" android:text="." android:includeFontPadding="true" android:shadowColor="#fe000000" android:shadowDx="3.0" android:shadowDy="3.0" android:shadowRadius="3.0" android:fontFamily="sans-serif" />
				<TextClock android:textSize="10.0dip" android:textStyle="bold" android:textColor="#ffffffff" android:paddingLeft="1.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginTop="8.0dip" android:includeFontPadding="true" android:shadowColor="#fe000000" android:shadowDx="3.0" android:shadowDy="3.0" android:shadowRadius="3.0" android:fontFamily="sans-serif" android:format24Hour="d" />
				<TextView android:textSize="10.0dip" android:textStyle="normal" android:textColor="#ffffffff" android:paddingLeft="1.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginTop="9.0dip" android:layout_marginBottom="4.0dip" android:text="." android:includeFontPadding="true" android:shadowColor="#fe000000" android:shadowDx="3.0" android:shadowDy="3.0" android:shadowRadius="3.0" android:fontFamily="sans-serif" />
				<TextClock android:textSize="10.0dip" android:textStyle="bold" android:textColor="#ffffffff" android:paddingLeft="1.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginTop="8.0dip" android:includeFontPadding="true" android:shadowColor="#fe000000" android:shadowDx="3.0" android:shadowDy="3.0" android:shadowRadius="3.0" android:fontFamily="sans-serif" android:format24Hour="MM" />
			</LinearLayout>
			<LinearLayout android:gravity="center" android:orientation="horizontal" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginTop="-2.0dip" android:singleLine="false" android:layout_alignParentRight="true">
				<TextClock android:textSize="15.0dip" android:textStyle="bold" android:textColor="#ffffffff" android:paddingLeft="0.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:includeFontPadding="true" android:shadowColor="#fe000000" android:shadowDx="3.0" android:shadowDy="3.0" android:shadowRadius="3.0" android:fontFamily="sans-serif" android:format24Hour="kk" />
				<blink android:layout_gravity="top|center" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginTop="-1.0dip">
					<TextView android:textSize="15.0dip" android:textStyle="normal" android:textColor="#ffffffff" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginBottom="4.0dip" android:text=":" android:includeFontPadding="true" android:shadowColor="#fe000000" android:shadowDx="3.0" android:shadowDy="3.0" android:shadowRadius="3.0" android:fontFamily="sans-serif" />
				</blink>
				<TextClock android:textSize="15.0dip" android:textStyle="bold" android:textColor="#ffffffff" android:paddingRight="0.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:includeFontPadding="true" android:shadowColor="#fe000000" android:shadowDx="3.0" android:shadowDy="3.0" android:shadowRadius="3.0" android:fontFamily="sans-serif" android:format24Hour="mm" />
				<com.android.systemui.statusbar.policy.Clock android:textSize="@dimen/status_bar_clock_size" android:textColor="#ffffffff" android:ellipsize="none" android:gravity="left|center" android:id="@id/clock" android:paddingLeft="3.0dip" android:visibility="gone" android:layout_width="0.0dip" android:layout_height="0.0dip" android:layout_marginTop="2.3299866dip" android:singleLine="true" android:includeFontPadding="false" />
			</LinearLayout>
			<com.android.systemui.statusbar.policy.KeyButtonView android:gravity="right" android:layout_gravity="right" android:id="@id/back" android:background="#00000000" android:layout_width="30.0dip" android:layout_height="30.0dip" android:layout_alignParentRight="true" android:contentDescription="@string/accessibility_back" systemui:keyCode="26" />
		</RelativeLayout>
Remove the stock clock
Code:
<com.android.systemui.statusbar.policy.Clock .......

will both these work? thanks in advance

Code:
</com.android.keyguard.AlphaOptimizedLinearLayout>
 <RelativeLayout android:gravity="center" android:layout_gravity="center" android:layout_width="45.0dip" android:layout_height="fill_parent" android:layout_marginLeft="0.0dip" android:layout_marginRight="0.0dip" android:singleLine="false" android:layout_alignParentRight="true">
		<com.android.systemui.statusbar.policy.KeyButtonView android:gravity="right" android:layout_gravity="right" android:id="@id/back" android:background="#00000000" android:layout_width="30.0dip" android:layout_height="30.0dip" android:layout_alignParentRight="true" android:contentDescription="@string/accessibility_back" systemui:keyCode="26" />
</RelativeLayout>

OR
Code:
</com.android.keyguard.AlphaOptimizedLinearLayout>
<com.android.systemui.statusbar.policy.KeyButtonView android:gravity="right" android:layout_gravity="right" android:id="@id/back" android:background="#00000000" android:layout_width="30.0dip" android:layout_height="30.0dip" android:layout_alignParentRight="true" android:contentDescription="@string/accessibility_back" systemui:keyCode="26" />
 

jaylence

Senior Member
Jun 24, 2012
751
730
113
Santo Tomas
No additional, only like guided. Maybe some changes to match surround code. Read your logcat what happen if not work

Hi again.
I re-did everything from start, adjusted the V's to match my smali's surrounding code but still option to chamge background won't work on my S6E (G925F).

By the way, on my QSTileView.smali, i found 2 occurrences of the public value for drawable normal bg.
One is in .method constructor <init> and the other one is in .method onClearState.

Does this mean I need to edit the onClearState method to match the changes done in constructor method?
 
Last edited:

thereassaad

Recognized Contributor
Aug 22, 2013
7,620
9,713
263
Bierut
So guy's what's the logs ? How can we imagine or thinking why it's fc , sorry to say it but this thing's issues its urs , its ur failed its ur errors , we can't imagine nor we can't help , yes we got fc & its our lovely when we got it because we can seen why by logcat , anyway if its work till ur updated base then u need to update the ux apks or its need framework edited or missing libs or too some xml / permission , damn i can't say even why .....
 
  • Like
Reactions: sonnguyenpg

ryan42680

Senior Member
Aug 17, 2013
1,309
4,080
0
Bou-ismail
steamcommunity.com
So guy's what's the logs ? How can we imagine or thinking why it's fc , sorry to say it but this thing's issues its urs , its ur failed its ur errors , we can't imagine nor we can't help , yes we got fc & its our lovely when we got it because we can seen why by logcat , anyway if its work till ur updated base then u need to update the ux apks or its need framework edited or missing libs or too some xml / permission , damn i can't say even why .....

Thx anyway mate
 

asc1977

Senior Member
Apr 15, 2012
5,330
6,989
0
Schwetzingen
Hi again.
I re-did everything from start, adjusted the V's to match my smali's surrounding code but still option to chamge background won't work on my S6E (G925F).

By the way, on my QSTileView.smali, i found 2 occurrences of the public value for drawable normal bg.
One is in .method constructor <init> and the other one is in .method onClearState.

Does this mean I need to edit the onClearState method to match the changes done in constructor method?
I cant help you because i didnt see what you done and what happen in logcat or what exactly not work. You need logcat like i say before or/and we must know which guide you do and what you do in smalis.
 

yogi_78

Senior Member
Jan 1, 2014
73
9
28
hello
i want to use TWLauncher swipe mod in j5 2016 android
MM.but i can't find flipboard.apk string in smali/com/android/launcher2/PagedView.smali. Is there other way to do it
thank you
 
Last edited:

jaylence

Senior Member
Jun 24, 2012
751
730
113
Santo Tomas
Change toggle buttons background in the notification panel.

@asc1977 here are the changes I made in QSTileView.smali
Blue text were the ones from the guide.
Red text are my edits to match the surrounding codes and pubic values.

Code:
.method public constructor <init>(Landroid/content/Context;)V
    .locals 6
    .
    .
    .
    .line 125
    .end local v0    # "dh":I
    :cond_0
    iget-object v2, p0, Lcom/android/systemui/qs/QSTileView;->mIcon:Landroid/view/View;

    [COLOR="Blue"]invoke-virtual {p0}, Lcom/android/systemui/qs/QSTileView;->set_toggles()I

    move-result [COLOR="red"]v3[/COLOR]

    if-eqz [COLOR="red"]v3[/COLOR], :[COLOR="red"]cond_1[/COLOR]
[/COLOR]
    invoke-virtual {v2, v3}, Landroid/view/View;->setBackgroundResource(I)V

    [COLOR="Blue"]invoke-virtual {[COLOR="red"]v2[/COLOR]}, Landroid/view/View;->getBackground()Landroid/graphics/drawable/Drawable;

    move-result-object v0

    invoke-virtual {[COLOR="Red"]v2[/COLOR], v0}, Landroid/view/View;->setBackground(Landroid/graphics/drawable/Drawable;)V

    :[COLOR="red"]cond_1[/COLOR]
   [/COLOR] iget-object v1, p0, Lcom/android/systemui/qs/QSTileView;->mIcon:Landroid/view/View;

    goto: got_0
.end method

No other changes made in the additional smali except for the corresponding public value of the added drawables.

Code:
.method set_toggles()I
    .locals 4

    iget-object v1, p0, Lcom/android/systemui/qs/QSTileView;->mLabel:Landroid/widget/TextView;

    invoke-virtual {v1}, Landroid/widget/ImageView;->getContext()Landroid/content/Context;

    move-result-object v1

    invoke-virtual {v1}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

    move-result-object v1

    const-string v2, "toggle_buttons_background"

    const/4 v3, 0x0

    invoke-static {v1, v2, v3}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I

    move-result v1

    const v2, 0x1

    if-eq v1, v2, :cond_1

    const v2, 0x2

    if-eq v1, v2, :cond_2

    const v2, 0x3

    if-eq v1, v2, :cond_3

    const v2, 0x4

    if-eq v1, v2, :cond_4

    const v2, 0x5

    if-eq v1, v2, :cond_5

    const v2, 0x6

    if-eq v1, v2, :cond_6

    const v2, 0x7

    if-eq v1, v2, :cond_7

    const v2, 0x8

    const v0, [COLOR="Red"]0x7f020631 [/COLOR]#    <public type="drawable" name="tw_quick_panel_quick_setting_button_round_bg" id="0x7f020631" />

    goto :goto_1

    :cond_1
    const v0, 0x0

    goto :goto_1

    :cond_2
    const v0, [COLOR="red"]0x7f020710 [/COLOR]#    <public type="drawable" name="tw_quick_panel_quick_setting_button_round_bg_01" id="0x7f020710" />

    goto :goto_1

    :cond_3
    const v0, [COLOR="red"]0x7f020711 [/COLOR]#    <public type="drawable" name="tw_quick_panel_quick_setting_button_round_bg_02" id="0x7f020711" />

    goto :goto_1

    :cond_4
    const v0, [COLOR="red"]0x7f020712 [/COLOR]#    <public type="drawable" name="tw_quick_panel_quick_setting_button_round_bg_03" id="0x7f020712" />

    goto :goto_1

    :cond_5
    const v0, [COLOR="red"]0x7f020713 [/COLOR]#    <public type="drawable" name="tw_quick_panel_quick_setting_button_round_bg_04" id="0x7f020713" />

    goto :goto_1

    :cond_6
    const v0, [COLOR="red"]0x7f020714 [/COLOR]#    <public type="drawable" name="tw_quick_panel_quick_setting_button_round_bg_05" id="0x7f020714" />

    goto :goto_1

    :cond_7
    const v0, [COLOR="red"]0x7f020715 [/COLOR]#    <public type="drawable" name="tw_quick_panel_quick_setting_button_round_bg_06" id="0x7f020715" />

    goto :goto_1

    :goto_1
    return v0
.end method

Here is my logcat.

https://mega.nz/#!IgMmWQZA!U6EUTmx8P641BrVjKv3tBOkyUyFdV6yjzW6u9jN-YUY
 

bollycao18

Senior Member
Oct 13, 2009
490
276
0
lisbon
guys any help for this what i did wrong ??? tanks in advance

Screenshot_20161021_130446.png
 

genuine55

Senior Member
[Guide] Remove Charging and Low Battery dialog from Lockscreen

@tdunham I tried your remove charging and low battery dialog from lockscreen I didn't see the method u posted in the xml I'm using the tmobile s6 any help would be appreciated this (method private getChargeInfo) I do not see this this method in there mate

---------- Post added at 05:46 PM ---------- Previous post was at 05:39 PM ----------
@JavixKGDmate can I ask how did u get the data usage in the middle of pull down under the brightness slider like that ? Thanks also your device info in thr notification pull down where did u get the infother for that mod I used one but I'm guessing it's the old device info thanks a lot for any help
 

daxgirl

Senior Member
Jun 30, 2012
4,047
9,165
0
Jerusalem
[Guide] Remove Charging and Low Battery dialog from Lockscreen

@tdunham I tried your remove charging and low battery dialog from lockscreen I didn't see the method u posted in the xml I'm using the tmobile s6 any help would be appreciated this (method private getChargeInfo) I do not see this this method in there mate

---------- Post added at 05:46 PM ---------- Previous post was at 05:39 PM ----------
@JavixKGDmate can I ask how did u get the data usage in the middle of pull down under the brightness slider like that ? Thanks also your device info in thr notification pull down where did u get the infother for that mod I used one but I'm guessing it's the old device info thanks a lot for any help

Those are our original mods. Look on the first page of this thread under "6thGear repository". Both custom position for data usage and our original device info are there.

Sent from my SM-G920F using Tapatalk
 

genuine55

Senior Member
Those are our original mods. Look on the first page of this thread under "6thGear repository". Both custom position for data usage and our original device info are there.

Sent from my SM-G920F using Tapatalk
Thanks a lot for the help

Sent from my SM-G925T using Tapatalk

---------- Post added at 06:45 PM ---------- Previous post was at 06:35 PM ----------

Those are our original mods. Look on the first page of this thread under "6thGear repository". Both custom position for data usage and our original device info are there.

Sent from my SM-G920F using Tapatalk

Can I do the device info mod without having rom control ?

Also any help with removing charging info from lockscreen I followed the guide for it but the method that's in the guide is not in my xml
method private getChargeInfo that's not in my xml that the guide says to edit thanks in advance
 

JavixKGD

Senior Member
May 9, 2015
1,530
3,000
153
Somewhere around here.....
@genuine55 yeah you can make the mod and will work without rom control, but u wont be able to make changes unless you go to the databases and make the changes manually. So.....RC is the way to go friend. Unless u just want that static there at all times without being able to choose what is displayed and in what color. Also the data usage is like @daxgirl mentioned on the first page along with this mod under 6th Gear repository. Good luck!

Sent from my TWIZtd N910T3 N7
 

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