[ask] add invisible power button on systemui miui 8 - Xiaomi Mi 4i

i have try to add invisible power button on systemUI MIUI 8 and got this error
Code:
Log For : MiuiSystemUI.apk
Log Type : Recompiling
Log Recorded At : Wed 16-11-2016 15:49:38.49
Log Recorded By : Advanced ApkTool v3.0.0 By BDFreak
------------------------------------------------------
W: E:\FLASHXIAOMI\AdvancedApkTool\3-Out\MiuiSystemUI.apk\res\layout\status_bar.xml:2: error: Error parsing XML: unbound prefix
W:
Exception in thread "main" brut.androlib.AndrolibException: brut.androlib.AndrolibException: brut.common.BrutException: could not exec (exit code = 1): [C:\Users\k4gara\AppData\Local\Temp\brut_util_Jar_6691148060102741333.tmp, p, --forced-package-id, 127, --min-sdk-version, 21, --target-sdk-version, 21, --version-code, 21, --version-name, 5.0.2, -F, C:\Users\k4gara\AppData\Local\Temp\APKTOOL6317259639059092263.tmp, -0, arsc, -0, arsc, -I, E:\FLASHXIAOMI\AdvancedApkTool\1-BDFreak\Frameworks\1.apk, -I, E:\FLASHXIAOMI\AdvancedApkTool\1-BDFreak\Frameworks\16.apk, -I, E:\FLASHXIAOMI\AdvancedApkTool\1-BDFreak\Frameworks\17.apk, -S, E:\FLASHXIAOMI\AdvancedApkTool\3-Out\MiuiSystemUI.apk\res, -M, E:\FLASHXIAOMI\AdvancedApkTool\3-Out\MiuiSystemUI.apk\AndroidManifest.xml]
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:478)
at brut.androlib.Androlib.buildResources(Androlib.java:412)
at brut.androlib.Androlib.build(Androlib.java:311)
at brut.androlib.Androlib.build(Androlib.java:264)
at brut.apktool.Main.cmdBuild(Main.java:227)
at brut.apktool.Main.main(Main.java:84)
Caused by: brut.androlib.AndrolibException: brut.common.BrutException: could not exec (exit code = 1): [C:\Users\k4gara\AppData\Local\Temp\brut_util_Jar_6691148060102741333.tmp, p, --forced-package-id, 127, --min-sdk-version, 21, --target-sdk-version, 21, --version-code, 21, --version-name, 5.0.2, -F, C:\Users\k4gara\AppData\Local\Temp\APKTOOL6317259639059092263.tmp, -0, arsc, -0, arsc, -I, E:\FLASHXIAOMI\AdvancedApkTool\1-BDFreak\Frameworks\1.apk, -I, E:\FLASHXIAOMI\AdvancedApkTool\1-BDFreak\Frameworks\16.apk, -I, E:\FLASHXIAOMI\AdvancedApkTool\1-BDFreak\Frameworks\17.apk, -S, E:\FLASHXIAOMI\AdvancedApkTool\3-Out\MiuiSystemUI.apk\res, -M, E:\FLASHXIAOMI\AdvancedApkTool\3-Out\MiuiSystemUI.apk\AndroidManifest.xml]
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:439)
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:464)
... 5 more
Caused by: brut.common.BrutException: could not exec (exit code = 1): [C:\Users\k4gara\AppData\Local\Temp\brut_util_Jar_6691148060102741333.tmp, p, --forced-package-id, 127, --min-sdk-version, 21, --target-sdk-version, 21, --version-code, 21, --version-name, 5.0.2, -F, C:\Users\k4gara\AppData\Local\Temp\APKTOOL6317259639059092263.tmp, -0, arsc, -0, arsc, -I, E:\FLASHXIAOMI\AdvancedApkTool\1-BDFreak\Frameworks\1.apk, -I, E:\FLASHXIAOMI\AdvancedApkTool\1-BDFreak\Frameworks\16.apk, -I, E:\FLASHXIAOMI\AdvancedApkTool\1-BDFreak\Frameworks\17.apk, -S, E:\FLASHXIAOMI\AdvancedApkTool\3-Out\MiuiSystemUI.apk\res, -M, E:\FLASHXIAOMI\AdvancedApkTool\3-Out\MiuiSystemUI.apk\AndroidManifest.xml]
at brut.util.OS.exec(OS.java:95)
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:433)
... 6 more
------------------------------------------------------
code that i insert
Code:
<com.android.systemui.statusbar.policy.KeyButtonView android:id="@id/home" android:layout_gravity="right" android:layout_width="wrap_content" android:layout_height="fill_parent" android:src="@drawable/screen_off" android:layout_toRightOf="@id/recent_apps" android:contentDescription="@string/accessibility_back" systemui:keyCode="26" systemui:glowBackground="@drawable/ic_sysbar_highlight_land" systemui:keyRepeat="false" androidrientation="vertical" />
my status_bar.xml
Code:
<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.policy.KeyButtonView android:id="@id/home" android:layout_gravity="right" android:layout_width="wrap_content" android:layout_height="fill_parent" android:src="@drawable/screen_off" android:layout_toRightOf="@id/recent_apps" android:contentDescription="@string/accessibility_back" systemui:keyCode="26" systemui:glowBackground="@drawable/ic_sysbar_highlight_land" systemui:keyRepeat="false" androidrientation="vertical" />
<com.android.systemui.statusbar.phone.PhoneStatusBarView android:id="@id/status_bar" android:background="@drawable/status_bar_background" android:focusable="true" android:fitsSystemWindows="true" android:descendantFocusability="afterDescendants"
xmlns:android="http://schemas.android.com/apk/res/android">
<FrameLayout android:id="@id/oldman_std_status_wrapper" android:layout_width="fill_parent" android:layout_height="fill_parent">
<com.android.systemui.TorchServiceView android:visibility="gone" android:layout_width="wrap_content" android:layout_height="wrap_content" />
<include android:id="@id/status_bar_simple" layout="@layout/status_bar_simple" />
<LinearLayout android:gravity="center" android:id="@id/returnToDriveModeScreen" android:background="@drawable/status_bar_orange_bar_bg" android:visibility="gone" android:layout_width="fill_parent" android:layout_height="fill_parent">
<ImageView android:id="@id/driveModeIcon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@drawable/status_bar_drive_mode_icon" android:layout_marginStart="3.0dip" />
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/drive_mode_tip" android:singleLine="true" android:layout_weight="1.0" android:layout_marginStart="5.0dip" />
<com.android.systemui.statusbar.policy.Clock android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:gravity="start|center" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" android:paddingEnd="3.0dip" />
</LinearLayout>
<LinearLayout android:gravity="center" android:id="@id/returnToRecorderScreen" android:background="@drawable/status_bar_recorder_layout_bg" android:visibility="gone" android:layout_width="fill_parent" android:layout_height="fill_parent">
<ImageView android:id="@id/recorderIcon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@drawable/status_bar_recorder_icon" android:layout_marginStart="8.0dip" />
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:id="@id/recorderTitle" android:layout_width="wrap_content" android:layout_height="wrap_content" android:singleLine="true" android:layout_weight="1.0" android:layout_marginStart="8.0dip" />
<Chronometer android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:gravity="end" android:id="@id/recorderTimer" android:layout_width="wrap_content" android:layout_height="wrap_content" android:minWidth="46.0dip" android:singleLine="true" android:layout_marginEnd="8.0dip" />
<com.android.systemui.statusbar.phone.BatteryStatusIconView android:id="@id/recorder_battery" android:layout_width="wrap_content" android:layout_height="wrap_content" />
</LinearLayout>
<LinearLayout android:gravity="center" android:orientation="vertical" android:id="@id/safepayStatusBar" android:visibility="gone" android:layout_width="fill_parent" android:layout_height="fill_parent">
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:gravity="center" android:id="@id/safepayStatusBarText" android:layout_width="wrap_content" android:layout_height="wrap_content" android:singleLine="true" android:drawableLeft="@drawable/safepay_statusbar_icon" android:drawablePadding="18.0px" />
<miui.widget.ProgressBar android:gravity="bottom" android:id="@id/progressbar" android:visibility="gone" android:layout_width="fill_parent" android:layout_height="4.0px" android:layout_marginTop="4.0px" android:progressDrawable="@drawable/safepay_progressbar_style" style="?android:attr/progressBarStyleHorizontal" />
</LinearLayout>
<LinearLayout android:gravity="center" android:id="@id/returnToIncallScreen" android:background="@drawable/status_bar_green_bar_bg" android:visibility="gone" android:layout_width="fill_parent" android:layout_height="fill_parent" android:paddingStart="3.0dip" android:paddingEnd="3.0dip">
<ImageView android:id="@id/callStateIcon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@drawable/status_bar_ic_return_to_incall_screen_normal" />
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:layout_width="0.0dip" android:layout_height="wrap_content" android:text="@string/return_to_incall_screen" android:singleLine="true" android:layout_weight="1.0" android:paddingStart="3.0dip" android:paddingEnd="3.0dip" />
<LinearLayout android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/callIcons" android:layout_width="wrap_content" android:layout_height="fill_parent" />
<Chronometer android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:id="@id/callTimer" android:layout_width="wrap_content" android:layout_height="wrap_content" android:singleLine="true" android:layout_marginStart="3.0dip" android:layout_marginEnd="3.0dip" />
</LinearLayout>
</FrameLayout>
<ViewStub android:id="@id/oldman_status_pane_stub" android:layout="@layout/oldman_status_pane" android:inflatedId="@id/oldman_status_pane" android:layout_width="fill_parent" android:layout_height="fill_parent" />
</com.android.systemui.statusbar.phone.PhoneStatusBarView>
can anyone help?
 @serajr @Ticklefish
thanks for advance :fingers-crossed:

@kagara The line you added must be somewhere inside main layout, and it's outside of it!

@serajr thanks for your answer , i'll try every line hehe... the result will post later

@serajr i am failed bro, every line i have tried, would you help me ?

The error code is saying that line 2 has an issue. Like my esteemed colleague said, you need to include your KeyButtonView inside the main Layout for it to work.
Code:
<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.phone.PhoneStatusBarView android:id="@id/status_bar" android:background="@drawable/status_bar_background" android:focusable="true" android:fitsSystemWindows="true" android:descendantFocusability="afterDescendants"
xmlns:android="http://schemas.android.com/apk/res/android">
<FrameLayout android:id="@id/oldman_std_status_wrapper" android:layout_width="fill_parent" android:layout_height="fill_parent">
[color="red"] <com.android.systemui.statusbar.policy.KeyButtonView android:id="@id/home" android:layout_gravity="right" android:layout_width="wrap_content" android:layout_height="fill_parent" android:src="@drawable/screen_off" android:layout_toRightOf="@id/recent_apps" android:contentDescription="@string/accessibility_back" systemui:keyCode="26" systemui:glowBackground="@drawable/ic_sysbar_highlight_land" systemui:keyRepeat="false" androidrientation="vertical" />[/color]
<com.android.systemui.TorchServiceView android:visibility="gone" android:layout_width="wrap_content" android:layout_height="wrap_content" />
<include android:id="@id/status_bar_simple" layout="@layout/status_bar_simple" />
<LinearLayout android:gravity="center" android:id="@id/returnToDriveModeScreen" android:background="@drawable/status_bar_orange_bar_bg" android:visibility="gone" android:layout_width="fill_parent" android:layout_height="fill_parent">
<ImageView android:id="@id/driveModeIcon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@drawable/status_bar_drive_mode_icon" android:layout_marginStart="3.0dip" />
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/drive_mode_tip" android:singleLine="true" android:layout_weight="1.0" android:layout_marginStart="5.0dip" />
<com.android.systemui.statusbar.policy.Clock android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:gravity="start|center" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" android:paddingEnd="3.0dip" />
</LinearLayout>
<LinearLayout android:gravity="center" android:id="@id/returnToRecorderScreen" android:background="@drawable/status_bar_recorder_layout_bg" android:visibility="gone" android:layout_width="fill_parent" android:layout_height="fill_parent">
<ImageView android:id="@id/recorderIcon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@drawable/status_bar_recorder_icon" android:layout_marginStart="8.0dip" />
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:id="@id/recorderTitle" android:layout_width="wrap_content" android:layout_height="wrap_content" android:singleLine="true" android:layout_weight="1.0" android:layout_marginStart="8.0dip" />
<Chronometer android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:gravity="end" android:id="@id/recorderTimer" android:layout_width="wrap_content" android:layout_height="wrap_content" android:minWidth="46.0dip" android:singleLine="true" android:layout_marginEnd="8.0dip" />
<com.android.systemui.statusbar.phone.BatteryStatusIconView android:id="@id/recorder_battery" android:layout_width="wrap_content" android:layout_height="wrap_content" />
</LinearLayout>
<LinearLayout android:gravity="center" android:orientation="vertical" android:id="@id/safepayStatusBar" android:visibility="gone" android:layout_width="fill_parent" android:layout_height="fill_parent">
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:gravity="center" android:id="@id/safepayStatusBarText" android:layout_width="wrap_content" android:layout_height="wrap_content" android:singleLine="true" android:drawableLeft="@drawable/safepay_statusbar_icon" android:drawablePadding="18.0px" />
<miui.widget.ProgressBar android:gravity="bottom" android:id="@id/progressbar" android:visibility="gone" android:layout_width="fill_parent" android:layout_height="4.0px" android:layout_marginTop="4.0px" android:progressDrawable="@drawable/safepay_progressbar_style" style="?android:attr/progressBarStyleHorizontal" />
</LinearLayout>
<LinearLayout android:gravity="center" android:id="@id/returnToIncallScreen" android:background="@drawable/status_bar_green_bar_bg" android:visibility="gone" android:layout_width="fill_parent" android:layout_height="fill_parent" android:paddingStart="3.0dip" android:paddingEnd="3.0dip">
<ImageView android:id="@id/callStateIcon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@drawable/status_bar_ic_return_to_incall_screen_normal" />
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:layout_width="0.0dip" android:layout_height="wrap_content" android:text="@string/return_to_incall_screen" android:singleLine="true" android:layout_weight="1.0" android:paddingStart="3.0dip" android:paddingEnd="3.0dip" />
<LinearLayout android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/callIcons" android:layout_width="wrap_content" android:layout_height="fill_parent" />
<Chronometer android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:id="@id/callTimer" android:layout_width="wrap_content" android:layout_height="wrap_content" android:singleLine="true" android:layout_marginStart="3.0dip" android:layout_marginEnd="3.0dip" />
</LinearLayout>
</FrameLayout>
<ViewStub android:id="@id/oldman_status_pane_stub" android:layout="@layout/oldman_status_pane" android:inflatedId="@id/oldman_status_pane" android:layout_width="fill_parent" android:layout_height="fill_parent" />
</com.android.systemui.statusbar.phone.PhoneStatusBarView>
This is the correct syntax and your APK should compile now. Whether it works, or the power button is in the right place, is a different question. You need to have a good understanding of what the different Layouts represent, even if you don't understand what the actual code is.
I have a guide to modding XML here: http://forum.xda-developers.com/general/xda-university/xml-101-xml-modding-easy-t2929816 It may help you. :good:

@Ticklefish got same error, but i try to put in xml called super_status_bar.xml and its works
Code:
<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.phone.StatusBarWindowView android:background="@android:color/transparent" android:focusable="true" android:descendantFocusability="afterDescendants"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:systemui="http://schemas.android.com/apk/res/com.android.systemui">
<include android:layout_width="fill_parent" android:layout_height="@dimen/status_bar_height" layout="@layout/status_bar" />
<include android:id="@id/brightness_mirror_panel" android:visibility="invisible" android:layout_width="wrap_content" android:layout_height="wrap_content" android:alpha="0.0" layout="@layout/status_bar_expanded_brightness_panel" />
<ViewStub android:id="@id/status_bar_expanded" android:layout="@layout/status_bar_expanded" android:layout_width="fill_parent" android:layout_height="0.0dip" />
<ViewStub android:id="@id/status_bar_expanded_single_page" android:layout="@layout/status_bar_expanded_single_page" android:layout_width="fill_parent" android:layout_height="0.0dip" />
<com.android.systemui.statusbar.policy.KeyButtonView android:layout_gravity="right" android:id="@id/home" android:layout_width="wrap_content" android:layout_height="fill_parent" android:src="@drawable/screen_off" android:layout_toRightOf="@id/recent_apps" android:contentDescription="@string/accessibility_back" systemui:keyCode="26" systemui:keyRepeat="false" androidrientation="vertical" />
</com.android.systemui.statusbar.phone.StatusBarWindowView>
thankyou for yor help

