Skip to content
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

HashMap creation per mouse event #13

Closed
AllanWang opened this issue Oct 2, 2017 · 1 comment
Closed

HashMap creation per mouse event #13

AllanWang opened this issue Oct 2, 2017 · 1 comment

Comments

@AllanWang
Copy link

This line: ClipboardContent content = new ClipboardContent();

I think it would be okay to have this as a private final global variable and reuse it with each motion event

putString calls

public final boolean putString(String s) {
	if (s == null) {
		remove(DataFormat.PLAIN_TEXT);
	} else {
		put(DataFormat.PLAIN_TEXT, s);
	}
	return true;
}

so the old content will be removed anyways

prmr added a commit that referenced this issue Oct 2, 2017
@prmr
Copy link
Owner

prmr commented Oct 2, 2017

Thanks.

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

No branches or pull requests

2 participants