Split Client::updateFirstInTabBox into two parts
parent
327dd406e6
commit
584bdbce71
16
client.cpp
16
client.cpp
|
@ -2291,12 +2291,22 @@ Client::Position Client::titlebarPosition() const
|
|||
return PositionTop;
|
||||
}
|
||||
|
||||
Xcb::Property Client::fetchFirstInTabBox() const
|
||||
{
|
||||
return Xcb::Property(false, m_client, atoms->kde_first_in_window_list,
|
||||
atoms->kde_first_in_window_list, 0, 1);
|
||||
}
|
||||
|
||||
void Client::readFirstInTabBox(Xcb::Property &property)
|
||||
{
|
||||
setFirstInTabBox(property.toBool(32, atoms->kde_first_in_window_list));
|
||||
}
|
||||
|
||||
void Client::updateFirstInTabBox()
|
||||
{
|
||||
// TODO: move into KWindowInfo
|
||||
Xcb::Property property(false, m_client, atoms->kde_first_in_window_list,
|
||||
atoms->kde_first_in_window_list, 0, 1);
|
||||
setFirstInTabBox(property.toBool(32, atoms->kde_first_in_window_list));
|
||||
Xcb::Property property = fetchFirstInTabBox();
|
||||
readFirstInTabBox(property);
|
||||
}
|
||||
|
||||
Xcb::StringProperty Client::fetchColorScheme() const
|
||||
|
|
2
client.h
2
client.h
|
@ -654,6 +654,8 @@ public:
|
|||
void setFirstInTabBox(bool enable) {
|
||||
m_firstInTabBox = enable;
|
||||
}
|
||||
Xcb::Property fetchFirstInTabBox() const;
|
||||
void readFirstInTabBox(Xcb::Property &property);
|
||||
void updateFirstInTabBox();
|
||||
Xcb::StringProperty fetchColorScheme() const;
|
||||
void readColorScheme(Xcb::StringProperty &property);
|
||||
|
|
|
@ -102,6 +102,7 @@ bool Client::manage(xcb_window_t w, bool isMapped)
|
|||
auto gtkFrameExtentsCookie = fetchGtkFrameExtents();
|
||||
auto showOnScreenEdgeCookie = fetchShowOnScreenEdge();
|
||||
auto colorSchemeCookie = fetchColorScheme();
|
||||
auto firstInTabBoxCookie = fetchFirstInTabBox();
|
||||
info = new WinInfo(this, m_client, rootWindow(), properties, properties2);
|
||||
|
||||
// If it's already mapped, ignore hint
|
||||
|
@ -144,7 +145,7 @@ bool Client::manage(xcb_window_t w, bool isMapped)
|
|||
|
||||
original_skip_taskbar = skip_taskbar = (info->state() & NET::SkipTaskbar) != 0;
|
||||
skip_pager = (info->state() & NET::SkipPager) != 0;
|
||||
updateFirstInTabBox();
|
||||
readFirstInTabBox(firstInTabBoxCookie);
|
||||
|
||||
setupCompositing();
|
||||
|
||||
|
|
Loading…
Reference in New Issue