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

shift keyboard release issue in jsk_picker_tool ,The KeyRelease inside is not responding #854

Open
lidongxu111 opened this issue Oct 13, 2022 · 4 comments

Comments

@lidongxu111
Copy link

int PickerTool::processKeyEvent(QKeyEvent* event, rviz::RenderPanel* panel)
{
// bool processed = false;
if (event->type() == QEvent::KeyPress && event->key() == Qt::Key_Shift ) { // shift event->type() == QEvent::KeyPress
// if (event->isAutoRepeat()){
// event->ignore();
shift_pressing_ = true;
// processed == true;
}
else if (event->type() == QEvent::KeyRelease && event->key() == Qt::Key_Shift) {
shift_pressing_ = false;
// event->accept();
}
cout << "shift_pressing: " << shift_pressing_ <<endl;
return 0;
}

@k-okada
Copy link
Member

k-okada commented Oct 13, 2022

Thank you for report, could you create PR for this?

@lidongxu111
Copy link
Author

I don't know how to create PR, but I can send the complete code to your email, OK?

@lidongxu111
Copy link
Author

Because my knowledge of the code was borrowed from the code

@lidongxu111
Copy link
Author

So, can you help me?

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

No branches or pull requests

2 participants