-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Conversation
I really hate tests sometimes 😆 @samtstern
|
Also:
|
compile "com.android.support:appcompat-v7:$support_library_version" | ||
implementation "com.android.support:appcompat-v7:$support_library_version" | ||
api "com.android.support:support-compat:$support_library_version" | ||
api "com.android.support:support-fragment:$support_library_version" |
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.
When I removed appcompat-v7
from the demo project, I couldn't get it to compile without these api declarations.
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.
I think this is working as intended. Some of the AppCompat classes are part of our public API, so we need an api
dependency on them.
@samtstern Ok, this PR has grown too big so I've rebased all my commits such that they can be merged individually (instead of the usual squashing). I could also try to create a PR per commit, what do you think? Since my last comment, I've fixed a bug where the |
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.
This seems mostly good! Some comments left.
compile "com.android.support:appcompat-v7:$support_library_version" | ||
implementation "com.android.support:appcompat-v7:$support_library_version" | ||
api "com.android.support:support-compat:$support_library_version" | ||
api "com.android.support:support-fragment:$support_library_version" |
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.
I think this is working as intended. Some of the AppCompat classes are part of our public API, so we need an api
dependency on them.
} | ||
|
||
void setNegativeListener(DialogInterface.OnClickListener negativeListener) { | ||
mNegativeListener = negativeListener; | ||
private static Context parseContext(Object activityOrFragment) { |
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.
Could we make this method something we call just once (at build()
time for example?) and then save the Context
in a variable rather than re-casting activityOrFragment
every time we want to use it?
|
||
void setContext(Context context) { | ||
mContext = context; | ||
static AppSettingsDialog parse(Intent intent, Activity activity) { |
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.
nit: I would call this method either getInstance()
or fromIntent()
@SUPERCILEX this PR is big but not problematically so, I think we can try to keep it together. Thank you for sending it! |
Signed-off-by: Alex Saveau <[email protected]>
Signed-off-by: Alex Saveau <[email protected]>
Signed-off-by: Alex Saveau <[email protected]>
Signed-off-by: Alex Saveau <[email protected]>
Signed-off-by: Alex Saveau <[email protected]>
Signed-off-by: Alex Saveau <[email protected]>
…scendants Signed-off-by: Alex Saveau <[email protected]>
@samtstern SGTM! I rebased everything because I thought you could compare two commits coming from the same HEAD, but apparently not so the diff is broken, sorry! 😊 I added back the While working on |
@SUPERCILEX thanks for all the hard work here! This LGTM, I am going to merge it. |
fixes #154