Java Code Examples for org.eclipse.swt.dnd.DND#FEEDBACK_INSERT_AFTER
The following examples show how to use
org.eclipse.swt.dnd.DND#FEEDBACK_INSERT_AFTER .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: JdtViewerDropAdapter.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
private void setFeedback(DropTargetEvent event, int location) { if (feedbackEnabled) { switch (location) { case LOCATION_BEFORE: event.feedback = DND.FEEDBACK_INSERT_BEFORE; break; case LOCATION_AFTER: event.feedback = DND.FEEDBACK_INSERT_AFTER; break; case LOCATION_ON: default: event.feedback = DND.FEEDBACK_SELECT; break; } } // Explicitly inhibit SELECT feedback if desired if (!selectFeedbackEnabled) { event.feedback &= ~DND.FEEDBACK_SELECT; } if (expandEnabled) { event.feedback |= DND.FEEDBACK_EXPAND; } if (scrollEnabled) { event.feedback |= DND.FEEDBACK_SCROLL; } }
Example 2
Source File: GridDropTargetEffect.java From nebula with Eclipse Public License 2.0 | 4 votes |
int checkEffect(int effect) { // Some effects are mutually exclusive. Make sure that only one of the mutually exclusive effects has been specified. if ((effect & DND.FEEDBACK_SELECT) != 0) effect = effect & ~DND.FEEDBACK_INSERT_AFTER & ~DND.FEEDBACK_INSERT_BEFORE; if ((effect & DND.FEEDBACK_INSERT_BEFORE) != 0) effect = effect & ~DND.FEEDBACK_INSERT_AFTER; return effect; }
Example 3
Source File: GridDropTargetEffect.java From translationstudio8 with GNU General Public License v2.0 | 4 votes |
int checkEffect(int effect) { // Some effects are mutually exclusive. Make sure that only one of the mutually exclusive effects has been specified. if ((effect & DND.FEEDBACK_SELECT) != 0) effect = effect & ~DND.FEEDBACK_INSERT_AFTER & ~DND.FEEDBACK_INSERT_BEFORE; if ((effect & DND.FEEDBACK_INSERT_BEFORE) != 0) effect = effect & ~DND.FEEDBACK_INSERT_AFTER; return effect; }
Example 4
Source File: GridDropTargetEffect.java From tmxeditor8 with GNU General Public License v2.0 | 4 votes |
int checkEffect(int effect) { // Some effects are mutually exclusive. Make sure that only one of the mutually exclusive effects has been specified. if ((effect & DND.FEEDBACK_SELECT) != 0) effect = effect & ~DND.FEEDBACK_INSERT_AFTER & ~DND.FEEDBACK_INSERT_BEFORE; if ((effect & DND.FEEDBACK_INSERT_BEFORE) != 0) effect = effect & ~DND.FEEDBACK_INSERT_AFTER; return effect; }