Java Code Examples for java.awt.Cursor

The following examples show how to use java.awt.Cursor. These examples are extracted from open source projects. 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 want to check out the right sidebar which shows the related API usage.
Example 1
Source Project: uima-uimaj   Source File: DocumentAnalyzer.java    License: Apache License 2.0 6 votes vote down vote up
/**
 * Collection process complete.
 *
 * @see org.apache.uima.collection.base_cpm.BaseStatusCallbackListener#collectionProcessComplete()
 */
@Override
public void collectionProcessComplete() {
  // invoke ProcessingCompleteRunnable in Swing event handler thread
  // SwingUtilities.invokeLater(new ProcessingCompleteRunnable());
  // hide progress bar dialog if it is visible
  if (!progressMonitor.isCanceled()) {
    progressMonitor.close();
    progressTimer.stop();
  }

  // Re-enable frame:
  setEnabled(true);

  // reset cursor
  setCursor(Cursor.getDefaultCursor());

  // if everything works, output performance stats and print them to a
  // pane. Allow users to open generated files.
  showAnalysisResults(new AnalysisEnginePerformanceReports(mCPM.getPerformanceReport()),
          outputDirectory);
}
 
Example 2
Source Project: importer-exporter   Source File: DatePicker.java    License: Apache License 2.0 6 votes vote down vote up
private JPanel createLinkPanel() {
    linkPanel = new JPanel();
    linkPanel.setLayout(new FlowLayout(FlowLayout.RIGHT));

    todayLink = new JLabel();
    todayLink.setForeground(new Color(16, 66, 104));
    todayLink.setCursor(new Cursor(Cursor.HAND_CURSOR));
    linkPanel.add(todayLink);

    todayLink.addMouseListener(new MouseAdapter() {
        public void mouseClicked(MouseEvent e) {
            if (SwingUtilities.isLeftMouseButton(e)) {
                Action delegate = getActionMap().get(e.getClickCount() != 2 ? JXDatePicker.HOME_NAVIGATE_KEY : JXDatePicker.HOME_COMMIT_KEY);
                if (delegate != null && delegate.isEnabled())
                    delegate.actionPerformed(null);
            }
        }
    });

    return linkPanel;
}
 
Example 3
Source Project: openjdk-8   Source File: RangeSlider.java    License: GNU General Public License v2.0 6 votes vote down vote up
public void mouseMoved(MouseEvent e) {
    isOverBar = false;
    if (model == null) {
        return;
    }


    Point p = e.getPoint();
    if (isOverFirstPosition(p) || isOverSecondPosition(p)) {
        setCursor(Cursor.getPredefinedCursor(Cursor.E_RESIZE_CURSOR));
    } else if (isOverSelection(p)) {
        isOverBar = true;
        setCursor(Cursor.getPredefinedCursor(Cursor.HAND_CURSOR));
    } else {
        this.setCursor(Cursor.getDefaultCursor());
    }
    repaint();
}
 
Example 4
Source Project: ET_Redux   Source File: MaskingShade.java    License: Apache License 2.0 6 votes vote down vote up
/**
 *
 * @param e
 */
@Override
public void mouseDragged(MouseEvent e) {

    if (mouseIsPressedInPullTab) {
        currentMouseX = e.getX();
        currentMouseY = e.getY();

        if (pullFrom == PULL_FROM_LEFT) {
            setShadeCover(Math.max(WIDTH_OF_PULLTAB, getWidth() + (currentMouseX - pressedMouseX)));
            pressedMouseX = currentMouseX;
        } else {
            setShadeCover(Math.max(WIDTH_OF_PULLTAB, getWidth() + (pressedMouseX - currentMouseX)));
            pressedMouseX = WIDTH_OF_PULLTAB / 2;
        }

        if (!mouseInPullTab()) {
            processMouseExitedPullTab();
            setCursor(new Cursor(Cursor.CROSSHAIR_CURSOR));
        }
    }
}
 
Example 5
Source Project: ET_Redux   Source File: WeightedMeanGraphPanel.java    License: Apache License 2.0 6 votes vote down vote up
/**
     * Creates a new instance of WeightedMeanGraphPanel
     *
     * @param sample
     */
    public WeightedMeanGraphPanel(SampleInterface sample) {
        super();

        this.sample = sample;

        setOpaque(true);

        setBackground(Color.white);

        graphWidth = 775;
        graphHeight = 600;

        selectedSampleDateModels = new Object[0][0];

        weightedMeanCursor = Cursor.getDefaultCursor();
        imageMode = "PAN";
//        setInRandomMode( false );
        weightedMeanOptions = new SampleDateInterpretationGUIOptions().getWeightedMeanOptions();

        addMouseListener(this);
        addMouseMotionListener(this);
    }
 
Example 6
private OperationResponse execute(ModelNode request, boolean useWaitCursor) throws IOException {

        if(request.get(Util.OPERATION).asString().equals(Util.COMPOSITE) &&
                (!request.get(Util.STEPS).isDefined() || request.get(Util.STEPS).asList().isEmpty())) {
            return OperationResponse.Factory.createSimple(new ModelNode("WARN: no request was sent as there were no server-side operations to execute"));
        }

        try {
            if (useWaitCursor) {
                cliGuiCtx.getMainWindow().setCursor(Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR));
            }
            return client.get().executeOperation(OperationBuilder.create(request).build(), OperationMessageHandler.DISCARD);
        } finally {
            if (useWaitCursor) {
                cliGuiCtx.getMainWindow().setCursor(Cursor.getDefaultCursor());
            }
        }
    }
 
Example 7
Source Project: javagame   Source File: DQC.java    License: MIT License 6 votes vote down vote up
/**
 * �t���X�N���[�����[�h�̏�����
 * 
 */
private void initFullScreen() {
    GraphicsEnvironment env = GraphicsEnvironment
            .getLocalGraphicsEnvironment();
    device = env.getDefaultScreenDevice();

    // �^�C�g���o�[������
    setUndecorated(true);
    // �}�E�X�J�[�\��������
    Cursor cursor = Toolkit.getDefaultToolkit().createCustomCursor(
            new BufferedImage(1, 1, BufferedImage.TYPE_INT_ARGB),
            new Point(), "");
    setCursor(cursor);

    if (!device.isFullScreenSupported()) {
        System.out.println("�t���X�N���[�����[�h�̓T�|�[�g����Ă��܂���B");
        System.exit(0);
    }

    device.setFullScreenWindow(this); // �t���X�N���[�����I

    DisplayMode mode = new DisplayMode(640, 480, 16,
            DisplayMode.REFRESH_RATE_UNKNOWN);
    device.setDisplayMode(mode);
}
 
Example 8
Source Project: megamek   Source File: BoardEditor.java    License: GNU General Public License v2.0 6 votes vote down vote up
/**
 * Saves the board in PNG image format.
 */
private void boardSaveImage(boolean ignoreUnits) {
    if (curfileImage == null) {
        boardSaveAsImage(ignoreUnits);
        return;
    }
    JDialog waitD = new JDialog(frame, Messages.getString("BoardEditor.waitDialog.title")); //$NON-NLS-1$
    waitD.add(new JLabel(Messages.getString("BoardEditor.waitDialog.message"))); //$NON-NLS-1$
    waitD.setSize(250, 130);
    // move to middle of screen
    waitD.setLocation(
            (frame.getSize().width / 2) - (waitD.getSize().width / 2),
            (frame.getSize().height / 2) - (waitD.getSize().height / 2));
    waitD.setVisible(true);
    frame.setCursor(Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR));
    waitD.setCursor(Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR));
    // save!
    try {
        ImageIO.write(bv.getEntireBoardImage(ignoreUnits), "png", curfileImage);
    } catch (IOException e) {
        e.printStackTrace();
    }
    waitD.setVisible(false);
    frame.setCursor(Cursor.getDefaultCursor());
}
 
Example 9
Source Project: jdk8u_jdk   Source File: XComponentPeer.java    License: GNU General Public License v2.0 6 votes vote down vote up
public void pSetCursor(Cursor cursor, boolean ignoreSubComponents) {
    XToolkit.awtLock();
    try {
        long xcursor = XGlobalCursorManager.getCursor(cursor);

        XSetWindowAttributes xwa = new XSetWindowAttributes();
        xwa.set_cursor(xcursor);

        long valuemask = XConstants.CWCursor;

        XlibWrapper.XChangeWindowAttributes(XToolkit.getDisplay(),getWindow(),valuemask,xwa.pData);
        XlibWrapper.XFlush(XToolkit.getDisplay());
        xwa.dispose();
    } finally {
        XToolkit.awtUnlock();
    }
}
 
Example 10
Source Project: ET_Redux   Source File: EvolutionPlotPanel.java    License: Apache License 2.0 6 votes vote down vote up
/**
 *
 * @param evt
 */
@Override
public void mouseMoved(MouseEvent evt) {
    int myX = evt.getX();
    int myY = evt.getY();

    eastResizing = isEastResize(myX);
    southResizing = isSouthResize(myY);

    setCursor(Cursor.getDefaultCursor());
    if (eastResizing ^ southResizing) {
        if (eastResizing) {
            setCursor(Cursor.getPredefinedCursor(Cursor.E_RESIZE_CURSOR));
        } else {
            setCursor(Cursor.getPredefinedCursor(Cursor.S_RESIZE_CURSOR));
        }
    }

    if (eastResizing && southResizing) {
        setCursor(Cursor.getPredefinedCursor(Cursor.SE_RESIZE_CURSOR));
    }
}
 
Example 11
Source Project: tn5250j   Source File: TN5250jSplashScreen.java    License: GNU General Public License v2.0 6 votes vote down vote up
/**
 * This method will show or hide the splash screen.  Once the splash
 * screen is hidden, the splash screen window will be disposed. This means
 * the splash screen cannot become visible again.
 */
public void setVisible(boolean show) {
   if (show == true && dialog != null && f != null && !dialog.isVisible()) {
      dialog.setVisible(true);
   }
   else {

      if (dialog != null) {
         updateProgress(steps + 1);
         dialog.setCursor(Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR));
         dialog.dispose();
      }
      if (f != null) {
         f.dispose();
      }
      dialog = null;
      f = null;
   }
}
 
Example 12
Source Project: TencentKona-8   Source File: RangeSlider.java    License: GNU General Public License v2.0 6 votes vote down vote up
public void mouseMoved(MouseEvent e) {
    isOverBar = false;
    if (model == null) {
        return;
    }


    Point p = e.getPoint();
    if (isOverFirstPosition(p) || isOverSecondPosition(p)) {
        setCursor(Cursor.getPredefinedCursor(Cursor.E_RESIZE_CURSOR));
    } else if (isOverSelection(p)) {
        isOverBar = true;
        setCursor(Cursor.getPredefinedCursor(Cursor.HAND_CURSOR));
    } else {
        this.setCursor(Cursor.getDefaultCursor());
    }
    repaint();
}
 
Example 13
Source Project: TencentKona-8   Source File: XComponentPeer.java    License: GNU General Public License v2.0 6 votes vote down vote up
public void pSetCursor(Cursor cursor, boolean ignoreSubComponents) {
    XToolkit.awtLock();
    try {
        long xcursor = XGlobalCursorManager.getCursor(cursor);

        XSetWindowAttributes xwa = new XSetWindowAttributes();
        xwa.set_cursor(xcursor);

        long valuemask = XConstants.CWCursor;

        XlibWrapper.XChangeWindowAttributes(XToolkit.getDisplay(),getWindow(),valuemask,xwa.pData);
        XlibWrapper.XFlush(XToolkit.getDisplay());
        xwa.dispose();
    } finally {
        XToolkit.awtUnlock();
    }
}
 
Example 14
Source Project: audiveris   Source File: Rubber.java    License: GNU Affero General Public License v3.0 6 votes vote down vote up
private void setCursor (MouseEvent e)
{
    if (isDragWanted(e)) {
        e.getComponent().setCursor(Cursor.getPredefinedCursor(Cursor.MOVE_CURSOR));
    } else if (isAdditionWanted(e)) {
        e.getComponent().setCursor(Cursor.getPredefinedCursor(Cursor.CROSSHAIR_CURSOR));
    } else if (isContextWanted(e)) {
        e.getComponent().setCursor(Cursor.getPredefinedCursor(Cursor.HAND_CURSOR));
    } else if (isRubberWanted(e)) {
        e.getComponent().setCursor(Cursor.getPredefinedCursor(Cursor.SE_RESIZE_CURSOR));
    } else if (isRezoomWanted(e)) {
        e.getComponent().setCursor(Cursor.getPredefinedCursor(Cursor.SE_RESIZE_CURSOR));
    } else {
        e.getComponent().setCursor(Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR));
    }
}
 
Example 15
Source Project: ET_Redux   Source File: DataPresentationModeChooserPanel.java    License: Apache License 2.0 6 votes vote down vote up
/**
 *
 * @param sampleSessionDataView
 * @param dataPresentationMode
 * @param timeArray
 * @param bounds
 * @param meanOnly the value of meanOnly
 */
public DataPresentationModeChooserPanel(//
        JLayeredPane sampleSessionDataView, //
        DataPresentationModeEnum dataPresentationMode, //
        double[] timeArray, //
        Rectangle bounds, //
        boolean meanOnly) {

    super(bounds);

    this.sampleSessionDataView = sampleSessionDataView;

    this.dataPresentationMode = dataPresentationMode;

    this.myOnPeakNormalizedAquireTimes = timeArray;
    this.meanOnly = meanOnly;

    setOpaque(true);
    setBackground(new Color(250, 240, 230));
    setCursor(Cursor.getDefaultCursor());

    dataViewModeButtonGroup = new ButtonGroup();
}
 
Example 16
protected void setNativeCursor(long nativeCtxt, Cursor c, int cType) {
    assert XToolkit.isAWTLockHeldByCurrentThread();

    if (c == null) {
        return;
    }

    long xcursor = XGlobalCursorManager.getCursor(c);

    if (xcursor == 0) {
        return;
    }

    XlibWrapper.XChangeActivePointerGrab(XToolkit.getDisplay(),
                                         GRAB_EVENT_MASK,
                                         xcursor,
                                         XConstants.CurrentTime);
}
 
Example 17
Source Project: MobyDroid   Source File: JPanel_FileBrowser.java    License: Apache License 2.0 6 votes vote down vote up
/**
 * Disable the User Interface.
 */
public void disableUI() {
    // turn on the wait cursor
    setCursor(Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR));
    // hide jTable (disabling show out of bound exception ! ! !)
    jTable_Browser.setVisible(false);
    // disable input
    jComboBox_Path.setEnabled(false);
    jTextField_Filter.setEnabled(false);
    // disable buttons
    mButton_Copy.setEnabled(false);
    mButton_Delete.setEnabled(false);
    mButton_GoUp.setEnabled(false);
    mButton_MakeDirectory.setEnabled(false);
    mButton_MakeFile.setEnabled(false);
    mButton_Paste.setEnabled(false);
    mButton_Refresh.setEnabled(false);
    mButton_Rename.setEnabled(false);
}
 
Example 18
Source Project: MeteoInfo   Source File: FrmMain.java    License: GNU Lesser General Public License v3.0 6 votes vote down vote up
/**
 * Load an application
 *
 * @param plugin Application
 */
public void loadApplication(Application plugin) {
    this.setCursor(Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR));
    try {
        PythonInterpreter interp = this.getConsoleDockable().getInterpreter();
        String path = plugin.getPath();
        interp.exec("import " + path);
        interp.exec("from " + path + ".loadApp import LoadApp");
        PyObject loadClass = interp.get("LoadApp");
        PyObject loadObj = loadClass.__call__();
        IPlugin instance = (IPlugin) loadObj.__tojava__(IPlugin.class);
        instance.setApplication(FrmMain.this);
        instance.setName(plugin.getName());
        plugin.setPluginObject(instance);
        plugin.setLoad(true);
        instance.load();
    } catch (Exception e) {
        e.printStackTrace();
    }
    this.setCursor(Cursor.getDefaultCursor());
}
 
Example 19
public void stopProgress() {
  stopRunner();

  updateProgress(0);
  perc = 0;
  msg  = "";
  repaint();

  setCursor(Cursor.DEFAULT_CURSOR);
}
 
Example 20
Source Project: sc2gears   Source File: BrowserDialog.java    License: Apache License 2.0 5 votes vote down vote up
/**
 * Completes the initialization of the dialog.
 * @param url           URL of the page to be displayed
 * @param preferredSize optional preferred size of the browser component
 */
private void completeInit( final String url, final Dimension preferredSize ) {
	final JEditorPane browserPane = GuiUtils.createEditorPane();
	browserPane.setPreferredSize( preferredSize );
	final JScrollPane scrollPane = new JScrollPane( browserPane );
	scrollPane.setBorder( BorderFactory.createEmptyBorder( 10, 10, 10, 10 ) );
	getContentPane().add( scrollPane, BorderLayout.CENTER );
	
	final JButton okButton = createCloseButton( "button.close" );
	getContentPane().add( GuiUtils.wrapInPanel( okButton ), BorderLayout.SOUTH );
	
	// Load page content in a new thread to not block the AWT event dispatcher thread
	new NormalThread( "Browser dialog content loader" ) {
		@Override
           public void run() {
			try {
				browserPane.setCursor( Cursor.getPredefinedCursor( Cursor.WAIT_CURSOR ) );
		        browserPane.setPage( url );
	        } catch ( final IOException ie ) {
		        ie.printStackTrace();
		        browserPane.setContentType( "text/html" );
		        browserPane.setText( "<html><body style='font-family:arial;font-size:10px;font-style:italic;background:#ffffff;'>"
						+ "<p>This content is currently unavailable. Please try again later.</p></body></html>" );
	        } finally {
				browserPane.setCursor( null );
	        }
           }
	}.start();
	
	packAndShow( okButton, false );
}
 
Example 21
Source Project: netbeans   Source File: NewConnectionPanel.java    License: Apache License 2.0 5 votes vote down vote up
public void setWaitingState(boolean wait) {
    Component rootPane = getRootPane();
    enableInput(! wait);
    if (rootPane != null) {
        rootPane.setCursor(wait ? Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR) : null);
    }
}
 
Example 22
Source Project: spotbugs   Source File: MainFrame.java    License: GNU Lesser General Public License v2.1 5 votes vote down vote up
void updateProjectAndBugCollection(BugCollection bugCollection) {

        if (bugCollection != null) {
            displayer.clearCache();
            BugSet bs = new BugSet(bugCollection);
            // Don't clear data, the data's correct, just get the tree off the
            // listener lists.
            BugTreeModel model = (BugTreeModel) mainFrameTree.getTree().getModel();
            model.getOffListenerList();
            model.changeSet(bs);
            // curProject=BugLoader.getLoadedProject();
            setProjectChanged(true);
        }
        setCursor(new Cursor(Cursor.DEFAULT_CURSOR));
    }
 
Example 23
Source Project: nordpos   Source File: JRViewer.java    License: GNU General Public License v3.0 5 votes vote down vote up
public void mouseMoved(MouseEvent e)
{
	JRPrintImageAreaHyperlink imageArea = getImageMapArea(e);
	if (imageArea != null
			&& imageArea.getHyperlink().getHyperlinkTypeValue() != HyperlinkTypeEnum.NONE)
	{
		e.getComponent().setCursor(Cursor.getPredefinedCursor(Cursor.HAND_CURSOR));
	}
	else
	{
		e.getComponent().setCursor(Cursor.getDefaultCursor());
	}
}
 
Example 24
Source Project: netbeans   Source File: TooltipWindow.java    License: Apache License 2.0 5 votes vote down vote up
public void mouseMoved(MouseEvent e) {
    if (e.getSource().equals(textPane)) {
        textPane.setCursor(Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR));
        linkerSupport.computeBounds(textPane, 0);
        linkerSupport.mouseMoved(e.getPoint(), textPane, messageOffset);
    }
    textPane.setToolTipText("");  // NOI18N
}
 
Example 25
Source Project: stendhal   Source File: CursorRepository.java    License: GNU General Public License v2.0 5 votes vote down vote up
public Cursor get(StendhalCursor stendhalCursor) {
	Cursor res = cursorMap.get(stendhalCursor);
	if (res == null) {
		res = loadCursor(stendhalCursor);
	}
	return res;
}
 
Example 26
Source Project: ET_Redux   Source File: YAxisView.java    License: Apache License 2.0 5 votes vote down vote up
/**
 *
 *
 * @param rawDataModelViews
 * @param sampleSessionDataView
 * @param backgroundColor
 * @param minY
 * @param maxY
 * @param bounds
 * @param floating
 * @param forStandards the value of forStandards
 */
public YAxisView(//
        AbstractRawDataView[] rawDataModelViews, //
        JLayeredPane sampleSessionDataView, //
        Color backgroundColor, //
        double minY, //
        double maxY, //
        Rectangle bounds, //
        boolean floating, //
        boolean forStandards) {
    super(bounds);

    this.rawDataModelViews = rawDataModelViews;
    this.dataViewsOverlay = null;
    this.sampleSessionDataView = sampleSessionDataView;
    this.backgroundColor = backgroundColor;
    this.yOnMousePress = 0;
    this.minY = minY;
    this.maxY = maxY;
    this.floating = floating;
    this.forStandards = forStandards;

    // horizontal layout arbitrarily fixed
    this.minX = 0;
    this.maxX = bounds.getWidth();//100;

    setOpaque(true);
    setBackground(Color.white);

    setBounds(bounds);
    graphWidth = bounds.width - leftMargin;
    graphHeight = bounds.height - topMargin;

    addMeAsMouseListener();
    addMeAsMouseMotionListener();

    setCursor(Cursor.getPredefinedCursor(Cursor.HAND_CURSOR));
}
 
Example 27
Source Project: Course_Generator   Source File: frmMain.java    License: GNU General Public License v3.0 5 votes vote down vote up
/**
 * Save the selected data to disk in CGX format
 */
private void SavePartCGX() {
	String s;

	if (Track.data.isEmpty())
		return;

	s = Utils.SaveDialog(this, Settings.previousCGXDirectory, "", ".cgx", bundle.getString("frmMain.CGXFile"), true,
			bundle.getString("frmMain.FileExist"));

	if (!s.isEmpty()) {
		setCursor(Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR));

		// -- Save track
		int start = panelTrackData.getSelectedRow();
		int end = start + panelTrackData.getSelectedRowCount() - 1;

		Track.SaveCGX(s, start, end, false);
		// -- Store the directory
		Settings.previousCGXDirectory = Utils.GetDirFromFilename(s);

		// -- Update GPX MRU
		AddMruCGX(s);
		RefreshMruCGX();

		// -- We don't reset the track modified flag because we save only a
		// part of the track!
		Track.isModified = false;

		// -- Refresh info panel
		RefreshStatusbar(Track);

		setCursor(Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR));
	}
}
 
Example 28
Source Project: WhiteRabbit   Source File: RabbitInAHatMain.java    License: Apache License 2.0 5 votes vote down vote up
private void doGenerateEtlHtmlDoc() {
	String directoryName = chooseSaveDirectory();
	if (directoryName != null) {
		frame.setCursor(Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR));
		ETLMarkupDocumentGenerator generator = new ETLMarkupDocumentGenerator(ObjectExchange.etl);
		generator.generate(directoryName, DocumentType.HTML);
		frame.setCursor(Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR));
	}
}
 
Example 29
Source Project: netbeans   Source File: MultiSplitPane.java    License: Apache License 2.0 5 votes vote down vote up
@Override
public void mouseReleased(MouseEvent e) {
    if( null == draggingDivider )
        return;
    
    final Point p = new Point( e.getPoint() );
    draggingDivider.finishDraggingTo( p );
    draggingDivider = null;
    setCursor( Cursor.getDefaultCursor() );
    e.consume();
}
 
Example 30
public static void main(final String[] args) throws AWTException {
    // This list is copied from cursors.properties
    String[] names = {"CopyDrop.32x32", "MoveDrop.32x32", "LinkDrop.32x32",
                      "CopyNoDrop.32x32", "MoveNoDrop.32x32",
                      "LinkNoDrop.32x32", "Invalid.32x32"};
    for (final String name : names) {
        if (Cursor.getSystemCustomCursor(name) == null) {
            throw new RuntimeException("Cursor is null: " + name);
        }
    }
    System.out.println("Test passed");
}