mirror of
https://github.com/ArthurSonzogni/FTXUI.git
synced 2024-11-22 18:59:59 +08:00
Apply clang-tidy.
This commit is contained in:
parent
affa787244
commit
7e3e1d4bca
@ -15,7 +15,7 @@ struct Box {
|
|||||||
static auto Intersection(Box a, Box b) -> Box;
|
static auto Intersection(Box a, Box b) -> Box;
|
||||||
static auto Union(Box a, Box b) -> Box;
|
static auto Union(Box a, Box b) -> Box;
|
||||||
bool Contain(int x, int y) const;
|
bool Contain(int x, int y) const;
|
||||||
bool IsEmpty();
|
bool IsEmpty() const;
|
||||||
bool operator==(const Box& other) const;
|
bool operator==(const Box& other) const;
|
||||||
bool operator!=(const Box& other) const;
|
bool operator!=(const Box& other) const;
|
||||||
};
|
};
|
||||||
|
@ -32,7 +32,7 @@ Component Dropdown(ConstStringListRef entries, int* selected) {
|
|||||||
Component Dropdown(DropdownOption option) {
|
Component Dropdown(DropdownOption option) {
|
||||||
class Impl : public ComponentBase, public DropdownOption {
|
class Impl : public ComponentBase, public DropdownOption {
|
||||||
public:
|
public:
|
||||||
Impl(DropdownOption option) : DropdownOption(std::move(option)) {
|
explicit Impl(DropdownOption option) : DropdownOption(std::move(option)) {
|
||||||
FillDefault();
|
FillDefault();
|
||||||
checkbox_ = Checkbox(checkbox);
|
checkbox_ = Checkbox(checkbox);
|
||||||
radiobox_ = Radiobox(radiobox);
|
radiobox_ = Radiobox(radiobox);
|
||||||
@ -71,8 +71,8 @@ Component Dropdown(DropdownOption option) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void FillDefault() {
|
void FillDefault() {
|
||||||
open_ = std::move(checkbox.checked);
|
open_ = checkbox.checked;
|
||||||
selected_ = std::move(radiobox.selected);
|
selected_ = radiobox.selected;
|
||||||
checkbox.checked = &*open_;
|
checkbox.checked = &*open_;
|
||||||
radiobox.selected = &*selected_;
|
radiobox.selected = &*selected_;
|
||||||
|
|
||||||
|
@ -41,7 +41,7 @@ bool Box::Contain(int x, int y) const {
|
|||||||
|
|
||||||
/// @return whether the box is empty.
|
/// @return whether the box is empty.
|
||||||
/// @ingroup screen
|
/// @ingroup screen
|
||||||
bool Box::IsEmpty() {
|
bool Box::IsEmpty() const {
|
||||||
return x_min > x_max || y_min > y_max;
|
return x_min > x_max || y_min > y_max;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user