refactor: use C++11 class member variable initialization (#27477)
This commit is contained in:
parent
f083380c38
commit
ddf3ef0a5f
93 changed files with 130 additions and 163 deletions
|
@ -8,15 +8,15 @@
|
|||
|
||||
namespace electron {
|
||||
|
||||
ScopedHString::ScopedHString(const wchar_t* source) : str_(nullptr) {
|
||||
ScopedHString::ScopedHString(const wchar_t* source) {
|
||||
Reset(source);
|
||||
}
|
||||
|
||||
ScopedHString::ScopedHString(const std::wstring& source) : str_(nullptr) {
|
||||
ScopedHString::ScopedHString(const std::wstring& source) {
|
||||
Reset(source);
|
||||
}
|
||||
|
||||
ScopedHString::ScopedHString() : str_(nullptr) {}
|
||||
ScopedHString::ScopedHString() {}
|
||||
|
||||
ScopedHString::~ScopedHString() {
|
||||
Reset();
|
||||
|
|
|
@ -35,7 +35,7 @@ class ScopedHString {
|
|||
bool success() const { return str_; }
|
||||
|
||||
private:
|
||||
HSTRING str_;
|
||||
HSTRING str_ = nullptr;
|
||||
|
||||
DISALLOW_COPY_AND_ASSIGN(ScopedHString);
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue