Commit Graph

58 Commits

Author SHA1 Message Date
Jasper St. Pierre
66a4cb5875 messageTray: Move the notification policy classes here
The NotificationDaemon really should be for the hookup of remote
notifications, rather than policies.

https://bugzilla.gnome.org/show_bug.cgi?id=710115
2013-10-14 15:24:53 -04:00
Giovanni Campagna
fdb732c8c2 Bluetooth: fix ngettext call
https://bugzilla.gnome.org/show_bug.cgi?id=709043
2013-10-03 16:01:27 +02:00
Jasper St. Pierre
005272bde9 bluetooth: Actually add the menu item to the bluetooth menu
https://bugzilla.gnome.org/show_bug.cgi?id=708541
2013-09-22 22:22:49 +02:00
Jasper St. Pierre
73e1f238cf panelMenu: Remove the gicon parameter from addIndicator, and make private
There's only two uses of the parameter left, which can easily be added as a
separate line below. Since it's really a private interface meant for the
indicators, make it private as well so external users are less likely to
use it.

https://bugzilla.gnome.org/show_bug.cgi?id=705845
2013-08-13 06:50:24 -04:00
Jasper St. Pierre
5cca26a565 status: Port to a new SystemIndicator framework
We can't silently replace the old behavior of separate status
icons into a new system. Replace SystemStatusButton with a new
SystemIndicator class which will allow for the flexibility we
need. For now, make it a subclass of Button so that it mostly
feels the same, but we'll soon be swapping it out with a dummy
implementation that the aggregate menu will use.

I think the code cleanup here is worth it.

https://bugzilla.gnome.org/show_bug.cgi?id=705845
2013-08-13 06:50:24 -04:00
Jasper St. Pierre
7dc9a9bf2f bluetooth: Adapt to new designs for the bluetooth menu
This is a part of the new system status design, see
https://wiki.gnome.org/GnomeShell/Design/Guidelines/SystemStatus/
for design details.

https://bugzilla.gnome.org/show_bug.cgi?id=704368
2013-07-26 04:41:49 -04:00
Jasper St. Pierre
2cd41773ba status: Remove settings actions
These aren't used in the new system status designs.

This is a part of the new system status design, see
https://wiki.gnome.org/GnomeShell/Design/Guidelines/SystemStatus/
for design details.

https://bugzilla.gnome.org/show_bug.cgi?id=704368
2013-07-19 05:34:17 -04:00
Emilio Pozuelo Monfort
dd74ea99a7 bluetooth: Port to BlueZ 5
In BlueZ 4, Authorize() was used to authorize both service
and JustWorks authorization requests. In BlueZ 5 these two
have been split into AuthorizeService() for services and
RequestAuthorization for JustWorks devices. Adapt the
Bluetooth code accordingly.

https://bugzilla.gnome.org/show_bug.cgi?id=700891
2013-06-14 11:36:10 +02:00
Gustavo Padovan
9ba78ce04a Bluetooth: Use "Passkey" instead of "PIN"
Passkey is the proper name to be used when we are pairing with a Bluetooth
2.1+ device. PIN are only used for older devices which is not the case
here, the message is only shown when dealing with 2.1+ devices.

https://bugzilla.gnome.org/show_bug.cgi?id=697661
2013-05-24 16:42:04 +02:00
Jeremy Bicha
2a5f8e84bb js: Use proper Unicode ellipsis (…) instead of three dots
https://bugzilla.gnome.org/show_bug.cgi?id=689542
2013-02-12 17:05:00 -05:00
Jeremy Bicha
3d638c692e bluetooth: use "Set Up" instead of "Set up"
Capitalize prepositions if they are part of a verb phrase

https://bugzilla.gnome.org/show_bug.cgi?id=689589
2013-02-05 13:21:13 -05:00
Giovanni Campagna
9794e71a86 Add policy for builtin message sources
Some notifications, despite being emitted by shell code, should appear
to be from application or "separable" system components. Do that by
associating them with a notification-daemon policy.

Note that for this to look really good, empathy should rename itself
to Chat.

https://bugzilla.gnome.org/show_bug.cgi?id=685926
2013-01-31 13:20:08 +01:00
Giovanni Campagna
45c2e6575d Bluetooth: remove dead code
Notification.grabFocus doesn't exist anymore.

https://bugzilla.gnome.org/show_bug.cgi?id=687081
2012-12-23 13:32:13 +01:00
Bastien Nocera
5a7b7b7389 bluetooth: Update settings desktop file
For the one now used in gnome-control-center

https://bugzilla.gnome.org/show_bug.cgi?id=690046
2012-12-11 17:12:00 +01:00
Stéphane Démurget
989d0a5682 bluetooth: add translation hints
A couple of translations were hard to translate.

https://bugzilla.gnome.org/show_bug.cgi?id=638351
2012-11-19 19:56:08 +01:00
Bastien Nocera
1f2d7fa28f Bluetooth: Remove ObexFTP functionality
ObexFTP browsing in gvfs is completely broken, and unmaintained.
http://www.hadess.net/2011/11/obexftp-in-gnome-non-update.html

Remove the UI for it. The more adventurous can go and use it
(as long as I don't get the bug reports).

https://bugzilla.gnome.org/show_bug.cgi?id=688160
2012-11-13 17:03:21 +01:00
Giovanni Campagna
3710b88ab9 Bluetooth: don't restrict the length of non numeric PINs
The protocol restriction is only for numeric PINs (passkeys, in bluez
jargon). For passwords, any length is allowed.

https://bugzilla.gnome.org/show_bug.cgi?id=683356
2012-09-05 13:15:33 +02:00
Jasper St. Pierre
ca2e09fe8b sessionMode: Allow changing the session mode at runtime
Since we eventually want to add a system for changing the top panel
contents depending on the current state of the shell, let's use the
"session mode" feature for this, and add a mechanism for updating the
session mode at runtime. Add support for every key besides the two
functional keys, and make all the components update automatically when the
session mode is changed. Add a new lock-screen mode, and make the lock
screen change to this when locked.

https://bugzilla.gnome.org/show_bug.cgi?id=683156
2012-09-04 18:42:44 -03:00
Giovanni Campagna
a3d8b5e526 Fix some more icon names
Message tray sources should never have symbolic icons.
The VPN secondary icon in the panel instead should.
2012-08-31 23:31:25 +02:00
Jasper St. Pierre
c21b1e5fe0 st: Remove StIconType
GTK+ works by explicitly specifying a -symbolic suffix for all icons.
Do the same here.

https://bugzilla.gnome.org/show_bug.cgi?id=682540
2012-08-29 16:41:09 -03:00
Jasper St. Pierre
e875b9cdca status: Clean up imports
https://bugzilla.gnome.org/show_bug.cgi?id=680426
2012-08-03 14:25:35 -03:00
Florian Müllner
a2465e0670 bluetooth: Adapt to GnomeBluetooth API break 2012-07-30 19:15:23 +02:00
Giovanni Campagna
c3afe1a83a Show the panel above the screenshield when locked
Track locked status and use it to provide a reduced version of
the panel in the locked screen. Accessibility, input sources and
volume menus are preserved, without the link to the control center.
Network, battery and user menu are reduced to pure indicators,
with no menu.
This is similar to the design but not exactly, because designers
in IRC said that network needs more analysis before exposing, and
because the design didn't account for a11y and IM (so the one menu
metaphor is not really appropriate).

https://bugzilla.gnome.org/show_bug.cgi?id=619955
2012-07-21 15:40:28 +02:00
Florian Müllner
48d6eb168f bluetooth: Enforce a PIN length of 6 digits
Bluetooth PINs are required to have 6 digits, so enforce that
condition by making the PIN request notification's confirm
button insensitive unless the entered PIN has the correct length.

https://bugzilla.gnome.org/show_bug.cgi?id=651251
2012-05-18 17:41:19 +02:00
Florian Müllner
76616dc98c bluetooth: zero-pad PIN
Bluetooth PINs always consist of 6 digits, so make sure to add
leading zeros as necessary.

https://bugzilla.gnome.org/show_bug.cgi?id=651251
2012-05-18 17:39:50 +02:00
Jasper St. Pierre
9e1a2cfeac Start using MessageTray.Source directly instead of having to subclass it
For most subclasses, this is a direct swap -- a lot of the time, the
constructor was a blank class that override createNotificationIcon,
and called _setSummaryIcon in _init.

https://bugzilla.gnome.org/show_bug.cgi?id=661236
2012-05-17 08:32:22 -04:00
Jasper St. Pierre
723a1c843a Refactor show()/hide() sequences
We seem to have a lot of code that does something along the lines of:

    if (condition)
        actor.show();
    else
        actor.hide();

ClutterActor already has such a thing for exactly this purpose: the 'visible'
property. Use it instead of the mess above.

https://bugzilla.gnome.org/show_bug.cgi?id=672272
2012-05-02 12:43:58 -04:00
Colin Guthrie
f32ab20267 bluetooth: Fix connectedMenuItem variable case.
This fixes a regression introduced in d856338f86.
2012-03-05 22:05:12 +01:00
Jasper St. Pierre
d81958a074 st: Remove st-tooltip
StTooltip has been plagued by lots of issues, and we recently ditched
it in the dash. Remove it for good.

https://bugzilla.gnome.org/show_bug.cgi?id=670034
2012-02-15 20:12:49 -05:00
Alejandro Piñeiro
74dd298891 a11y: Setting a name/label_actor for several items on the panel
https://bugzilla.gnome.org/show_bug.cgi?id=667376
2012-01-27 12:29:52 +01:00
Bastien Nocera
10df80b96a status: Remove unneeded pkill call
The bluetooth-applet is only started in the fallback session,
not when running under the shell.

https://bugzilla.gnome.org/show_bug.cgi?id=647587
2011-12-01 10:51:19 +01:00
Giovanni Campagna
17c46c2452 Port everything to class framework
The last patch in the sequence. Every place that was previously
setting prototype has been ported to Lang.Class, to make code more
concise and allow for better toString().

https://bugzilla.gnome.org/show_bug.cgi?id=664436
2011-11-24 09:50:04 +01:00
Giovanni Campagna
b356aa8e3b Port message tray sources and notifications to class framework
Third step in the class framework port, now it's the turn of
MessageTray.Source and MessageTray.Notification, as well as
the various implementations around the shell.

https://bugzilla.gnome.org/show_bug.cgi?id=664436
2011-11-24 09:50:04 +01:00
Giovanni Campagna
566bdb50c2 Port PanelMenu to new class framework
Second patch in the class framework, now it's the turn of
PanelMenu (buttons, menus and status indicators).

https://bugzilla.gnome.org/show_bug.cgi?id=664436
2011-11-24 09:50:04 +01:00
Jasper St. Pierre
d856338f86 bluetooth: Fix undefined variable issue
https://bugzilla.gnome.org/show_bug.cgi?id=663891
2011-11-13 15:23:38 -05:00
Dan Winship
75b824d032 *.js: Make emacs modelines consistent
js2-mode is no longer developed and we recommend js-mode these days,
so switch the modelines to specify that, and make them consistent
across all files.

https://bugzilla.gnome.org/show_bug.cgi?id=660358
2011-10-11 08:05:12 -04:00
Ray Strode
13bf64a53d popupMenu: Use new convenience method for settings
All the system status menus in the panel offer a
menu item to jump to a relevant part of the
control-center.

This means each status icon has the same, or nearly the
same bit of code to:

- Add a new "action" menu item and listen for its activation.
- Hide the overview if it's showing when the menu item is activated
- Find the relevant control-center panel from its desktop file
- Launch the control-center to the relevant panel

This commit consolidates all those details in a new method,
addSettingsAction.  This refactoring reduces code duplication and
slight inconsistencies in the code resulting from that duplication.
It will also make it easier in subsequent commits to hide settings menu
items when the shell is used in the login screen.

https://bugzilla.gnome.org/show_bug.cgi?id=657082
2011-08-28 12:16:04 -04:00
Ray Strode
f96b2ee858 popupMenu: Hide separators when they aren't separating
A separator only makes sense if there are items on both
sides of it. There is quite a lot of code written
throughout the shell that manages the process of showing
and hiding separators as the items around those separators
change.

This commit drops all that code in favor of changes to the menu
implementation to dynamically hide or show separators as
appropriate, so the callers don't have to deal with it.

https://bugzilla.gnome.org/show_bug.cgi?id=657082
2011-08-28 12:15:17 -04:00
Colin Walters
4886275df4 ShellApp: Change activation API
Since almost all of the callers of shell_app_activate were using the
default workspace (by passing -1), remove that parameter.

Add a new shell_app_activate_full() API which takes a workspace as
well as a timestamp; previously we might have been ignoring event
timestamps from elsewhere.

https://bugzilla.gnome.org/show_bug.cgi?id=648149
2011-08-11 05:35:23 -04:00
Colin Walters
10dcc100e9 Kill off ShellAppInfo, move into ShellApp
This dramatically thins down and sanitizes the application code.

