I've attached the launcher.apk file with this post from the Galaxy SII system dump
Has anyone successfully ported the TouchWiz 4 launcher for the X10 yet?
On TripMIUI: not installed
Wolfbreak CM6.1.3: not installed
If it is straight from the system dump it will probably not install on any x10 rom with out someone tweaking the files a little bit. This was the same problem I faced with the Casio Commando launcher I system dumped.
this one works on my 2.1 rom
http://forum.xda-developers.com/showthread.php?t=1068147
svtfmook said:
this one works on my 2.1 rom
http://forum.xda-developers.com/showthread.php?t=1068147
Click to expand...
Click to collapse
This is the touchwiz 3 launcher (galaxy s), he ask about touchwiz 4 launcher (galaxy s 2).
bye
achotjan not installed
x10iachotjanblisshdluciddark.bb58
have you tried actually moving it to system/apps and changing permissions?
for the record, I tried on rdannars superasop v006, and it was a no go. Both regular install, and push to system/apps....
It doesn't work on any rom, i had tried it before as i wanted to put touchwiz 4 in kryptonfroyo rom, but i couldnt get it working. I'm still trying on it though.
Edit- it doesn't work with any 2.3 rom
jobumaru said:
This is the touchwiz 3 launcher (galaxy s), he ask about touchwiz 4 launcher (galaxy s 2).
bye
Click to expand...
Click to collapse
hence why i said "this one".
The launcher found in touchwiz 4.0 is more deeply rooted to the system then just an .apk. It relies on a few files in the framework, AKA the skin known as TouchWiz. You will see that it'll run fine on any phone with Touchwiz 4.0 (GS &GSII) but nothing else- until we add the files the launcher needs in the framework to the launcher itself. Or make it independent of those files at all.
I'm researching everything right now. I can't be the one to do this, but I can figure out how to do it.
Hello X10 users,
Someone on our neo forums has posted a link to TouchWiz 4, and it works fine on my phone (see signature of info). [It might be noted that I just installed the apk manually as a user app via a file explorer, instead of using th recovery zip, didn't try that.] Recovery zip in attachments.
Now, I see a small problem. The Galaxy SII has a 480x800 resolution, and we have 480x854 resolution. Hence this:
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
So I decompiled the apk to see if I can lower the paginator icons. I think this is the correct xml file. Problem is: I'm a noob in most development stuff, including this. Who can help me?
TouchWiz30LauncherICS.apk\res\values\public.xml
Code:
<?xml version="1.0" encoding="utf-8"?>
<resources>
<public type="attr" name="direction" id="0x7f010000" />
<public type="attr" name="defaultScreen" id="0x7f010001" />
<public type="attr" name="delayedShortcutDisplay" id="0x7f010002" />
<public type="attr" name="cellWidth" id="0x7f010003" />
<public type="attr" name="cellHeight" id="0x7f010004" />
<public type="attr" name="rowStartPadding" id="0x7f010005" />
<public type="attr" name="rowEndPadding" id="0x7f010006" />
<public type="attr" name="columnStartPadding" id="0x7f010007" />
<public type="attr" name="columnEndPadding" id="0x7f010008" />
<public type="attr" name="columnCells" id="0x7f010009" />
<public type="attr" name="rowCells" id="0x7f01000a" />
<public type="attr" name="applyIconHoverColorFilter" id="0x7f01000b" />
<public type="attr" name="drawDeleteZoneBg" id="0x7f01000c" />
<public type="attr" name="inOutAnimationTranslationRatio" id="0x7f01000d" />
<public type="attr" name="inOutAnimationDuration" id="0x7f01000e" />
<public type="attr" name="supportAppUninstall" id="0x7f01000f" />
<public type="attr" name="className" id="0x7f010010" />
<public type="attr" name="packageName" id="0x7f010011" />
<public type="attr" name="screen" id="0x7f010012" />
<public type="attr" name="x" id="0x7f010013" />
<public type="attr" name="y" id="0x7f010014" />
<public type="attr" name="spanX" id="0x7f010015" />
<public type="attr" name="spanY" id="0x7f010016" />
<public type="attr" name="icon" id="0x7f010017" />
<public type="attr" name="title" id="0x7f010018" />
<public type="attr" name="uri" id="0x7f010019" />
<public type="attr" name="multipleSize" id="0x7f01001a" />
<public type="attr" name="classNameFallback" id="0x7f01001b" />
<public type="attr" name="packageNameFallback" id="0x7f01001c" />
<public type="attr" name="foldertitle" id="0x7f01001d" />
<public type="attr" name="count" id="0x7f01001e" />
<public type="attr" name="width" id="0x7f01001f" />
<public type="attr" name="height" id="0x7f010020" />
<public type="attr" name="left" id="0x7f010021" />
<public type="attr" name="top" id="0x7f010022" />
<public type="attr" name="iconColumnCount" id="0x7f010023" />
<public type="attr" name="menuColumnCount" id="0x7f010024" />
<public type="attr" name="itemNumOfPage" id="0x7f010025" />
<public type="attr" name="zoomScaleLM" id="0x7f010026" />
<public type="attr" name="zoomTransYLM" id="0x7f010027" />
<public type="attr" name="modelFamily" id="0x7f010028" />
<public type="attr" name="model" id="0x7f010029" />
<public type="attr" name="useLargeDrawablesOnly" id="0x7f01002a" />
<public type="attr" name="screenCount" id="0x7f01002b" />
<public type="attr" name="defaultScreenCount" id="0x7f01002c" />
<public type="attr" name="useFullScreenQuickViewLandScape" id="0x7f01002d" />
<public type="attr" name="useMainMenuConcentrationEffect" id="0x7f01002e" />
<public type="attr" name="use16BitWindow" id="0x7f01002f" />
<public type="attr" name="useMainMenuListMode" id="0x7f010030" />
<public type="attr" name="workspaceCellsX" id="0x7f010031" />
<public type="attr" name="workspaceCellsY" id="0x7f010032" />
<public type="attr" name="maxHeight" id="0x7f010033" />
<public type="attr" name="backgroundColor" id="0x7f010034" />
<public type="attr" name="dividerThickness" id="0x7f010035" />
<public type="attr" name="dividerColor" id="0x7f010036" />
<public type="attr" name="horizontalScrollbarHeight" id="0x7f010037" />
<public type="attr" name="verticalScrollbarWidth" id="0x7f010038" />
<public type="attr" name="scrollbarPadding" id="0x7f010039" />
<public type="attr" name="scrollbarColor" id="0x7f01003a" />
<public type="attr" name="textBg" id="0x7f01003b" />
<public type="attr" name="textTypeface" id="0x7f01003c" />
<public type="attr" name="textTypefaceStyle" id="0x7f01003d" />
<public type="attr" name="textFontSize" id="0x7f01003e" />
<public type="attr" name="textColor" id="0x7f01003f" />
<public type="attr" name="textUppercase" id="0x7f010040" />
<public type="attr" name="textCharSpacingStrategy" id="0x7f010041" />
<public type="attr" name="textCharSpacingWidth" id="0x7f010042" />
<public type="attr" name="textCharPaddingLeft" id="0x7f010043" />
<public type="attr" name="textCharPaddingRight" id="0x7f010044" />
<public type="attr" name="indexGravity" id="0x7f010045" />
<public type="attr" name="popupWidth" id="0x7f010046" />
<public type="attr" name="popupHeight" id="0x7f010047" />
<public type="attr" name="popupWidthInc" id="0x7f010048" />
<public type="attr" name="popupHeightInc" id="0x7f010049" />
<public type="attr" name="firstCharColor" id="0x7f01004a" />
<public type="attr" name="touchAlpha" id="0x7f01004b" />
<public type="attr" name="normalAlpha" id="0x7f01004c" />
<public type="attr" name="alphaAnimDur" id="0x7f01004d" />
<public type="attr" name="pressDelay" id="0x7f01004e" />
<public type="attr" name="unpressDelay" id="0x7f01004f" />
<public type="attr" name="overflowGrpSepChar" id="0x7f010050" />
<public type="attr" name="firstCharPreMatches" id="0x7f010051" />
<public type="attr" name="indexBg" id="0x7f010052" />
<public type="attr" name="selTextColor" id="0x7f010053" />
<public type="attr" name="indexStr" id="0x7f010054" />
<public type="attr" name="itemsPerPage" id="0x7f010055" />
<public type="attr" name="itemPadding" id="0x7f010056" />
<public type="attr" name="pageFramePaddingLeft" id="0x7f010057" />
<public type="attr" name="pageFramePaddingTop" id="0x7f010058" />
<public type="attr" name="pageFramePaddingRight" id="0x7f010059" />
<public type="attr" name="pageFramePaddingBottom" id="0x7f01005a" />
<public type="attr" name="pageFrameExpandX" id="0x7f01005b" />
<public type="attr" name="pageFrameExpandY" id="0x7f01005c" />
<public type="attr" name="pageBorderPaddingLeft" id="0x7f01005d" />
<public type="attr" name="pageBorderPaddingTop" id="0x7f01005e" />
<public type="attr" name="pageBorderPaddingRight" id="0x7f01005f" />
<public type="attr" name="pageBorderPaddingBottom" id="0x7f010060" />
<public type="attr" name="zoomScaleMain" id="0x7f010061" />
<public type="attr" name="zoomScaleSide" id="0x7f010062" />
<public type="attr" name="normalScaleSlide" id="0x7f010063" />
<public type="attr" name="pageGap" id="0x7f010064" />
<public type="attr" name="zoomPageGap" id="0x7f010065" />
<public type="drawable" name="h_alphagradient_1to0" id="0x7f020000" />
<public type="drawable" name="v_alphagradient_1to0" id="0x7f020001" />
<public type="drawable" name="box_launcher_top" id="0x7f020002" />
<public type="drawable" name="btn_search_dialog_voice" id="0x7f020003" />
<public type="drawable" name="grid_selector" id="0x7f020004" />
<public type="drawable" name="grid_selector2" id="0x7f020005" />
<public type="drawable" name="textfield_searchwidget" id="0x7f020006" />
<public type="drawable" name="widget_frame" id="0x7f020007" />
<public type="drawable" name="widget_preview_button_left" id="0x7f020008" />
<public type="drawable" name="widget_preview_button_right" id="0x7f020009" />
<public type="drawable" name="bg_appwidget_error" id="0x7f02000a" />
<public type="drawable" name="bigpond" id="0x7f02000b" />
<public type="drawable" name="bottompanel" id="0x7f02000c" />
<public type="drawable" name="box_launcher_bottom" id="0x7f02000d" />
<public type="drawable" name="box_launcher_top_normal" id="0x7f02000e" />
<public type="drawable" name="box_launcher_top_pressed" id="0x7f02000f" />
<public type="drawable" name="box_launcher_top_selected" id="0x7f020010" />
<public type="drawable" name="btn_search_dialog_voice_default" id="0x7f020011" />
<public type="drawable" name="btn_search_dialog_voice_pressed" id="0x7f020012" />
<public type="drawable" name="btn_search_dialog_voice_selected" id="0x7f020013" />
<public type="drawable" name="citysearch" id="0x7f020014" />
<public type="drawable" name="downloads" id="0x7f020015" />
<public type="drawable" name="focused_application_background" id="0x7f020016" />
<public type="drawable" name="folder_icon_mainmenu" id="0x7f020017" />
<public type="drawable" name="foxtel" id="0x7f020018" />
<public type="drawable" name="games" id="0x7f020019" />
<public type="drawable" name="grid_gray" id="0x7f02001a" />
<public type="drawable" name="grid_point_gray" id="0x7f02001b" />
<public type="drawable" name="grid_point_red" id="0x7f02001c" />
<public type="drawable" name="grid_point_yellow" id="0x7f02001d" />
<public type="drawable" name="grid_red" id="0x7f02001e" />
<public type="drawable" name="grid_yellow" id="0x7f02001f" />
<public type="drawable" name="homescreen_menu_edit_locked" id="0x7f020020" />
<public type="drawable" name="homescreen_menu_icon_delete" id="0x7f020021" />
<public type="drawable" name="homescreen_menu_icon_edit_bg" id="0x7f020022" />
<public type="drawable" name="homescreen_menu_noti_bg" id="0x7f020023" />
<public type="drawable" name="homescreen_menu_page_focus_large" id="0x7f020024" />
<public type="drawable" name="homescreen_quick_navigation_add" id="0x7f020025" />
<public type="drawable" name="homescreen_quick_navigation_bg" id="0x7f020026" />
<public type="drawable" name="homescreen_quick_navigation_bg_press" id="0x7f020027" />
<public type="drawable" name="homescreen_remove_bg" id="0x7f020028" />
<public type="drawable" name="homescreen_remove_bg_drag" id="0x7f020029" />
<public type="drawable" name="homescreen_remove_icon" id="0x7f02002a" />
<public type="drawable" name="homescreen_remove_uninstall_bg" id="0x7f02002b" />
<public type="drawable" name="homescreen_remove_uninstall_bg_drag_r" id="0x7f02002c" />
<public type="drawable" name="homescreen_remove_uninstall_bg_drag_u" id="0x7f02002d" />
<public type="drawable" name="homescreen_uninstall_icon" id="0x7f02002e" />
<public type="drawable" name="hover_outline" id="0x7f02002f" />
<public type="drawable" name="ic_btn_speak_now" id="0x7f020030" />
<public type="drawable" name="ic_launcher_add_folder" id="0x7f020031" />
<public type="drawable" name="ic_launcher_application" id="0x7f020032" />
<public type="drawable" name="ic_launcher_home" id="0x7f020033" />
<public type="drawable" name="ic_launcher_appwidget" id="0x7f020034" />
<public type="drawable" name="ic_launcher_folder" id="0x7f020035" />
<public type="drawable" name="ic_launcher_shortcut" id="0x7f020036" />
<public type="drawable" name="ic_launcher_wallpaper" id="0x7f020037" />
<public type="drawable" name="ic_menu_add" id="0x7f020038" />
<public type="drawable" name="ic_menu_cancel" id="0x7f020039" />
<public type="drawable" name="ic_menu_details" id="0x7f02003a" />
<public type="drawable" name="ic_menu_discard" id="0x7f02003b" />
<public type="drawable" name="ic_menu_edit" id="0x7f02003c" />
<public type="drawable" name="ic_menu_grid_view" id="0x7f02003d" />
<public type="drawable" name="ic_menu_list_view" id="0x7f02003e" />
<public type="drawable" name="ic_menu_save" id="0x7f02003f" />
<public type="drawable" name="ic_menu_search" id="0x7f020040" />
<public type="drawable" name="ic_menu_settings" id="0x7f020041" />
<public type="drawable" name="ic_menu_market" id="0x7f020042" />
<public type="drawable" name="ic_menu_wallpaper" id="0x7f020043" />
<public type="drawable" name="lm_help_1" id="0x7f020044" />
<public type="drawable" name="mainmenu_icon_application" id="0x7f020045" />
<public type="drawable" name="mainmenu_icon_folder" id="0x7f020046" />
<public type="drawable" name="mainmenu_icon_home" id="0x7f020047" />
<public type="drawable" name="mainmenu_icon_sd" id="0x7f020048" />
<public type="drawable" name="mainmenu_pop_image" id="0x7f020049" />
<public type="drawable" name="makefoldericon" id="0x7f02004a" />
<public type="drawable" name="makefoldericon_f" id="0x7f02004b" />
<public type="drawable" name="makefolderpopup" id="0x7f02004c" />
<public type="drawable" name="makepageicon" id="0x7f02004d" />
<public type="drawable" name="makepageicon_f" id="0x7f02004e" />
<public type="drawable" name="makepagepopup" id="0x7f02004f" />
<public type="drawable" name="motion_moving_panning_l" id="0x7f020050" />
<public type="drawable" name="movies" id="0x7f020051" />
<public type="drawable" name="music" id="0x7f020052" />
<public type="drawable" name="myaccount" id="0x7f020053" />
<public type="drawable" name="myemail" id="0x7f020054" />
<public type="drawable" name="mymagazine_handle" id="0x7f020055" />
<public type="drawable" name="news" id="0x7f020056" />
<public type="drawable" name="page_outline" id="0x7f020057" />
<public type="drawable" name="pageindicator_fastscroll_bar_nine" id="0x7f020058" />
<public type="drawable" name="pageindicator_fastscroll_handle" id="0x7f020059" />
<public type="drawable" name="pageindicator_fastscroll_panel" id="0x7f02005a" />
<public type="drawable" name="panel_frame" id="0x7f02005b" />
<public type="drawable" name="panel_highlight" id="0x7f02005c" />
<public type="drawable" name="placeholder_google" id="0x7f02005d" />
<public type="drawable" name="preview_arrow_left" id="0x7f02005e" />
<public type="drawable" name="preview_arrow_left_disable" id="0x7f02005f" />
<public type="drawable" name="preview_arrow_left_focus" id="0x7f020060" />
<public type="drawable" name="preview_arrow_left_press" id="0x7f020061" />
<public type="drawable" name="preview_arrow_right" id="0x7f020062" />
<public type="drawable" name="preview_arrow_right_disable" id="0x7f020063" />
<public type="drawable" name="preview_arrow_right_focus" id="0x7f020064" />
<public type="drawable" name="preview_arrow_right_press" id="0x7f020065" />
<public type="drawable" name="preview_title_tab_bg" id="0x7f020066" />
(...)
<public type="string" name="viewtype_dialog_item_alphabetical_grid" id="0x7f0800ae" />
<public type="string" name="viewtype_dialog_item_alphabetical_list" id="0x7f0800af" />
<public type="string" name="mm_listmode_alpha_index" id="0x7f0800b0" />
<public type="string" name="tips_dialog_text" id="0x7f0800b1" />
<public type="string" name="tips_dialog_title" id="0x7f0800b2" />
<public type="string" name="tips_dialog_switch_button" id="0x7f0800b3" />
<public type="string" name="tips_dialog_cancel_button" id="0x7f0800b4" />
<public type="string" name="background_note" id="0x7f0800b5" />
<public type="string" name="folder_utility" id="0x7f0800b6" />
<public type="string" name="dmb_rest" id="0x7f0800b7" />
<public type="string" name="restrictdmb" id="0x7f0800b8" />
<public type="string" name="home_screen_delete" id="0x7f0800b9" />
<public type="string" name="lm_help_1_content" id="0x7f0800ba" />
<public type="bool" name="config_force32BitWindowAlways" id="0x7f090000" />
<public type="bool" name="config_useFullScreenQuickViewLandscape" id="0x7f090001" />
<public type="bool" name="config_useMainMenuConcentrationEffect" id="0x7f090002" />
<public type="bool" name="mm_enableListMode" id="0x7f090003" />
<public type="bool" name="pageindicator_largeDrawableOnly" id="0x7f090004" />
<public type="bool" name="pageindicator_showhide_enable" id="0x7f090005" />
(...)
<public type="dimen" name="pageindicator_top" id="0x7f0b003c" />
<public type="dimen" name="pageindicator_padH" id="0x7f0b003d" />
<public type="dimen" name="pageindicator_padV" id="0x7f0b003e" />
<public type="dimen" name="pageindicator_launcherManagerTransY" id="0x7f0b003f" />
<public type="dimen" name="pageindicator_pageicon_fontsize" id="0x7f0b0040" />
<public type="dimen" name="pageindicator_fastscroll_fontsize" id="0x7f0b0041" />
<public type="dimen" name="pageindicator_fastscroll_paneloffset" id="0x7f0b0042" />
Here's the original post in the SGS forum:
http://forum.xda-developers.com/showthread.php?t=1520436
Did you notice there was a link to a modded version with a 'lower bar' for the Nexus?
Related
The trick actually comes from Defy devs and I tested it before on Milestone, but unsuccessfully at that time.
normal battery capacity reading is done using
/sys/class/power_supply/battery/capacity - which is in 10% steps
On some Motorola phones, there's also
/sys/class/power_supply/battery/charge_counter - that is in 1% steps.
But on Milestone, the charge_counter is always 0.
Unless you use /system/bin/battd from Milestone 2 or Droid 2 (or possibly other phone as well)
See (origin - Defy)
https://github.com/Quarx2k/android_...ni/com_android_server_BatteryService.cpp#L301
Btw., in CM7 I've decided to use battd from the leaked Droid2 gingerbread firmware, as that is the most recent (and the only 2.3) motorola's build for phone with similar HW as Milestone that I'm aware of.
Current implementation in CM7 for Milestone (optional, using persist.sys.one_percent_batt property):
https://github.com/nadlabak/android_frameworks_base/commit/b912685321b67b4d2b145e6f17fd6bc3cedf4e45
https://github.com/nadlabak/android...mmit/113eb4200fd3c9237ce5d9c4aa9df2778aa55e97
https://github.com/nadlabak/android...mmit/32efe6e51ea1666222cf082075d6683d2b6fc791
https://github.com/nadlabak/android...mmit/b709ad1e344959529db158d48cf10b8faaa8955a
Please note that Droid 2 / Milestone 2 is more strict when it comes to third party batteries.
So this feature may cause issues when third party batteries are used.
There may also be problems with some third party AC adapters that are not able to provide stable 5V when charging.
sounds good btw, any tut how to do it on any 2.3 rom?
or just replace battd from mileston2 rom (or your last cm7) and it will work? or...?
It's certainly not limited to 2.3 ROMs.
But frameworks/base/services/jni/com_android_server_BatteryService.cpp needs the above mentioned change.
kabaldan said:
It's certainly not limited to 2.3 ROMs.
Click to expand...
Click to collapse
Again, brilliant work Kabaldan!
The only feature I'm looking for now is the ability to use a SWAP partition in the micro SD.
@kab
I have compiled the framework using that commit, then used the battd and libbattd.so from CM7, but I still have 10% steps!
Any other changes I have to do?
salisbury_steak said:
Again, brilliant work Kabaldan!
The only feature I'm looking for now is the ability to use a SWAP partition in the micro SD.
Click to expand...
Click to collapse
I totally second that, but I don't think that that is ever going to happen though we should never underestimate the power of kabaldan
please can you finalise froyo kabaldan? so much good work going on since the last version. ive found your froyo to be the best on battery and performance/snappiness
deleted....
how can i make the rom i use right now showing one by one the battery percentage?? thank you.
I decompiled framework-res.apk, edit file stat_sys_battery lik this:
Code:
<item android:drawable="@drawable/stat_sys_battery_0" android:maxLevel="1" />
<item android:drawable="@drawable/stat_sys_battery_1" android:maxLevel="2" />
<item android:drawable="@drawable/stat_sys_battery_2" android:maxLevel="3" />
<item android:drawable="@drawable/stat_sys_battery_3" android:maxLevel="4" />
<item android:drawable="@drawable/stat_sys_battery_4" android:maxLevel="5" />
<item android:drawable="@drawable/stat_sys_battery_5" android:maxLevel="6" />
<item android:drawable="@drawable/stat_sys_battery_6" android:maxLevel="7" />
<item android:drawable="@drawable/stat_sys_battery_7" android:maxLevel="8" />
<item android:drawable="@drawable/stat_sys_battery_8" android:maxLevel="9" />
<item android:drawable="@drawable/stat_sys_battery_9" android:maxLevel="10" />
<item android:drawable="@drawable/stat_sys_battery_10" android:maxLevel="11" />
<item android:drawable="@drawable/stat_sys_battery_11" android:maxLevel="12" />
<item android:drawable="@drawable/stat_sys_battery_12" android:maxLevel="13" />
<item android:drawable="@drawable/stat_sys_battery_13" android:maxLevel="14" />
<item android:drawable="@drawable/stat_sys_battery_14" android:maxLevel="15" />
<item android:drawable="@drawable/stat_sys_battery_15" android:maxLevel="16" />
<item android:drawable="@drawable/stat_sys_battery_16" android:maxLevel="17" />
<item android:drawable="@drawable/stat_sys_battery_17" android:maxLevel="18" />
<item android:drawable="@drawable/stat_sys_battery_18" android:maxLevel="19" />
<item android:drawable="@drawable/stat_sys_battery_19" android:maxLevel="20" />
<item android:drawable="@drawable/stat_sys_battery_20" android:maxLevel="21" />
<item android:drawable="@drawable/stat_sys_battery_21" android:maxLevel="22" />
<item android:drawable="@drawable/stat_sys_battery_22" android:maxLevel="23" />
<item android:drawable="@drawable/stat_sys_battery_23" android:maxLevel="24" />
<item android:drawable="@drawable/stat_sys_battery_24" android:maxLevel="25" />
<item android:drawable="@drawable/stat_sys_battery_25" android:maxLevel="26" />
<item android:drawable="@drawable/stat_sys_battery_26" android:maxLevel="27" />
<item android:drawable="@drawable/stat_sys_battery_27" android:maxLevel="28" />
<item android:drawable="@drawable/stat_sys_battery_28" android:maxLevel="29" />
<item android:drawable="@drawable/stat_sys_battery_29" android:maxLevel="30" />
<item android:drawable="@drawable/stat_sys_battery_30" android:maxLevel="31" />
<item android:drawable="@drawable/stat_sys_battery_31" android:maxLevel="32" />
<item android:drawable="@drawable/stat_sys_battery_32" android:maxLevel="33" />
<item android:drawable="@drawable/stat_sys_battery_33" android:maxLevel="34" />
<item android:drawable="@drawable/stat_sys_battery_34" android:maxLevel="35" />
<item android:drawable="@drawable/stat_sys_battery_35" android:maxLevel="36" />
<item android:drawable="@drawable/stat_sys_battery_36" android:maxLevel="37" />
<item android:drawable="@drawable/stat_sys_battery_37" android:maxLevel="38" />
<item android:drawable="@drawable/stat_sys_battery_38" android:maxLevel="39" />
<item android:drawable="@drawable/stat_sys_battery_39" android:maxLevel="40" />
<item android:drawable="@drawable/stat_sys_battery_40" android:maxLevel="41" />
<item android:drawable="@drawable/stat_sys_battery_41" android:maxLevel="42" />
<item android:drawable="@drawable/stat_sys_battery_42" android:maxLevel="43" />
<item android:drawable="@drawable/stat_sys_battery_43" android:maxLevel="44" />
<item android:drawable="@drawable/stat_sys_battery_44" android:maxLevel="45" />
<item android:drawable="@drawable/stat_sys_battery_45" android:maxLevel="46" />
<item android:drawable="@drawable/stat_sys_battery_46" android:maxLevel="47" />
<item android:drawable="@drawable/stat_sys_battery_47" android:maxLevel="48" />
<item android:drawable="@drawable/stat_sys_battery_48" android:maxLevel="49" />
<item android:drawable="@drawable/stat_sys_battery_49" android:maxLevel="50" />
<item android:drawable="@drawable/stat_sys_battery_50" android:maxLevel="51" />
<item android:drawable="@drawable/stat_sys_battery_51" android:maxLevel="52" />
<item android:drawable="@drawable/stat_sys_battery_52" android:maxLevel="53" />
<item android:drawable="@drawable/stat_sys_battery_53" android:maxLevel="54" />
<item android:drawable="@drawable/stat_sys_battery_54" android:maxLevel="55" />
<item android:drawable="@drawable/stat_sys_battery_55" android:maxLevel="56" />
<item android:drawable="@drawable/stat_sys_battery_56" android:maxLevel="57" />
<item android:drawable="@drawable/stat_sys_battery_57" android:maxLevel="58" />
<item android:drawable="@drawable/stat_sys_battery_58" android:maxLevel="59" />
<item android:drawable="@drawable/stat_sys_battery_59" android:maxLevel="60" />
<item android:drawable="@drawable/stat_sys_battery_60" android:maxLevel="61" />
<item android:drawable="@drawable/stat_sys_battery_61" android:maxLevel="62" />
<item android:drawable="@drawable/stat_sys_battery_62" android:maxLevel="63" />
<item android:drawable="@drawable/stat_sys_battery_63" android:maxLevel="64" />
<item android:drawable="@drawable/stat_sys_battery_64" android:maxLevel="65" />
<item android:drawable="@drawable/stat_sys_battery_65" android:maxLevel="66" />
<item android:drawable="@drawable/stat_sys_battery_66" android:maxLevel="67" />
<item android:drawable="@drawable/stat_sys_battery_67" android:maxLevel="68" />
<item android:drawable="@drawable/stat_sys_battery_68" android:maxLevel="69" />
<item android:drawable="@drawable/stat_sys_battery_69" android:maxLevel="70" />
<item android:drawable="@drawable/stat_sys_battery_70" android:maxLevel="71" />
<item android:drawable="@drawable/stat_sys_battery_71" android:maxLevel="72" />
<item android:drawable="@drawable/stat_sys_battery_72" android:maxLevel="73" />
<item android:drawable="@drawable/stat_sys_battery_73" android:maxLevel="74" />
<item android:drawable="@drawable/stat_sys_battery_74" android:maxLevel="75" />
<item android:drawable="@drawable/stat_sys_battery_75" android:maxLevel="76" />
<item android:drawable="@drawable/stat_sys_battery_76" android:maxLevel="77" />
<item android:drawable="@drawable/stat_sys_battery_77" android:maxLevel="78" />
<item android:drawable="@drawable/stat_sys_battery_78" android:maxLevel="79" />
<item android:drawable="@drawable/stat_sys_battery_79" android:maxLevel="80" />
<item android:drawable="@drawable/stat_sys_battery_80" android:maxLevel="81" />
<item android:drawable="@drawable/stat_sys_battery_81" android:maxLevel="82" />
<item android:drawable="@drawable/stat_sys_battery_82" android:maxLevel="83" />
<item android:drawable="@drawable/stat_sys_battery_83" android:maxLevel="84" />
<item android:drawable="@drawable/stat_sys_battery_84" android:maxLevel="85" />
<item android:drawable="@drawable/stat_sys_battery_85" android:maxLevel="86" />
<item android:drawable="@drawable/stat_sys_battery_86" android:maxLevel="87" />
<item android:drawable="@drawable/stat_sys_battery_87" android:maxLevel="88" />
<item android:drawable="@drawable/stat_sys_battery_88" android:maxLevel="89" />
<item android:drawable="@drawable/stat_sys_battery_89" android:maxLevel="90" />
<item android:drawable="@drawable/stat_sys_battery_90" android:maxLevel="91" />
<item android:drawable="@drawable/stat_sys_battery_91" android:maxLevel="92" />
<item android:drawable="@drawable/stat_sys_battery_92" android:maxLevel="93" />
<item android:drawable="@drawable/stat_sys_battery_93" android:maxLevel="94" />
<item android:drawable="@drawable/stat_sys_battery_94" android:maxLevel="95" />
<item android:drawable="@drawable/stat_sys_battery_95" android:maxLevel="96" />
<item android:drawable="@drawable/stat_sys_battery_96" android:maxLevel="97" />
<item android:drawable="@drawable/stat_sys_battery_97" android:maxLevel="98" />
<item android:drawable="@drawable/stat_sys_battery_98" android:maxLevel="99" />
<item android:drawable="@drawable/stat_sys_battery_100" android:maxLevel="100" />
Then added png files battery level with % number into drawable-hdpi, rebuilt, reflashed, rebooted, when the fall started, it showed new battery icon with % number on statusbar, but a lot of app FC...
Did i do anything wrong?
keunhuvac said:
I decompiled framework-res.apk, edit file stat_sys_battery lik this:
Then added png files battery level with % number into drawable-hdpi, rebuilt, reflashed, rebooted, when the fall started, it showed new battery icon with % number on statusbar, but a lot of app FC...
Did i do anything wrong?
Click to expand...
Click to collapse
it's not that easy, dude.
as kabaldan wrote: you have to build frameworks/base/services/jni/com_android_server_BatteryService.cpp from sources!!! with the changes you find in github-link he posted + using the battd in /system/bin/ he used (from Droid2 od MS2)
eybee1970 said:
it's not that easy, dude.
as kabaldan wrote: you have to build frameworks/base/services/jni/com_android_server_BatteryService.cpp from sources!!! with the changes you find in github-link he posted + using the battd in /system/bin/ he used (from Droid2 od MS2)
Click to expand...
Click to collapse
So the method to display battery in step 1% is only available if i choose display % battery in statatusbar tweak (in cyanogenmod settings)?
Nope sileshn got it working on my Froyomod with all 100 battery icons!!
Ask him
keunhuvac said:
So the method to display battery in step 1% is only available if i choose display % battery in statatusbar tweak (in cyanogenmod settings)?
Click to expand...
Click to collapse
You need to change the resource ID's for all of the PNG's you are adding. Silesh said it was something like 89 extra PNG's for all 100 icons.
Where can I find him? I port MIUI to the droid from the Milestone build each week. I would like to port this to Droid as well.
TreyMotes said:
Where can I find him? I port MIUI to the droid from the Milestone build each week. I would like to port this to Droid as well.
Click to expand...
Click to collapse
You can send him a PM. He is always around here though, so he might also reply to this thread soon.
I just realized that it won't really matter. MIUI is closed source so building framework from source is impossible. I have passed this info to the Chinese developers in hopes that they will add this to the Milestone MIUI builds.
TreyMotes said:
I just realized that it won't really matter. MIUI is closed source so building framework from source is impossible. I have passed this info to the Chinese developers in hopes that they will add this to the Milestone MIUI builds.
Click to expand...
Click to collapse
Very true my friend. You will need to wait till miui cn include it in their releases. Then you can mod it to use extra png's.
It works perfectly on Froyomod.
Sent from my Milestone using Tapatalk
This saddens me. I really wanted to surprise the users of my port this morning. Oh well. We patiently wait I guess...
keunhuvac said:
So the method to display battery in step 1% is only available if i choose display % battery in statatusbar tweak (in cyanogenmod settings)?
Click to expand...
Click to collapse
Hey buddy, I can add the pngs to the framework of cm7 if you want me to. Just link me up to the icons you want to use.
Sent from my Milestone using Tapatalk
I have decompile the apk using apktool and on public.xml I found something like the following.
<public type="drawable" name="border" id="0x7f020001" />
<public type="drawable" name="button1" id="0x7f020006" />
<public type="drawable" name="button1_1" id="0x7f020007" />
<public type="drawable" name="button2" id="0x7f020008" />
<public type="drawable" name="button2_1" id="0x7f020009" />
<public type="drawable" name="button3" id="0x7f02000a" />
<public type="drawable" name="button3_1" id="0x7f02000b" />
<public type="drawable" name="button4" id="0x7f02000c" />
<public type="drawable" name="button4_1" id="0x7f02000d" />
Click to expand...
Click to collapse
Is there anyway to decompile these values? or if I need to add more, I can compile using the same algorithm?
thanks,
public.xml is not used so much by regular applications.
aapt scans the resources and generates arbitrary numeric identifiers.
It generates R.java which is used to compile these values into your Java code.
When you apktool d an apk, you get smali code with numeric ids for resources.
apktool generates public.xml so you can reference by the same value as the existing code.
It's should be possible to simply add new resources.
The aapt should take note of public.xml and not reissue any of the used numeric ids.
Renate NST said:
public.xml is not used so much by regular applications.
aapt scans the resources and generates arbitrary numeric identifiers.
It generates R.java which is used to compile these values into your Java code.
When you apktool d an apk, you get smali code with numeric ids for resources.
apktool generates public.xml so you can reference by the same value as the existing code.
It's should be possible to simply add new resources.
The aapt should take note of public.xml and not reissue any of the used numeric ids.
Click to expand...
Click to collapse
so how do I understand what is
<public type="drawable" name="button1" id="0x7f020006" />
in this case it is just the button id.
What I was more interested to know what this
<public type="string" name="client_id" id="0x7f08000d" />
is there anyway for me to know the decompile value of the client_id?
-greenboy- said:
<public type="string" name="client_id" id="0x7f08000d" />
is there anyway for me to know the decompile value of the client_id?
Click to expand...
Click to collapse
Um, it's 0x7f08000d.
That means when it was initially compiled that aapt thought that 0x7f08000d was a pretty value for it.
Somebody's original Java code said:
Code:
String secret = getString(R.string.client_id);
Which is exactly the same (given the id assignments) as:
Code:
String secret = getString(0x7f08000d);
If you are looking for the string itself, it's in res/values/strings.xml
Just search for client_id, it's plain as day.
Enable % Battery and Icons
Tools Required :
1. apktool (For Decompile/Compile)
2. Notepad++ (Windows) Or Text Editor (OSX)
3. 7zip (Windows)
4. Java Runtime
Steps -
1. Extract all files for apktool into a folder (Lets say /apktool for this example)
2. Extract files from your phone and copy into apktool folder :
/system/framework/framework-res.apk
/system/framework/com.htc.resources.apk
/system/app/SystemUI.apk
3. Open a command/terminal prompt at /apktool
4. Run following commands :
apktool if framework-res.apk (OSX - ./apktool if framework-res.apk)
apktool com.htc.resources.apk (OSX - ./apktool if com.htc.resources.apk)
apktool d SystemUI.apk (OSX - ./apktool d SystemUI.apk)
5. This should decompile the SystemUI apk successfully and create folder SystemUI in /apktool
6. Change into SystemUI folder. Edit file - res/drawable/stat_sys_battery.xml
7. Remove all lines between following lines :
xmlns:android="http://schemas.android.com/apk/res/android">
....
</level-list>
8. Copy and paste the following lines in place
Code:
<item android:drawable="@drawable/stat_sys_battery_1" android:maxLevel="1" />
<item android:drawable="@drawable/stat_sys_battery_2" android:maxLevel="2" />
<item android:drawable="@drawable/stat_sys_battery_3" android:maxLevel="3" />
<item android:drawable="@drawable/stat_sys_battery_4" android:maxLevel="4" />
<item android:drawable="@drawable/stat_sys_battery_5" android:maxLevel="5" />
<item android:drawable="@drawable/stat_sys_battery_6" android:maxLevel="6" />
<item android:drawable="@drawable/stat_sys_battery_7" android:maxLevel="7" />
<item android:drawable="@drawable/stat_sys_battery_8" android:maxLevel="8" />
<item android:drawable="@drawable/stat_sys_battery_9" android:maxLevel="9" />
<item android:drawable="@drawable/stat_sys_battery_10" android:maxLevel="10" />
<item android:drawable="@drawable/stat_sys_battery_11" android:maxLevel="11" />
<item android:drawable="@drawable/stat_sys_battery_12" android:maxLevel="12" />
<item android:drawable="@drawable/stat_sys_battery_13" android:maxLevel="13" />
<item android:drawable="@drawable/stat_sys_battery_14" android:maxLevel="14" />
<item android:drawable="@drawable/stat_sys_battery_15" android:maxLevel="15" />
<item android:drawable="@drawable/stat_sys_battery_16" android:maxLevel="16" />
<item android:drawable="@drawable/stat_sys_battery_17" android:maxLevel="17" />
<item android:drawable="@drawable/stat_sys_battery_18" android:maxLevel="18" />
<item android:drawable="@drawable/stat_sys_battery_19" android:maxLevel="19" />
<item android:drawable="@drawable/stat_sys_battery_20" android:maxLevel="20" />
<item android:drawable="@drawable/stat_sys_battery_21" android:maxLevel="21" />
<item android:drawable="@drawable/stat_sys_battery_22" android:maxLevel="22" />
<item android:drawable="@drawable/stat_sys_battery_23" android:maxLevel="23" />
<item android:drawable="@drawable/stat_sys_battery_24" android:maxLevel="24" />
<item android:drawable="@drawable/stat_sys_battery_25" android:maxLevel="25" />
<item android:drawable="@drawable/stat_sys_battery_26" android:maxLevel="26" />
<item android:drawable="@drawable/stat_sys_battery_27" android:maxLevel="27" />
<item android:drawable="@drawable/stat_sys_battery_28" android:maxLevel="28" />
<item android:drawable="@drawable/stat_sys_battery_29" android:maxLevel="29" />
<item android:drawable="@drawable/stat_sys_battery_30" android:maxLevel="30" />
<item android:drawable="@drawable/stat_sys_battery_31" android:maxLevel="31" />
<item android:drawable="@drawable/stat_sys_battery_32" android:maxLevel="32" />
<item android:drawable="@drawable/stat_sys_battery_33" android:maxLevel="33" />
<item android:drawable="@drawable/stat_sys_battery_34" android:maxLevel="34" />
<item android:drawable="@drawable/stat_sys_battery_35" android:maxLevel="35" />
<item android:drawable="@drawable/stat_sys_battery_36" android:maxLevel="36" />
<item android:drawable="@drawable/stat_sys_battery_37" android:maxLevel="37" />
<item android:drawable="@drawable/stat_sys_battery_38" android:maxLevel="38" />
<item android:drawable="@drawable/stat_sys_battery_39" android:maxLevel="39" />
<item android:drawable="@drawable/stat_sys_battery_40" android:maxLevel="40" />
<item android:drawable="@drawable/stat_sys_battery_41" android:maxLevel="41" />
<item android:drawable="@drawable/stat_sys_battery_42" android:maxLevel="42" />
<item android:drawable="@drawable/stat_sys_battery_43" android:maxLevel="43" />
<item android:drawable="@drawable/stat_sys_battery_44" android:maxLevel="44" />
<item android:drawable="@drawable/stat_sys_battery_45" android:maxLevel="45" />
<item android:drawable="@drawable/stat_sys_battery_46" android:maxLevel="46" />
<item android:drawable="@drawable/stat_sys_battery_47" android:maxLevel="47" />
<item android:drawable="@drawable/stat_sys_battery_48" android:maxLevel="48" />
<item android:drawable="@drawable/stat_sys_battery_49" android:maxLevel="49" />
<item android:drawable="@drawable/stat_sys_battery_50" android:maxLevel="50" />
<item android:drawable="@drawable/stat_sys_battery_51" android:maxLevel="51" />
<item android:drawable="@drawable/stat_sys_battery_52" android:maxLevel="52" />
<item android:drawable="@drawable/stat_sys_battery_53" android:maxLevel="53" />
<item android:drawable="@drawable/stat_sys_battery_54" android:maxLevel="54" />
<item android:drawable="@drawable/stat_sys_battery_55" android:maxLevel="55" />
<item android:drawable="@drawable/stat_sys_battery_56" android:maxLevel="56" />
<item android:drawable="@drawable/stat_sys_battery_57" android:maxLevel="57" />
<item android:drawable="@drawable/stat_sys_battery_58" android:maxLevel="58" />
<item android:drawable="@drawable/stat_sys_battery_59" android:maxLevel="59" />
<item android:drawable="@drawable/stat_sys_battery_60" android:maxLevel="60" />
<item android:drawable="@drawable/stat_sys_battery_61" android:maxLevel="61" />
<item android:drawable="@drawable/stat_sys_battery_62" android:maxLevel="62" />
<item android:drawable="@drawable/stat_sys_battery_63" android:maxLevel="63" />
<item android:drawable="@drawable/stat_sys_battery_64" android:maxLevel="64" />
<item android:drawable="@drawable/stat_sys_battery_65" android:maxLevel="65" />
<item android:drawable="@drawable/stat_sys_battery_66" android:maxLevel="66" />
<item android:drawable="@drawable/stat_sys_battery_67" android:maxLevel="67" />
<item android:drawable="@drawable/stat_sys_battery_68" android:maxLevel="68" />
<item android:drawable="@drawable/stat_sys_battery_69" android:maxLevel="69" />
<item android:drawable="@drawable/stat_sys_battery_70" android:maxLevel="70" />
<item android:drawable="@drawable/stat_sys_battery_71" android:maxLevel="71" />
<item android:drawable="@drawable/stat_sys_battery_72" android:maxLevel="72" />
<item android:drawable="@drawable/stat_sys_battery_73" android:maxLevel="73" />
<item android:drawable="@drawable/stat_sys_battery_74" android:maxLevel="74" />
<item android:drawable="@drawable/stat_sys_battery_75" android:maxLevel="75" />
<item android:drawable="@drawable/stat_sys_battery_76" android:maxLevel="76" />
<item android:drawable="@drawable/stat_sys_battery_77" android:maxLevel="77" />
<item android:drawable="@drawable/stat_sys_battery_78" android:maxLevel="78" />
<item android:drawable="@drawable/stat_sys_battery_79" android:maxLevel="79" />
<item android:drawable="@drawable/stat_sys_battery_80" android:maxLevel="80" />
<item android:drawable="@drawable/stat_sys_battery_81" android:maxLevel="81" />
<item android:drawable="@drawable/stat_sys_battery_82" android:maxLevel="82" />
<item android:drawable="@drawable/stat_sys_battery_83" android:maxLevel="83" />
<item android:drawable="@drawable/stat_sys_battery_84" android:maxLevel="84" />
<item android:drawable="@drawable/stat_sys_battery_85" android:maxLevel="85" />
<item android:drawable="@drawable/stat_sys_battery_86" android:maxLevel="86" />
<item android:drawable="@drawable/stat_sys_battery_87" android:maxLevel="87" />
<item android:drawable="@drawable/stat_sys_battery_88" android:maxLevel="88" />
<item android:drawable="@drawable/stat_sys_battery_89" android:maxLevel="89" />
<item android:drawable="@drawable/stat_sys_battery_90" android:maxLevel="90" />
<item android:drawable="@drawable/stat_sys_battery_91" android:maxLevel="91" />
<item android:drawable="@drawable/stat_sys_battery_92" android:maxLevel="92" />
<item android:drawable="@drawable/stat_sys_battery_93" android:maxLevel="93" />
<item android:drawable="@drawable/stat_sys_battery_94" android:maxLevel="94" />
<item android:drawable="@drawable/stat_sys_battery_95" android:maxLevel="95" />
<item android:drawable="@drawable/stat_sys_battery_96" android:maxLevel="96" />
<item android:drawable="@drawable/stat_sys_battery_97" android:maxLevel="97" />
<item android:drawable="@drawable/stat_sys_battery_98" android:maxLevel="98" />
<item android:drawable="@drawable/stat_sys_battery_99" android:maxLevel="99" />
<item android:drawable="@drawable/stat_sys_battery_100" android:maxLevel="100" />
<item android:drawable="@drawable/stat_sys_battery_100" android:maxLevel="101" />
9. Save and exit the file
10. Now to explain the other file "stat_sys_battery_charge.xml"
Each percent of battery has its own set of animation list going from current battery to 100% with given amount of millisecond gap on each icon. This forms the Animation part.
Example -
Code:
<item android:maxLevel="95">
<animation-list android:oneshot="false"
xmlns:android="http://schemas.android.com/apk/res/android">
<item android:duration="300" android:drawable="@drawable/stat_sys_battery_charge_anim95" />
<item android:duration="300" android:drawable="@drawable/stat_sys_battery_charge_anim96" />
<item android:duration="300" android:drawable="@drawable/stat_sys_battery_charge_anim97" />
<item android:duration="300" android:drawable="@drawable/stat_sys_battery_charge_anim98" />
<item android:duration="300" android:drawable="@drawable/stat_sys_battery_charge_anim99" />
<item android:duration="300" android:drawable="@drawable/stat_sys_battery_charge_anim100" />
</animation-list>
</item>
Each icon is shown for 300ms and goes in a loop. So we need 101 such <item> tags to complete the xml. 101 indicates battery full and can have code as follows :
Code:
<item android:maxLevel="101">
<animation-list android:oneshot="false"
xmlns:android="http://schemas.android.com/apk/res/android">
<item android:duration="3000" android:drawable="@drawable/stat_sys_battery_charge_animfull" />
</animation-list>
</item>
This basically stops any animation on battery full (Same icon is refreshed every 3 seconds) and shows a special icon (animfull). Note that all this is upto your icon naming convention. The examples given here are what is mostly stock and used.
As you must have gathered by now that creating such XML manually is a really tedious job. So I will be attaching a Windows program and script for OSX which will generate such XML based on your inputs.
Also note that if you do not want animation, you can copy over the lines from the non-charging xml given above and use same list for the charging xml. The names can be changed from normal to _anim to reflect the charging icons.
11. Save and exit the charging xml file
12. Copy over your set of 1% icons to res/drawable-xhdpi (Replace existing)
13. Remove all such named icons from res/drawable-hdpi
14. Recompile the apk using command prompt :
apktool b SystemUI (OSX - ./apktool b SystemUI)
15. New compiled apk will be available in /apktool/SystemUI/dist
16. You can use attached template zip and open (DO NOT EXTRACT) using 7z
17. Change into system/app folder in 7z and drag the new compiled SystemUI.apk into it. Answer YES if you get prompt in 7z
18. Similarly use the template to create an original zip for your untouched SystemUI.apk for reverting back to original
19. Flash away in Recovery and Enjoy!
Click to expand...
Click to collapse
TOOLS
Windows
Download here
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Fields :
1. Animation Duration : Number of milliseconds to wait at each icon
2. Filename Prefix : Filename prefix to be used for animation icons (Part of filename before the 01-100 numbers)
3. Animation Flag : Y for animated charging icons, N for standard animated icons without animation xml
Extract the exe from WIN_xmlgen_battperc in attachment and copy to apktool folder. Run the tool and click Generate after selecting options. It will prompt when done and the xml will be created in the same folder as the exe file.
NOTE - Existing stat_sys_battery_charge.xml will be overwritten without warning.
Click to expand...
Click to collapse
OSX/Linux
Download here
Fields :
1. Animation Duration : Number of milliseconds to wait at each icon
2. Filename Prefix : Filename prefix to be used for animation icons (Part of filename before the 01-100 numbers)
3. Animation Flag : Y for animated charging icons, N for standard animated icons without animation xml
Copy the script from within the OSX_xmlgen_battperc in attachment and copy over to apktool folder.
Set execute permission on the script using GUI or terminal (chmod +x xmlgen_battperc.sh)
Change to apktool folder in Terminal and Run the script (sh xmlgen_battperc.sh or ./xmlgen_battperc)
It will create the charging xml in same folder as the script.
NOTE - Existing stat_sys_battery_charge.xml will be overwritten without warning.
Click to expand...
Click to collapse
Guide/Tut - 1 % battery change & charge with customised icons - Any ROM Any DEVICE
This guide helps you is achieving 1 % battery change in icons; normal and charging . All you need to do is extract the 2 xml files provided in the zip file below in your LGSystemUI.apk after you decompile it and then add 101 battery icons of your choice and 101 charging icons. Recompile and you will have 1% battery change in your statusbar. This works fine on JB and on KK.
For incorporating the mod you need to de-odex your Systemui. There are lots of de-odexers available on xda...Try searching and your will find. Once you deodex your systemui you can either once again odex it before using on your phone or you can also use the de-odexed version,but for which you need to delete the respective odex file before applying the mod by flashing or moving it manually.
JB- You will find Systemui file in "/system/app" folder.
KK-You will find Systemui file in "/system/priv-app" folder.
Since this thread is in G2 section, I mention the mod files for LGSystemUI.apk. For other devices you have to locate your SystemUI as per your phone and modify the code accordingly. The code herein below works for the G2, G-FLEX & G3.
How to do it? Here we go:--
--Deodex your LGSystemUI.apk (if you run a odexed ROM). For de-odexed ROM this isn't required.
--Decompile LGSystemUI.apk
--Go to the "/res/drawable" directory and edit "stat_sys_battery.xml" & stat_sys_battery_charge.xml with notepad++
--Just copy the "stat_sys_battery.xml" & stat_sys_battery_charge.xml attached herewith in the zip file and replace the file existing in that folder
-- FYI. the entire code reads as follows:
1. stat_sys_battery.xml
Code:
<?xml version="1.0" encoding="utf-8"?>
<level-list
xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="@drawable/stat_sys_battery_00" android:maxLevel="0" />
<item android:maxLevel="2">
<animation-list android:oneshot="false"
xmlns:android="http://schemas.android.com/apk/res/android">
<item android:duration="400" android:drawable="@drawable/stat_sys_battery_00" />
<item android:duration="400" android:drawable="@drawable/stat_sys_battery_blank" />
</animation-list>
</item>
<item android:drawable="@drawable/stat_sys_battery_0" android:maxLevel="0" />
<item android:drawable="@drawable/stat_sys_battery_1" android:maxLevel="1" />
<item android:drawable="@drawable/stat_sys_battery_2" android:maxLevel="2" />
<item android:drawable="@drawable/stat_sys_battery_3" android:maxLevel="3" />
<item android:drawable="@drawable/stat_sys_battery_4" android:maxLevel="4" />
<item android:drawable="@drawable/stat_sys_battery_5" android:maxLevel="5" />
<item android:drawable="@drawable/stat_sys_battery_6" android:maxLevel="6" />
<item android:drawable="@drawable/stat_sys_battery_7" android:maxLevel="7" />
<item android:drawable="@drawable/stat_sys_battery_8" android:maxLevel="8" />
<item android:drawable="@drawable/stat_sys_battery_9" android:maxLevel="9" />
<item android:drawable="@drawable/stat_sys_battery_10" android:maxLevel="10" />
<item android:drawable="@drawable/stat_sys_battery_11" android:maxLevel="11" />
<item android:drawable="@drawable/stat_sys_battery_12" android:maxLevel="12" />
<item android:drawable="@drawable/stat_sys_battery_13" android:maxLevel="13" />
<item android:drawable="@drawable/stat_sys_battery_14" android:maxLevel="14" />
<item android:drawable="@drawable/stat_sys_battery_15" android:maxLevel="15" />
<item android:drawable="@drawable/stat_sys_battery_16" android:maxLevel="16" />
<item android:drawable="@drawable/stat_sys_battery_17" android:maxLevel="17" />
<item android:drawable="@drawable/stat_sys_battery_18" android:maxLevel="18" />
<item android:drawable="@drawable/stat_sys_battery_19" android:maxLevel="19" />
<item android:drawable="@drawable/stat_sys_battery_20" android:maxLevel="20" />
<item android:drawable="@drawable/stat_sys_battery_21" android:maxLevel="21" />
<item android:drawable="@drawable/stat_sys_battery_22" android:maxLevel="22" />
<item android:drawable="@drawable/stat_sys_battery_23" android:maxLevel="23" />
<item android:drawable="@drawable/stat_sys_battery_24" android:maxLevel="24" />
<item android:drawable="@drawable/stat_sys_battery_25" android:maxLevel="25" />
<item android:drawable="@drawable/stat_sys_battery_26" android:maxLevel="26" />
<item android:drawable="@drawable/stat_sys_battery_27" android:maxLevel="27" />
<item android:drawable="@drawable/stat_sys_battery_28" android:maxLevel="28" />
<item android:drawable="@drawable/stat_sys_battery_29" android:maxLevel="29" />
<item android:drawable="@drawable/stat_sys_battery_30" android:maxLevel="30" />
<item android:drawable="@drawable/stat_sys_battery_31" android:maxLevel="31" />
<item android:drawable="@drawable/stat_sys_battery_32" android:maxLevel="32" />
<item android:drawable="@drawable/stat_sys_battery_33" android:maxLevel="33" />
<item android:drawable="@drawable/stat_sys_battery_34" android:maxLevel="34" />
<item android:drawable="@drawable/stat_sys_battery_35" android:maxLevel="35" />
<item android:drawable="@drawable/stat_sys_battery_36" android:maxLevel="36" />
<item android:drawable="@drawable/stat_sys_battery_37" android:maxLevel="37" />
<item android:drawable="@drawable/stat_sys_battery_38" android:maxLevel="38" />
<item android:drawable="@drawable/stat_sys_battery_39" android:maxLevel="39" />
<item android:drawable="@drawable/stat_sys_battery_40" android:maxLevel="40" />
<item android:drawable="@drawable/stat_sys_battery_41" android:maxLevel="41" />
<item android:drawable="@drawable/stat_sys_battery_42" android:maxLevel="42" />
<item android:drawable="@drawable/stat_sys_battery_43" android:maxLevel="43" />
<item android:drawable="@drawable/stat_sys_battery_44" android:maxLevel="44" />
<item android:drawable="@drawable/stat_sys_battery_45" android:maxLevel="45" />
<item android:drawable="@drawable/stat_sys_battery_46" android:maxLevel="46" />
<item android:drawable="@drawable/stat_sys_battery_47" android:maxLevel="47" />
<item android:drawable="@drawable/stat_sys_battery_48" android:maxLevel="48" />
<item android:drawable="@drawable/stat_sys_battery_49" android:maxLevel="49" />
<item android:drawable="@drawable/stat_sys_battery_50" android:maxLevel="50" />
<item android:drawable="@drawable/stat_sys_battery_51" android:maxLevel="51" />
<item android:drawable="@drawable/stat_sys_battery_52" android:maxLevel="52" />
<item android:drawable="@drawable/stat_sys_battery_53" android:maxLevel="53" />
<item android:drawable="@drawable/stat_sys_battery_54" android:maxLevel="54" />
<item android:drawable="@drawable/stat_sys_battery_55" android:maxLevel="55" />
<item android:drawable="@drawable/stat_sys_battery_56" android:maxLevel="56" />
<item android:drawable="@drawable/stat_sys_battery_57" android:maxLevel="57" />
<item android:drawable="@drawable/stat_sys_battery_58" android:maxLevel="58" />
<item android:drawable="@drawable/stat_sys_battery_59" android:maxLevel="59" />
<item android:drawable="@drawable/stat_sys_battery_60" android:maxLevel="60" />
<item android:drawable="@drawable/stat_sys_battery_61" android:maxLevel="61" />
<item android:drawable="@drawable/stat_sys_battery_62" android:maxLevel="62" />
<item android:drawable="@drawable/stat_sys_battery_63" android:maxLevel="63" />
<item android:drawable="@drawable/stat_sys_battery_64" android:maxLevel="64" />
<item android:drawable="@drawable/stat_sys_battery_65" android:maxLevel="65" />
<item android:drawable="@drawable/stat_sys_battery_66" android:maxLevel="66" />
<item android:drawable="@drawable/stat_sys_battery_67" android:maxLevel="67" />
<item android:drawable="@drawable/stat_sys_battery_68" android:maxLevel="68" />
<item android:drawable="@drawable/stat_sys_battery_69" android:maxLevel="69" />
<item android:drawable="@drawable/stat_sys_battery_70" android:maxLevel="70" />
<item android:drawable="@drawable/stat_sys_battery_71" android:maxLevel="71" />
<item android:drawable="@drawable/stat_sys_battery_72" android:maxLevel="72" />
<item android:drawable="@drawable/stat_sys_battery_73" android:maxLevel="73" />
<item android:drawable="@drawable/stat_sys_battery_74" android:maxLevel="74" />
<item android:drawable="@drawable/stat_sys_battery_75" android:maxLevel="75" />
<item android:drawable="@drawable/stat_sys_battery_76" android:maxLevel="76" />
<item android:drawable="@drawable/stat_sys_battery_77" android:maxLevel="77" />
<item android:drawable="@drawable/stat_sys_battery_78" android:maxLevel="78" />
<item android:drawable="@drawable/stat_sys_battery_79" android:maxLevel="79" />
<item android:drawable="@drawable/stat_sys_battery_80" android:maxLevel="80" />
<item android:drawable="@drawable/stat_sys_battery_81" android:maxLevel="81" />
<item android:drawable="@drawable/stat_sys_battery_82" android:maxLevel="82" />
<item android:drawable="@drawable/stat_sys_battery_83" android:maxLevel="83" />
<item android:drawable="@drawable/stat_sys_battery_84" android:maxLevel="84" />
<item android:drawable="@drawable/stat_sys_battery_85" android:maxLevel="85" />
<item android:drawable="@drawable/stat_sys_battery_86" android:maxLevel="86" />
<item android:drawable="@drawable/stat_sys_battery_87" android:maxLevel="87" />
<item android:drawable="@drawable/stat_sys_battery_88" android:maxLevel="88" />
<item android:drawable="@drawable/stat_sys_battery_89" android:maxLevel="89" />
<item android:drawable="@drawable/stat_sys_battery_90" android:maxLevel="90" />
<item android:drawable="@drawable/stat_sys_battery_91" android:maxLevel="91" />
<item android:drawable="@drawable/stat_sys_battery_92" android:maxLevel="92" />
<item android:drawable="@drawable/stat_sys_battery_93" android:maxLevel="93" />
<item android:drawable="@drawable/stat_sys_battery_94" android:maxLevel="94" />
<item android:drawable="@drawable/stat_sys_battery_95" android:maxLevel="95" />
<item android:drawable="@drawable/stat_sys_battery_96" android:maxLevel="96" />
<item android:drawable="@drawable/stat_sys_battery_97" android:maxLevel="97" />
<item android:drawable="@drawable/stat_sys_battery_98" android:maxLevel="98" />
<item android:drawable="@drawable/stat_sys_battery_99" android:maxLevel="99" />
<item android:drawable="@drawable/stat_sys_battery_100" android:maxLevel="100" />
</level-list>
2. stat_sys_battery_charge.xml
Havent reproduced the code here as it is very very long. The file is in the zip attached herewith
--Make/obtain 101 battery icons with %nos & charging icons or your choice of icons and copy them to "res/drawable-xxhdpi" folder replacing any file that you may be asked to. I have made the stock G2 icons with battery % inscribed on them which is attached herewith for those who prefer stock icons and don't want to look any further. In my set of icons fully charged reflects "F" on battery. Please make sure you retain the name of the battery icon in the series of
>>>Battery icons: "stat_sys_battery_0; stat_sys_battery_1......stat_sys_battery_100".
>>>Battery Charging icons: "stat_sys_battery_charging_ani_0; stat_sys_battery_charging_ani_1......stat_sys_battery_charging_ani_100".
--Recompile the LGSystemUI.apk
--V-Imp: Drag the "meta_inf" folder from original LGSystemUI.apk to the recompiled Systemui file using 7zip.
--Rename your recompiled file to "LGSystemUI.apk" and move to the appropriate folder in your phone with 644 / -rw-r--r-- permissions i.e
JB- in "/system/app" folder.
KK- in "/system/priv-app" folder.
--Reboot and Enjoy the 1% battery change in normal and in charging icons.
TIP: Make sure the icons you select are xxhdpi for G2, xxxhdpi for G3 and xhdpi for Flex and files are put in respective folders
Press thanks button if this was useful to you....promotes development.. Its nice to give a little credit for this guide/tutorial.... feels nice that your efforts went appreciated
Due credit to @Erhany from whom I learnt a lot of things while I had my Xperia Sola
good work very useful information.
screen please? thanks
There you go
Nice guide rastigo :good:
But had previously shared
http://forum.xda-developers.com/showthread.php?p=50536498#post50536498
pendroz said:
Nice guide rastigo :good:
But had previously shared
http://forum.xda-developers.com/showthread.php?p=50536498#post50536498
Click to expand...
Click to collapse
oops...hadnt seen yours @pendroz.....Yesterday @XxZombiePikachu asked for the files as he wants to include in his mods...thats why I made this. I thought this might help others who wanna take up dev of mods.
rastigo said:
oops...hadnt seen yours @pendroz.....Yesterday @XxZombiePikachu asked for the files as he wants to include in his mods...thats why I made this. I thought this might help others who wanna take up dev of mods.
Click to expand...
Click to collapse
No problem mate
rastigo said:
--Deodex your LGSystemUI.apk (if you run a odexed ROM). For de-odexed ROM this isn't required.
Click to expand...
Click to collapse
This isn't required period, regardless of your ROM.
Also, only apktool built with code after 9/May is capable of handling LGSystemUI.apk, it's newer than 2.0.0b9 and not widely available unless you compile yourself.
My custom icons
As required by some I am uploading another set of battery icons made by me for G2. It is a wider batter icon showing battery percentage inside it and animations for charging as well.
You need to incorporate the status bar battery in Post 1 and these icons in the respective folder and voila....
Dont forget the thanks button if you liked the icons...:laugh:
For Lg G Pro 2 too..
Hi, please make for Lg G Pro 2 too..
Or help me to make it by my self ...
Tnx
A nice guide...but not quite accurate.
If you're on 4.3 or below, you don't need to have a deodexed apk to be able to change the battery icon.
If you're on 4.4 or above, you do need to have a deodexed apk as you need to do a lot of smali editing before you can even think about changing the battery icon.
And I really don't suggest moving your modded apk to your phone's memory and rebooting. LGSystemUI.apk is a system app and you'll be replacing it while it's running.
This is a bit like changing your car's gearbox while you're driving it. You might get away with it but you're asking for trouble.
Personally I always recommend using a flashable zip to change files in the system partition.
Otherwise, a very neat tutorial. :highfive:
rastigo said:
oops...hadnt seen yours @pendroz.....Yesterday @XxZombiePikachu asked for the files as he wants to include in his mods...thats why I made this. I thought this might help others who wanna take up dev of mods.
Click to expand...
Click to collapse
yep I had been looking all over and for some reason the term I did not try for my search was 1% battery mod(I tried all sorts of stuff to no luck), thanks @rastigo for the great easy to follow guide will soon be working it into some mods; yo @pendroz it seems like there is a step missing in your guide?
I do have a quick question what if I also want to apply it for the charging animation would it be the same as here(add 100 separate battery charging images and call out to them in the xml?) or is there something else involved for the charging animation?
I am uploading that xml too
rastigo said:
I am uploading that xml too
Click to expand...
Click to collapse
Op updated with xharging xml also. Now you can also have 1% battery mod on charging
XxZombiePikachu said:
yep I had been looking all over and for some reason the term I did not try for my search was 1% battery mod(I tried all sorts of stuff to no luck), thanks @rastigo for the great easy to follow guide will soon be working it into some mods; yo @pendroz it seems like there is a step missing in your guide?
I do have a quick question what if I also want to apply it for the charging animation would it be the same as here(add 100 separate battery charging images and call out to them in the xml?) or is there something else involved for the charging animation?
Click to expand...
Click to collapse
The great thing about the charging animation is that it actually is an animation.
If you're feeling creative, you can change the timing of the animation, change which icons are shown..you can even create a nice-looking animation for when the battery's fully-charged.
Everytime I create a new battery icon, I always put some sort of looping animation for when it's charged to 100%. Just because it looks cool.
And it's very easy to do, if you understand what the xml code is actually saying...
Code:
<item android:maxLevel="100">
<animation-list android:oneshot="false"
xmlns:android="http://schemas.android.com/apk/res/android">
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_0" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_1" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_2" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_3" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_4" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_5" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_6" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_7" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_8" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_9" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_10" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_11" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_12" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_13" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_14" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_15" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_16" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_17" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_18" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_19" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_20" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_21" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_22" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_23" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_24" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_25" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_26" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_27" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_28" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_29" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_30" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_31" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_32" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_33" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_34" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_35" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_36" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_37" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_38" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_39" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_40" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_41" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_42" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_43" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_44" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_45" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_46" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_47" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_48" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_49" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_50" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_51" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_52" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_53" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_54" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_55" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_56" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_57" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_58" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_59" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_60" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_61" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_62" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_63" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_64" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_65" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_66" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_67" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_68" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_69" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_70" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_71" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_72" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_73" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_74" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_75" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_76" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_77" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_78" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_79" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_80" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_81" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_82" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_83" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_84" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_85" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_86" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_87" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_88" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_89" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_90" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_91" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_92" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_93" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_94" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_95" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_96" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_97" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_98" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_99" />
<item android:duration="100" android:drawable="@drawable/stat_sys_battery_100" />
</animation-list>
</item>
rastigo said:
--Decompile LGSystemUI.apk
Click to expand...
Click to collapse
which apktool are you using for Kitkat? I got systemUI has stoped after recompiling..
Did you copy metainf folder and androidmanifestxml from orig file to the recompiled app. I use 1.5.2.
@rastigothanks for sharing!
Can you point me how to deodex and odex back the LGSystemUI.apk? I´m on D80220f stock rom.
Thanks in advance
vladmir said:
@rastigothanks for sharing!
Can you point me how to deodex and odex back the LGSystemUI.apk? I´m on D80220f stock rom.
Thanks in advance
Click to expand...
Click to collapse
I use the auto-odexer utility for reodexing. Works flawlessly. If u search on xda, you will find it. Here is the link http://forum.xda-developers.com/showthread.php?p=31360029
Can you please explain how to use the app to deodex, am a noob, sorry
I tried so many time to add list view animation.
but every time i failed.
Please help me......
i followed those thread.
Link:
http://forum.xda-developers.com/showthread.php?t=2685334
http://forum.xda-developers.com/android/themes/guide-how-to-port-mokee-listview-t2808288
Advance thanks
sorry bad english
And how about you tell your progress?
Any logcat . why it did not work?
Vivek_Neel said:
And how about you tell your progress?
Any logcat . why it did not work?
Click to expand...
Click to collapse
I followed this progress
Adi Aisiteru Reborn said:
Guide for CyanogenMod11 KOT49H
HOW TO PORT "Mokee ListView Animations" for CyanogenMod11 only !!
Hello guys, I want to share to you smali Guide how to port with settings. custom Mokee ListView Animation,.
credit to Mokee rom
ok lets go to Guide:
first of all need some requirement for this MOD-GUIDE
REQUIREMENT:
- BRAIN
- Patient
- experience
- Know how to decompile/recompiling Apk and JAR file
- notepad++
- Tool for decompiling, : apkmanager/apktool/Virtous/apkmultitools/ or else
Settings.apk
Decompile your CM11 Settings.apk
1. Settings.apk\res\values\arrays.xml
add this to end of it before
Code:
</resources>
so it will be like this
Code:
<string-array name="listview_animation_entries">
<item>@string/listview_off</item>
<item>@string/listview_wave_left</item>
<item>@string/listview_wave_right</item>
<item>@string/listview_scale</item>
<item>@string/listview_alpha</item>
<item>@string/listview_stack_top</item>
<item>@string/listview_stack_bottom</item>
<item>@string/listview_unfold</item>
<item>@string/listview_fold</item>
<item>@string/listview_translate_left</item>
<item>@string/listview_translate_right</item>
<item>@string/listview_rotate</item>
</string-array>
<string-array name="listview_animation_values">
<item>0</item>
<item>1</item>
<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>
</string-array>
<string-array name="listview_interpolator_entries">
<item>@string/listview_off</item>
<item>@string/listview_accelerate_interpolator</item>
<item>@string/listview_decelerate_interpolator</item>
<item>@string/listview_accelerate_decelerate_interpolator</item>
<item>@string/listview_anticipate_interpolator</item>
<item>@string/listview_overshoot_interpolator</item>
<item>@string/listview_anticipate_overshoot_interpolator</item>
<item>@string/listview_bounce_interpolator</item>
</string-array>
<string-array name="listview_interpolator_values">
<item>0</item>
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
<item>5</item>
<item>6</item>
<item>7</item>
</string-array>
[COLOR="Blue"]</resources>[/COLOR]
2. Settings.apk\res\values\strings.xml
add this to end of it before
Code:
</resources>
so it will be like this
Code:
<string name="listview_animation_title">ListView animation</string>
<string name="listview_off">Off</string>
<string name="listview_wave_left">Wave (left)</string>
<string name="listview_wave_right">Wave (right)</string>
<string name="listview_alpha">Alpha</string>
<string name="listview_scale">Scale</string>
<string name="listview_stack_top">Stack (top)</string>
<string name="listview_stack_bottom">Stack (bottom)</string>
<string name="listview_unfold">Unfold</string>
<string name="listview_fold">Fold</string>
<string name="listview_translate_left">Translate (left)</string>
<string name="listview_translate_right">Translate (right)</string>
<string name="listview_rotate">Rotate</string>
<string name="listview_interpolator_title">ListView interpolator</string>
<string name="listview_accelerate_interpolator">Accelerate</string>
<string name="listview_decelerate_interpolator">Decelerate</string>
<string name="listview_accelerate_decelerate_interpolator">Accelerate decelerate</string>
<string name="listview_anticipate_interpolator">Anticipate</string>
<string name="listview_overshoot_interpolator">Overshoot</string>
<string name="listview_anticipate_overshoot_interpolator">Anticipate overshoot</string>
<string name="listview_bounce_interpolator">Bounce</string>
[COLOR="Blue"]</resources>[/COLOR]
3. Settings.apk\res\xml\system_ui_settings.xml
add this line
Code:
<PreferenceScreen android:title="@string/listview_animation_title" android:key="listview_animation_settings" android:fragment="com.android.settings.adi.ListViewSettings" />
this is the example :
Code:
<?xml version="1.0" encoding="utf-8"?>
<PreferenceScreen android:title="@string/system_interface_title"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:settings="http://schemas.android.com/apk/res/com.android.settings">
<PreferenceScreen android:title="@string/status_bar_title" android:key="status_bar" android:fragment="com.android.settings.cyanogenmod.StatusBar" />
<PreferenceScreen android:title="@string/quick_settings_panel_title" android:key="quick_settings_panel" android:fragment="com.android.settings.quicksettings.QuickSettings" />
<PreferenceScreen android:title="@string/notification_drawer_title" android:key="notification_drawer" android:fragment="com.android.settings.cyanogenmod.NotificationDrawer" />
<PreferenceCategory android:title="@string/power_menu_expanded_desktop" android:key="expanded_desktop_category">
<ListPreference android:persistent="false" android:entries="@array/expanded_desktop_entries" android:title="@string/expanded_desktop_style" android:key="expanded_desktop" android:entryValues="@array/expanded_desktop_values" />
<com.android.settings.cyanogenmod.SystemSettingCheckBoxPreference android:title="@string/expanded_desktop_system_bars_visibility" android:key="expanded_desktop_system_bars_visibility" android:summary="@string/expanded_desktop_system_bars_visibility_summary" android:defaultValue="false" />
</PreferenceCategory>
<Preference android:key="touch_screen_gesture_settings">
<intent android:targetPackage="com.cyanogenmod.settings.device" android:action="com.cyanogenmod.action.LAUNCH_TOUCHSCREEN_GESTURE_SETTINGS" android:targetClass="com.cyanogenmod.settings.device.TouchscreenGestureSettings" />
</Preference>
[COLOR="Red"]<PreferenceScreen android:title="@string/listview_animation_title" android:key="listview_animation_settings" android:fragment="com.android.settings.adi.ListViewSettings" />[/COLOR]
<PreferenceScreen android:title="@string/ram_bar" android:key="recents_panel" android:fragment="com.android.settings.adi.RecentsPanelSettings" />
<PreferenceCategory android:title="@string/navigation_bar_category">
<CheckBoxPreference android:title="@string/navbar_enable_bar" android:key="enable_nav_bar" android:summary="@string/navbar_enable_bar_summary" android:defaultValue="true" />
<PreferenceScreen android:title="@string/navbar_style_dimen_title" android:key="navbar_dimen_settings" android:dependency="enable_nav_bar" android:fragment="com.android.settings.adi.NavbarDimenSettings" />
<PreferenceScreen android:title="@string/navigation_bar_title" android:key="navigation_bar" android:dependency="enable_nav_bar" android:fragment="com.android.settings.cyanogenmod.NavBar" />
<PreferenceScreen android:title="@string/navigation_ring_title" android:key="navigation_ring" android:dependency="enable_nav_bar" android:fragment="com.android.settings.cyanogenmod.NavRing" />
<com.android.settings.cyanogenmod.SystemSettingCheckBoxPreference android:title="@string/navigation_bar_left_title" android:key="navigation_bar_left" android:summary="@string/navigation_bar_left_summary" android:dependency="enable_nav_bar" android:defaultValue="false" />
</PreferenceCategory>
<PreferenceCategory android:title="@string/hw_keys_title" android:key="hw_keys_on_navbar">
<CheckBoxPreference android:title="@string/key_back_enabled" android:key="key_back_enabled" android:defaultValue="true" />
<CheckBoxPreference android:title="@string/key_menu_enabled" android:key="key_menu_enabled" android:defaultValue="true" />
<CheckBoxPreference android:title="@string/key_home_enabled" android:key="key_home_enabled" android:defaultValue="true" />
</PreferenceCategory>
</PreferenceScreen>
4. Download attached file and merge to your decompiled Settings.apk, done and recompile it
5. Decompile the newly Recompiled APK again
- Next go to res/values/public.xml
open it with Notepad++
search for this line
Code:
<public type="xml" name="adi_mokee_listview_animations" id="[COLOR="Red"]??????????[/COLOR]" />
and pay attention to this ??????????
leave it, but keep it open
6. from the second decompiled Settings.apk , go to Settings.apk\smali\com\android\settings\adi\ListViewSettings.smali
search for this line
Code:
const v6, 0x7f050076
change this ids value 0x7f050076 in the smali
from here
Code:
<public type="xml" name="adi_mokee_listview_animations" id="[COLOR="Red"]??????????[/COLOR]" />
7. Done and recompile your settings.apk
Click to expand...
Click to collapse
Adi Aisiteru Reborn said:
framework.jar
1. Decompile your CM11 framework.jar
go to framework.jar\classout\android\widget\
remove all AbsListView.smali and its subs file
replace them with attached file
2. Decompile your CM11 framework-res.apk
go to \framework-res.apk\res\values\public.xml
search for this lines :
Code:
<public type="attr" name="absListViewStyle" id="0x010[COLOR="Red"]?????[/COLOR]" />
Code:
<public type="style" name="Animation.TypingFilter" id="0x010[COLOR="Red"]?????[/COLOR]" />
Code:
<public type="style" name="Animation.TypingFilterRestore" id="0x010[COLOR="Red"]?????[/COLOR]" />
Code:
<public type="layout" name="typing_filter" id="0x010[COLOR="Red"]?????[/COLOR]" />
Code:
<public type="drawable" name="list_selector_background" id="0x010[COLOR="Red"]?????[/COLOR]" />
Code:
<public type="anim" name="accelerate_interpolator" id="0x010[COLOR="Red"]?????[/COLOR]" />
Code:
<public type="anim" name="decelerate_interpolator" id="0x010[COLOR="Red"]?????[/COLOR]" />
Code:
<public type="anim" name="accelerate_decelerate_interpolator" id="0x010[COLOR="Red"]?????[/COLOR]" />
Code:
<public type="anim" name="anticipate_interpolator" id="0x010[COLOR="Red"]?????[/COLOR]" />
Code:
<public type="anim" name="overshoot_interpolator" id="0x010[COLOR="Red"]?????[/COLOR]" />
Code:
<public type="anim" name="anticipate_overshoot_interpolator" id="0x010[COLOR="Red"]?????[/COLOR]" />
Code:
<public type="anim" name="bounce_interpolator" id="0x010[COLOR="Red"]?????[/COLOR]" />
pay attention to the red highlight the last 5 digits of each line 0x010?????
3. open AbsListView.smali file I gave
and search for this
- const v0, 0x101006a
change the last 5 digits ids 1006a in the smali according to your own have in
Code:
<public type="attr" name="absListViewStyle" id="0x010[COLOR="Red"]?????[/COLOR]" />
do it too to all of line below
- const v2, 0x10301ed
Code:
<public type="style" name="Animation.TypingFilter" id="0x010[COLOR="Red"]?????[/COLOR]" />
- const v2, 0x10301ee
Code:
<public type="style" name="Animation.TypingFilterRestore" id="0x010[COLOR="Red"]?????[/COLOR]" />
- const v1, 0x10900b8
Code:
<public type="layout" name="typing_filter" id="0x010[COLOR="Red"]?????[/COLOR]" />
- const v1, 0x1080062
Code:
<public type="drawable" name="list_selector_background" id="0x010[COLOR="Red"]?????[/COLOR]" />
- const v2, 0x10a0005
Code:
<public type="anim" name="accelerate_interpolator" id="0x010[COLOR="Red"]?????[/COLOR]" />
- const v2, 0x10a0006
Code:
<public type="anim" name="decelerate_interpolator" id="0x010[COLOR="Red"]?????[/COLOR]" />
- const v2, 0x10a0004
Code:
<public type="anim" name="accelerate_decelerate_interpolator" id="0x010[COLOR="Red"]?????[/COLOR]" />
- const v2, 0x10a0007
Code:
<public type="anim" name="anticipate_interpolator" id="0x010[COLOR="Red"]?????[/COLOR]" />
- const v2, 0x10a0008
Code:
<public type="anim" name="overshoot_interpolator" id="0x010[COLOR="Red"]?????[/COLOR]" />
- const v2, 0x10a0009
Code:
<public type="anim" name="anticipate_overshoot_interpolator" id="0x010[COLOR="Red"]?????[/COLOR]" />
- const v2, 0x10a000a
Code:
<public type="anim" name="bounce_interpolator" id="0x010[COLOR="Red"]?????[/COLOR]" />
4. Done and compile your framework.jar
Click to expand...
Click to collapse
Vivek_Neel said:
And how about you tell your progress?
Any logcat . why it did not work?
Click to expand...
Click to collapse
i haven't logcat but i will get you soon