|
|
@ -376,6 +376,7 @@ class Theme { |
|
|
|
this.tux = 'img/antergos-logo-user.png'; |
|
|
|
this.tux = 'img/antergos-logo-user.png'; |
|
|
|
this.user_list_visible = false; |
|
|
|
this.user_list_visible = false; |
|
|
|
this.auth_pending = false; |
|
|
|
this.auth_pending = false; |
|
|
|
|
|
|
|
this.showing_message = false; |
|
|
|
this.selected_user = null; |
|
|
|
this.selected_user = null; |
|
|
|
this.$user_list = $( '#user-list2' ); |
|
|
|
this.$user_list = $( '#user-list2' ); |
|
|
|
this.$session_list = $( '#sessions' ); |
|
|
|
this.$session_list = $( '#sessions' ); |
|
|
@ -718,6 +719,7 @@ class Theme { |
|
|
|
|
|
|
|
|
|
|
|
} else { |
|
|
|
} else { |
|
|
|
// The user did not enter the correct password. Show error message.
|
|
|
|
// The user did not enter the correct password. Show error message.
|
|
|
|
|
|
|
|
this.showing_message = true; |
|
|
|
this.show_message( err_msg, 'error' ); |
|
|
|
this.show_message( err_msg, 'error' ); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -748,21 +750,24 @@ class Theme { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
key_press_handler( event ) { |
|
|
|
key_press_handler( event ) { |
|
|
|
let action; |
|
|
|
let action = this.showing_message ? this.dismiss_message : null; |
|
|
|
|
|
|
|
|
|
|
|
switch ( event.which ) { |
|
|
|
if ( null === action ) { |
|
|
|
case 13: |
|
|
|
switch ( event.which ) { |
|
|
|
action = this.auth_pending ? this.submit_password : ! this.user_list_visible ? this.show_user_list : null; |
|
|
|
case 13: |
|
|
|
break; |
|
|
|
if ( this.auth_pending ) { |
|
|
|
case 27: |
|
|
|
action = this.submit_password; |
|
|
|
action = this.auth_pending ? this.cancel_authentication : null; |
|
|
|
} else if ( ! this.user_list_visible ) { |
|
|
|
break; |
|
|
|
action = this.show_user_list; |
|
|
|
case 32: |
|
|
|
} |
|
|
|
action = ( ! this.user_list_visible && ! this.auth_pending ) ? this.show_user_list : null; |
|
|
|
break; |
|
|
|
break; |
|
|
|
case 27: |
|
|
|
default: |
|
|
|
action = this.auth_pending ? this.cancel_authentication : null; |
|
|
|
action = null; |
|
|
|
break; |
|
|
|
break; |
|
|
|
case 32: |
|
|
|
|
|
|
|
action = ( !this.user_list_visible && !this.auth_pending ) ? this.show_user_list : null; |
|
|
|
|
|
|
|
break; |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if ( null !== action ) { |
|
|
|
if ( null !== action ) { |
|
|
@ -853,6 +858,13 @@ class Theme { |
|
|
|
$( '#collapseTwo .user-wrap2' ).hide(); |
|
|
|
$( '#collapseTwo .user-wrap2' ).hide(); |
|
|
|
this.$msg_area_container.show(); |
|
|
|
this.$msg_area_container.show(); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
dismiss_message() { |
|
|
|
|
|
|
|
this.$msg_area_container |
|
|
|
|
|
|
|
.children( '.alert-dismissible' ) |
|
|
|
|
|
|
|
.find('.close') |
|
|
|
|
|
|
|
.trigger('click'); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|