[polari/wip/initialSetup: 1/2] Add error notification on nick changed
- From: Carlos Soriano <csoriano src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [polari/wip/initialSetup: 1/2] Add error notification on nick changed
- Date: Mon, 7 Oct 2013 15:36:09 +0000 (UTC)
commit 4e8a77dbb12305a3eca7bcb1bb98732abc67fa54
Author: Carlos Soriano <carlos soriano89 gmail com>
Date: Tue Oct 1 16:32:28 2013 +0200
Add error notification on nick changed
src/appNotifications.js | 28 ++++++++++++++++++++++++++++
1 files changed, 28 insertions(+), 0 deletions(-)
---
diff --git a/src/appNotifications.js b/src/appNotifications.js
index e292d30..58002e0 100644
--- a/src/appNotifications.js
+++ b/src/appNotifications.js
@@ -122,6 +122,34 @@ const ConnectingNotification = new Lang.Class({
}
});
+const NicknameErrorNotification = new Lang.Class({
+ Name: 'NicknameErrorNotification',
+ Extends: AppNotification,
+
+ _init: function(error) {
+ this.parent();
+
+ this._grid = new Gtk.Grid({ orientation: Gtk.Orientation.HORIZONTAL,
+ column_spacing: 12 });
+
+ this._grid.add(new Gtk.Spinner({ active: true }));
+
+ let text = error;
+ let label = new Gtk.Label({ label: text });
+ this._grid.add(label);
+
+ this.widget.add(this._grid);
+ this.widget.show_all();
+
+ Gtk.timeout_add(3, _onTimeout, null);
+ },
+
+ _onTimeout: function() {
+ this.close();
+ return false;
+ }
+});
+
const NotificationQueue = new Lang.Class({
Name: 'NotificationQueue',
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]