mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-03-16 16:21:02 +00:00
Qt: only allow double leftclick in screenshot manager
This commit is contained in:
parent
69ef9c8a6a
commit
a4011376e0
@ -127,7 +127,7 @@ void screenshot_manager_dialog::showEvent(QShowEvent* event)
|
|||||||
|
|
||||||
bool screenshot_manager_dialog::eventFilter(QObject* watched, QEvent* event)
|
bool screenshot_manager_dialog::eventFilter(QObject* watched, QEvent* event)
|
||||||
{
|
{
|
||||||
if (event && event->type() == QEvent::MouseButtonDblClick)
|
if (event && event->type() == QEvent::MouseButtonDblClick && static_cast<QMouseEvent*>(event)->button() == Qt::LeftButton)
|
||||||
{
|
{
|
||||||
if (screenshot_item* item = static_cast<screenshot_item*>(watched))
|
if (screenshot_item* item = static_cast<screenshot_item*>(watched))
|
||||||
{
|
{
|
||||||
|
@ -29,7 +29,7 @@ screenshot_preview::screenshot_preview(const QString& filepath, QWidget* parent)
|
|||||||
connect(this, &screenshot_preview::customContextMenuRequested, this, &screenshot_preview::show_context_menu);
|
connect(this, &screenshot_preview::customContextMenuRequested, this, &screenshot_preview::show_context_menu);
|
||||||
}
|
}
|
||||||
|
|
||||||
void screenshot_preview::show_context_menu(const QPoint & pos)
|
void screenshot_preview::show_context_menu(const QPoint& pos)
|
||||||
{
|
{
|
||||||
QMenu* menu = new QMenu();
|
QMenu* menu = new QMenu();
|
||||||
menu->addAction(tr("&Copy"), [this]() { QGuiApplication::clipboard()->setImage(m_image); });
|
menu->addAction(tr("&Copy"), [this]() { QGuiApplication::clipboard()->setImage(m_image); });
|
||||||
|
Loading…
x
Reference in New Issue
Block a user