move monitor damage to separate funcs
This commit is contained in:
parent
48c9e9d83d
commit
a9e34cba93
3 changed files with 14 additions and 4 deletions
|
|
@ -232,3 +232,11 @@ void CMonitor::onDisconnect() {
|
|||
|
||||
g_pCompositor->m_vMonitors.erase(std::remove_if(g_pCompositor->m_vMonitors.begin(), g_pCompositor->m_vMonitors.end(), [&](std::shared_ptr<CMonitor>& el) { return el.get() == this; }));
|
||||
}
|
||||
|
||||
void CMonitor::addDamage(pixman_region32_t* rg) {
|
||||
wlr_output_damage_add(damage, rg);
|
||||
}
|
||||
|
||||
void CMonitor::addDamage(wlr_box* box) {
|
||||
wlr_output_damage_add_box(damage, box);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -55,6 +55,8 @@ public:
|
|||
// methods
|
||||
void onConnect(bool noRule);
|
||||
void onDisconnect();
|
||||
void addDamage(pixman_region32_t* rg);
|
||||
void addDamage(wlr_box* box);
|
||||
|
||||
std::shared_ptr<CMonitor>* m_pThisWrap = nullptr;
|
||||
bool m_bEnabled = false;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue