Skip to content

Commit

Permalink
Merge "Improve the layout-related comments." into nyc-dev
Browse files Browse the repository at this point in the history
  • Loading branch information
TreeHugger Robot authored and Android (Google) Code Review committed Apr 28, 2016
2 parents eeca191 + a369104 commit 343eb72
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions screen_ui.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -105,16 +105,18 @@ int ScreenRecoveryUI::PixelsFromDp(int dp) {

// Here's the intended layout:

// 162dp
// icon (200dp)
// 62dp
// text (14sp)
// 24dp
// progress (2dp)
// 172dp
// | regular large
// ---------+--------------------
// | 220dp 366dp
// icon | (200dp) (200dp)
// | 68dp 68dp
// text | (14sp) (14sp)
// | 32dp 32dp
// progress | (2dp) (2dp)
// | 194dp 340dp

// Note that "baseline" is actually the *top* of each icon (because that's how our drawing
// routines work), so that's the more useful measurement.
// routines work), so that's the more useful measurement for calling code.

int ScreenRecoveryUI::GetAnimationBaseline() {
return GetTextBaseline() - PixelsFromDp(68) - gr_get_height(loopFrames[0]);
Expand Down

0 comments on commit 343eb72

Please sign in to comment.