Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Utilities
Kate
Commits
8ff8f6b7
Commit
8ff8f6b7
authored
Jan 25, 2022
by
Waqar Ahmed
Browse files
Move null check in slotViewChanged
parent
e86e3838
Pipeline
#128879
passed with stage
in 3 minutes and 26 seconds
Changes
1
Pipelines
3
Hide whitespace changes
Inline
Side-by-side
addons/externaltools/kateexternaltoolsview.cpp
View file @
8ff8f6b7
...
...
@@ -171,9 +171,7 @@ KateExternalToolsPluginView::KateExternalToolsPluginView(KTextEditor::MainWindow
// ESC should close & hide ToolView
connect
(
m_mainWindow
,
&
KTextEditor
::
MainWindow
::
unhandledShortcutOverride
,
this
,
&
KateExternalToolsPluginView
::
handleEsc
);
connect
(
m_mainWindow
,
&
KTextEditor
::
MainWindow
::
viewChanged
,
this
,
&
KateExternalToolsPluginView
::
slotViewChanged
);
if
(
auto
view
=
m_mainWindow
->
activeView
())
{
slotViewChanged
(
view
);
}
slotViewChanged
(
m_mainWindow
->
activeView
());
}
KateExternalToolsPluginView
::~
KateExternalToolsPluginView
()
...
...
@@ -280,6 +278,10 @@ void KateExternalToolsPluginView::slotViewChanged(KTextEditor::View *v)
}
m_currentView
=
v
;
if
(
!
m_currentView
)
{
return
;
}
connect
(
v
->
document
(),
&
KTextEditor
::
Document
::
documentSavedOrUploaded
,
this
,
&
KateExternalToolsPluginView
::
onDocumentSaved
,
Qt
::
UniqueConnection
);
#if KTEXTEDITOR_VERSION >= QT_VERSION_CHECK(5, 90, 0)
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment