[polari] mainWindow: Expand nick entry



commit db645319e80555c6e277932374aeb2bed1b0fe07
Author: Carlos Soriano <carlos soriano89 gmail com>
Date:   Tue Nov 19 16:47:36 2013 +0100

    mainWindow: Expand nick entry
    
    Acomodate nick entry to the length of the actual nick
    
    https://bugzilla.gnome.org/show_bug.cgi?id=711853

 src/mainWindow.js |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/src/mainWindow.js b/src/mainWindow.js
index 9fc7343..ed9808f 100644
--- a/src/mainWindow.js
+++ b/src/mainWindow.js
@@ -318,6 +318,7 @@ const MainWindow = new Lang.Class({
     },
 
     _setNick: function(nick) {
+        this._nickEntry.width_chars = Math.max(nick.length, ChatView.MAX_NICK_CHARS)
         this._nickEntry.placeholder_text = nick;
 
         let account = this._room.channel.connection.get_account();
@@ -403,6 +404,8 @@ const MainWindow = new Lang.Class({
     _updateNick: function() {
         let nick = this._room ? this._room.channel.connection.self_contact.alias
                               : '';
+
+        this._nickEntry.width_chars = Math.max(nick.length, ChatView.MAX_NICK_CHARS)
         this._nickEntry.placeholder_text = nick;
     },
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]