Commit 4ad22a7f authored by Ahmad Samir's avatar Ahmad Samir Committed by Kurt Hindenburg
Browse files

Initialize members in-class where possible

parent 1be4689d
Pipeline #193485 passed with stage
in 2 minutes and 11 seconds
......@@ -21,15 +21,6 @@
using namespace Konsole;
Emulation::Emulation()
: _windows(QList<ScreenWindow *>())
, _currentScreen(nullptr)
, _codec(nullptr)
, _keyTranslator(nullptr)
, _usesMouseTracking(false)
, _bracketedPasteMode(false)
, _imageSizeInitialized(false)
, _peekingPrimary(false)
, _activeScreenIndex(0)
{
// create screens with a default size
_screen[0] = new Screen(40, 80);
......
......@@ -433,7 +433,7 @@ protected:
QList<ScreenWindow *> _windows;
Screen *_currentScreen; // pointer to the screen which is currently active,
Screen *_currentScreen = nullptr; // pointer to the screen which is currently active,
// this is one of the elements in the screen[] array
Screen *_screen[2]; // 0 = primary screen ( used by most programs, including the shell
......@@ -443,9 +443,9 @@ protected:
// decodes an incoming C-style character stream into a unicode QString using
// the current text codec. (this allows for rendering of non-ASCII characters in text files etc.)
const QTextCodec *_codec;
const QTextCodec *_codec = nullptr;
std::unique_ptr<QTextDecoder> _decoder;
const KeyboardTranslator *_keyTranslator; // the keyboard layout
const KeyboardTranslator *_keyTranslator = nullptr; // the keyboard layout
protected Q_SLOTS:
/**
......@@ -474,13 +474,13 @@ private:
void setScreenInternal(int index);
Q_DISABLE_COPY(Emulation)
bool _usesMouseTracking;
bool _bracketedPasteMode;
bool _usesMouseTracking = false;
bool _bracketedPasteMode = false;
QTimer _bulkTimer1{this};
QTimer _bulkTimer2{this};
bool _imageSizeInitialized;
bool _peekingPrimary;
int _activeScreenIndex;
bool _imageSizeInitialized = false;
bool _peekingPrimary = false;
int _activeScreenIndex = 0;
};
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment