Skip to content

Commit 50bd731

Browse files
committed
Some cosmetics around Bevel widget
1 parent 5bc4abb commit 50bd731

File tree

2 files changed

+15
-16
lines changed

2 files changed

+15
-16
lines changed

include/lsp-plug.in/tk/widgets/simple/Bevel.h

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*
2-
* Copyright (C) 2021 Linux Studio Plugins Project <https://lsp-plug.in/>
3-
* (C) 2021 Vladimir Sadovnikov <[email protected]>
2+
* Copyright (C) 2025 Linux Studio Plugins Project <https://lsp-plug.in/>
3+
* (C) 2025 Vladimir Sadovnikov <[email protected]>
44
*
55
* This file is part of lsp-tk-lib
66
* Created on: 13 июн. 2021 г.
@@ -48,10 +48,6 @@ namespace lsp
4848
*/
4949
class Bevel: public Widget
5050
{
51-
private:
52-
Bevel & operator = (const Bevel &);
53-
Bevel(const Bevel &);
54-
5551
public:
5652
static const w_class_t metadata;
5753

@@ -75,7 +71,12 @@ namespace lsp
7571

7672
public:
7773
explicit Bevel(Display *dpy);
78-
virtual ~Bevel();
74+
Bevel(const Bevel &) = delete;
75+
Bevel(Bevel &&) = delete;
76+
virtual ~Bevel() override;
77+
78+
Bevel & operator = (const Bevel &) = delete;
79+
Bevel & operator = (Bevel &&) = delete;
7980

8081
public:
8182
LSP_TK_PROPERTY(SizeConstraints, constraints, &sConstraints)
@@ -86,13 +87,13 @@ namespace lsp
8687
LSP_TK_PROPERTY(Arrangement, arrangement, &sArrangement)
8788

8889
protected:
89-
virtual void size_request(ws::size_limit_t *r);
90-
virtual void property_changed(Property *prop);
90+
virtual void size_request(ws::size_limit_t *r) override;
91+
virtual void property_changed(Property *prop) override;
9192

9293
public:
93-
virtual status_t init();
94+
virtual status_t init() override;
9495

95-
virtual void render(ws::ISurface *s, const ws::rectangle_t *area, bool force);
96+
virtual void render(ws::ISurface *s, const ws::rectangle_t *area, bool force) override;
9697
};
9798

9899
} /* namespace tk */

src/main/widgets/simple/Bevel.cpp

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*
2-
* Copyright (C) 2021 Linux Studio Plugins Project <https://lsp-plug.in/>
3-
* (C) 2021 Vladimir Sadovnikov <[email protected]>
2+
* Copyright (C) 2025 Linux Studio Plugins Project <https://lsp-plug.in/>
3+
* (C) 2025 Vladimir Sadovnikov <[email protected]>
44
*
55
* This file is part of lsp-tk-lib
66
* Created on: 13 июн. 2021 г.
@@ -86,9 +86,7 @@ namespace lsp
8686

8787
if (sConstraints.is(prop))
8888
query_resize();
89-
if (sColor.is(prop))
90-
query_draw();
91-
if (sBorderColor.is(prop))
89+
if (prop->one_of(sColor, sBorderColor))
9290
query_draw();
9391
if (sBorder.is(prop))
9492
query_resize();

0 commit comments

Comments
 (0)