quick commit
This commit is contained in:
@@ -12,7 +12,7 @@ class Popover : public Button {
|
||||
|
||||
protected:
|
||||
void on_toggle_window();
|
||||
Gtk::Popover *popover = nullptr;
|
||||
std::unique_ptr<Gtk::Popover> popover;
|
||||
void set_popover_child(Gtk::Widget &child) {
|
||||
gtk_popover_set_child(popover->gobj(), child.gobj());
|
||||
}
|
||||
|
||||
@@ -29,7 +29,7 @@ window {
|
||||
popover {
|
||||
margin-top: 4px;
|
||||
font-family: var(--text-font);
|
||||
padding: 6px;
|
||||
/* padding: 6px; TODO: create better padding*/
|
||||
border-radius: 8px;
|
||||
|
||||
background: rgba(25, 25, 25, 0.8);
|
||||
@@ -39,7 +39,7 @@ popover {
|
||||
}
|
||||
|
||||
.control-center-popover {
|
||||
padding: 12px;
|
||||
margin: 0;
|
||||
background-color: rgba(25, 25, 25, 0.95);
|
||||
}
|
||||
|
||||
|
||||
@@ -7,14 +7,12 @@ Popover::Popover(const std::string icon, std::string name): Button(icon) {
|
||||
|
||||
this->add_css_class("material-icons");
|
||||
|
||||
popover = new Gtk::Popover();
|
||||
popover = std::make_unique<Gtk::Popover>();
|
||||
popover->set_parent(*this);
|
||||
popover->set_autohide(true);
|
||||
}
|
||||
|
||||
Popover::~Popover() {
|
||||
delete popover;
|
||||
}
|
||||
Popover::~Popover() = default;
|
||||
|
||||
void Popover::on_toggle_window() {
|
||||
if (popover->get_visible()) {
|
||||
|
||||
Reference in New Issue
Block a user