[MOD]iphone style screencapture.apk
disassemble screencapture.apk with apktool
edit /screencapture/AndroidManifest.xml
line 11 change android:theme
Code:
android:theme="@android:style/Theme.NoTitleBar.Fullscreen"
edit /res/layout/preview.xml
Code:
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout android:layout_width="fill_parent" android:layout_height="fill_parent"
xmlns:android="http://schemas.android.com/apk/res/android">
<RelativeLayout android:id="@id/top" android:background="#ff000000" android:visibility="invisible" android:layout_width="fill_parent" android:layout_height="fill_parent">
<ImageView android:id="@id/screenshot" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_marginTop="6.0dip" android:layout_marginBottom="6.0dip" android:layout_above="@id/button_row" android:layout_alignParentTop="true" />
<Button android:state_enabled="false" android:id="@id/share_button" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_marginLeft="4.0dip" android:layout_marginTop="2.0dip" android:layout_marginRight="2.0dip" android:text="@string/screenshot_button_share" android:layout_weight="50.0" android:visibility="invisible" />
<Button android:state_enabled="false" android:id="@id/use_as_button" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_marginLeft="3.0dip" android:layout_marginTop="2.0dip" android:layout_marginRight="3.0dip" android:text="@string/screenshot_button_use_as" android:layout_weight="50.0" android:visibility="invisible" />
</RelativeLayout>
<LinearLayout android:id="@id/shutter" android:background="#ffffffff" android:visibility="invisible" android:layout_width="fill_parent" android:layout_height="fill_parent">
<View android:id="@id/fullscreen" android:background="#ffffffff" android:visibility="invisible" android:layout_width="fill_parent" android:layout_height="fill_parent" />
</LinearLayout>
</RelativeLayout>
edit /smali/com/sonyericsson/screencapture/DisplayScreenshot.smali
find ".line 371" and insert the following code to make it exit after shutter animation
Code:
invoke-virtual {p0}, Lcom/sonyericsson/screencapture/DisplayScreenshot;->finish()V
build with apktool and sign with auto-sign tool
remove or hide stock screencapture.apk in /system/app
then install the modified apk, enjoy!
A question:
Is there a way to install modified apk as a update? like stock maps
in that way no need to remove stock apk and only upgrade apk works.
Sorry, I did not test it fully. It does not work after restart.
|