public inbox for [email protected]
help / color / mirror / Atom feedbackup accessecibility
2+ messages / 1 participants
[nested] [flat]
* backup accessecibility
@ 2019-01-23 10:24 Aditya Toshniwal <[email protected]>
2019-01-23 10:30 ` Re: backup accessecibility Aditya Toshniwal <[email protected]>
0 siblings, 1 reply; 2+ messages in thread
From: Aditya Toshniwal @ 2019-01-23 10:24 UTC (permalink / raw)
To: pgadmin-hackers
PFA
--
Thanks and Regards,
Aditya Toshniwal
Software Engineer | EnterpriseDB Software Solutions | Pune
"Don't Complain about Heat, Plant a tree"
Attachments:
[application/octet-stream] backup.access.patch (3.2K, 3-backup.access.patch)
download | inline diff:
diff --git a/web/pgadmin/static/js/alertify/dialog_wrapper.js b/web/pgadmin/static/js/alertify/dialog_wrapper.js
index 75452f2b..82d236f9 100644
--- a/web/pgadmin/static/js/alertify/dialog_wrapper.js
+++ b/web/pgadmin/static/js/alertify/dialog_wrapper.js
@@ -8,6 +8,7 @@
//////////////////////////////////////////////////////////////
import * as commonUtils from '../utils';
+import $ from 'jquery';
export class DialogWrapper {
constructor(
@@ -53,11 +54,25 @@ export class DialogWrapper {
return undefined;
}
- focusOnDialog(dialog) {
- dialog.$el.attr('tabindex', -1);
- this.pgBrowser.keyboardNavigation.getDialogTabNavigator(dialog);
- const container = dialog.$el.find('.tab-content:first > .tab-pane.active:first');
+ focusOnDialog(alertifyDialog) {
+ let backform_tab = $(alertifyDialog.elements.body).find('.backform-tab');
+ backform_tab.attr('tabindex', -1);
+ this.pgBrowser.keyboardNavigation.getDialogTabNavigator($(alertifyDialog.elements.dialog));
+ const container = backform_tab.find('.tab-content:first > .tab-pane.active:first');
commonUtils.findAndSetFocus(container);
+
+ $(alertifyDialog.elements.footer).on('keydown', 'button', function(event) {
+ if (event.keyCode == 9 && $(this).nextAll('button:not([disabled])').length == 0) {
+ // set focus back to first editable input element of current active tab once we cycle through all enabled buttons.
+ commonUtils.findAndSetFocus($(alertifyDialog.elements.body).find('.tab-content div.active'));
+ return false;
+ }
+ });
+
+
+
+
+
}
isNodeSelected(selectedTreeNode) {
diff --git a/web/pgadmin/static/js/utils.js b/web/pgadmin/static/js/utils.js
index 86727a19..27b999f7 100644
--- a/web/pgadmin/static/js/utils.js
+++ b/web/pgadmin/static/js/utils.js
@@ -28,7 +28,7 @@ export function findAndSetFocus(container) {
if (first_el.length == 0) {
first_el = container
- .find('.pgadmin-controls:first>input:enabled,.CodeMirror-scroll');
+ .find('.pgadmin-controls:first input:enabled,.CodeMirror-scroll');
}
if(first_el.length > 0) {
diff --git a/web/pgadmin/tools/backup/static/js/backup_dialog_wrapper.js b/web/pgadmin/tools/backup/static/js/backup_dialog_wrapper.js
index 931d0a02..a9a01e5d 100644
--- a/web/pgadmin/tools/backup/static/js/backup_dialog_wrapper.js
+++ b/web/pgadmin/tools/backup/static/js/backup_dialog_wrapper.js
@@ -99,7 +99,7 @@ export class BackupDialogWrapper extends DialogWrapper {
this.elements.content.appendChild($container.get(0));
- this.focusOnDialog(dialog);
+ this.focusOnDialog(this);
this.setListenersForFilenameChanges();
}
diff --git a/web/pgadmin/tools/restore/static/js/restore_dialog_wrapper.js b/web/pgadmin/tools/restore/static/js/restore_dialog_wrapper.js
index 0d211aec..aba30480 100644
--- a/web/pgadmin/tools/restore/static/js/restore_dialog_wrapper.js
+++ b/web/pgadmin/tools/restore/static/js/restore_dialog_wrapper.js
@@ -99,7 +99,7 @@ export class RestoreDialogWrapper extends DialogWrapper {
this.elements.content.appendChild($container.get(0));
- this.focusOnDialog(dialog);
+ this.focusOnDialog(this);
this.setListenersForFilenameChanges();
}
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: backup accessecibility
2019-01-23 10:24 backup accessecibility Aditya Toshniwal <[email protected]>
@ 2019-01-23 10:30 ` Aditya Toshniwal <[email protected]>
0 siblings, 0 replies; 2+ messages in thread
From: Aditya Toshniwal @ 2019-01-23 10:30 UTC (permalink / raw)
To: pgadmin-hackers
Apologies. Kindly ignore.
On Wed, Jan 23, 2019 at 3:54 PM Aditya Toshniwal <
[email protected]> wrote:
> PFA
>
> --
> Thanks and Regards,
> Aditya Toshniwal
> Software Engineer | EnterpriseDB Software Solutions | Pune
> "Don't Complain about Heat, Plant a tree"
>
--
Thanks and Regards,
Aditya Toshniwal
Software Engineer | EnterpriseDB Software Solutions | Pune
"Don't Complain about Heat, Plant a tree"
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2019-01-23 10:30 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2019-01-23 10:24 backup accessecibility Aditya Toshniwal <[email protected]>
2019-01-23 10:30 ` Aditya Toshniwal <[email protected]>
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox