What is cliprect? - Android Q&A, Help & Troubleshooting

When I was looking into the Android 9.0 Pixel 2 factory image (9.0.0 (PPR2.180905.005, Sep 2018)) I found this thing in decompiled framework-res.apk/res/anim/activity_open_enter.xml,
Code:
<?xml version="1.0" encoding="utf-8"?>
<set android:shareInterpolator="false"
xmlns:android="http://schemas.android.com/apk/res/android">
<translate android:interpolator="@interpolator/fast_out_slow_in" android:duration="425" android:fromYDelta="4.100001%" android:toYDelta="0.0" />
<cliprect android:interpolator="@interpolator/fast_out_extra_slow_in" android:duration="425" android:fromBottom="100.0%" android:fromLeft="0.0%" android:fromRight="100.0%" android:fromTop="95.9%" android:toBottom="100.0%" android:toLeft="0.0%" android:toRight="100.0%" android:toTop="0.0%" />
</set>
In line5 you can see there is this "Cliprect" thing which I never know existed before, can someone tell me what is that?

Related

Animation codes

1) Fly in straight line
----fly along X----
<?xml version="1.0" encoding="utf-8"?><set android:shareInterpolator="false" android:zAdjustment="top" xmlns:android="http://schemas.android.com/apk/res/android"> <translate android:duration="@integer/config_longAnimTime" android:fromXDelta="100.0%p" android:toXDelta="0.0" /></set>
----fly along y---
<?xml version="1.0" encoding="utf-8"?><set android:shareInterpolator="false" android:zAdjustment="top" xmlns:android="http://schemas.android.com/apk/res/android"> <translate android:duration="@integer/config_longAnimTime" android:fromYDelta="100.0%p" android:toYDelta="0.0" /></set>
---fly along X-Y-----
<?xml version="1.0" encoding="utf-8"?><set android:shareInterpolator="false" android:zAdjustment="top" xmlns:android="http://schemas.android.com/apk/res/android"> <translate android:duration="@integer/config_longAnimTime" android:fromYDelta="100.0%p" android:toYDelta="0.0" android:fromXDelta="100.0%p" android:toXDelta="0.0" /></set>
^^^^^^^^^CHANGE VALUES ACCORDINGLY TO ALTER DIRECTIONS^^^^^^^^^
---requirements------ basic knowledge of co-ordinate geometry----in translate animation,,,,, the center of mass of screen (if seen as a rectangle) is the ORIGIN (0,0)-=----------------------and 100%p means 100% (along X or Y , down or right if positive and up or left if negative) relative to paren]]]]]
2) Popup from CENTER
<?xml version="1.0" encoding="utf-8"?><set android:interpolator="@anim/decelerate_interpolator" xmlns:android="http://schemas.android.com/apk/res/android">
<scale android:duration="500 android:fromXScale="0.0" android:toXScale="1.0" android:fromYScale="0.0" android:toYScale="1.0" />
</set>
3) Popup from top-left (relative to you,, not screen)
<?xml version="1.0" encoding="utf-8"?><set android:interpolator="@anim/decelerate_interpolator" xmlns:android="http://schemas.android.com/apk/res/android">
<scale android:duration="500 androidivotX="100%p" android:fromXScale="0.0" android:toXScale="1.0" android:fromYScale="0.0" android:toYScale="1.0" />
</set>
4) Fade in
<?xml version="1.0" encoding="utf-8"?><set android:interpolator="@anim/decelerate_interpolator" xmlns:android="http://schemas.android.com/apk/res/android"> <alpha android:duration="@integer/config_mediumAnimTime" android:fromAlpha="0.0" android:toAlpha="1.0" /></set>
-------combine all these intelligently to create several combos------------------------
change values accordingly to create OUT animations
------------------------------------------------------------------PRESS THANKS IF YOU LIKE MY WORK :good: ---------------------------------------------------------------------
Can I apply this for lockscreen...
Regards,
Ganesh
Ganesh A said:
Can I apply this for lockscreen...
Regards,
Ganesh
Click to expand...
Click to collapse
yes you can... just edit lockscreen exit xml in framework-res/anim/
Great one ..... Helped meh alot !! (Y)
@aman d awsum--- COOL :good:
re animation
nice guide
i will try
where are the activity_open_enter, open_exit and activity_close_enter, close_exit used for? i mean, how do these work? if an app is opened, does activity_open_enter get used, and if an app is closed activity_close_exit is used?
How to do this with stock rom
mjz2cool said:
where are the activity_open_enter, open_exit and activity_close_enter, close_exit used for? i mean, how do these work? if an app is opened, does activity_open_enter get used, and if an app is closed activity_close_exit is used?
Click to expand...
Click to collapse
bro,,, see the anims that begin with the word wallpaper,,,, those are the one that show the way wallpaper and app opening closing etc!!! just search for them in styles.xml and you will know

[Q] How to hide menu items?

Hiya all
I've got this piece of code from an xml in my settings.apk (SecSettings actually) that contains tutorials on motion settings.
Code:
<?xml version="1.0" encoding="utf-8"?>
<PreferenceScreen android:title="@string/motion_tutorial_settings_title" android:key="parent"
xmlns:android="http://schemas.android.com/apk/res/android">
<Preference android:title="@string/turn_over_title" android:key="turn_over" android:summary="@string/turn_over_summary" />
<Preference android:title="@string/shake_title" android:key="shake" android:summary="@string/shake_summary" />
<Preference android:title="@string/pick_up_to_call_out_title" android:key="pick_up_to_call_out" android:summary="@string/pick_up_to_call_out_summary" />
[Color=red] <Preference android:title="@string/air_glance_view" android:key="glance_view" android:summary="@string/air_glance_view_descption" />
<Preference android:title="@string/pick_up_title" android:key="pick_up" android:summary="@string/pick_up_summary" />
<Preference android:title="@string/double_tap_title" android:key="double_tap" android:summary="@string/double_tap_summary" />
<Preference android:title="@string/tilt_title" android:key="tilt" android:summary="@string/tilt_summary" />
<Preference android:title="@string/tilt_to_scroll_list_title" android:key="tilt_to_scroll_list" android:summary="@string/tilt_to_scroll_list_summary" />
<Preference android:title="@string/pan_title" android:key="pan" android:summary="@string/pan_summary" />
<Preference android:title="@string/pan_to_browse_image_title" android:key="pan_to_browse_image" android:summary="@string/pan_to_browse_image_summary" />
<Preference android:title="@string/palm_swipe_title" android:key="palm_swipe" android:summary="@string/palm_swipe_summary" />
<Preference android:title="@string/palm_touch_title" android:key="palm_touch" android:summary="@string/palm_touch_summary" />
<Preference android:title="@string/tap_and_twist_title" android:key="tap_and_twist" android:summary="@string/tap_and_twist_summary" />[/color]
</PreferenceScreen>
In there, all the red parts contain tutorials on settings that don't actually work on my device, and for OCD sake, I don't want them appearing in my settings because of it.
But simply cutting them out of that file will make the settings app crash whenever i open that menu :crying:
So question is: is there a way to hide these settings without impairing their functions?
XML style ofcourse, as I don't dare touch smali
bump! I am still struggling with this :crying:
Is there really no simple xml line for this?
If not, is it possible to resize the not-working menu's to zero pixels? (thus making them invisible)
for the record, adding android:visibility="gone" / androi:visibility="invisible" and android:layout_height="0.0dip" all do nothing
you need to remove also the line inside a smali sir. removing the line will just force the app to close . i also want to remove a category sir, but im not good at smali so i just remove the strings and leave it blank xD
sorry for my english xD

[Q] Help please to create a submenu with apps in settings

Hello. im trying to create a menu for my apps ( xposed etc.. ) bloatware apps .
I started with the bloatware apps.
I was able to link them in settings + I found the list of setting will be long so I decide to create a submenu of categories.
here is the pic attached when I click on fido_menu it force close...
and here is what I did :
I in settings_headers:
<header android:title="@string/header_category_geo" />
<header android:icon="@drawable/ic_fidomenu" android:id="@id/fido_menu" android:title="fido menu" android:fragment="xml.Fido_Menu.xml" /> im not sure about the fragment what do u think?
and the Fido_Menu.xml that I created
<?xml version="1.0" encoding="utf-8"?>
<PreferenceScreen android:title="@string/fido_tab"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:settings="http://schemas.android.com/apk/res/com.android.settings."> do I have to create a samli file?
<Preference android:icon="@drawable/ic_fido" android:title="@string/fido_myaccount">
<intent android:targetPackage="com.fidosolutions.myaccount" android:action="android.intent.action.MAIN" android:targetClass="com.fidosolutions.myaccount.MyAccount" />
</Preference>
<Preference android:icon="@drawable/ic_vfido" android:title="@string/fido_VVM">
<intent android:targetPackage="com.fido.vvm" android:action="android.intent.action.MAIN" android:targetClass="com.communology.vvm.ui.MessagesListActivity" />
</Preference>
<Preference android:icon="@drawable/ic_afido" android:title="@string/fido_anti_theft">
<intent android:targetPackage="com.fido.rogers.security" android:action="android.intent.action.MAIN" android:targetClass="net.juniper.junos.pulse.android.ui.LaunchActivity" />
</Preference>
</PreferenceScreen>
Looking for help also how to create a smali file if need it
Thanks for your help
P.S: if u r not willing to help but just to fake that u r helping (( MEAN not giving the details )) so thanks in advance and don't help me...

Delete This

I want to delete this thread
Reserved
Reserved
Hi, I was wondering if you could help? I'm looking to invert the colours on my settings menu (see screenshot) from a white background with black script to a black background with white script.
Thing is, I really don't know what does what in the background holo dark/holo light xml files. Does one xml file control the background colour and the other the script colour? Here's what each xml file reads - can you advise what I should change to end up with a black background and white script?
background_holo_light.xml
<?xml version="1.0" encoding="utf-8"?>
<shape
xmlns:android="http://schemas.android.com/apk/res/android">
<gradient android:startColor="#ffe8e8e8" android:endColor="#ffffffff" android:angle="270.0" />
</shape>
background_holo_dark.xml
<?xml version="1.0" encoding="utf-8"?>
<shape
xmlns:android="http://schemas.android.com/apk/res/android">
<gradient android:startColor="#ff000000" android:endColor="#ff272d33" android:angle="270.0" />
</shape>
Would really appreciate any help you can give.

Difference between the cts v2 default plan and everything plan

Hi guys,
I'm a bit confused about the CTS v2 plans.
If I run "run cts" from the cts tradefed console how is it different from saying "run everything" ?
Also I notice that the default cts plan
Code:
<?xml version="1.0" encoding="utf-8"?>
<configuration description="Runs CTS from a pre-existing CTS installation">
<include name="cts-common" />
<include name="cts-exclude" />
<include name="cts-exclude-instant" />
<option name="plan" value="cts" />
</configuration>
include a config called "cts-exclude"
which looks like this
Code:
<?xml version="1.0" encoding="utf-8"?>
<configuration description="Excluded tests from main CTS runs">
<!-- b/64127136 -->
<option name="compatibility:exclude-filter" value="CtsSecurityHostTestCases android.security.cts.SELinuxHostTest#testNoExemptionsForBinderInVendorBan" />
<option name="compatibility:exclude-filter" value="CtsSecurityHostTestCases android.security.cts.SELinuxHostTest#testNoExemptionsForSocketsBetweenCoreAndVendorBan" />
<option name="compatibility:exclude-filter" value="CtsSecurityHostTestCases android.security.cts.SELinuxHostTest#testNoExemptionsForVendorExecutingCore" />
<!-- Test Harness Mode tests are not a part of CTS. They are a part
of their own testing plan, as they reset the device during the
test. It's possible and ideal in the future to incorporate the
tests into CTS, but until then, they should be excluded. -->
<option name="compatibility:exclude-filter" value="CtsTestHarnessModeTestCases" />
</configuration>
Which seems to exclude some tests from a module called CtsSecurityHostTestCases.
Why does the default plan do this?
If i were to run CTS to certify some Android Mods should I run the default plan or the everything plan?.
Apologies if my question is a bit cryptic, it's my first post on here and I will make any modifications you ask to make my question better

Categories

Resources