Signed-off-by: Dominik Csapak <d.csa...@proxmox.com>
---
 js/MainView.js | 17 ++++++++++++++++-
 1 file changed, 16 insertions(+), 1 deletion(-)

diff --git a/js/MainView.js b/js/MainView.js
index adbfb74..998ce4c 100644
--- a/js/MainView.js
+++ b/js/MainView.js
@@ -91,10 +91,19 @@ Ext.define('PMG.MainView', {
            this.redirectTo(item.get('path'));
        },
 
+       changeLanguage: function() {
+           Ext.create('Proxmox.window.LanguageEditWindow', {
+               cookieName: 'PMGLangCookie'
+           }).show();
+       },
+
        control: {
            '[reference=logoutButton]': {
                click: 'logout'
-           }
+           },
+           '[reference=languageButton]': {
+               click: 'changeLanguage',
+           },
        },
 
        init: function(view) {
@@ -191,6 +200,12 @@ Ext.define('PMG.MainView', {
                    margin: '0 5 0 0',
                    iconCls: 'fa fa-user',
                    menu: [
+                       {
+                           iconCls: 'fa fa-language',
+                           text: gettext('Language'),
+                           reference: 'languageButton',
+                       },
+                       '-',
                        {
                            reference: 'logoutButton',
                            iconCls: 'fa fa-sign-out',
-- 
2.20.1


_______________________________________________
pve-devel mailing list
pve-devel@pve.proxmox.com
https://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

Reply via email to