mirror of
https://github.com/RGBCube/serenity
synced 2025-07-28 20:37:35 +00:00
Applications: Use default constructors/destructors
https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#cother-other-default-operation-rules "The compiler is more likely to get the default semantics right and you cannot implement these functions better than the compiler."
This commit is contained in:
parent
6be75bd5e4
commit
160bda7228
195 changed files with 335 additions and 638 deletions
|
@ -1,6 +1,7 @@
|
|||
/*
|
||||
* Copyright (c) 2021, Andreas Kling <kling@serenityos.org>
|
||||
* Copyright (c) 2021, Mathias Jakobsen <mathias@jbcoding.com>
|
||||
* Copyright (c) 2022, the SerenityOS developers.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
@ -13,10 +14,6 @@ REGISTER_WIDGET(MouseSettings, DoubleClickArrowWidget);
|
|||
|
||||
namespace MouseSettings {
|
||||
|
||||
DoubleClickArrowWidget::~DoubleClickArrowWidget()
|
||||
{
|
||||
}
|
||||
|
||||
void DoubleClickArrowWidget::set_double_click_speed(int speed)
|
||||
{
|
||||
if (m_double_click_speed == speed)
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
/*
|
||||
* Copyright (c) 2021, Andreas Kling <kling@serenityos.org>
|
||||
* Copyright (c) 2021, Mathias Jakobsen <mathias@jbcoding.com>
|
||||
* Copyright (c) 2022, the SerenityOS developers.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
@ -16,7 +17,7 @@ class DoubleClickArrowWidget final : public GUI::Widget {
|
|||
C_OBJECT(DoubleClickArrowWidget);
|
||||
|
||||
public:
|
||||
virtual ~DoubleClickArrowWidget() override;
|
||||
virtual ~DoubleClickArrowWidget() override = default;
|
||||
void set_double_click_speed(int);
|
||||
|
||||
private:
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2021, the SerenityOS developers.
|
||||
* Copyright (c) 2021-2022, the SerenityOS developers.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
@ -65,7 +65,3 @@ void MouseWidget::reset_default_values()
|
|||
m_double_click_speed_slider->set_value(double_click_speed_default);
|
||||
m_switch_buttons_checkbox->set_checked(false);
|
||||
}
|
||||
|
||||
MouseWidget::~MouseWidget()
|
||||
{
|
||||
}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2021, the SerenityOS developers.
|
||||
* Copyright (c) 2021-2022, the SerenityOS developers.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
@ -14,7 +14,7 @@
|
|||
class MouseWidget final : public GUI::SettingsWindow::Tab {
|
||||
C_OBJECT(MouseWidget)
|
||||
public:
|
||||
virtual ~MouseWidget() override;
|
||||
virtual ~MouseWidget() override = default;
|
||||
|
||||
virtual void apply_settings() override;
|
||||
virtual void reset_default_values() override;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2021, the SerenityOS developers.
|
||||
* Copyright (c) 2021-2022, the SerenityOS developers.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
@ -137,7 +137,3 @@ void ThemeWidget::reset_default_values()
|
|||
{
|
||||
m_theme_name_box->set_text("Default");
|
||||
}
|
||||
|
||||
ThemeWidget::~ThemeWidget()
|
||||
{
|
||||
}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2021, the SerenityOS developers.
|
||||
* Copyright (c) 2021-2022, the SerenityOS developers.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
@ -14,7 +14,7 @@
|
|||
class MouseCursorModel final : public GUI::Model {
|
||||
public:
|
||||
static NonnullRefPtr<MouseCursorModel> create() { return adopt_ref(*new MouseCursorModel); }
|
||||
virtual ~MouseCursorModel() override { }
|
||||
virtual ~MouseCursorModel() override = default;
|
||||
|
||||
enum Column {
|
||||
Bitmap,
|
||||
|
@ -36,7 +36,7 @@ public:
|
|||
}
|
||||
|
||||
private:
|
||||
MouseCursorModel() { }
|
||||
MouseCursorModel() = default;
|
||||
|
||||
struct Cursor {
|
||||
RefPtr<Gfx::Bitmap> bitmap;
|
||||
|
@ -65,7 +65,7 @@ private:
|
|||
class ThemeWidget final : public GUI::SettingsWindow::Tab {
|
||||
C_OBJECT(ThemeWidget)
|
||||
public:
|
||||
virtual ~ThemeWidget() override;
|
||||
virtual ~ThemeWidget() override = default;
|
||||
|
||||
virtual void apply_settings() override;
|
||||
virtual void reset_default_values() override;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue