LawnchairLauncher / lawnchair

No clever tagline needed.
https://lawnchair.app
Other
8.86k stars 1.17k forks source link

[BUG] When using Smartspacer as the At A Glance provider, the At A Glance widget gets incorrectly sized #4274

Open obvionaoe opened 2 months ago

obvionaoe commented 2 months ago

Describe the bug

When I enable Smartspacer as the At A Glance provider the At A Glance widget gets incorrectly sized and puts information off screen

Steps to reproduce

Steps to reproduce the behavior:

  1. Go to Lawnchair Settings
  2. Click on At A Glance
  3. Change provider to Smartspacer
  4. Go back to home screen
  5. See error

Expected behavior

The widget should have the correct size

Screenshots

Screenshot_20240412-113759_Lawnchair (1)

Device information

Additional context

No response

srappan commented 2 months ago

Can repro.

obvionaoe commented 2 months ago

Any news?

MrDodojo commented 2 months ago

Can repro too. Screenshot_20240428-135851

obvionaoe commented 2 months ago

I did a little debugging and figured out that the issue is due to the At A Glance scaling when the Home Screen grid size is changed. The weird thing is this only happens when using Smartspacer as the provider. At least on my phone

amrbashir commented 1 month ago

I can confirm that it happens with SmartSpacer only when the grid size is changed from default

CoelacanthusHex commented 1 month ago

I have some discovery but don't know wether it is related.

Upstream said SmartSpacerView as a replacement for BcSmartpaceView in Pixel Launcher based launcher or QSB search fragment in Launcher3 based launcher. https://github.com/KieronQuinn/Smartspacer/wiki/9.-SDK:-Client-SDK-(for-Launchers)#adding-smartspacers-views

And I remember Lawnchair is based on Launcher3, so Lawnchair should use QSB search fragment. But Lawnchair use BcSmartspaceView actually: https://github.com/LawnchairLauncher/lawnchair/blob/bf612c3dc275b4da01fdfa486e008149f3f2d4ca/res/layout/smartspace_smartspacer.xml#L2-L3 The builtin smartspace seems use QSB search fragment: https://github.com/LawnchairLauncher/lawnchair/blob/bf612c3dc275b4da01fdfa486e008149f3f2d4ca/lawnchair/res/layout/smartspace_container.xml#L2-L3

obvionaoe commented 1 month ago

that could be it, I'll try and test it if I have time later today