Related

Development: WM6 Dutch MUI

I am working on a Dutch language pack for my Tornado under WM6.
I have ripped the Dutch WM6 SDK rom and got a lot of files. Made a cab with these files and some registry settings.
It isn't working yet.
So I browsed my phone today this is the list of files wich are still missing:
Already got:
05-12-2006 07:56 2.186 about_0413.htm
19-07-2007 14:21 27.136 AutoUpdateRes_smartfon.exe.0413.mui
19-07-2007 14:21 29.184 bbcbres.dll.0413.mui
19-07-2007 14:21 19.456 browsres.dll.0413.mui
19-07-2007 14:21 17.408 bthbond.exe.0413.mui
05-12-2006 07:58 8.138 Busy.0413.wav
19-07-2007 14:21 3.072 commctrl.dll.0413.mui
19-07-2007 15:29 2.578 compose_note.0413.htm
19-07-2007 15:26 1.332 compose_sms.0413.htm
22-06-2006 03:13 2.201 compose_style.0413.css
19-07-2007 14:21 2.560 coreres.dll.0413.mui
19-07-2007 14:21 5.632 crypt32.dll.0413.mui
19-07-2007 14:21 6.144 ctlgres.dll.0413.mui
09-01-2007 04:19 12.892 default_0413.htm
21-07-2007 23:11 0 dir.txt
19-07-2007 14:21 6.144 fatutil.dll.0413.mui
19-07-2007 14:21 1.024 filesys.exe.0413.mui
19-07-2007 14:21 18.432 gwes.exe.0413.mui
19-07-2007 14:21 9.728 LocInfo.dll.0413.mui
19-07-2007 14:21 13.824 MdsRes_smartfon.exe.0413.mui
19-07-2007 14:21 26.112 mlang.dll.0413.mui
19-07-2007 14:21 4.608 msscript.dll.0413.mui
19-07-2007 14:21 138.240 outres.dll.0413.mui
19-07-2007 14:21 10.240 quartz.dll.0413.mui
19-07-2007 15:36 2.920 read_mtgreq.0413.htm
19-07-2007 15:42 2.406 read_note.0413.htm
19-07-2007 15:41 2.358 read_sms.0413.htm
19-07-2007 14:21 56.832 shellres.dll.0413.mui
19-07-2007 14:21 28.672 shellresapps.dll.0413.mui
19-07-2007 14:21 4.096 shlwapi.dll.0413.mui
19-07-2007 14:21 50.176 syncres.dll.0413.mui
19-07-2007 14:21 84.480 tapres.dll.0413.mui
19-07-2007 14:21 93.184 tshres.dll.0413.mui
19-07-2007 14:21 1.536 unimodem.dll.0413.mui
19-07-2007 14:21 15.360 urlmon.dll.0413.mui
19-07-2007 14:21 6.144 waveapi.dll.0413.mui
19-07-2007 14:21 30.208 wininet.dll.0413.mui
19-07-2007 14:21 6.656 WLMContactsResources.dll.0413.MUI
19-07-2007 14:21 2.048 WLMHSContainerResources.dll.0413.MUI
19-07-2007 14:21 2.048 WLMHSMailResources.dll.0413.MUI
19-07-2007 14:21 2.048 WLMHSMeResources.dll.0413.MUI
19-07-2007 14:21 2.048 WLMHSMessengerResources.dll.0413.MUI
19-07-2007 14:21 2.048 WLMHSSearchBarResources.dll.0413.MUI
19-07-2007 14:21 2.048 WLMHSSplashResources.dll.0413.MUI
19-07-2007 14:21 2.048 WLMHSSyncResources.dll.0413.MUI
19-07-2007 14:21 5.120 WLMMailResources.dll.0413.MUI
19-07-2007 14:21 22.528 WLMMessengerResources.dll.0413.MUI
19-07-2007 14:21 9.728 WLMServiceResources.dll.0413.MUI
19-07-2007 14:21 2.560 WLMSharedResources.dll.0413.MUI
19-07-2007 14:21 2.560 WLMSpacesResources.dll.0413.MUI
19-07-2007 14:21 3.584 WLMSyncResources.dll.0413.MUI
19-07-2007 14:21 37.888 wmploc.dll.0413.mui
19-07-2007 14:21 3.584 wsp.dll.0413.mui
Looking for: (Can't find these in the SDK so I guess I need a Dutch VOX rom for these)
Authentication.dll.0413
btftpress.dll.0413
eT9.Vox.0413.kmap
IECEExt.dll.0413
Leap.dll.0413
officeres.dll.0413
pptres.dll.0413
SIM_Mgr.exe.0413
StorageLow.exe.0413
Sysinfo.dll.0413
T9Ime.dll.0413
USSD_Service.dll.0413
WiFiHomePlugin.dll.0413
WiFiSettings.dll.0409
WLANSettings.dll.0413
WLMDeckResources.dll.0413
How can I get a Dutch Vox rom to extract these?
Registry Keys in the Cab file:
- <characteristic type="HKCU\MUI">
<parm name="CurLang" value="1043" datatype="integer" />
</characteristic>
- <characteristic type="HKLM\MUI">
<parm name="0413" value="Nederlands" datatype="string" />
</characteristic>
- <characteristic type="HKCU\Software\Microsoft\Internet Explorer\International\0413">
<parm name="Default_CodePage" value="1250" datatype="integer" />
</characteristic>
- <characteristic type="HKLM\Software\Microsoft\Internet Explorer\AboutUrls">
<parm name="home_0413" value="file://\windows\default_0413.htm" datatype="string" />
<parm name="version_0413" value="file://\windows\about_0413.htm" datatype="string" />
</characteristic>
- <characteristic type="HKLM\System\Inbox\Templates\IPM\Note\0413">
<parm name="Read" value="\windows\read_note.0413.htm" datatype="string" />
<parm name="Compose" value="\windows\compose_note.0413.htm" datatype="string" />
</characteristic>
- <characteristic type="HKLM\System\Inbox\Templates\IPM\SMStext\0413">
<parm name="Read" value="\windows\read_sms.0413.htm" datatype="string" />
<parm name="Compose" value="\windows\compose_sms.0413.htm" datatype="string" />
</characteristic>
- <characteristic type="HKLM\System\Inbox\Templates\IPM\SMStext\VoiceNot\0413">
<parm name="Read" value="\windows\read_sms.0413.htm" datatype="string" />
</characteristic>
- <characteristic type="HKCU\ControlPanel\Profiles\Automatic">
<parm name="LocName" value="Automatisch" datatype="string" />
</characteristic>
- <characteristic type="HKCU\ControlPanel\Profiles\Loud">
<parm name="LocName" value="Hard" datatype="string" />
</characteristic>
- <characteristic type="HKCU\ControlPanel\Profiles\Meeting">
<parm name="LocName" value="Vergadering" datatype="string" />
</characteristic>
- <characteristic type="HKCU\ControlPanel\Profiles\Normal">
<parm name="LocName" value="Normaal" datatype="string" />
</characteristic>
- <characteristic type="HKCU\ControlPanel\Profiles\Silent">
<parm name="LocName" value="Stil" datatype="string" />
</characteristic>
- <characteristic type="HKLM\MUI\Available">
<parm name="0413" value="Nederlands" datatype="string" />
</characteristic>
- <characteristic type="HKLM\Software\Microsoft\Inbox\Svc\SMS">
<parm name="ReceivedMessages" value="Ontvangen berichten" datatype="string" />
<parm name="NewMessage" value="Nieuw bericht" datatype="string" />
<parm name="SendMessage" value="Verstuur bericht" datatype="string" />
<parm name="MessageSent" value="Bericht verzonden" datatype="string" />
<parm name="FriendlyName" value="SMS Berichen" datatype="string" />
<parm name="DeleteMessages" value="Berichten wissen" datatype="string" />
</characteristic>
- <characteristic type="HKLM\System\Inbox\Templates\REPORT\IPM\SMStext\DR\0413">
<parm name="Read" value="\windows\read_sms.0413.htm" datatype="string" />
</characteristic>
- <characteristic type="HKLM\System\Inbox\Templates\REPORT\IPM\SMStext\NDR">
<parm name="Read" value="\windows\read_sms.0413.htm" datatype="string" />
Do you have a newer version than the one in here? I'm hoping for a fully translated WM6 Btw if I can help, let me know. I have an SPV C600 with WM6... and obviously I'm Dutch
Missing Files
Hi,
I currently use WM 5 NL rom, because my phone had to get repaired (it has been repaired btw, but when I recieved my phone, the display was broken..).
WM 5 NL has some files like authenticiation.dll.0413.MUI
I don't know if you could use this file? It's WM5, and I don't know if the missing files have been changed??
Regards!
Any progress? Finished product available maybe?
you can rename the links in windows/startmenu to dutch names to make it more dutch
When you install this package and use exchange push e-mail, then the e-mail content is not shown.
Dutch t9 here:
http://melgurth.ovh.org/index.php?page=downloads
Also has link to language rip guide.
Is this a posting in the wrong thread?
Kirpeknots said:
I am working on a Dutch language pack for my Tornado under WM6.
<snip>
Looking for: (Can't find these in the SDK so I guess I need a Dutch VOX rom for these)
eT9.Vox.0413.kmap
T9Ime.dll.0413
<snip>
How can I get a Dutch Vox rom to extract these?
Click to expand...
Click to collapse
j.lambers I don't think my post was in the wrong thread or this thread in the wrong forum. Why do you ask? Did you think you posted in the wrong thread?
Kirpeknots:
Pardon my ignorance, the Netherlands speak Dutch, yes?
Well someone may have already done your work for you:
http://forum.xda-developers.com/showpost.php?p=1433253&postcount=35

cant install touchflow 1.4.1

dont know what im doing wrong and i cant find an answer anywhere
i've downloaded the zip and unzipped it to my desktop then i copied it to my tytn 2 try to run it but i only get an internet page open saying :
wap-provisioningdoc>
- <characteristic type="Install">
<parm name="InstallPhase" value="install" />
<parm name="OSVersionMin" value="4.0" />
<parm name="OSVersionMax" value="5.99" />
<parm name="BuildNumberMin" value="0" />
<parm name="BuildNumberMax" value="-536870912" />
<parm name="AppName" value="efrost FTouchFlo v,1.4.1" />
<parm name="InstallDir" value="%CE1%\FTouchFlo" translation="install" />
<parm name="NumDirs" value="3" />
<parm name="NumFiles" value="2" />
<parm name="NumRegKeys" value="0" />
<parm name="NumRegVals" value="0" />
<parm name="NumShortcuts" value="1" />
</characteristic>
- <characteristic type="FileOperation">
- <characteristic type="%InstallDir%" translation="install">
<characteristic type="MakeDir" />
please help
thanks
helder said:
dont know what im doing wrong and i cant find an answer anywhere
i've downloaded the zip and unzipped it to my desktop then i copied it to my tytn 2 try to run it but i only get an internet page open saying :
wap-provisioningdoc>
- <characteristic type="Install">
<parm name="InstallPhase" value="install" />
<parm name="OSVersionMin" value="4.0" />
<parm name="OSVersionMax" value="5.99" />
<parm name="BuildNumberMin" value="0" />
<parm name="BuildNumberMax" value="-536870912" />
<parm name="AppName" value="efrost FTouchFlo v,1.4.1" />
<parm name="InstallDir" value="%CE1%\FTouchFlo" translation="install" />
<parm name="NumDirs" value="3" />
<parm name="NumFiles" value="2" />
<parm name="NumRegKeys" value="0" />
<parm name="NumRegVals" value="0" />
<parm name="NumShortcuts" value="1" />
</characteristic>
- <characteristic type="FileOperation">
- <characteristic type="%InstallDir%" translation="install">
<characteristic type="MakeDir" />
please help
thanks
Click to expand...
Click to collapse
I'll start with the obvious questions first: is this your first time flashing? did you do the hard spl?
hi
its is my first time flashing
and i did do the hard spl
thanks
do you know if the hard spl worked? go into the bootloader screen and check.
Also, what operating system are you using? finally, you may want to pose your question in the the thread that deals with that ROM. Someone may have the answers already.
oh, and if you downloaded the ROM, you should be running it from your PC. Connect the phone to the PC, let activesynce connect and then run the install file from there.
os on my pc is vista ultimate
...how do i get to the bootloader screen?
helder said:
os on my pc is vista ultimate
...how do i get to the bootloader screen?
Click to expand...
Click to collapse
let's back up a bit.
Please read this and then try to reflash . . .
http://forum.xda-developers.com/showthread.php?t=356895
thanks for all your help it works now
helder said:
thanks for all your help it works now
Click to expand...
Click to collapse
congrats! Welcome to the madness . . .
wireless_one said:
congrats! Welcome to the madness . . .
Click to expand...
Click to collapse
real madness yow every week a diffrent flash pssh

[GUIDE][HOW TO]Android List View

Informations
This tutorial will be demonstrating how to build a simple android List View.
It is about creating list view and launching new activity on selecting single list item.
Below are two screenshots of the final output:
{
"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"
}
Guide
Let’s get start by creating a project in Eclipse IDE.
Create a new project by going to File ⇒ New Android Project. Fill all the details and name your activity as AndroidListViewActivity.
Once the project is created open your main activity java file (in this case AndroidListViewActivity.java) and extend the class from ListActivity.
Code:
[FONT="Courier New"][B][COLOR=#006699]public class[/COLOR][/B] AndroidListViewActivity [B][COLOR=#006699]extends[/COLOR][/B] ListActivity {[/FONT]
Now we need a string resources file to store all list item labels. So create an XML file under values folder and name it as list_data.xml and paste the following code.
( Right Click on res/values ⇒ New ⇒ Android XML File)
Code:
[FONT="Courier New"][COLOR=#819f07]list_data.xml[/COLOR]
<?[B][COLOR=#006699]xml[/COLOR][/B] [COLOR="Gray"]version[/COLOR]=[COLOR="Blue"]"1.0"[/COLOR] [COLOR="Gray"]encoding[/COLOR]=[COLOR="Blue"]"utf-8"[/COLOR]?>
<[B][COLOR=#006699]resources[/COLOR][/B]>
<[B][COLOR=#006699]string-array name[/COLOR][/B]=[COLOR="Blue"]"adobe_products"[/COLOR]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe After Effects</[B][COLOR=#006699]item[/COLOR][/B]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe Bridge</[B][COLOR=#006699]item[/COLOR][/B]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe Dreamweaver</[B][COLOR=#006699]item[/COLOR][/B]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe Edge</[B][COLOR=#006699]item[/COLOR][/B]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe Fireworks</[B][COLOR=#006699]item[/COLOR][/B]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe Flash</[B][COLOR=#006699]item[/COLOR][/B]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe Photoshop</[B][COLOR=#006699]item[/COLOR][/B]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe Premiere</[B][COLOR=#006699]item[/COLOR][/B]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe Reader</[B][COLOR=#006699]item[/COLOR][/B]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe Illustrator</[B][COLOR=#006699]item[/COLOR][/B]>
</[B][COLOR=#006699]string-array[/COLOR][/B]>
</[B][COLOR=#006699]resources[/COLOR][/B]>[/FONT]
In ListView each list item will be an xml layout, so we can customize each list item. Create an XML file under res/layout folder and name it as list_item.xml and type the following code. This xml layout will be single list item row.
( Right Click on res/layout ⇒ New ⇒ Android XML File)
Code:
[FONT="Courier New"]<?[B][COLOR=#006699]xml[/COLOR][/B] [COLOR="Gray"]version[/COLOR]=[COLOR="Blue"]"1.0"[/COLOR] [COLOR="Gray"]encoding[/COLOR]=[COLOR="Blue"]"utf-8"[/COLOR]?>
[COLOR=#819f07]<!-- Single List Item Design -->[/COLOR]
<[B][COLOR=#006699]TextView[/COLOR][/B] [COLOR="Gray"]xmlns:android[/COLOR]=[COLOR="Blue"]"http://schemas.android.com/apk/res/android"[/COLOR]
[COLOR="Gray"]android:id[/COLOR]=[COLOR="Blue"]"@+id/label"[/COLOR]
[COLOR="Gray"]android:layout_width[/COLOR]=[COLOR="Blue"]"fill_parent"[/COLOR]
[COLOR="Gray"]android:layout_height[/COLOR]=[COLOR="Blue"]"fill_parent"[/COLOR]
[COLOR="Gray"]android:padding[/COLOR]=[COLOR="Blue"]"10dip"[/COLOR]
[COLOR="Gray"]android:textSize[/COLOR]=[COLOR="Blue"]"16dip"[/COLOR]
[COLOR="Gray"]android:textStyle[/COLOR]=[COLOR="Blue"]"bold"[/COLOR] >
</[B][COLOR=#006699]TextView[/COLOR][/B]>[/FONT]
Now open your main activity java file (AndroidListViewActivity.java) and type the following code. In the following code I'm importing all XML resources data and storing them in an Array. On the next step I'm binding array to ListAdapter.
Code:
[FONT="Courier New"][COLOR=#819f07]AndroidListViewActivity.java[/color]
[B][COLOR=#006699]package[/COLOR][/B] com.androidhive.androidlistview;
[B][COLOR=#006699]import[/COLOR][/B] android.app.ListActivity;
[B][COLOR=#006699]import[/COLOR][/B] android.content.Intent;
[B][COLOR=#006699]import[/COLOR][/B] android.os.Bundle;
[B][COLOR=#006699]import[/COLOR][/B] android.view.View;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.AdapterView;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.AdapterView.OnItemClickListener;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.ArrayAdapter;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.ListView;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.TextView;
[B][COLOR=#006699]public class[/COLOR][/B] AndroidListViewActivity [B][COLOR=#006699]extends[/COLOR][/B] ListActivity {
[COLOR="Gray"]@Override[/COLOR]
[B][COLOR=#006699]public void[/COLOR][/B] onCreate(Bundle savedInstanceState) {
[B][COLOR=#006699]super[/COLOR][/B].onCreate(savedInstanceState);
[COLOR=#819f07]// storing string resources into Array[/COLOR]
String[] adobe_products = getResources().getStringArray(R.array.adobe_products);
[COLOR=#819f07]// Binding resources Array to ListAdapter[/COLOR]
[B][COLOR=#006699]this[/COLOR][/B].setListAdapter([B][COLOR=#006699]new[/COLOR][/B] ArrayAdapter<String>([B][COLOR=#006699]this[/COLOR][/B], R.layout.list_item, R.id.label, adobe_products));
}
}[/FONT]
Now run your project you can see listview with list of array items. But on clicking single list item you can see no action. So we need to start new activity on selecting single list item.
Launching new Activity on selecting single list item.
Now create new activity class under src folder. Right Click on src/package folder ⇒ New ⇒ Class and name it as SingleListItem. (SingleListItem.java)
Open your AndroidListViewActivity.java and modify the code to following. In the following code i am getting the selected list item string(product name) and sending it to new Activity.
Code:
[FONT="Courier New"][COLOR=#819f07]AndroidListViewActivity.java[/color]
[B][COLOR=#006699]package[/COLOR][/B] com.androidhive.androidlistview;
[B][COLOR=#006699]import[/COLOR][/B] android.app.ListActivity;
[B][COLOR=#006699]import[/COLOR][/B] android.content.Intent;
[B][COLOR=#006699]import[/COLOR][/B] android.os.Bundle;
[B][COLOR=#006699]import[/COLOR][/B] android.view.View;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.AdapterView;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.AdapterView.OnItemClickListener;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.ArrayAdapter;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.ListView;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.TextView;
[B][COLOR=#006699]public class[/COLOR][/B] AndroidListViewActivity [B][COLOR=#006699]extends[/COLOR][/B] ListActivity {
[COLOR="Gray"]@Override[/COLOR]
[B][COLOR=#006699]public void[/COLOR][/B] onCreate(Bundle savedInstanceState) {
[B][COLOR=#006699]super[/COLOR][/B].onCreate(savedInstanceState);
[COLOR=#819f07]// storing string resources into Array[/COLOR]
String[] adobe_products = getResources().getStringArray(R.array.adobe_products);
[COLOR=#819f07]// Binding resources Array to ListAdapter[/COLOR]
[B][COLOR=#006699]this[/COLOR][/B].setListAdapter([B][COLOR=#006699]new[/COLOR][/B] ArrayAdapter<String>([B][COLOR=#006699]this[/COLOR][/B], R.layout.list_item, R.id.label, adobe_products));
ListView lv = getListView();
[COLOR=#819f07]// listening to single list item on click[/COLOR]
lv.setOnItemClickListener([B][COLOR=#006699]new[/COLOR][/B] OnItemClickListener() {
[B][COLOR=#006699]public void[/COLOR][/B] onItemClick(AdapterView<?> parent, View view,
[B][COLOR=#006699]int[/COLOR][/B] position, [B][COLOR=#006699]long[/COLOR][/B] id) {
[COLOR=#819f07]// selected item [/COLOR]
String product = ((TextView) view).getText().toString();
[COLOR=#819f07]// Launching new Activity on selecting single List Item[/COLOR]
Intent i = [B][COLOR=#006699]new[/COLOR][/B] Intent(getApplicationContext(), SingleListItem.[B][COLOR=#006699]class[/COLOR][/B]);
[COLOR=#819f07]// sending data to new activity[/COLOR]
i.putExtra([COLOR="Blue"]"product"[/COLOR], product);
startActivity(i);
}
});
}
}[/FONT]
Now in new activity we need to display the received from listview activity.
Create a new xml file under res/layout and name it as single_list_item_view.xml and type the following code. This XML file will be layout for SingleListItem.java
Code:
[FONT="Courier New"][COLOR=#819f07]single_list_item_view.xml[/COLOR]
<?[B][COLOR=#006699]xml[/COLOR][/B] [COLOR="gray"]version[/COLOR]=[COLOR="Blue"]"1.0"[/COLOR] [COLOR="gray"]encoding[/COLOR]=[COLOR="Blue"]"utf-8"[/COLOR]?>
<[B][COLOR=#006699]LinearLayout[/COLOR][/B]
[COLOR="gray"]xmlns:android[/COLOR]=[COLOR="Blue"]"http://schemas.android.com/apk/res/android"[/COLOR]
[COLOR="gray"]android:orientation[/COLOR]=[COLOR="Blue"]"vertical"[/COLOR]
[COLOR="gray"]android:layout_width[/COLOR]=[COLOR="Blue"]"match_parent"[/COLOR]
[COLOR="gray"]android:layout_height[/COLOR]=[COLOR="Blue"]"match_parent"[/COLOR]>
<[B][COLOR=#006699]TextView[/COLOR][/B] [COLOR="Gray"]android:id[/COLOR]=[COLOR="Blue"]"@+id/product_label"[/COLOR]
[COLOR="gray"]android:layout_width[/COLOR]=[COLOR="Blue"]"fill_parent"[/COLOR]
[COLOR="gray"]android:layout_height[/COLOR]=[COLOR="Blue"]"wrap_content"[/COLOR]
[COLOR="gray"]android:textSize[/COLOR]=[COLOR="Blue"]"25dip"[/COLOR]
[COLOR="gray"]android:textStyle[/COLOR]=[COLOR="Blue"]"bold"[/COLOR]
[COLOR="gray"]android:padding[/COLOR]=[COLOR="Blue"]"10dip"[/COLOR]
[COLOR="gray"]android:textColor[/COLOR]=[COLOR="Blue"]"#ffffff"[/COLOR]/>
</[B][COLOR=#006699]LinearLayout[/COLOR][/B]>[/FONT]
Now open your second activity file i.e SingleListItem.java and paste the following code.
Code:
[FONT="Courier New"][COLOR=#819f07]SingleListItem.java[/COLOR]
[B][COLOR=#006699]package[/COLOR][/B] com.androidhive.androidlistview;
[B][COLOR=#006699]import[/COLOR][/B] android.app.Activity;
[B][COLOR=#006699]import[/COLOR][/B] android.content.Intent;
[B][COLOR=#006699]import[/COLOR][/B] android.os.Bundle;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.TextView;
[B][COLOR=#006699]public class[/COLOR][/B] SingleListItem extends Activity{
[COLOR="Gray"]@Override[/COLOR]
[B][COLOR=#006699]public void[/COLOR][/B] onCreate(Bundle savedInstanceState) {
[B][COLOR=#006699]super[/COLOR][/B].onCreate(savedInstanceState);
[B][COLOR=#006699]this[/COLOR][/B].setContentView(R.layout.single_list_item_view);
TextView txtProduct = (TextView) findViewById(R.id.product_label);
Intent i = getIntent();
[COLOR=#819f07]// getting attached intent data[/COLOR]
String product = i.getStringExtra([COLOR="Blue"]"product"[/COLOR]);
[COLOR=#819f07]// displaying selected product name[/COLOR]
txtProduct.setText(product);
}
}[/FONT]
The final step is to add an entry of new activity name in AndroidManifest.xml file. Open you AndroidManifest.xml file and modify the code as below:
Code:
[FONT="Courier New"][COLOR=#819f07]AndroidManifest.xml[/COLOR]
<?[B][COLOR=#006699]xml[/COLOR][/B] [COLOR="Gray"]version[/COLOR]=[COLOR="blue"]"1.0"[/COLOR] [COLOR="gray"]encoding[/COLOR]=[COLOR="Blue"]"utf-8"[/COLOR]?>
<[B][COLOR=#006699]manifest[/COLOR][/B] [COLOR="gray"]xmlns:android[/COLOR]=[COLOR="blue"]"http://schemas.android.com/apk/res/android"[/COLOR]
[COLOR="gray"]package[/COLOR]=[COLOR="blue"]"com.androidhive.androidlistview"[/COLOR]
[COLOR="gray"]android:versionCode[/COLOR]=[COLOR="blue"]"1"[/COLOR]
[COLOR="gray"]android:versionName[/COLOR]=[COLOR="blue"]"1.0"[/COLOR]>
<[B][COLOR=#006699]uses-sdk[/COLOR][/B] [COLOR="gray"]android:minSdkVersion[/COLOR]=[COLOR="blue"]"8"[/COLOR] />
<[B][COLOR=#006699]application[/COLOR][/B] [COLOR="gray"]android:icon[/COLOR]=[COLOR="blue"]"@drawable/icon"[/COLOR] [COLOR="gray"]android:label[/COLOR]=[COLOR="blue"]"@string/app_name"[/COLOR]>
<[B][COLOR=#006699]activity[/COLOR][/B] [COLOR="gray"]android:name[/COLOR]=[COLOR="blue"]".AndroidListViewActivity"[/COLOR]
[COLOR="gray"]android:label[/COLOR]=[COLOR="blue"]"Android List View"[/COLOR]>
<[B][COLOR=#006699]intent-filter[/COLOR][/B]>
<[B][COLOR=#006699]action[/COLOR][/B] [COLOR="gray"]android:name[/COLOR]=[COLOR="blue"]"android.intent.action.MAIN"[/COLOR] />
<[B][COLOR=#006699]category[/COLOR][/B] [COLOR="gray"]android:name[/COLOR]=[COLOR="blue"]"android.intent.category.LAUNCHER"[/COLOR] />
</[B][COLOR=#006699]intent-filter[/COLOR][/B]>
</[B][COLOR=#006699]activity[/COLOR][/B]>
<[B][COLOR=#006699]activity[/COLOR][/B] [COLOR="gray"]android:name[/COLOR]=[COLOR="blue"]".SingleListItem"[/COLOR]
[COLOR="gray"]android:label[/COLOR]=[COLOR="blue"]"Single Item Selected"[/COLOR]>
</[B][COLOR=#006699]activity[/COLOR][/B]>
</[B][COLOR=#006699]application[/COLOR][/B]>
</[B][COLOR=#006699]manifest[/COLOR][/B]>[/FONT]
Finally run your project by Right Clicking on your Project Folder ⇒ Run As ⇒ 1 Android Application.
Credits
Me - For the topic design.
And I must thank 4 other guys that helped me understand the Android and they're still teaching me:
ihavenick - The first one who helped me understand the Android!
Volk204 - He's the guy that helps me with codes and makes me understand what they do.
Tigrouzen - Lmao! Your kernels are great dude!
Rebellos - He motivated me and I thank him very much!
thnks
it works fine thanks
rommo_911 said:
it works fine thanks
Click to expand...
Click to collapse
Thank you, rommo_911!
I appreciate!
Roach_ said:
Informations
This tutorial will be demonstrating how to build a simple android List View.
It is about creating list view and launching new activity on selecting single list item.
Below are two screenshots of the final output:
Guide
Let’s get start by creating a project in Eclipse IDE.
Create a new project by going to File ⇒ New Android Project. Fill all the details and name your activity as AndroidListViewActivity.
Once the project is created open your main activity java file (in this case AndroidListViewActivity.java) and extend the class from ListActivity.
Code:
[FONT="Courier New"][B][COLOR=#006699]public class[/COLOR][/B] AndroidListViewActivity [B][COLOR=#006699]extends[/COLOR][/B] ListActivity {[/FONT]
Now we need a string resources file to store all list item labels. So create an XML file under values folder and name it as list_data.xml and paste the following code.
( Right Click on res/values ⇒ New ⇒ Android XML File)
Code:
[FONT="Courier New"][COLOR=#819f07]list_data.xml[/COLOR]
<?[B][COLOR=#006699]xml[/COLOR][/B] [COLOR="Gray"]version[/COLOR]=[COLOR="Blue"]"1.0"[/COLOR] [COLOR="Gray"]encoding[/COLOR]=[COLOR="Blue"]"utf-8"[/COLOR]?>
<[B][COLOR=#006699]resources[/COLOR][/B]>
<[B][COLOR=#006699]string-array name[/COLOR][/B]=[COLOR="Blue"]"adobe_products"[/COLOR]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe After Effects</[B][COLOR=#006699]item[/COLOR][/B]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe Bridge</[B][COLOR=#006699]item[/COLOR][/B]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe Dreamweaver</[B][COLOR=#006699]item[/COLOR][/B]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe Edge</[B][COLOR=#006699]item[/COLOR][/B]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe Fireworks</[B][COLOR=#006699]item[/COLOR][/B]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe Flash</[B][COLOR=#006699]item[/COLOR][/B]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe Photoshop</[B][COLOR=#006699]item[/COLOR][/B]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe Premiere</[B][COLOR=#006699]item[/COLOR][/B]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe Reader</[B][COLOR=#006699]item[/COLOR][/B]>
<[B][COLOR=#006699]item[/COLOR][/B]>Adobe Illustrator</[B][COLOR=#006699]item[/COLOR][/B]>
</[B][COLOR=#006699]string-array[/COLOR][/B]>
</[B][COLOR=#006699]resources[/COLOR][/B]>[/FONT]
In ListView each list item will be an xml layout, so we can customize each list item. Create an XML file under res/layout folder and name it as list_item.xml and type the following code. This xml layout will be single list item row.
( Right Click on res/layout ⇒ New ⇒ Android XML File)
Code:
[FONT="Courier New"]<?[B][COLOR=#006699]xml[/COLOR][/B] [COLOR="Gray"]version[/COLOR]=[COLOR="Blue"]"1.0"[/COLOR] [COLOR="Gray"]encoding[/COLOR]=[COLOR="Blue"]"utf-8"[/COLOR]?>
[COLOR=#819f07]<!-- Single List Item Design -->[/COLOR]
<[B][COLOR=#006699]TextView[/COLOR][/B] [COLOR="Gray"]xmlns:android[/COLOR]=[COLOR="Blue"]"http://schemas.android.com/apk/res/android"[/COLOR]
[COLOR="Gray"]android:id[/COLOR]=[COLOR="Blue"]"@+id/label"[/COLOR]
[COLOR="Gray"]android:layout_width[/COLOR]=[COLOR="Blue"]"fill_parent"[/COLOR]
[COLOR="Gray"]android:layout_height[/COLOR]=[COLOR="Blue"]"fill_parent"[/COLOR]
[COLOR="Gray"]android:padding[/COLOR]=[COLOR="Blue"]"10dip"[/COLOR]
[COLOR="Gray"]android:textSize[/COLOR]=[COLOR="Blue"]"16dip"[/COLOR]
[COLOR="Gray"]android:textStyle[/COLOR]=[COLOR="Blue"]"bold"[/COLOR] >
</[B][COLOR=#006699]TextView[/COLOR][/B]>[/FONT]
Now open your main activity java file (AndroidListViewActivity.java) and type the following code. In the following code I'm importing all XML resources data and storing them in an Array. On the next step I'm binding array to ListAdapter.
Code:
[FONT="Courier New"][COLOR=#819f07]AndroidListViewActivity.java[/color]
[B][COLOR=#006699]package[/COLOR][/B] com.androidhive.androidlistview;
[B][COLOR=#006699]import[/COLOR][/B] android.app.ListActivity;
[B][COLOR=#006699]import[/COLOR][/B] android.content.Intent;
[B][COLOR=#006699]import[/COLOR][/B] android.os.Bundle;
[B][COLOR=#006699]import[/COLOR][/B] android.view.View;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.AdapterView;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.AdapterView.OnItemClickListener;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.ArrayAdapter;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.ListView;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.TextView;
[B][COLOR=#006699]public class[/COLOR][/B] AndroidListViewActivity [B][COLOR=#006699]extends[/COLOR][/B] ListActivity {
[COLOR="Gray"]@Override[/COLOR]
[B][COLOR=#006699]public void[/COLOR][/B] onCreate(Bundle savedInstanceState) {
[B][COLOR=#006699]super[/COLOR][/B].onCreate(savedInstanceState);
[COLOR=#819f07]// storing string resources into Array[/COLOR]
String[] adobe_products = getResources().getStringArray(R.array.adobe_products);
[COLOR=#819f07]// Binding resources Array to ListAdapter[/COLOR]
[B][COLOR=#006699]this[/COLOR][/B].setListAdapter([B][COLOR=#006699]new[/COLOR][/B] ArrayAdapter<String>([B][COLOR=#006699]this[/COLOR][/B], R.layout.list_item, R.id.label, adobe_products));
}
}[/FONT]
Now run your project you can see listview with list of array items. But on clicking single list item you can see no action. So we need to start new activity on selecting single list item.
Launching new Activity on selecting single list item.
Now create new activity class under src folder. Right Click on src/package folder ⇒ New ⇒ Class and name it as SingleListItem. (SingleListItem.java)
Open your AndroidListViewActivity.java and modify the code to following. In the following code i am getting the selected list item string(product name) and sending it to new Activity.
Code:
[FONT="Courier New"][COLOR=#819f07]AndroidListViewActivity.java[/color]
[B][COLOR=#006699]package[/COLOR][/B] com.androidhive.androidlistview;
[B][COLOR=#006699]import[/COLOR][/B] android.app.ListActivity;
[B][COLOR=#006699]import[/COLOR][/B] android.content.Intent;
[B][COLOR=#006699]import[/COLOR][/B] android.os.Bundle;
[B][COLOR=#006699]import[/COLOR][/B] android.view.View;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.AdapterView;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.AdapterView.OnItemClickListener;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.ArrayAdapter;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.ListView;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.TextView;
[B][COLOR=#006699]public class[/COLOR][/B] AndroidListViewActivity [B][COLOR=#006699]extends[/COLOR][/B] ListActivity {
[COLOR="Gray"]@Override[/COLOR]
[B][COLOR=#006699]public void[/COLOR][/B] onCreate(Bundle savedInstanceState) {
[B][COLOR=#006699]super[/COLOR][/B].onCreate(savedInstanceState);
[COLOR=#819f07]// storing string resources into Array[/COLOR]
String[] adobe_products = getResources().getStringArray(R.array.adobe_products);
[COLOR=#819f07]// Binding resources Array to ListAdapter[/COLOR]
[B][COLOR=#006699]this[/COLOR][/B].setListAdapter([B][COLOR=#006699]new[/COLOR][/B] ArrayAdapter<String>([B][COLOR=#006699]this[/COLOR][/B], R.layout.list_item, R.id.label, adobe_products));
ListView lv = getListView();
[COLOR=#819f07]// listening to single list item on click[/COLOR]
lv.setOnItemClickListener([B][COLOR=#006699]new[/COLOR][/B] OnItemClickListener() {
[B][COLOR=#006699]public void[/COLOR][/B] onItemClick(AdapterView<?> parent, View view,
[B][COLOR=#006699]int[/COLOR][/B] position, [B][COLOR=#006699]long[/COLOR][/B] id) {
[COLOR=#819f07]// selected item [/COLOR]
String product = ((TextView) view).getText().toString();
[COLOR=#819f07]// Launching new Activity on selecting single List Item[/COLOR]
Intent i = [B][COLOR=#006699]new[/COLOR][/B] Intent(getApplicationContext(), SingleListItem.[B][COLOR=#006699]class[/COLOR][/B]);
[COLOR=#819f07]// sending data to new activity[/COLOR]
i.putExtra([COLOR="Blue"]"product"[/COLOR], product);
startActivity(i);
}
});
}
}[/FONT]
Now in new activity we need to display the received from listview activity.
Create a new xml file under res/layout and name it as single_list_item_view.xml and type the following code. This XML file will be layout for SingleListItem.java
Code:
[FONT="Courier New"][COLOR=#819f07]single_list_item_view.xml[/COLOR]
<?[B][COLOR=#006699]xml[/COLOR][/B] [COLOR="gray"]version[/COLOR]=[COLOR="Blue"]"1.0"[/COLOR] [COLOR="gray"]encoding[/COLOR]=[COLOR="Blue"]"utf-8"[/COLOR]?>
<[B][COLOR=#006699]LinearLayout[/COLOR][/B]
[COLOR="gray"]xmlns:android[/COLOR]=[COLOR="Blue"]"http://schemas.android.com/apk/res/android"[/COLOR]
[COLOR="gray"]android:orientation[/COLOR]=[COLOR="Blue"]"vertical"[/COLOR]
[COLOR="gray"]android:layout_width[/COLOR]=[COLOR="Blue"]"match_parent"[/COLOR]
[COLOR="gray"]android:layout_height[/COLOR]=[COLOR="Blue"]"match_parent"[/COLOR]>
<[B][COLOR=#006699]TextView[/COLOR][/B] [COLOR="Gray"]android:id[/COLOR]=[COLOR="Blue"]"@+id/product_label"[/COLOR]
[COLOR="gray"]android:layout_width[/COLOR]=[COLOR="Blue"]"fill_parent"[/COLOR]
[COLOR="gray"]android:layout_height[/COLOR]=[COLOR="Blue"]"wrap_content"[/COLOR]
[COLOR="gray"]android:textSize[/COLOR]=[COLOR="Blue"]"25dip"[/COLOR]
[COLOR="gray"]android:textStyle[/COLOR]=[COLOR="Blue"]"bold"[/COLOR]
[COLOR="gray"]android:padding[/COLOR]=[COLOR="Blue"]"10dip"[/COLOR]
[COLOR="gray"]android:textColor[/COLOR]=[COLOR="Blue"]"#ffffff"[/COLOR]/>
</[B][COLOR=#006699]LinearLayout[/COLOR][/B]>[/FONT]
Now open your second activity file i.e SingleListItem.java and paste the following code.
Code:
[FONT="Courier New"][COLOR=#819f07]SingleListItem.java[/COLOR]
[B][COLOR=#006699]package[/COLOR][/B] com.androidhive.androidlistview;
[B][COLOR=#006699]import[/COLOR][/B] android.app.Activity;
[B][COLOR=#006699]import[/COLOR][/B] android.content.Intent;
[B][COLOR=#006699]import[/COLOR][/B] android.os.Bundle;
[B][COLOR=#006699]import[/COLOR][/B] android.widget.TextView;
[B][COLOR=#006699]public class[/COLOR][/B] SingleListItem extends Activity{
[COLOR="Gray"]@Override[/COLOR]
[B][COLOR=#006699]public void[/COLOR][/B] onCreate(Bundle savedInstanceState) {
[B][COLOR=#006699]super[/COLOR][/B].onCreate(savedInstanceState);
[B][COLOR=#006699]this[/COLOR][/B].setContentView(R.layout.single_list_item_view);
TextView txtProduct = (TextView) findViewById(R.id.product_label);
Intent i = getIntent();
[COLOR=#819f07]// getting attached intent data[/COLOR]
String product = i.getStringExtra([COLOR="Blue"]"product"[/COLOR]);
[COLOR=#819f07]// displaying selected product name[/COLOR]
txtProduct.setText(product);
}
}[/FONT]
The final step is to add an entry of new activity name in AndroidManifest.xml file. Open you AndroidManifest.xml file and modify the code as below:
Code:
[FONT="Courier New"][COLOR=#819f07]AndroidManifest.xml[/COLOR]
<?[B][COLOR=#006699]xml[/COLOR][/B] [COLOR="Gray"]version[/COLOR]=[COLOR="blue"]"1.0"[/COLOR] [COLOR="gray"]encoding[/COLOR]=[COLOR="Blue"]"utf-8"[/COLOR]?>
<[B][COLOR=#006699]manifest[/COLOR][/B] [COLOR="gray"]xmlns:android[/COLOR]=[COLOR="blue"]"http://schemas.android.com/apk/res/android"[/COLOR]
[COLOR="gray"]package[/COLOR]=[COLOR="blue"]"com.androidhive.androidlistview"[/COLOR]
[COLOR="gray"]android:versionCode[/COLOR]=[COLOR="blue"]"1"[/COLOR]
[COLOR="gray"]android:versionName[/COLOR]=[COLOR="blue"]"1.0"[/COLOR]>
<[B][COLOR=#006699]uses-sdk[/COLOR][/B] [COLOR="gray"]android:minSdkVersion[/COLOR]=[COLOR="blue"]"8"[/COLOR] />
<[B][COLOR=#006699]application[/COLOR][/B] [COLOR="gray"]android:icon[/COLOR]=[COLOR="blue"]"@drawable/icon"[/COLOR] [COLOR="gray"]android:label[/COLOR]=[COLOR="blue"]"@string/app_name"[/COLOR]>
<[B][COLOR=#006699]activity[/COLOR][/B] [COLOR="gray"]android:name[/COLOR]=[COLOR="blue"]".AndroidListViewActivity"[/COLOR]
[COLOR="gray"]android:label[/COLOR]=[COLOR="blue"]"Android List View"[/COLOR]>
<[B][COLOR=#006699]intent-filter[/COLOR][/B]>
<[B][COLOR=#006699]action[/COLOR][/B] [COLOR="gray"]android:name[/COLOR]=[COLOR="blue"]"android.intent.action.MAIN"[/COLOR] />
<[B][COLOR=#006699]category[/COLOR][/B] [COLOR="gray"]android:name[/COLOR]=[COLOR="blue"]"android.intent.category.LAUNCHER"[/COLOR] />
</[B][COLOR=#006699]intent-filter[/COLOR][/B]>
</[B][COLOR=#006699]activity[/COLOR][/B]>
<[B][COLOR=#006699]activity[/COLOR][/B] [COLOR="gray"]android:name[/COLOR]=[COLOR="blue"]".SingleListItem"[/COLOR]
[COLOR="gray"]android:label[/COLOR]=[COLOR="blue"]"Single Item Selected"[/COLOR]>
</[B][COLOR=#006699]activity[/COLOR][/B]>
</[B][COLOR=#006699]application[/COLOR][/B]>
</[B][COLOR=#006699]manifest[/COLOR][/B]>[/FONT]
Finally run your project by Right Clicking on your Project Folder ⇒ Run As ⇒ 1 Android Application.
Credits
Me - For the topic design.
And I must thank 4 other guys that helped me understand the Android and they're still teaching me:
ihavenick - The first one who helped me understand the Android!
Volk204 - He's the guy that helps me with codes and makes me understand what they do.
Tigrouzen - Lmao! Your kernels are great dude!
Rebellos - He motivated me and I thank him very much!
Click to expand...
Click to collapse
hey man could you help-me how can I add this feature (listview) in my own source build ???
I know a lot off nexus 4 roms have this implemented but I like to add this in my source, and I'm a little noob in editing the android source code =/
thank's a lot BTW
Can you show a tutorial on how to use Listview in Navigation drawer (material design) ?

[Q] Language Coordinates for Custom ROM

I am translating a ROM to Tamil language. I am a bit lost on what coordinate values should come under donottranslate-maps.xml.
The path is --> core/res/res/values-ta-rIN/donottranslate-maps.xml
Currently I have used the values for Hindi language. Will it be the same for Tamil too?
<resources>
<!-- Stub for Tamil -->
<integer-array name="maps_starting_lat_lng">
<item>20593684</item>
<item>78962880</item>
</integer-array>
<integer-array name="maps_starting_zoom">
<item>3</item>
</integer-array>
</resources>

[Request] Ask help for recompiling LegacyIncallUI.apk (Lollipop)

Hello all dear,
I have problem recompling LegacyIncallUI.apk (ver.: Note3 Lollipop NL8) with apktool 2.0.0 (RC3/RC4)
Here is the error log:
----------------------------------------------------------------------------------------------------------------
E:\AdvancedApkTool\3-Out\LegacyInCallUI.nl8.apk\res\values\arrays.xml:63: error: Error: No resource found that matches the given name (at '^index_0' with value '@android:string/APKTOOL_DUMMY_06c2').
Exception in thread "main" brut.androlib.AndrolibException: brut.androlib.AndrolibException: brut.common.BrutException: could not exec command: [C:\Users\Philippe\AppData\Local\Temp\brut_util_Jar_5740710932211160419.tmp, p, --forced-package-id, 127, --min-sdk-version, 21, --target-sdk-version, 21, --version-code, 21, --version-name, 5.0-N9005XXUGBNL8, -F, C:\Users\Philippe\AppData\Local\Temp\APKTOOL7206926664454227497.tmp, -0, arsc, -I, E:\AdvancedApkTool\1-BDFreak\Frameworks\1.apk, -S, E:\AdvancedApkTool\3-Out\LegacyInCallUI.nl8.apk\res, -M, E:\AdvancedApkTool\3-Out\LegacyInCallUI.nl8.apk\AndroidManifest.xml]
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:442)
at brut.androlib.Androlib.buildResources(Androlib.java:379)
at brut.androlib.Androlib.build(Androlib.java:282)
at brut.androlib.Androlib.build(Androlib.java:255)
at brut.apktool.Main.cmdBuild(Main.java:225)
at brut.apktool.Main.main(Main.java:84)
Caused by: brut.androlib.AndrolibException: brut.common.BrutException: could not exec command: [C:\Users\Philippe\AppData\Local\Temp\brut_util_Jar_5740710932211160419.tmp, p, --forced-package-id, 127, --min-sdk-version, 21, --target-sdk-version, 21, --version-code, 21, --version-name, 5.0-N9005XXUGBNL8, -F, C:\Users\Philippe\AppData\Local\Temp\APKTOOL7206926664454227497.tmp, -0, arsc, -I, E:\AdvancedApkTool\1-BDFreak\Frameworks\1.apk, -S, E:\AdvancedApkTool\3-Out\LegacyInCallUI.nl8.apk\res, -M, E:\AdvancedApkTool\3-Out\LegacyInCallUI.nl8.apk\AndroidManifest.xml]
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:504)
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:428)
... 5 more
Caused by: brut.common.BrutException: could not exec command: [C:\Users\Philippe\AppData\Local\Temp\brut_util_Jar_5740710932211160419.tmp, p, --forced-package-id, 127, --min-sdk-version, 21, --target-sdk-version, 21, --version-code, 21, --version-name, 5.0-N9005XXUGBNL8, -F, C:\Users\Philippe\AppData\Local\Temp\APKTOOL7206926664454227497.tmp, -0, arsc, -I, E:\AdvancedApkTool\1-BDFreak\Frameworks\1.apk, -S, E:\AdvancedApkTool\3-Out\LegacyInCallUI.nl8.apk\res, -M, E:\AdvancedApkTool\3-Out\LegacyInCallUI.nl8.apk\AndroidManifest.xml]
at brut.util.OS.exec(OS.java:90)
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:498)
... 6 more
------------------------------------------------------
These errors happend even when I recompile the original apk without any mod.
Please tell me what apktool should I use, or how can I recompile LegacyIncallUI.apk (Lollipop Note3).
Thanks in advance.
dongfangri said:
Hello all dear,
I have problem recompling LegacyIncallUI.apk (ver.: Note3 Lollipop NL8) with apktool 2.0.0 (RC3/RC4)
These errors happend even when I recompile the original apk without any mod.
Please tell me what apktool should I use, or how can I recompile LegacyIncallUI.apk (Lollipop Note3).
Thanks in advance.
Click to expand...
Click to collapse
I think you need (Advanced+ApkTool+v4.1.0+By+BDFreak+Repackecd+By+Kmokhtar79.zip - ZIP archive, unpacked size 11,518,919 bytes)
Thanks.
Finally I got it by changing framework-res.apk.
dongfangri said:
Thanks.
Finally I got it by changing framework-res.apk.
Click to expand...
Click to collapse
Did you get settings for auto call recording too?
Thanks
zoya4u said:
Did you get settings for auto call recording too?
Thanks
Click to expand...
Click to collapse
No. I don't use this feature.
dongfangri said:
No. I don't use this feature.
Click to expand...
Click to collapse
can u make it multi DPI?

Categories

Resources