unity-2d is no more :-)
** Changed in: unity
Status: Triaged => Won't Fix
** Changed in: unity (Ubuntu)
Status: Triaged => Won't Fix
--
You received this bug notification because you are a member of Desktop
Packages, which is subscribed to unity in Ubuntu.
Matching subscriptions: dp-unity
https://bugs.launchpad.net/bugs/868425
Title:
It would be nice to be able to programmatically distinguish between 2D
and 3D Unity
Status in Unity:
Won't Fix
Status in “unity” package in Ubuntu:
Won't Fix
Bug description:
This came from a brief discussion with Didier about determining if a
system is runnign 3D or 2D. Previously, we could determine this
simply by checking com.canonical.Unity with has_owner() as Unity only
ran in 3d with the old Gnome UI being the 2D fallback.
Now that Unity runs in both 2D and 3D, however, there isn't a ready
method for determing which one we're actually using.
So this is a wishlist to add that determination. It would be great if
we could probe something in com.canonical.Unity and see if we're
running the 3D or 2D version programmatically.
For background, here's the post from ubuntu-devel-discuss:
Le 05/10/2011 15:50, Jeff Lane a écrit :
> On 10/05/2011 02:30 AM, Didier Roche wrote:
>> Le 05/10/2011 08:17, YunQiang Su a écrit :
>>> I am trying to make a program has different tray in different
>>> environment:
>>> when indicator is supported, indicator plug-in is used,
>>> when in gnome-shell or gnome-panel, notification area written by gtk
>>> when KDE, use the way KDE prefer,
>>>
>>> Then the problem is that how I can determine which are using dynamic?
>>> unity, gnome-shell or something else ?
>>>
>>>
>> You can detect Unity using dbus. There is a Bus Name
>> com.canonical.Unity.Launcher which is there only when Unity is running.
>> This method is 100% reliable compared to session name
>> (DESKTOP_SESSION=ubuntu, DESKTOP_SESSION=ubuntu-2d…) which isn't cross
>> distribution.
>>
>> For other like gnome-shell, I'm not sure if something similar exists.
>
> Didier,
>
> Is there a specific dbus method for determining 3D vs 2D? We previously
were simply looking for com.canonical.Unity since at that time, Unity only ran
in 3D, with Gnome begin the fallback. Now that we have both 3D and 2D, how can
we make that determination. It would be useful in testing to know if the
installation is providing 3d or 2d by default.
>
Interesting question! There is nothing "official" right now, but only 3D has
the Debug method right now, so you can base on that:
com.canonical.Unity,
/com/canonical/Unity/Debug
use the interface com.canonical.Unity.Debug.Introspection and GetState()
method.
You should open a wishlist so that we can add a common dbus method returning
2D or 3D (and raise it at UDS if possible) so that it's on the list.
For ubuntu only from Oneiric, you can rely on the DESKTOP_SESSION
environment variable being "ubuntu" for unity 3D and "ubuntu-2d" for
unity 2D. (the detection is done before choosing the session). That
won't tell you if the ui crashed at startup though.
Didier
To manage notifications about this bug go to:
https://bugs.launchpad.net/unity/+bug/868425/+subscriptions
--
Mailing list: https://launchpad.net/~desktop-packages
Post to : [email protected]
Unsubscribe : https://launchpad.net/~desktop-packages
More help : https://help.launchpad.net/ListHelp