mirror of
https://github.com/RGBCube/serenity
synced 2025-07-24 14:27:35 +00:00
MenuApplets: Fix using OwnPtr<> with RefCounted types
This commit is contained in:
parent
eb3700c565
commit
62d1ac63e8
1 changed files with 2 additions and 2 deletions
|
@ -36,8 +36,8 @@ class AudioWidget final : public GUI::Widget {
|
||||||
C_OBJECT(AudioWidget)
|
C_OBJECT(AudioWidget)
|
||||||
public:
|
public:
|
||||||
AudioWidget()
|
AudioWidget()
|
||||||
|
: m_audio_client(Audio::ClientConnection::construct())
|
||||||
{
|
{
|
||||||
m_audio_client = make<Audio::ClientConnection>();
|
|
||||||
m_audio_client->on_muted_state_change = [this](bool muted) {
|
m_audio_client->on_muted_state_change = [this](bool muted) {
|
||||||
if (m_audio_muted == muted)
|
if (m_audio_muted == muted)
|
||||||
return;
|
return;
|
||||||
|
@ -68,7 +68,7 @@ private:
|
||||||
painter.blit({}, audio_bitmap, audio_bitmap.rect());
|
painter.blit({}, audio_bitmap, audio_bitmap.rect());
|
||||||
}
|
}
|
||||||
|
|
||||||
OwnPtr<Audio::ClientConnection> m_audio_client;
|
NonnullRefPtr<Audio::ClientConnection> m_audio_client;
|
||||||
RefPtr<Gfx::Bitmap> m_muted_bitmap;
|
RefPtr<Gfx::Bitmap> m_muted_bitmap;
|
||||||
RefPtr<Gfx::Bitmap> m_unmuted_bitmap;
|
RefPtr<Gfx::Bitmap> m_unmuted_bitmap;
|
||||||
bool m_audio_muted { false };
|
bool m_audio_muted { false };
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue