Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Overlays Tab #1508

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from
Draft

Overlays Tab #1508

wants to merge 2 commits into from

Conversation

Tharow
Copy link
Contributor

@Tharow Tharow commented Jan 31, 2025

Add Basic Support for an Overlays tab that shows available/enabled/disabled overlays that can effect the current app in should hide tab in older devices as Overlays are newer then the min api AM supports

There be many issues at the moment any help would be appreciated.
At the current moment I can't seem to get the AppDetailsOverlayFragment to load the data required to show the items in the tab tho i may be missing something.

Further work on PackageInstaller replacement is on going, but slow. I need a much better understanding on how the rest of AM works before that project can be completed as it needs to integrate into systems to which i do not even know of. nor can seem to find.

How does with AM, load a SystemService Interface for use as it will be the best way to interact with overlays

Signed-off-by: Theray Tharow <[email protected]>
@Tharow
Copy link
Contributor Author

Tharow commented Feb 1, 2025

@MuntashirAkon I can't seem to get the AppDetailsOverlayFragment to find the overlayInfos that i loaded into the veiwModel. Any suggestions?,
also while your here Does AM have any custom facility for loading system service Interfaces. just tell me the class name of an example I'll clone the design / implement for IOverlayManager.

@MuntashirAkon
Copy link
Owner

I can't seem to get the AppDetailsOverlayFragment to find the overlayInfos that i loaded into the veiwModel. Any suggestions?

I need to take a look at your code which I cannot right now as I'm quite busy with work.

Does AM have any custom facility for loading system service Interfaces. just tell me the class name of an example I'll clone the design / implement for IOverlayManager.

You can add IOverlayManager interface in the hiddenapi library (watch out for any API changes for each Android release), and then load it through ProxyBinder#getService(). You can find plenty of examples in the *Compat classes.

for (OverlayInfo o : overlays) {
overlayItems.add(new AppDetailsOverlayItem(o));
}
mOverlays.postValue(overlayItems);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's possibly throwing an error before reaching here. You can try catching exceptions here for testing.

@Tharow
Copy link
Contributor Author

Tharow commented Feb 4, 2025

Still need to fix a few things but it's working now.
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants