Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion actions.cc
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,10 @@ void TreeViewMulti::on_drag_begin(const Glib::RefPtr<Gdk::DragContext> &context)
bool negate(bool b) { return !b; }

TreeViewMulti::TreeViewMulti() : Gtk::TreeView(), pending(false) {
get_selection()->set_select_function(sigc::group(&negate, sigc::ref(pending)));
get_selection()->set_select_function(
[this](Glib::RefPtr<Gtk::TreeModel> const&, Gtk::TreeModel::Path const&, bool) {
return !pending;
});
}

enum Type { COMMAND, KEY, TEXT, SCROLL, IGNORE, BUTTON, MISC };
Expand Down
2 changes: 1 addition & 1 deletion handler.cc
Original file line number Diff line number Diff line change
Expand Up @@ -533,7 +533,7 @@ class WaitForPongHandler : public Handler, protected Timeout {
virtual Grabber::State grab_mode() { return parent->grab_mode(); }
};

static inline float abs(float x) { return x > 0 ? x : -x; }
/* static inline float abs(float x) { return x > 0 ? x : -x; } */

class AbstractScrollHandler : public Handler {
bool have_x, have_y;
Expand Down
2 changes: 1 addition & 1 deletion win.cc
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ void Win::timeout() {
}

void Win::set_icon(RStroke stroke, bool invert) {
if (!icon)
if (!icon || icon->get_size() <= 0)
return;
icon->set(stroke->draw(icon->get_size(), 2.0, invert));
set_timeout(10000);
Expand Down