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

[Feature Request][P] On/Off Icons for Stay Awake QS Tile #1992

Closed
creeve4 opened this issue Jun 9, 2019 · 6 comments

Comments

Projects
None yet
2 participants
@creeve4
Copy link

commented Jun 9, 2019

It would be nice to have different icons for On and Off states.
On = NEVER_SLEEP
Off = any other timeout

@C3C0

This comment has been minimized.

Copy link

commented Jun 10, 2019

I agree. The thing is I am not that good at graphics and I always struggle when I need to create something. Especially when it's in a vector format. Here is the current icon: https://github.com/GravityBox/GravityBox/blob/pie/GravityBox/src/main/res/drawable/ic_qs_stayawake_on.xml
So if you have some skills you can let your creativity go :) Otherwise I will have to fight with Inscape once again.

@creeve4

This comment has been minimized.

Copy link
Author

commented Jun 11, 2019

I'll take a crack at it. I might as well learn how to create and edit vector drawables.

Where in your code are you indicating the state of the QS tile (active or inactive)?

I was thinking that all states which have a time (15s, 30s, 1min, etc) the tile is inactive (color is gray) and only the stay awake state is active.

@C3C0

This comment has been minimized.

Copy link

commented Jun 11, 2019

For this suggested functionality it is not necessary to provide additional images. On/off state of tile can be controlled in handleUpdateState method of each tile. If mState.booleanValue is set to true (which is default) system renders icon as active. When false it renders it inactive. It uses the same white image which gets tinted accordingly.

@C3C0

This comment has been minimized.

Copy link

commented Jun 12, 2019

What about something like this. The icon would be for NEVER_SLEEP mode. Strike over the timer would mean screen off timer is not in effect.
image

@C3C0

This comment has been minimized.

Copy link

commented Jun 12, 2019

And here is how it would look like.
qs_stay_awake

@creeve4

This comment has been minimized.

Copy link
Author

commented Jun 12, 2019

@C3C0 C3C0 closed this in c3ed7bd Jun 13, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.