[Android Themes] Adi Aisiteru Reborn:
How to add Selectable 8 style Music Visualizer - to Notification panel

Hello again XDA :)

this guide is new style from this thread http://xdaforums.com/android/themes...alizerview-t3062114/post59626798#post59626798

ANDROID 2.3.+.+/ Gingerbread go to POST #3 http://xdaforums.com/showpost.php?p=59841454&postcount=3

Available selectable 8 style Music Visualizer :

1. Hide

2. Random

3. Circular

4. Lines

5. Top Bottom Graphic

6. Circle

7. Cycle Color Graphic

8. CyanogenMod Graphic

Oke let's start it

REQUIREMENT:

- BRAIN

- Patient

- experience

- Know how to decompile/recompiling Apk

- notepad++

- APKTOOL 2-RC4 / latest apktool.jar

STEP 1

Decompile SystemUI.apk

Download attached smali and merge to your decompiled SystemUI

STEP 2

go to SystemUI.apk/res/layout/ status_bar_expanded.xml, gemini_status_bar_expanded.xml, tw_status_bar_expanded.xml, status_bar_tracking.xml , depend on your UI

and add the red line

<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.phone.NotificationPanelView android:id="@id/notification_panel" android:background="@drawable/notification_panel_bg" android:paddingTop="@dimen/notification_panel_padding_top" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_marginStart="@dimen/notification_panel_margin_left"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:systemui="http://schemas.android.com/apk/res/com.android.systemui">
<View android:id="@id/handle" android:background="@drawable/status_bar_close" android:visibility="invisible" android:layout_width="fill_parent" android:layout_height="@dimen/close_handle_height" />
<LinearLayout android:layout_gravity="bottom" android:orientation="vertical" android:id="@id/carrier_label_container" android:layout_width="fill_parent" android:layout_height="wrap_content" android:animateLayoutChanges="false">
<include android:layout_gravity="bottom" android:layout_width="fill_parent" android:layout_height="@dimen/carrier_label_height" layout="@layout/subs_label" />
<include android:layout_gravity="bottom" android:layout_width="fill_parent" android:layout_height="@dimen/carrier_label_height" android:layout_marginBottom="@dimen/close_handle_height" layout="@layout/carrier_label" />
</LinearLayout>
<LinearLayout android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_marginBottom="@dimen/close_handle_underlap" android:animateLayoutChanges="false">
<include android:layout_width="fill_parent" android:layout_height="@dimen/notification_panel_header_height" layout="@layout/status_bar_expanded_header" />
<ViewStub android:id="@id/ribbon_settings_stub" android:layout="@layout/ribbon_settings" android:layout_width="fill_parent" android:layout_height="@dimen/qs_ribbon_height_big" />
<TextView android:textAppearance="@style/TextAppearance.StatusBar.Expanded.Network.EmergencyOnly" android:gravity="center" android:id="@id/emergency_calls_only" android:padding="4.0dip" android:visibility="gone" android:layout_width="fill_parent" android:layout_height="wrap_content" />
<FrameLayout android:layout_width="fill_parent" android:layout_height="wrap_content">
<ViewStub android:id="@id/flip_settings_stub" android:layout="@layout/flip_settings" android:layout_width="fill_parent" android:layout_height="wrap_content" />
<ScrollView android:id="@id/scroll" android:fadingEdge="none" android:layout_width="fill_parent" android:layout_height="wrap_content" android:overScrollMode="ifContentScrolls">
<com.android.systemui.statusbar.policy.NotificationRowLayout android:id="@id/latestItems" android:layout_width="fill_parent" android:layout_height="wrap_content" systemui:rowHeight="@dimen/notification_row_min_height" />
</ScrollView>
</FrameLayout>
</LinearLayout>
[COLOR="Red"] <com.adi.rom.interface.MusicEqualizerVisualizer android:layout_gravity="bottom" android:id="@id/new_visualizer_view_panel" android:layout_width="fill_parent" android:layout_height="50.0dip" android:layout_marginBottom="36.0dip">
<FrameLayout android:id="@id/new_custom_visualizer_view_panel" android:layout_width="fill_parent" android:layout_height="fill_parent">
<com.adi.rom.interface.VisualizerView android:id="@id/new_custom_visualizer_view" android:visibility="gone" android:layout_width="fill_parent" android:layout_height="fill_parent" />
</FrameLayout>
</com.adi.rom.interface.MusicEqualizerVisualizer>[/COLOR]
</com.android.systemui.statusbar.phone.NotificationPanelView>

STEP 3

SystemUI.apk/res/values/colors.xml

add the red line to end of it before </resources>

<color name="status_bar_clock_color">#ffffffff</color>
<color name="equalizer_fill_color">#96ffffff</color>
[COLOR="Red"]<color name="new_custom_equalizer_fill_color">#96ffffff</color>[/COLOR]
</resources>

SystemUI.apk/res/values/dimens.xml

add the red line to end of it before </resources>

<dimen name="status_bar_battery_bottom_padding">1.0px</dimen>
<dimen name="eqalizer_path_effect_1">6.0dip</dimen>
<dimen name="eqalizer_path_effect_2">1.0dip</dimen>
<dimen name="eqalizer_path_stroke_width">6.0dip</dimen>
[COLOR="Red"]<dimen name="new_custom_eqalizer_path_effect_1">6.0dip</dimen>
<dimen name="new_custom_eqalizer_path_effect_2">1.0dip</dimen>
<dimen name="new_custom_eqalizer_path_stroke_width">6.0dip</dimen>[/COLOR]
</resources>

SystemUI.apk/res/values/ids.xml

add the red line to end of it before </resources>

<item type="id" name="recent_force_stop">false</item>
<item type="id" name="recent_wipe_app">false</item>
<item type="id" name="recent_uninstall">false</item>
[COLOR="Red"]<item type="id" name="new_visualizer_view_panel">false</item>
<item type="id" name="new_custom_visualizer_view_panel">false</item>
<item type="id" name="new_custom_visualizer_view">false</item>[/COLOR]
</resources>

SystemUI.apk/res/values/integers.xml

add the red line to end of it before </resources>

<integer name="equalizer_divisions">4</integer>
<integer name="equalizer_db_fuzz_factor">2</integer>
<integer name="equalizer_db_fuzz">-10</integer>
[COLOR="Red"]<integer name="new_custom_equalizer_divisions">4</integer>
<integer name="new_custom_equalizer_db_fuzz_factor">2</integer>
<integer name="new_custom_equalizer_db_fuzz">-10</integer>[/COLOR]
</resources>

STEP -4

AndroidManifest.xml

Add the red line

<uses-permission android:name="android.permission.READ_DREAM_STATE"/>
<uses-permission android:name="android.permission.WRITE_DREAM_STATE"/>
<uses-permission android:name="android.permission.WRITE_SECURE_SETTINGS"/>
<uses-permission android:name="android.permission.READ_SYNC_SETTINGS"/>
<uses-permission android:name="android.permission.WRITE_SYNC_SETTINGS"/>
[COLOR="Red"]<uses-permission android:name="android.permission.RECORD_AUDIO"/>
<uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS"/>[/COLOR]
<application android:allowBackup="false" android:allowClearUserData="false" android:hardwareAccelerated="true" android:icon="@android:drawable/platlogo" android:label="@string/app_label" android:persistent="true">
<service android:exported="true" android:name="SystemUIService"/>

STEP -5

- Compile

- Sign it

- Disable Signature check

- Push to System/app or System/priv-app with right permission

- Download attached VisualizerStyleSettings.apk, push to System/app with right permission

- or use this Visualizer settings http://xdaforums.com/showpost.php?p=59883864&postcount=53

You can try using any of the keys that come with whatever apk signing tool you use, but you will more then likely end up with a SystemUI.apk that wont show as being installed, you must sign it with platfrom keys from CyanogenMod's android_build github https://github.com/CyanogenMod/android_build/tree/jellybean/target/product/security

Note !

for CM / AOSP from source whic has

STATIC TILES, you need to uncheck/disable Equalizer tile, otherwise the Visualizer will not appear on Notification panel

Credits :

- CyanogenMod

- Recognized Developer / Recognized Themer [MENTION=3989065]serajr[/MENTION] for his ResourceUtils.smali