-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
refactor: add CardTemplateEditor.getIntent & introduce CardOrdinal #20056
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
BrayanDSO
left a comment
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.
TemplatePreviewerViewModel could use CardOrdinal as well
de73ffc to
b9cf1c2
Compare
|
Re-requested a review as that added a number more |
b9cf1c2 to
36052ba
Compare
BrayanDSO
left a comment
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.
Still LGTM. Thanks!
mikehardy
left a comment
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.
good to clarify a confusing concept, I remember when I was first learning about note types and ordinals and it took me quite a while to suss out. Likely reflected (still) in the code. Making everything as explicit as possible can't hurt
I was curious what this looked like for ephemeral items or partially specified items and it seems to make sense, e.g. if you just edit a note type but not on a particular card:
01-09 08:33:41.530 4025 4025 D CardTemplateEditor$Companion: Built intent for CardTemplateEditor; ntid: 1767965588557; nid: null; ord: null
(but everything works as it should)
As I'd expect. Let's go
Purpose / Description
Creating the CardTemplateEditor was unusual, as it creates an intent, then further modifies it.
I found this unclear when working on
From first glance, the
NoteIdwas unset (as it used a hardcoded string constant rather thanEDITOR_NOTE_IDApproach
CardOrdinal, as I didn't want to document oneIntparameter ongetIntentand ignore the restCardTemplateEditor.getIntentHow Has This Been Tested?
Logcat:
Built intent for CardTemplateEditor; ntid: 1381831066614; nid: 1767661996450; ord: 1Checklist