All of lore.kernel.org
 help / color / mirror / Atom feed
From: Bastien Nocera <hadess@hadess.net>
To: Marcel Holtmann <marcel@holtmann.org>
Cc: Stefan Seyfried <seife@suse.de>, linux-bluetooth@vger.kernel.org
Subject: Re: bluez-gnome: how to turn adapter off?
Date: Tue, 30 Sep 2008 11:17:21 +0100	[thread overview]
Message-ID: <1222769841.3311.127.camel@cookie.hadess.net> (raw)
In-Reply-To: <1222744734.1825.36.camel@violet.holtmann.net>

On Tue, 2008-09-30 at 05:18 +0200, Marcel Holtmann wrote:
> Hi Bastien,
> 
> > > Ok, so I remembered wrong ;-) How about adding a "disable this adapter"
> > > option? Would a patch that implements this be welcome?
> > 
> > I'd like a patch implementing HAL killswitching. DannyK can explain to
> > you how that's supposed to work.
> > 
> > I saw this as a single toggle menu item in the right-click, allowing you
> > to enable/disable the main Bluetooth adapter on laptops. If there's a
> > killswitch present, and there's 0 or 1 adapter (and the adapter matches
> > the expected device) then the Bluetooth icon would shown grayed out.
> 
> so I added killswitch support to bluetooth-properties. Works pretty good
> enough for me.
> 
> I like having a grayed out icon, but for that to work, we first need to
> have some who actually draws it in all resolutions for us.

GTK+ doesn't use separate pixbufs for those type of icons, but generates
them on the fly with gdk_pixbuf_saturate_and_pixelate().

new_pixbuf = gdk_pixbuf_copy (original);
gdk_pixbuf_saturate_and_pixelate(original, new_pixbuf, 0.8, TRUE);

And then set "new_pixbuf" as the image for the status icon. This will be
a bit convoluted in the actual code as you're using icon names, and we'd
need to 1) know whether we have a killswitch, and whether it's enabled
and 2) modify the status icon to use the pixbuf.

  reply	other threads:[~2008-09-30 10:17 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-09-29 15:59 bluez-gnome: how to turn adapter off? Stefan Seyfried
2008-09-29 16:05 ` Bastien Nocera
2008-09-29 16:20   ` Stefan Seyfried
2008-09-29 20:39     ` Bastien Nocera
2008-09-29 23:44       ` Marcel Holtmann
2008-09-30  3:18       ` Marcel Holtmann
2008-09-30 10:17         ` Bastien Nocera [this message]
2008-09-30 10:29           ` Marcel Holtmann
2008-09-29 23:43     ` Marcel Holtmann

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1222769841.3311.127.camel@cookie.hadess.net \
    --to=hadess@hadess.net \
    --cc=linux-bluetooth@vger.kernel.org \
    --cc=marcel@holtmann.org \
    --cc=seife@suse.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.