Opened 12 years ago

Closed 12 years ago

Last modified 11 years ago

#3827 closed defect (fixed)

Home View: owner icon/activity icon not drawn correctly when rotating the screen

Reported by: erikos Owned by: erikos
Priority: Unspecified by Maintainer Milestone:
Component: Sugar Version: 0.97.x
Severity: Critical Keywords: r+, olpc-test-passed
Cc: Distribution/OS: OLPC
Bug Status: Resolved


Attachments (2)

home_buddy_icon_shifts_on_rotation.png (55.0 KB) - added by garycmartin 12 years ago.
0001-Reset-Layout-when-the-allocation-changes-SL-3827.patch (2.3 KB) - added by erikos 12 years ago.
Reset Layout when the allocation changes

Download all attachments as: .zip

Change History (8)

comment:1 Changed 12 years ago by erikos

Actually, this is not a direct issue with the nohippo code. We had the same issue already before.

When the screen is rotated the new orientation is not taken into account when calculating the positions of the icons. The positioning of the icons in the layout is based on the screen dimensions. When the screen is rotated we do not re-calculate the positions. An easy way to see this in an old build is:

  • start Sugar
  • rotate screen one time (in portrait mode)
  • switch to Neighborhood View

---> look at the icons

  • rotate screen one time (landscape mode)

---> look at the icons

If you have enough icons in the Neighborhood View, you will see that there are more icons in the landscape mode than in the portrait mode, the positions have just been calculated once with the width/height of the landscape mode.

Changed 12 years ago by garycmartin

Changed 12 years ago by erikos

Reset Layout when the allocation changes

comment:2 Changed 12 years ago by erikos

  • Keywords r? added; nohippo removed

In the HomeWindow we listen to the size-changed signal and resize the window in that case. This will be triggered by the ViewContainer and the ViewLayout. In those cases we have to recreate the grid with the new dimensions.

Attached is a patch that does fix the issue.

comment:3 Changed 12 years ago by manuq

Yes, this fixes the central buddy icon allocation, and patch looks good. Please make it in.

comment:4 Changed 12 years ago by erikos

  • Bug Status changed from Unconfirmed to Resolved
  • Keywords r+ olpc-test-pending added; r? removed
  • Resolution set to fixed
  • Status changed from new to closed

comment:5 Changed 11 years ago by greenfeld

  • Keywords olpc-test-passed added; olpc-test-pending removed

Rotation works in the home view and keeps all networks in the network view in OLPC 13.1.0 os8.

comment:6 Changed 11 years ago by dnarvaez

  • Milestone 0.98 deleted

Milestone 0.98 deleted

Note: See TracTickets for help on using tickets.