The ShellAppSystem changes in a number of ways:
* Preferences are special cased more explicitly; they aren't apps,
  they're shortcuts for an app), and we don't have many of them, so
  don't need e.g. the optimizations in ShellAppSystem for searching.
* get_app() changes to lookup_app() and returns null if an app isn't
  found.  The semantics where it tried to find the .desktop file
  if we didn't know about it were just broken; I am pretty sure no
  caller needs this, and if they do we'll fix them.
* ShellAppSystem maintains two indexes on apps (by desktop file id
  and by GMenuTreeEntry), but is no longer in the business of
  dealing with GMenuTree as far as hierarchy and categories go.  That
  is moved up into js/ui/appDisplay.js.  Actually, it flattens both
  apps and settings.

Also, ShellWindowTracker is now the sole reference-owner for
window-backed apps.  We still do the weird "window:0x1234beef" id
for these apps, but a reference is not stored in ShellAppSystem.

The js/ui/appDisplay.js code is rewritten, and sucks a lot less.
Variable names are clearer:

_apps -> _appIcons
_filterApp -> _visibleApps
_filters -> _categoryBox

Similarly for function names.  We no longer call (for every app) a
recursive lookup in GMenuTree to see if it's in a particular section
on every category switch; it's all cached.

NOTE - this intentionally reverts the incremental loading code from
commit 7813c5b93f.  It's fast enough
here without that.

https://bugzilla.gnome.org/show_bug.cgi?id=648149
2011-08-10 12:59:32 -04:00
Giovanni Campagna
9412ac2027 BluetoothStatus: show "hardware disabled" when disabled by rfkill
Use the new PopupSwitchMenuItem functionality when bluetooth cannot
be enabled. Use it also for showing "connecting..." when activating
device items.

https://bugzilla.gnome.org/show_bug.cgi?id=648048
2011-06-27 17:21:38 +02:00
Colin Walters
8834a7df10 Consistently exit the overview when launching external applications
We were doing this in one or two places, but not most of them.

https://bugzilla.gnome.org/show_bug.cgi?id=653095
2011-06-22 17:49:44 -04:00
Dan Winship
898b2b903d environment: put gettext stuff into global environment
Rather than defining _() as a local function in every module, put it
into the global environment (along with C_() and ngettext()).

https://bugzilla.gnome.org/show_bug.cgi?id=649203
2011-05-16 14:57:21 -04:00
Dan Williams
8ec62ce46b bluetooth: fix mis-spelling of "Set up"
"setup" is not a verb.

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=648410
2011-04-28 16:22:04 -05:00
Giovanni Campagna
76fce94b66 BluetoothStatus: always update devices
Previously, we skipped rebuilding device items in case the device
had already been seen, but this caused the connected switch not to
be updated. Now it has been refactored to update in case the device
changes, and to create only when the device is completely new.

https://bugzilla.gnome.org/show_bug.cgi?id=647565
2011-04-26 18:05:39 +02:00
Diego Escalante Urrelo
0d963df7b3 status: use Shell.AppSystem to launch settings panels
Different methos are being used to launch the control-center panels of each
status icon. Standarize on Shell.AppSystem.
This also fixes the network icon using a non-existant Util.spawnDesktop()
method.

Bug #645091
2011-03-17 23:26:14 -05:00
Giovanni Campagna
7f67c34b39 Bluetooth: fix updating the device list
Inside the inner loop, use the inner iterator, not that of the outer
loop. At the same time, refactor the code to rely less on private
properties appended to foreign objects.

https://bugzilla.gnome.org/show_bug.cgi?id=644858
2011-03-16 15:29:37 +01:00
Giovanni Campagna
25015c9c3a BluetoothStatus: don't pass NaNs to native functions
GJS complains when a NaN is passed in place of an integer, and
parseInt returns that from non numeric string. Pass a sentinel
that cancels the operation in that case.

https://bugzilla.gnome.org/show_bug.cgi?id=642978
2011-03-13 17:05:33 +01:00
Luca Ferretti
940f06fb32 bluetooth: remove weird "Agent" word from notification (close #637687)
Agents are an implementation detail of Bluetooth on Linux (it's actually
a D-Bus "agent", not a Bluetooth one anyway). Only "Bluetooth" is fine.
2011-02-09 23:08:02 +01:00
Luca Ferretti
05f9be046f BluetoothStatus: add a separator above Settings menu entry
Close bug #639704
2011-01-17 21:02:03 +01:00