Gentoo Archives: gentoo-commits

From: Nirbheek Chauhan <nirbheek@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/gnome:master commit in: gnome-base/gnome-shell/, gnome-base/gnome-shell/files/
Date: Mon, 28 Feb 2011 20:25:27
Message-Id: 144f8928be9bc1283eaca0e190da45f8ead1cddd.nirbheek@gentoo
1 commit: 144f8928be9bc1283eaca0e190da45f8ead1cddd
2 Author: Nirbheek Chauhan <nirbheek <AT> gentoo <DOT> org>
3 AuthorDate: Mon Feb 28 20:18:46 2011 +0000
4 Commit: Nirbheek Chauhan <nirbheek <AT> gentoo <DOT> org>
5 CommitDate: Mon Feb 28 20:18:46 2011 +0000
6 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/gnome.git;a=commit;h=144f8928
7
8 gnome-base/gnome-shell: update patch and shell recorder elog
9
10 ---
11 ...> gnome-shell-experimental-nm-applet-1.1.patch} | 182 +++++++++++---------
12 gnome-base/gnome-shell/gnome-shell-2.91.90.ebuild | 2 +-
13 gnome-base/gnome-shell/gnome-shell-9999.ebuild | 7 +-
14 3 files changed, 109 insertions(+), 82 deletions(-)
15
16 diff --git a/gnome-base/gnome-shell/files/gnome-shell-experimental-nm-applet-1.0.patch b/gnome-base/gnome-shell/files/gnome-shell-experimental-nm-applet-1.1.patch
17 similarity index 93%
18 rename from gnome-base/gnome-shell/files/gnome-shell-experimental-nm-applet-1.0.patch
19 rename to gnome-base/gnome-shell/files/gnome-shell-experimental-nm-applet-1.1.patch
20 index 15a560b..546a539 100644
21 --- a/gnome-base/gnome-shell/files/gnome-shell-experimental-nm-applet-1.0.patch
22 +++ b/gnome-base/gnome-shell/files/gnome-shell-experimental-nm-applet-1.1.patch
23 @@ -1,4 +1,4 @@
24 -From f8a4fa0646aa4ab620331c0bbcae4334173b614d Mon Sep 17 00:00:00 2001
25 +From 9fb864ff75921974ad1f09ae75dcd6cc94ac90ef Mon Sep 17 00:00:00 2001
26 From: Giovanni Campagna <gcampagna@×××××××××.org>
27 Date: Tue, 25 Jan 2011 22:08:12 +0100
28 Subject: [PATCH] Status area: add NetworkManager indicator
29 @@ -14,17 +14,17 @@ https://bugzilla.gnome.org/show_bug.cgi?id=621707
30 js/Makefile.am | 2 +
31 js/misc/modemManager.js | 103 +++
32 js/ui/panel.js | 3 +-
33 - js/ui/status/network.js | 1754 +++++++++++++++++++++++++++++++++++++++
34 + js/ui/status/network.js | 1780 +++++++++++++++++++++++++++++++++++++++
35 tools/build/gnome-shell.modules | 17 +
36 - 6 files changed, 1886 insertions(+), 1 deletions(-)
37 + 6 files changed, 1912 insertions(+), 1 deletions(-)
38 create mode 100644 js/misc/modemManager.js
39 create mode 100644 js/ui/status/network.js
40
41 diff --git a/data/theme/gnome-shell.css b/data/theme/gnome-shell.css
42 -index 1da6619..8f0fb52 100644
43 +index c7d875a..78f1361 100644
44 --- a/data/theme/gnome-shell.css
45 +++ b/data/theme/gnome-shell.css
46 -@@ -154,6 +154,14 @@ StTooltip StLabel {
47 +@@ -158,6 +158,14 @@ StTooltip StLabel {
48 spacing: .5em;
49 }
50
51 @@ -40,7 +40,7 @@ index 1da6619..8f0fb52 100644
52 icon-size: 1.14em;
53 }
54 diff --git a/js/Makefile.am b/js/Makefile.am
55 -index e4a4145..53f80d4 100644
56 +index 55bb111..a085bfc 100644
57 --- a/js/Makefile.am
58 +++ b/js/Makefile.am
59 @@ -8,6 +8,7 @@ nobase_dist_js_DATA = \
60 @@ -51,7 +51,7 @@ index e4a4145..53f80d4 100644
61 misc/params.js \
62 misc/util.js \
63 perf/core.js \
64 -@@ -49,6 +50,7 @@ nobase_dist_js_DATA = \
65 +@@ -50,6 +51,7 @@ nobase_dist_js_DATA = \
66 ui/statusMenu.js \
67 ui/status/accessibility.js \
68 ui/status/keyboard.js \
69 @@ -169,7 +169,7 @@ index 0000000..b368511
70 +};
71 +Signals.addSignalMethods(ModemCdma.prototype);
72 diff --git a/js/ui/panel.js b/js/ui/panel.js
73 -index 1c23ae8..ab7a656 100644
74 +index d1bf3fd..76c10f1 100644
75 --- a/js/ui/panel.js
76 +++ b/js/ui/panel.js
77 @@ -38,7 +38,8 @@ const STANDARD_TRAY_ICON_SHELL_IMPLEMENTATION = {
78 @@ -184,10 +184,10 @@ index 1c23ae8..ab7a656 100644
79 if (Config.HAVE_BLUETOOTH)
80 diff --git a/js/ui/status/network.js b/js/ui/status/network.js
81 new file mode 100644
82 -index 0000000..04e9c87
83 +index 0000000..ecc80cc
84 --- /dev/null
85 +++ b/js/ui/status/network.js
86 -@@ -0,0 +1,1754 @@
87 +@@ -0,0 +1,1780 @@
88 +// -*- mode: js2; indent-tabs-mode: nil; js2-basic-offset: 4 -*-
89 +const ByteArray = imports.byteArray;
90 +const DBus = imports.dbus;
91 @@ -282,7 +282,7 @@ index 0000000..04e9c87
92 + this.bestAP = accessPoints[0];
93 +
94 + let ssid = this.bestAP.get_ssid();
95 -+ title = title || NetworkManager.utils_ssid_to_utf8(ssid, ssid.length) || _("<unknown>");
96 ++ title = title || NetworkManager.utils_ssid_to_utf8(ssid) || _("<unknown>");
97 +
98 + PopupMenu.PopupImageMenuItem.prototype._init.call(this, title, this._getIcon(), params);
99 +
100 @@ -697,40 +697,59 @@ index 0000000..04e9c87
101 + }
102 +};
103 +
104 -+function NMDeviceWWAN() {
105 ++function NMDeviceModem() {
106 + this._init.apply(this, arguments);
107 +}
108 +
109 -+NMDeviceWWAN.prototype = {
110 ++NMDeviceModem.prototype = {
111 + __proto__: NMDevice.prototype,
112 +
113 + _init: function(client, device, connections) {
114 -+ this._autoConnectionName = _("New Mobile Broadband connection...");
115 -+ this.category = NMConnectionCategory.WWAN;
116 ++ let is_wwan = false;
117 ++
118 ++ this.mobileDevice = null;
119 ++ this._connecitonType = 'ppp';
120 +
121 -+ if (device instanceof NMClient.GsmDevice) {
122 ++ // FIXME: listen for this property changing and recreate modem stuff
123 ++ this._capabilities = device.current_capabilites;
124 ++ if (this._capabilities & NetworkManager.DeviceModemCapabilities.GSM_UMTS) {
125 ++ is_wwan = true;
126 + this.mobileDevice = new ModemManager.ModemGsm(device.udi);
127 + this._connectionType = NetworkManager.SETTING_GSM_SETTING_NAME;
128 -+ } else if (device instanceof NMClient.CdmaDevice) {
129 ++ } else if (this._capabilities & NetworkManager.DeviceModemCapabilities.CDMA_EVDO) {
130 ++ is_wwan = true;
131 + this.mobileDevice = new ModemManager.ModemCdma(device.udi);
132 + this._connectionType = NetworkManager.SETTING_CDMA_SETTING_NAME;
133 ++ } else if (this._capabilites & NetworkManager.DeviceModemCapabilites.LTE) {
134 ++ is_wwan = true;
135 ++ // FIXME: support signal quality
136 + }
137 +
138 -+ this.mobileDevice.connect('notify::operator-name', Lang.bind(this, function() {
139 -+ if (this._operatorItem) {
140 -+ let name = this.mobileDevice.operator_name;
141 -+ if (name) {
142 -+ this._operatorItem.label.text = name;
143 -+ this._operatorItem.actor.show();
144 -+ } else
145 -+ this._operatorItem.actor.hide();
146 -+ }
147 -+ }));
148 -+ this.mobileDevice.connect('notify::signal-quality', Lang.bind(this, function() {
149 -+ if (this._operatorItem) {
150 -+ this._operatorItem.setIcon(this._getSignalIcon());
151 -+ }
152 -+ }));
153 ++ if (is_wwan) {
154 ++ this.category = NMConnectionCategory.WWAN;
155 ++ this._autoConnectionName = _("New Mobile Broadband connection...");
156 ++ } else {
157 ++ this.category = NMConnectionCategory.WIRED;
158 ++ this._autoConnectionName = _("Auto dial-up");
159 ++ }
160 ++
161 ++ if (this.mobileDevice) {
162 ++ this.mobileDevice.connect('notify::operator-name', Lang.bind(this, function() {
163 ++ if (this._operatorItem) {
164 ++ let name = this.mobileDevice.operator_name;
165 ++ if (name) {
166 ++ this._operatorItem.label.text = name;
167 ++ this._operatorItem.actor.show();
168 ++ } else
169 ++ this._operatorItem.actor.hide();
170 ++ }
171 ++ }));
172 ++ this.mobileDevice.connect('notify::signal-quality', Lang.bind(this, function() {
173 ++ if (this._operatorItem) {
174 ++ this._operatorItem.setIcon(this._getSignalIcon());
175 ++ }
176 ++ }));
177 ++ }
178 +
179 + NMDevice.prototype._init.call(this, client, device, connections, 1);
180 + },
181 @@ -740,12 +759,14 @@ index 0000000..04e9c87
182 + },
183 +
184 + _createSection: function() {
185 -+ NMDevice.prototype._createSection.call(this);
186 ++ if (this.mobileDevice) {
187 ++ this._operatorItem = new PopupMenu.PopupImageMenuItem(this.mobileDevice.operator_name || '',
188 ++ this._getSignalIcon(),
189 ++ { reactive: false });
190 ++ this.section.addMenuItem(this._operatorItem);
191 ++ }
192 +
193 -+ this._operatorItem = new PopupMenu.PopupImageMenuItem(this.mobileDevice.operator_name || '',
194 -+ this._getSignalIcon(),
195 -+ { reactive: false });
196 -+ this.section.addMenuItem(this._operatorItem, 0);
197 ++ NMDevice.prototype._createSection.call(this);
198 + },
199 +
200 + clearSection: function() {
201 @@ -762,6 +783,7 @@ index 0000000..04e9c87
202 + // FIXME: we need to summon the mobile wizard here
203 + // or NM will not have the necessary parameters to complete the connection
204 + // (the same FIXME is currently in nm-applet, actually)
205 ++ // (this does not apply to dial-up)
206 +
207 + let connection = new NetworkManager.Connection;
208 + connection._uuid = NetworkManager.utils_uuid_generate();
209 @@ -1218,7 +1240,7 @@ index 0000000..04e9c87
210 + if (apObj.connections.length == 1)
211 + apObj.item = this._createAPItem(apObj.connections[0], apObj, false);
212 + else {
213 -+ let title = NetworkManager.utils_ssid_to_utf8(apObj.ssid, apObj.ssid.length) || _("<unknown>");
214 ++ let title = NetworkManager.utils_ssid_to_utf8(apObj.ssid) || _("<unknown>");
215 + apObj.item = new PopupMenu.PopupSubMenuMenuItem(title);
216 + apObj.item._apObj = apObj;
217 + for (let i = 0; i < apObj.connections.length; i++)
218 @@ -1229,7 +1251,7 @@ index 0000000..04e9c87
219 + apObj.item._apObj = apObj;
220 + apObj.item.connect('activate', Lang.bind(this, function() {
221 + let name;
222 -+ let ssid = NetworkManager.utils_ssid_to_utf8(apObj.ssid, apObj.ssid.length);
223 ++ let ssid = NetworkManager.utils_ssid_to_utf8(apObj.ssid);
224 + if (ssid) {
225 + /* TRANSLATORS: this the automatic wireless connection name (including the network name) */
226 + name = _("Auto %s").format(ssid);
227 @@ -1356,16 +1378,16 @@ index 0000000..04e9c87
228 + this._dtypes = { };
229 + this._dtypes[NetworkManager.DeviceType.ETHERNET] = NMDeviceWired;
230 + this._dtypes[NetworkManager.DeviceType.WIFI] = NMDeviceWireless;
231 -+ this._dtypes[NetworkManager.DeviceType.GSM] = NMDeviceWWAN;
232 -+ this._dtypes[NetworkManager.DeviceType.CDMA] = NMDeviceWWAN;
233 ++ this._dtypes[NetworkManager.DeviceType.MODEM] = NMDeviceModem;
234 + this._dtypes[NetworkManager.DeviceType.BT] = NMDeviceBluetooth;
235 -+ // FIXME: WWAN support (if enabled)
236 ++ // FIXME: WiMax support (if enabled)
237 +
238 + // Connection types
239 + this._ctypes = { };
240 + this._ctypes[NetworkManager.SETTING_WIRELESS_SETTING_NAME] = NMConnectionCategory.WIRELESS;
241 + this._ctypes[NetworkManager.SETTING_WIRED_SETTING_NAME] = NMConnectionCategory.WIRED;
242 + this._ctypes[NetworkManager.SETTING_PPPOE_SETTING_NAME] = NMConnectionCategory.WIRED;
243 ++ this._ctypes[NetworkManager.SETTING_PPP_SETTING_NAME] = NMConnectionCategory.WIRED;
244 + this._ctypes[NetworkManager.SETTING_BLUETOOTH_SETTING_NAME] = NMConnectionCategory.WWAN;
245 + this._ctypes[NetworkManager.SETTING_CDMA_SETTING_NAME] = NMConnectionCategory.WWAN;
246 + this._ctypes[NetworkManager.SETTING_GSM_SETTING_NAME] = NMConnectionCategory.WWAN;
247 @@ -1631,42 +1653,46 @@ index 0000000..04e9c87
248 +
249 + _notifyActiveConnection: function(active) {
250 + if (active.state == NetworkManager.ActiveConnectionState.ACTIVATED) {
251 -+ this._ensureSource();
252 +
253 -+ let icon;
254 -+ let banner;
255 -+ switch (active._section) {
256 -+ case NMConnectionCategory.WWAN:
257 -+ icon = 'network-cellular-signal-excellent';
258 -+ banner = _("You're now connected to mobile broadband connection '%s'").format(active._connection._name);
259 -+ break;
260 -+ case NMConnectionCategory.WIRELESS:
261 -+ icon = 'network-wireless-signal-excellent';
262 -+ banner = _("You're now connected to wireless network '%s'").format(active._connection._name);
263 -+ break;
264 -+ case NMConnectionCategory.WIRED:
265 -+ icon = 'network-wired';
266 -+ banner = _("You're now connected to wired network '%s'").format(active._connection._name);
267 -+ break;
268 -+ case NMConnectionCategory.VPN:
269 -+ icon = 'network-vpn';
270 -+ banner = _("You're now connected to VPN network '%s'").format(active._connection._name);
271 -+ break;
272 -+ default:
273 -+ // a fallback for a generic 'connected' icon
274 -+ icon = 'network-transmit-receive';
275 -+ banner = _("You're now connected to '%s'").format(active._connection._name);
276 -+ }
277 ++ // notify only connections that are visible
278 ++ if (active._connection) {
279 ++ this._ensureSource();
280 +
281 -+ let iconActor = new St.Icon({ icon_name: icon,
282 -+ icon_type: St.IconType.SYMBOLIC,
283 -+ icon_size: this._source.ICON_SIZE
284 -+ });
285 -+ let notification = new MessageTray.Notification(this._source,
286 -+ _("Connection estabilished"),
287 -+ banner,
288 -+ { icon: iconActor });
289 -+ this._source.notify(notification);
290 ++ let icon;
291 ++ let banner;
292 ++ switch (active._section) {
293 ++ case NMConnectionCategory.WWAN:
294 ++ icon = 'network-cellular-signal-excellent';
295 ++ banner = _("You're now connected to mobile broadband connection '%s'").format(active._connection._name);
296 ++ break;
297 ++ case NMConnectionCategory.WIRELESS:
298 ++ icon = 'network-wireless-signal-excellent';
299 ++ banner = _("You're now connected to wireless network '%s'").format(active._connection._name);
300 ++ break;
301 ++ case NMConnectionCategory.WIRED:
302 ++ icon = 'network-wired';
303 ++ banner = _("You're now connected to wired network '%s'").format(active._connection._name);
304 ++ break;
305 ++ case NMConnectionCategory.VPN:
306 ++ icon = 'network-vpn';
307 ++ banner = _("You're now connected to VPN network '%s'").format(active._connection._name);
308 ++ break;
309 ++ default:
310 ++ // a fallback for a generic 'connected' icon
311 ++ icon = 'network-transmit-receive';
312 ++ banner = _("You're now connected to '%s'").format(active._connection._name);
313 ++ }
314 ++
315 ++ let iconActor = new St.Icon({ icon_name: icon,
316 ++ icon_type: St.IconType.SYMBOLIC,
317 ++ icon_size: this._source.ICON_SIZE
318 ++ });
319 ++ let notification = new MessageTray.Notification(this._source,
320 ++ _("Connection estabilished"),
321 ++ banner,
322 ++ { icon: iconActor });
323 ++ this._source.notify(notification);
324 ++ }
325 +
326 + if (active._stateChangeId) {
327 + active.disconnect(active._stateChangeId);
328 @@ -1943,7 +1969,7 @@ index 0000000..04e9c87
329 + }
330 +};
331 diff --git a/tools/build/gnome-shell.modules b/tools/build/gnome-shell.modules
332 -index e8b5493..2f44c5d 100644
333 +index 778db20..6ad230d 100644
334 --- a/tools/build/gnome-shell.modules
335 +++ b/tools/build/gnome-shell.modules
336 @@ -9,6 +9,8 @@
337 @@ -1955,7 +1981,7 @@ index e8b5493..2f44c5d 100644
338 <repository type="tarball" name="cairo.org"
339 href="http://cairographics.org/"/>
340 <repository type="tarball" name="0pointer.de"
341 -@@ -315,4 +317,19 @@
342 +@@ -329,4 +331,19 @@
343 </dependencies>
344 </autotools>
345
346
347 diff --git a/gnome-base/gnome-shell/gnome-shell-2.91.90.ebuild b/gnome-base/gnome-shell/gnome-shell-2.91.90.ebuild
348 index 19872b0..242e352 100644
349 --- a/gnome-base/gnome-shell/gnome-shell-2.91.90.ebuild
350 +++ b/gnome-base/gnome-shell/gnome-shell-2.91.90.ebuild
351 @@ -93,6 +93,6 @@ pkg_postinst() {
352 ewarn "To make use of GNOME Shell's built-in screen recording utility,"
353 ewarn "you need to either install >=media-libs/gst-plugins-good-0.10.23"
354 ewarn "and media-plugins/gst-plugins-vp8, or use dconf-editor to change"
355 - ewarn "/apps/gnome-shell/recorder/pipeline to what you want to use."
356 + ewarn "apps.gnome-shell.recorder/pipeline to what you want to use."
357 fi
358 }
359
360 diff --git a/gnome-base/gnome-shell/gnome-shell-9999.ebuild b/gnome-base/gnome-shell/gnome-shell-9999.ebuild
361 index 8411da8..399a7ec 100644
362 --- a/gnome-base/gnome-shell/gnome-shell-9999.ebuild
363 +++ b/gnome-base/gnome-shell/gnome-shell-9999.ebuild
364 @@ -24,6 +24,7 @@ fi
365
366 # gnome-desktop-2.91.2 is needed due to header changes, db82a33 in gnome-desktop
367 # FIXME: Automagic gnome-bluetooth[introspection] support.
368 +# latest mutter is needed due to commit 474ff2e997
369 COMMON_DEPEND=">=dev-libs/glib-2.25.9
370 >=dev-libs/gjs-0.7.11
371 >=dev-libs/gobject-introspection-0.10.1
372 @@ -38,7 +39,7 @@ COMMON_DEPEND=">=dev-libs/glib-2.25.9
373 >=net-libs/telepathy-glib-0.13.12[introspection]
374 >=net-wireless/gnome-bluetooth-2.90.0[introspection]
375 >=sys-auth/polkit-0.100[introspection]
376 - >=x11-wm/mutter-2.91.90[introspection]
377 + >=x11-wm/mutter-2.91.90.1[introspection]
378
379 dev-libs/dbus-glib
380 dev-libs/libxml2:2
381 @@ -97,7 +98,7 @@ src_prepare() {
382 ewarn "Adding support for the experimental NetworkManager applet."
383 ewarn "This needs the latest NetworkManager & nm-applet trunk."
384 ewarn "Report bugs about this to 'nirbheek' on #gentoo-desktop @ FreeNode."
385 - epatch "${FILESDIR}/${PN}-experimental-nm-applet-1.0.patch"
386 + epatch "${FILESDIR}/${PN}-experimental-nm-applet-1.1.patch"
387 fi
388
389 gnome2_src_prepare
390 @@ -114,6 +115,6 @@ pkg_postinst() {
391 ewarn "To make use of GNOME Shell's built-in screen recording utility,"
392 ewarn "you need to either install >=media-libs/gst-plugins-good-0.10.23"
393 ewarn "and media-plugins/gst-plugins-vp8, or use dconf-editor to change"
394 - ewarn "/apps/gnome-shell/recorder/pipeline to what you want to use."
395 + ewarn "apps.gnome-shell.recorder/pipeline to what you want to use."
396 fi
397 }