mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-04-27 07:48:01 -07:00
Add keyboard shorcuts to focus and unfocus chat (#3898)
* Added keyboard shorcuts to focus and unfocus chat * Fixed format * Changed the Esc behavior to work on any QLineEdit in the main Window and ignore shortcut conflicts * Fixed a conflict with shortcuts * Configurable unfocus shortcut and format fixes * minor style fix
This commit is contained in:
parent
7285f24a29
commit
63b4f9b2f0
25 changed files with 235 additions and 107 deletions
|
|
@ -1,13 +1,13 @@
|
|||
#ifndef WINDOW_DECKEDITOR_H
|
||||
#define WINDOW_DECKEDITOR_H
|
||||
|
||||
#include "carddatabase.h"
|
||||
#include "customlineedit.h"
|
||||
#include "keysignals.h"
|
||||
#include "tab.h"
|
||||
|
||||
#include <QAbstractItemModel>
|
||||
#include <QDir>
|
||||
#include <QLineEdit>
|
||||
|
||||
#include "carddatabase.h"
|
||||
|
||||
class CardDatabaseModel;
|
||||
class CardDatabaseDisplayModel;
|
||||
|
|
@ -27,7 +27,7 @@ class QVBoxLayout;
|
|||
class QPushButton;
|
||||
class QDockWidget;
|
||||
|
||||
class SearchLineEdit : public QLineEdit
|
||||
class SearchLineEdit : public LineEditUnfocusable
|
||||
{
|
||||
private:
|
||||
QTreeView *treeView;
|
||||
|
|
@ -36,7 +36,7 @@ protected:
|
|||
void keyPressEvent(QKeyEvent *event) override;
|
||||
|
||||
public:
|
||||
SearchLineEdit() : QLineEdit(), treeView(nullptr)
|
||||
SearchLineEdit() : LineEditUnfocusable(), treeView(nullptr)
|
||||
{
|
||||
}
|
||||
void setTreeView(QTreeView *_treeView)
|
||||
|
|
@ -117,11 +117,11 @@ private:
|
|||
KeySignals searchKeySignals;
|
||||
|
||||
QLabel *nameLabel;
|
||||
QLineEdit *nameEdit;
|
||||
LineEditUnfocusable *nameEdit;
|
||||
QLabel *commentsLabel;
|
||||
QTextEdit *commentsEdit;
|
||||
QLabel *hashLabel1;
|
||||
QLineEdit *hashLabel;
|
||||
LineEditUnfocusable *hashLabel;
|
||||
FilterTreeModel *filterModel;
|
||||
QTreeView *filterView;
|
||||
KeySignals filterViewKeySignals;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue