Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
nheko
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Nheko Reborn
nheko
Commits
8a9a513e
Commit
8a9a513e
authored
7 years ago
by
Konstantinos Sideris
Browse files
Options
Downloads
Patches
Plain Diff
Move ctrl-k callback to the MainWindow
parent
9b60fdd6
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
include/ChatPage.h
+1
-4
1 addition, 4 deletions
include/ChatPage.h
include/MainWindow.h
+1
-0
1 addition, 0 deletions
include/MainWindow.h
src/ChatPage.cc
+0
-9
0 additions, 9 deletions
src/ChatPage.cc
src/MainWindow.cc
+9
-0
9 additions, 0 deletions
src/MainWindow.cc
with
11 additions
and
13 deletions
include/ChatPage.h
+
1
−
4
View file @
8a9a513e
...
...
@@ -48,6 +48,7 @@ public:
// Initialize all the components of the UI.
void
bootstrap
(
QString
userid
,
QString
homeserver
,
QString
token
);
void
showQuickSwitcher
();
signals:
void
contentLoaded
();
...
...
@@ -69,14 +70,10 @@ private slots:
void
addRoom
(
const
QString
&
room_id
);
void
removeRoom
(
const
QString
&
room_id
);
protected:
void
keyPressEvent
(
QKeyEvent
*
event
)
override
;
private:
void
updateTypingUsers
(
const
QString
&
roomid
,
const
QList
<
QString
>
&
user_ids
);
void
updateDisplayNames
(
const
RoomState
&
state
);
void
loadStateFromCache
();
void
showQuickSwitcher
();
QHBoxLayout
*
topLayout_
;
Splitter
*
splitter
;
...
...
This diff is collapsed.
Click to expand it.
include/MainWindow.h
+
1
−
0
View file @
8a9a513e
...
...
@@ -43,6 +43,7 @@ public:
protected:
void
closeEvent
(
QCloseEvent
*
event
);
void
keyPressEvent
(
QKeyEvent
*
event
);
private
slots
:
// Handle interaction with the tray icon.
...
...
This diff is collapsed.
Click to expand it.
src/ChatPage.cc
+
0
−
9
View file @
8a9a513e
...
...
@@ -576,15 +576,6 @@ ChatPage::loadStateFromCache()
client_
->
sync
();
}
void
ChatPage
::
keyPressEvent
(
QKeyEvent
*
event
)
{
if
(
event
->
key
()
==
Qt
::
Key_K
)
{
if
(
event
->
modifiers
()
==
Qt
::
ControlModifier
)
showQuickSwitcher
();
}
}
void
ChatPage
::
showQuickSwitcher
()
{
...
...
This diff is collapsed.
Click to expand it.
src/MainWindow.cc
+
9
−
0
View file @
8a9a513e
...
...
@@ -100,6 +100,15 @@ MainWindow::MainWindow(QWidget *parent)
}
}
void
MainWindow
::
keyPressEvent
(
QKeyEvent
*
e
)
{
if
((
e
->
key
()
==
Qt
::
Key_K
)
&&
(
e
->
modifiers
().
testFlag
(
Qt
::
ControlModifier
)))
chat_page_
->
showQuickSwitcher
();
else
QMainWindow
::
keyPressEvent
(
e
);
}
void
MainWindow
::
restoreWindowSize
()
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment