Skip to content

Commit 916f1aa

Browse files
author
Tejesh R
committed
8329756: [macos] "javax/swing/JTable/KeyBoardNavigation.java" fail because most combinations of navigational keys with the Ctrl key do not work
Reviewed-by: abhiscxk, dnguyen
1 parent 21d1e4d commit 916f1aa

File tree

2 files changed

+11
-14
lines changed

2 files changed

+11
-14
lines changed

src/java.desktop/macosx/classes/com/apple/laf/AquaKeyBindings.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -388,7 +388,9 @@ LateBoundInputMap getTableInputMap() {
388388
"alt shift TAB", "focusHeader",
389389
"F8", "focusHeader",
390390
"ctrl shift UP", "selectFirstRowExtendSelection",
391-
"ctrl shift DOWN", "selectLastRowExtendSelection"
391+
"ctrl shift DOWN", "selectLastRowExtendSelection",
392+
"ctrl shift RIGHT", "selectLastColumnExtendSelection",
393+
"ctrl shift LEFT", "selectFirstColumnExtendSelection"
392394
}));
393395
}
394396

test/jdk/javax/swing/JTable/KeyBoardNavigation.java

Lines changed: 8 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
/*
4040
* @test
4141
* @key headful
42-
* @bug 4112270 8264102
42+
* @bug 4112270 8264102 8329756
4343
* @library /java/awt/regtesthelpers
4444
* @build PassFailJFrame
4545
* @summary Test Keyboard Navigation in JTable.
@@ -178,7 +178,7 @@ public static void main(String[] args) throws Exception {
178178
1. Refer the below keyboard navigation specs
179179
(referenced from bug report 4112270).
180180
2. Check all combinations of navigational keys mentioned below
181-
and verifying each key combinations against the spec defined.
181+
and verify each key combination against the spec defined.
182182
If it does, press "pass", otherwise press "fail".
183183
184184
""";
@@ -270,24 +270,19 @@ public static String getOSSpecificInstructions() {
270270
up/down
271271
Left/Right Arrow - Deselect current selection;
272272
move focus one cell left/right
273-
FN+Up Arrow/FN+Down Arrow - Deselect current selection;
273+
fn+Up/Down Arrow - Deselect current selection;
274274
scroll up/down one JViewport view;
275275
first visible cell in current column gets focus
276-
Control-FN+Up Arrow/FN+Down Arrow - Deselect current selection;
277-
move focus and view to
278-
first/last cell in current row
279-
F2 - Allows editing in a cell containing information without
276+
fn - Allows editing in a cell containing information without
280277
overwriting the information
281278
Esc - Resets the cell content back to the state it was in
282279
before editing started
283-
Ctrl+A, Ctrl+/ - Select All
284-
Ctrl+\\ - Deselect all
280+
Cmd+A - Select All
285281
Shift-Up/Down Arrow - Extend selection up/down one row
286282
Shift-Left/Right Arrow - Extend selection left/right one column
287-
FN-Shift Up/Down Arrow - Extend selection to top/bottom of column
288-
Shift-PageUp/PageDown - Extend selection up/down one view and scroll
289-
table
290-
""";
283+
Ctrl-Shift Up/Down Arrow - Extend selection to top/bottom of row
284+
Ctrl-Shift Left/Right Arrow - Extend selection to first/last of column
285+
""";
291286
String osName = System.getProperty("os.name").toLowerCase();
292287
if (osName.startsWith("mac")) {
293288
return MAC_SPECIFIC;

0 commit comments

Comments
 (0)