Skip to content
This repository has been archived by the owner on Jan 10, 2023. It is now read-only.

Expanded/Collapsed listeners #50

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

johncordeiro
Copy link

This PR adds the Expanded/Collapsed listeners feature, described in README.md but not implemented.

@googlebot
Copy link

Thanks for your pull request. It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

📝 Please visit https://cla.developers.google.com/ to sign.

Once you've signed, please reply here (e.g. I signed it!) and we'll verify. Thanks.


  • If you've already signed a CLA, it's possible we don't have your GitHub username or you're using a different email address. Check your existing CLA data and verify that your email is set on your git commits.
  • If you signed the CLA as a corporation, please let us know the company's name.

Copy link
Contributor

@matthew-carroll matthew-carroll left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In addition to the comments, please make sure you sign the CLA if you'd like this to merge in. Thanks.

@@ -50,6 +50,25 @@
private HoverMenuAdapter mAdapter;
private SharedPreferences mPrefs;
private Set<OnExitListener> mOnExitListeners = new HashSet<>();
private Set<OnCollapseAndExpandListener> mOnCollapseAndExpandListeners = new HashSet<>();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you change the implementation to a CopyOnWriteArraySet to avoid possible concurrency issues?

@@ -45,6 +45,7 @@
private boolean mIsShowingHoverMenu; // Are we currently display mHoverMenuView?
private boolean mIsInDragMode; // If we're not in drag mode then we're in menu mode.
private Set<OnExitListener> mOnExitListeners = new HashSet<>();
private Set<OnCollapseAndExpandListener> mOnCollapseAndExpandListeners = new HashSet<>();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you change the implementation to a CopyOnWriteArraySet to avoid possible concurrency issues?

@@ -131,6 +150,7 @@ public void expandMenu() {

@Override
public void collapseMenu() {
mHoverMenuView.setHoverMenuTransitionListener(mHoverMenuTransitionListener);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's this for?

@johncordeiro
Copy link
Author

I signed it as a Company a corporation, the company's name is: Ilhasoft. I'll make the proper changes and update PR.

Thanks!

@mgood7123
Copy link

anyone gonna merge this?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants