mirror of
https://github.com/polybar/polybar.git
synced 2024-11-25 13:55:47 -05:00
fix: Pass xcb_params_t by value
This commit is contained in:
parent
d23119e24e
commit
55a5c5d896
3 changed files with 5 additions and 5 deletions
|
@ -308,7 +308,7 @@ class bar : public xpp::event::sink<evt::button_press> {
|
|||
XCB_AUX_ADD_PARAM(&mask, ¶ms, graphics_exposures, 0);
|
||||
xutils::pack_values(mask, ¶ms, value_list);
|
||||
m_gcontexts.emplace(gc(i), gcontext{m_connection, m_connection.generate_id()});
|
||||
m_connection.create_gc_checked(m_gcontexts.at(gc(i)), m_pixmap, mask, &value_list);
|
||||
m_connection.create_gc_checked(m_gcontexts.at(gc(i)), m_pixmap, mask, value_list);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -689,7 +689,7 @@ class bar : public xpp::event::sink<evt::button_press> {
|
|||
"bar: color_change(%i, %s -> %s)", static_cast<int>(gc_), color_.hex(), color_.rgb());
|
||||
|
||||
const uint32_t value_list[32]{color_.value()};
|
||||
m_connection.change_gc(m_gcontexts.at(gc_), XCB_GC_FOREGROUND, &value_list);
|
||||
m_connection.change_gc(m_gcontexts.at(gc_), XCB_GC_FOREGROUND, value_list);
|
||||
|
||||
if (gc_ == gc::FG)
|
||||
m_fontmanager->allocate_color(color_);
|
||||
|
|
|
@ -183,8 +183,8 @@ class fontmanager {
|
|||
} // }}}
|
||||
|
||||
void set_gcontext_font(gcontext& gc, xcb_font_t font) { // {{{
|
||||
const uint32_t values[]{font};
|
||||
m_connection.change_gc(gc, XCB_GC_FONT, &values);
|
||||
const uint32_t values[1]{font};
|
||||
m_connection.change_gc(gc, XCB_GC_FONT, values);
|
||||
} // }}}
|
||||
|
||||
protected:
|
||||
|
|
|
@ -26,7 +26,7 @@ class window : public xpp::window<connection_t&> {
|
|||
uint32_t value_list[16];
|
||||
xutils::pack_values(mask, params, value_list);
|
||||
connection().create_window_checked(depth, operator*(), screen->root, x, y, w, h, 0,
|
||||
XCB_WINDOW_CLASS_INPUT_OUTPUT, visual->visual_id, mask, &value_list);
|
||||
XCB_WINDOW_CLASS_INPUT_OUTPUT, visual->visual_id, mask, value_list);
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue