Fix static analyzer issue "A virtual function was overridden incorrectly"

V762 It is possible a virtual function was overridden incorrectly. See third argument of function 'create' in derived class 'UserDefineDialog' and base class 'StaticDialog'. userdefinedialog.h 332
V762 It is possible a virtual function was overridden incorrectly. See first argument of function 'redraw' in derived class 'SplitterContainer' and base class 'Window'. splittercontainer.h 61
V762 It is possible a virtual function was overridden incorrectly. See third argument of function 'create' in derived class 'FindReplaceDlg' and base class 'StaticDialog'. findreplacedlg.h 245
V762 It is possible a virtual function was overridden incorrectly. See third argument of function 'create' in derived class 'GoToLineDlg' and base class 'StaticDialog'. gotolinedlg.h 45
V762 It is possible a virtual function was overridden incorrectly. See third argument of function 'create' in derived class 'FindCharsInRangeDlg' and base class 'StaticDialog'. findcharsinrange.h 52
V762 It is possible a virtual function was overridden incorrectly. See third argument of function 'create' in derived class 'ColumnEditorDlg' and base class 'StaticDialog'. columneditor.h 45
V762 It is possible a virtual function was overridden incorrectly. See third argument of function 'create' in derived class 'WordStyleDlg' and base class 'StaticDialog'. wordstyledlg.h 77
V762 It is possible a virtual function was overridden incorrectly. See first argument of function 'redraw' in derived class 'WordStyleDlg' and base class 'Window'. wordstyledlg.h 99
V762 It is possible a virtual function was overridden incorrectly. See third argument of function 'create' in derived class 'PluginsAdminDlg' and base class 'StaticDialog'. pluginsadmin.h 100
This commit is contained in:
Oleksandr Redko 2017-10-29 18:11:05 +02:00
parent 81847599d0
commit 29f28098ae
12 changed files with 20 additions and 20 deletions

View File

@ -242,9 +242,9 @@ FindReplaceDlg::~FindReplaceDlg()
delete[] _uniFileName;
}
void FindReplaceDlg::create(int dialogID, bool isRTL)
void FindReplaceDlg::create(int dialogID, bool isRTL, bool msgDestParent)
{
StaticDialog::create(dialogID, isRTL);
StaticDialog::create(dialogID, isRTL, msgDestParent);
fillFindHistory();
_currentStatus = REPLACE_DLG;
initOptionsFromDlg();

View File

@ -242,7 +242,7 @@ public :
_ppEditView = ppEditView;
};
virtual void create(int dialogID, bool isRTL = false);
virtual void create(int dialogID, bool isRTL = false, bool msgDestParent = true);
void initOptionsFromDlg();

View File

@ -42,8 +42,8 @@ public :
_ppEditView = ppEditView;
};
virtual void create(int dialogID, bool isRTL = false) {
StaticDialog::create(dialogID, isRTL);
virtual void create(int dialogID, bool isRTL = false, bool msgDestParent = true) {
StaticDialog::create(dialogID, isRTL, msgDestParent);
};
void doDialog(bool isRTL = false) {

View File

@ -329,8 +329,8 @@ public :
void setScintilla(ScintillaEditView *pScinView) {
_pScintilla = pScinView;
};
virtual void create(int dialogID, bool isRTL = false) {
StaticDialog::create(dialogID, isRTL);
virtual void create(int dialogID, bool isRTL = false, bool msgDestParent = true) {
StaticDialog::create(dialogID, isRTL, msgDestParent);
}
void destroy() {
// A Ajouter les fils...

View File

@ -42,8 +42,8 @@ public :
void init(HINSTANCE hInst, HWND hPere, ScintillaEditView **ppEditView);
virtual void create(int dialogID, bool isRTL = false) {
StaticDialog::create(dialogID, isRTL);
virtual void create(int dialogID, bool isRTL = false, bool msgDestParent = true) {
StaticDialog::create(dialogID, isRTL, msgDestParent);
};
void doDialog(bool isRTL = false) {

View File

@ -836,9 +836,9 @@ void WordStyleDlg::setVisualFromStyleList()
}
void WordStyleDlg::create(int dialogID, bool isRTL)
void WordStyleDlg::create(int dialogID, bool isRTL, bool msgDestParent)
{
StaticDialog::create(dialogID, isRTL);
StaticDialog::create(dialogID, isRTL, msgDestParent);
if ((NppParameters::getInstance())->isTransparentAvailable())
{

View File

@ -74,7 +74,7 @@ public :
Window::init(hInst, parent);
};
virtual void create(int dialogID, bool isRTL = false);
virtual void create(int dialogID, bool isRTL = false, bool msgDestParent = true);
void doDialog(bool isRTL = false) {
if (!isCreated())
@ -96,7 +96,7 @@ public :
_gOverride2restored = (NppParameters::getInstance())->getGlobalOverrideStyle();
};
virtual void redraw() const {
virtual void redraw(bool forceUpdate = false) const {
_pFgColour->redraw();
_pBgColour->redraw();
::InvalidateRect(_hStyleInfoStaticText, NULL, TRUE);

View File

@ -49,8 +49,8 @@ public :
_ppEditView = ppEditView;
};
virtual void create(int dialogID, bool isRTL = false) {
StaticDialog::create(dialogID, isRTL);
virtual void create(int dialogID, bool isRTL = false, bool msgDestParent = true) {
StaticDialog::create(dialogID, isRTL, msgDestParent);
};
void doDialog(bool isRTL = false) {

View File

@ -203,12 +203,12 @@ long PluginsAdminDlg::searchFromCurrentSel(generic_string str2search, bool inWhi
return -1;
}
void PluginsAdminDlg::create(int dialogID, bool isRTL)
void PluginsAdminDlg::create(int dialogID, bool isRTL, bool msgDestParent)
{
// get plugin installation path and launch mode (Admin or normal)
collectNppCurrentStatusInfos();
StaticDialog::create(dialogID, isRTL);
StaticDialog::create(dialogID, isRTL, msgDestParent);
RECT rect;
getClientRect(rect);

View File

@ -97,7 +97,7 @@ public :
Window::init(hInst, parent);
};
virtual void create(int dialogID, bool isRTL = false);
virtual void create(int dialogID, bool isRTL = false, bool msgDestParent = true);
void doDialog(bool isRTL = false) {
if (!isCreated())

View File

@ -118,7 +118,7 @@ void SplitterContainer::display(bool toShow) const
}
void SplitterContainer::redraw() const
void SplitterContainer::redraw(bool forceUpdate) const
{
assert(_pWin0 != nullptr);
assert(_pWin1 != nullptr);

View File

@ -58,7 +58,7 @@ public :
virtual void display(bool toShow = true) const;
virtual void redraw() const;
virtual void redraw(bool forceUpdate = false) const;
void setWin0(Window* pWin)
{