[Android General] By Zonik:
Guide Custom Logo UI (18 types+Gallery)

A big thanks to [MENTION=6696465]Zidni[/MENTION] for amazing mod, original post here https://xdaforums.com/showpost.php?p=72987489&postcount=11079

a simple modification to this mod:

••On-Fly

••Position logo (Right/Left/hide)

••New logos with preview in RC

Well, we started!!

1.-Decompile you SystemUI and mergue files

In the compare folder do the edits to your smali, if you do not do so you will have FC UI, this is to do the on-fly mod and the mod can read GearContext observer .. If your rom already has this support skip this step

2.-Go to notification_icon_area.xml (res/layout folder)

before of

<com.android.systemui.statusbar.StatusBarIconView android:id="@id/moreIcon" android:visibility="gone" android:layout_width="@dimen/status_bar_icon_size" android:layout_height="fill_parent" android:src="@drawable/stat_notify_more" />

Add this

<com.zonik.switch.LayoutOff android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginTop="1.0dip" android:layout_marginBottom="2.0dip" android:paddingEnd="3.0dip" key="z_logo_hide_left">
<com.zonik.logo.ZCustomLogo android:layout_width="20.0dip" android:layout_height="20.0dip" android:layout_centerHorizontal="true" android:layout_centerVertical="true" />
</com.zonik.switch.LayoutOff>

equal to this

<com.zonik.switch.LayoutOff android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginTop="1.0dip" android:layout_marginBottom="2.0dip" android:paddingEnd="3.0dip" key="z_logo_hide_left">
<com.zonik.logo.ZCustomLogo android:layout_width="20.0dip" android:layout_height="20.0dip" android:layout_centerHorizontal="true" android:layout_centerVertical="true" />
</com.zonik.switch.LayoutOff>
<com.android.systemui.statusbar.StatusBarIconView android:id="@id/moreIcon" android:visibility="gone" android:layout_width="@dimen/status_bar_icon_size" android:layout_height="fill_parent" android:src="@drawable/stat_notify_more" />

3.-Go to status_bar.xml (res/layout folder)

before of

<TextView android:textSize="12.0dip" android:textColor="#ffffffff" android:gravity="center_vertical" android:id="@id/knoxCustomStatusBarText" android:visibility="gone" android:layout_width="0.0dip" android:layout_height="0.0dip" android:includeFontPadding="false" />

<include layout="@layout/system_icons" />

Add this

<com.zonik.switch.LayoutOff android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginTop="1.0dip" android:layout_marginBottom="2.0dip" android:paddingEnd="3.0dip" key="z_logo_hide_right">
<com.zonik.logo.ZCustomLogo android:layout_width="20.0dip" android:layout_height="20.0dip" android:layout_centerHorizontal="true" android:layout_centerVertical="true" />
</com.zonik.switch.LayoutOff>

equal to this

<com.zonik.switch.LayoutOff android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginTop="1.0dip" android:layout_marginBottom="2.0dip" android:paddingEnd="3.0dip" key="z_logo_hide_right">
<com.zonik.logo.ZCustomLogo android:layout_width="20.0dip" android:layout_height="20.0dip" android:layout_centerHorizontal="true" android:layout_centerVertical="true" />
</com.zonik.switch.LayoutOff>
<TextView android:textSize="12.0dip" android:textColor="#ffffffff" android:gravity="center_vertical" android:id="@id/knoxCustomStatusBarText" android:visibility="gone" android:layout_width="0.0dip" android:layout_height="0.0dip" android:includeFontPadding="false" />
<include layout="@layout/system_icons" />

Done now compile :fingers-crossed:

4.-Rom Control

Mergue files in drawable folder

-------

in arrays.xml

<array name="zcustom_logo_drawables">
<item>@drawable/zrr</item>
<item>@drawable/zbiohazard</item>
<item>@drawable/zLion</item>
<item>@drawable/zsnake</item>
<item>@drawable/zhead</item>
<item>@drawable/znike</item>
<item>@drawable/zadidas</item>
<item>@drawable/zgoku</item>
<item>@drawable/zgoku2</item>
<item>@drawable/zdiamant</item>
<item>@drawable/zpacman</item>
<item>@drawable/zfire</item>
<item>@drawable/zsuperman</item>
<item>@drawable/zheart</item>
<item>@drawable/zhi</item>
<item>@drawable/zhi2</item>
<item>@drawable/zplaystation</item>
<item>@drawable/ztrebol</item>
</array>
<string-array name="zcustom_logo_entries">
<item>Resurrection Remix</item>
<item>Biohazard</item>
<item>Lion</item>
<item>Snake</item>
<item>Head</item>
<item>Nike</item>
<item>Adidas</item>
<item>Pegatina DB</item>
<item>Pegatina DB 2</item>
<item>Diamond</item>
<item>Pacman</item>
<item>Fire</item>
<item>Superman</item>
<item>Heart</item>
<item>Hello 1</item>
<item>Hello2</item>
<item>PlayStation</item>
<item>Marijuana</item>
</string-array>
<string-array name="zcustom_logo_values">
<item>2</item>
<item>3</item>
<item>4</item>
<item>5</item>
<item>6</item>
<item>7</item>
<item>8</item>
<item>9</item>
<item>10</item>
<item>11</item>
<item>12</item>
<item>13</item>
<item>14</item>
<item>15</item>
<item>16</item>
<item>17</item>
<item>18</item>
<item>19</item>
</string-array>
<string-array name="custom_logo_image_entries">
<item>Select from Gallery</item>
</string-array>
<string-array name="custom_logo_image_values">
<item>1</item>
</string-array>

in preferences

<PreferenceScreen android:title="Custom Logo UI">
<PreferenceCategory android:title="Custom Logo UI position" />
<com.wubydax.romcontrol.v2.prefs.MySwitchPreference android:title="Logo Visibility on the left" android:key="z_logo_hide_left" android:defaultValue="false" android:summaryOn="Shown" android:summaryOff="Hidden" />
<com.wubydax.romcontrol.v2.prefs.MySwitchPreference android:title="Logo Visibility on the right" android:key="z_logo_hide_right" android:defaultValue="false" android:summaryOn="Shown" android:summaryOff="Hidden" />
<PreferenceCategory android:title="Custom Logo Image" />
<com.wubydax.romcontrol.v2.prefs.MyListPreference android:entries="@array/custom_logo_image_entries" android:title="Custom Logo Image" android:key="z_logo_type" android:entryValues="@array/custom_logo_image_values" app:dependentValue="1" />
<PreferenceCategory android:title="Please select image under 1 MB size, otherwise it will be laggy" />
<com.wubydax.romcontrol.v2.prefs.UriSelectionPreference android:title="Select Logo From Gallery" android:key="z_logo_image_uri" app:packageNameToKill="com.android." app:isSilent="false" />
<PreferenceCategory android:title="Custom Logo Type" />
<com.wubydax.romcontrol.v2.prefs.ThumbnailListPreference android:title="Custom Logo Type" android:key="z_logo_type" android:dependency="z_logo_hide_left" android:defaultValue="0" app:drawableArray="@array/zcustom_logo_drawables" app:entryList="@array/zcustom_logo_entries" app:entryValuesList="@array/zcustom_logo_values" />
<com.wubydax.romcontrol.v2.prefs.ColorPickerPreference android:title="Logo Colors" android:key="z_logo_Color" android:defaultValue="\#ffccdd" />
</PreferenceScreen>

Done compile RC

Credt: Thanks also to [MENTION=6911575]BlackMesa123[/MENTION] for observer method in this mod and some new icons

Captures: