- Timestamp:
- 01/13/14 10:38:41 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/expeditee/gui/Help.java
r683 r684 1 1 package org.expeditee.gui; 2 3 import java.util.Arrays;4 2 5 3 import org.expeditee.items.Item; 6 4 import org.expeditee.items.Line; 5 import org.expeditee.items.Text; 7 6 import org.expeditee.settings.experimental.ExperimentalFeatures; 8 7 … … 46 45 if((mod & (control | shift)) != 0) return "Go forward"; 47 46 return "Go back"; 48 case line: 49 case item: 47 default: 50 48 if((other & action) != 0 && (mod & control) == 0) return "Run action"; 51 49 return "Follow link"; 52 50 } 53 return null;54 51 } 55 52 … … 61 58 case line: 62 59 if((mod & shift) != 0) return "Extend shape"; 63 case item: 60 case text: 61 if((other & cursor) != 0 && FrameUtils.getCurrentItem() instanceof Text) return "Merge text"; 62 default: 64 63 if((other & cursor) != 0) return "Place item(s)"; 65 64 if((mod & shift) != 0) return "Create arrow"; 66 65 return "Pickup"; 67 66 } 68 return null;69 67 } 70 68 … … 76 74 case line: 77 75 if((mod & shift) != 0) return "Add line"; 78 case item:76 default: 79 77 if((other & cursor) != 0) return "Stamp item(s)"; 80 78 if((mod & shift) != 0) return "Create rectangle"; 81 79 return "Copy"; 82 80 } 83 return null;84 81 } 85 82 … … 90 87 private static final String left_right(int context, int mod, int other) { 91 88 switch(context) { 92 case line: 93 case item: 89 default: 94 90 if((other & cursor) == 0) return "Extract attributes"; 95 91 case background: 96 92 return "Auto format"; 97 93 } 98 return null;99 94 } 100 95 101 96 private static final String middle_right(int context, int mod, int other) { 102 97 switch(context) { 98 case text: 99 if((other & cursor) != 0 && FrameUtils.getCurrentItem() instanceof Text) return "Swap text"; 103 100 case background: 104 101 if((other & cursor) == 0) return "Undo"; 105 case line: 106 case item: 102 default: 107 103 return "Delete"; 108 104 } 109 return null;110 105 } 111 106 … … 114 109 case background: 115 110 if((mod & shift) != 0 && (other & cursor) == 0) return "Drag to pan"; 111 case text: 112 if((other & cursor) == 0) return "Select region"; 116 113 } 117 114 return null; … … 119 116 120 117 private static final String drag_middle(int context, int mod, int other) { 118 switch(context) { 119 case text: 120 if((other & cursor) == 0) return "Cut region"; 121 } 121 122 return null; 122 123 } … … 126 127 case line: 127 128 return "Extrude shape"; 129 case text: 130 if((other & cursor) == 0) return "Copy region"; 128 131 } 129 132 return null; … … 137 140 if(current instanceof Line) { 138 141 context = line; 142 } else if(current instanceof Text) { 143 context = text; 139 144 } else { 140 145 context = item;
Note:
See TracChangeset
for help on using the changeset viewer.