Commit Graph

5 Commits

Author SHA1 Message Date
Kenny Guy
14d035c969 Fix colorized messaging layout and smart replies.
Modify messaging style and smart replies view to
cope with colorized backgrounds.

Bug: 78928664
Bug: 77927019
Test: atest SystemUITests (with patch from ag/3992401)
Test: visual - see bug for screenshots

Change-Id: Iee66931574fb48d0340986bf520532f798ef59fc
2018-05-10 10:25:14 +01:00
Milo Sredkov
6d23a05128 Tweak the sizes of the smart reply buttons
Tweak the sizes of the smart reply buttons to be more consistent with
the rest of the notification UI.

Note that the padding for two-line buttons needs to be different from
the padding for one-line buttons until b/78876518 is fixed.

Screenshot before: https://screenshot.googleplex.com/ePaB3YZfLEk.png
Screenshot after: https://screenshot.googleplex.com/vZmPq7AyYOB.png
Two line version: https://screenshot.googleplex.com/9o8PxMusDXV.png

Bug: 73605520
Test: In Notify post a Messaging notification with chices
Change-Id: I4ef16dc8fb2682f9ac1a74aecadf8b6b6799cfb3
2018-05-01 09:58:10 +01:00
Milo Sredkov
a5bacea405 Address visual inconsistency in smart replies
Address the major style differences and make the smart reply buttons
fit better with the other notification UI elements.

This CL does not yet address all the isues but removes the most
obvious inconsistencies.

Screenshot before: https://screenshot.googleplex.com/90QVvxJmUJ3.png
Screenshot after: https://screenshot.googleplex.com/2C8cMQgTVBG.png

Bug: 73605520
Test: In Notify post a Messaging notification with Large chices

Change-Id: Ide285c21c7bf83e9f06ade6912fd13cb3e4b9024
2018-04-14 19:39:08 +00:00
Petr Cermak
102431d5eb Custom SmartReplyView layout
Implement SmartReplyView#onMeasure and SmartReplyView#onLayout according
to the redlines in go/p-notifications:

  * Smart reply buttons can have at most 2 lines of text.
  * Squeeze buttons to 2 lines of text when necessary to fit more
    buttons.
  * Don't show buttons which have more than 2 lines of text or don't fit
    within the notification width.
  * Update button background and text color.

Screenshot: https://screenshot.googleplex.com/cSM6Ve7qjb3.png

Bug: 67765414
Test: atest SmartReplyViewTest
Change-Id: Ia161c7f5669e7aef1b8c3480a8836784f0bde055
2018-02-16 17:30:45 +00:00
Petr Cermak
ed7429c529 Implement SmartReplyView
SmartReplyView creates and manages smart reply buttons in a
notification.

One-pager:  http://go/1p-smart-reply
PRD:        http://go/srn-prd
Mocks:      http://go/p-notifications
Design doc: http://go/srn-design

Screenshot: https://screenshot.googleplex.com/GT9NGckkFKB.png

Bug: 67765414
Test: Viewed a notification with mock smart replies
Change-Id: I6d90776571a559a2542aa35fa11e6a21969179c0
2018-01-17 14:22:47 +00:00