[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    Re: [plasma-workspace] shell: Fix plasma shell initialization after port to new libkscreen API
From:       Daniel =?ISO-8859-1?Q?Vr=E1til?= <dvratil () redhat ! com>
Date:       2014-11-26 8:26:54
Message-ID: 3176245.zfC0KXk47R () thor
[Download RAW message or body]


Dude, thanks for the fix!

Dan


On Tuesday 25 of November 2014 23:47:04 Aleix Pol wrote:
> Git commit 55bb013376c8688b74b5401587289b662fc5315b by Aleix Pol.
> Committed on 25/11/2014 at 23:46.
> Pushed by apol into branch 'master'.
> 
> Fix plasma shell initialization after port to new libkscreen API
> 
> Now kscreen initialization is asynchronous, always wait for the screen
> initialization to happen. Otherwise we'll end up in different occasions
> where the configuration is null.
> Furthermore, don't try to start loading the shell until the configuration
> has been fetched.
> 
> CCMAIL: dvratil@redhat.com
> 
> M  +4    -4    shell/shellcorona.cpp
> 
> http://commits.kde.org/plasma-workspace/55bb013376c8688b74b5401587289b662fc5
> 315b
> 
> diff --git a/shell/shellcorona.cpp b/shell/shellcorona.cpp
> index fd8e9b7..986e272 100644
> --- a/shell/shellcorona.cpp
> +++ b/shell/shellcorona.cpp
> @@ -228,13 +228,12 @@ void ShellCorona::setShell(const QString &shell)
> 
>      if (m_activityConsumer->serviceStatus() ==
> KActivities::Consumer::Unknown) { connect(m_activityConsumer,
> SIGNAL(serviceStatusChanged(Consumer::ServiceStatus)), SLOT(load()),
> Qt::UniqueConnection); -    } else {
> -        connect(new
> KScreen::GetConfigOperation(KScreen::GetConfigOperation::NoEDID),
> &KScreen::GetConfigOperation::finished, +    }
> +    connect(new
> KScreen::GetConfigOperation(KScreen::GetConfigOperation::NoEDID),
> &KScreen::GetConfigOperation::finished, this, [=](KScreen::ConfigOperation
> *op) {
>                      m_screenConfiguration =
> qobject_cast<KScreen::GetConfigOperation*>(op)->config(); load();
>                  });
> -    }
>  }
> 
>  QString ShellCorona::shell() const
> @@ -260,7 +259,8 @@ static QList<KScreen::OutputPtr> sortOutputs(const
> KScreen::OutputList &outputs) void ShellCorona::load()
>  {
>      if (m_shell.isEmpty() ||
> -        m_activityConsumer->serviceStatus() ==
> KActivities::Consumer::Unknown) { +       
> m_activityConsumer->serviceStatus() == KActivities::Consumer::Unknown || + 
>       !m_screenConfiguration) {
>          return;
>      }

-- 
Daniel Vrátil | dvratil@redhat.com | dvratil on #kde-devel, #kontact, #akonadi
Software Engineer - KDE Desktop Team, Red Hat Inc.

GPG Key: 0xC59D614F6F4AE348
Fingerprint: 4EC1 86E3 C54E 0B39 5FDD B5FB C59D 614F 6F4A E348
["signature.asc" (application/pgp-signature)]

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic