-
-
Notifications
You must be signed in to change notification settings - Fork 89
Added widget with just a sync icon #1340
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
Conversation
Not really a thing that needs to be done quickly, but at least it's something, and since those files are pretty much never modified, we can just leave this ready until we want to merge it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks nice, but wow that is a lot of new code. I can't help but think it would be less if we had only one widget.
Is it hard to make it one widget only, which resizes and then simply hides and shows the text depending on the widget size? Without the text they are exactly the same, no?
Also, does it need to be a circle? When adding the widget I can see the widget as a square, with/without rounded borders (depending on the widget settings) for a very short time before it goes back to circle again. I could think of users who want it to behave like the other widgets do. That is to have a full background color for the widget which is cropped by the widget setting and not enforce the rounded corners (circle shape) ourselves.
I took the screenshot at the right moment, but it turns back into a circle right after:
No, it should be easy, but I think @devvv4ever told me to have two different widgets, in case anyone wants a small widget with text |
Not technically, but I guess we can choose |
You can add the same widget twice and resize one of the instances to be smaller. They will look differently, but have the same action. So in the end it'll have the same effect as creating two different ones. I think a second widget only makes sense if we want to add other functionality or show data, etc. |
If you can manage to make the widget "responsive" in the sense of adapting text to to the user set size of the widget one widget would be good too. Speaking of: if the user sets it to 1x1 only display a sync button, and if it is large enough display an additional label. But it is of course more work to make the "one" widget more sophisticated ;-) for example: I also think that users like to see these widget options as seen in your previews in the first posting here (which I definitely like!) - so they "see what they get" when choosing between the two options. But you decide :) |
I don't think we should do it, if it means maintaining three different widget code bases. If we're able to reuse the same code it could be an option. |
It would not mean 3 widgets. Only two: one 1x1 fixed sync button widget without text and a second "resizeable" one with a label on it with min-size 1x2 and that can be enlargend as the user wishes. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code looks ok. I can't resize the bigger 1x2 widget though.
The description of how the buttons look in the widget description is superfluous. The existing widgets on the emulator always have their user action as description, so I would do it the same way. I.E. for google drive it's: "Quickly access suggested files and search" and for google calendar: "View your tasks and upcoming events".
So instead of:
"A circular button for running synchronization manually." and "A simple button for running synchronization manually with an icon and a label."
I would probably write this for both: "Tap to synchronize."
@devvv4ever Maybe you also want to spin this up on the emulator too and see if it's what you imagined it to be like.
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
96e59eb
to
4a018b5
Compare
Also possible. I'd be fine with it, but how do people understand the difference for both widgets then?
I can't since I have no Android studio to try it out myself |
They can see it :D Also it still says 1x1 or 2x1 for the size. I might be wrong, but I don't think we need to think in terms of accessibility here - as in describing what the buttons look like, for visually impaired. |
What is the status of the PR? |
Well, it's a matter of deciding how we want to implement this. Either in the same widget with resizing options, or with two different widgets |
I think it's all good to have two widgets like @devvv4ever says, so the user can see that different sizes with/without text/label are available. We just need the 1x2 widget to be resizable to a bigger size and to change the text to what the widget does, rather than what the widget looks like. |
Then we have to add the config screen and all of that. Is it really worth it? (I don't mind working on it) |
maybe not for a first implementation ^^ |
Okay so just to be clear. Maybe we can have two widgets now (after fixing the resize issue), and then in a future, if we want, use a single widget with a config screen |
And the text |
I'm fine with everything 😄 Soo this can be merged? |
No, changes are still missing. Just for focus I will repeat them here:
|
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perf 👍
Purpose
Some people is requesting a simple square widget to run synchronization for DAVx⁵ manually, this adds a new widget to extend the existing one.
Short description
Added a new widget with just an icon, that runs synchronization when clicked:
Screenshot
This doesn't exclude the already existing one with a label, but gives a new simpler option to the users.
TODO:
For some reason both widgets have the same label, it would be cool to be able to differentiate them.
Fixed
It would be cool to show a proper preview to know how the widget will look like.
Fixed
Checklist