public void handleEvent( Event event ) { cancelButton.setImage( new Image( display, GoogleAuthorizationDialog.class.getResourceAsStream( "/images/close-button-hover.png" ) ) ); cancelButton.setCursor( new Cursor( display, SWT.CURSOR_HAND ) ); } } );
public void setCursor(Cursor c) { super.setCursor(c); label.setCursor(c); }
public void setCursor(Cursor cursor) { if (isDisposed() || cursor == null || cursor.isDisposed()) { return; } label.setCursor(cursor); }
public static void makeLinkedLabel(Label label, Runnable runnable) { label.setCursor(label.getDisplay().getSystemCursor(SWT.CURSOR_HAND)); label.setForeground(Colors.blue); label.addMouseListener(new MouseAdapter() { @Override public void mouseDoubleClick(MouseEvent arg0) { runnable.run(); } @Override public void mouseUp(MouseEvent arg0) { runnable.run(); } }); } }
public LinkParameter( Composite composite, final String name_resource) { super(name_resource); link_label = new Label(composite, SWT.NULL); Messages.setLanguageText(link_label, name_resource); link_label.setCursor(link_label.getDisplay().getSystemCursor(SWT.CURSOR_HAND)); link_label.setForeground(Colors.blue); link_label.addMouseListener(new MouseAdapter() { @Override public void mouseDoubleClick(MouseEvent arg0) { fire(); } @Override public void mouseUp(MouseEvent arg0) { fire(); } }); }
link_label.setText( MessageText.getString( "ConfigView.label.please.visit.here" )); link_label.setCursor(link_label.getDisplay().getSystemCursor(SWT.CURSOR_HAND)); link_label.setForeground(Colors.blue); link_label.setBackground( Colors.white );
serviceUrl.setLayoutData(gridData); serviceUrl.setForeground(Colors.blue); serviceUrl.setCursor(handCursor); serviceUrl.addMouseListener(new MouseAdapter() { @Override
pop_out.setLayoutData(grid_data); pop_out.setCursor(pop_out.getDisplay().getSystemCursor(SWT.CURSOR_HAND));
linkLabel.setText( MessageText.getString( "ConfigView.label.please.visit.here" )); linkLabel.setData( links[userMode] ); linkLabel.setCursor(linkLabel.getDisplay().getSystemCursor(SWT.CURSOR_HAND)); linkLabel.setForeground(Colors.blue); gridData = new GridData(GridData.FILL_HORIZONTAL);
linkLabel.setText( Constants.APP_NAME + " Wiki Speed Test" ); linkLabel.setData( Constants.URL_WIKI + "w/Speed_Test_FAQ"); linkLabel.setCursor(display.getSystemCursor(SWT.CURSOR_HAND)); linkLabel.setForeground(Colors.blue); azwGridData = new GridData();
linkLabel.setText(MessageText.getString("ConfigView.label.please.visit.here")); linkLabel.setData( Constants.URL_WIKI+ "w/Public_Private_Keys"); linkLabel.setCursor(display.getSystemCursor(SWT.CURSOR_HAND)); linkLabel.setForeground(Colors.blue); gridData = new GridData();
socksMore.setText( MessageText.getString( "label.more") + "..." ); socksMore.setLayoutData(gridData); socksMore.setCursor(socksMore.getDisplay().getSystemCursor(SWT.CURSOR_HAND)); socksMore.setForeground(Colors.blue); socksMore.addMouseListener(new MouseAdapter() {
fMessageText.setCursor(fProposalShell.getDisplay().getSystemCursor(SWT.CURSOR_HAND)); fMessageText.addMouseListener(new MouseAdapter() { @Override
fMessageText.setCursor(fProposalShell.getDisplay().getSystemCursor(SWT.CURSOR_HAND)); fMessageText.addMouseListener(new MouseAdapter() { @Override
/** * Alters a given label to make it appear like a launchable * link. This should preferably be done after all other changes * have been performed on the label - especially the setting of * the label's text. */ public static void makeLinkedLabel(Label label, String hyperlink) { label.setData(hyperlink); String tooltip = label.getToolTipText(); // We only set a tooltip if one isn't set already and it isn't // identical to the label text. if (tooltip == null && !hyperlink.equals(label.getText())) { Utils.setTT(label,hyperlink.replaceAll("&", "&&")); } label.setCursor(label.getDisplay().getSystemCursor(SWT.CURSOR_HAND)); label.setForeground(Colors.blue); label.addMouseListener(new MouseAdapter() { @Override public void mouseDoubleClick(MouseEvent arg0) { Utils.launch((String) ((Label) arg0.widget).getData()); } @Override public void mouseUp(MouseEvent arg0) { Utils.launch((String) ((Label) arg0.widget).getData()); } }); ClipboardCopy.addCopyToClipMenu( label ); }
linkLabel.setText( MessageText.getString( messTexts[userMode] ) ); linkLabel.setData( links[userMode] ); linkLabel.setCursor(display.getSystemCursor(SWT.CURSOR_HAND)); linkLabel.setForeground(Colors.blue); gridData = new GridData(GridData.FILL_HORIZONTAL); linkLabel1.setText( (userMode == 1)?MessageText.getString(messTexts[3]):""); linkLabel1.setData( links[3] ); linkLabel1.setCursor(display.getSystemCursor(SWT.CURSOR_HAND)); linkLabel1.setForeground(Colors.blue); gridData = new GridData(GridData.FILL_HORIZONTAL);
linkLabel.setText(MessageText.getString("ConfigView.label.please.visit.here")); linkLabel.setData( Constants.URL_WIKI + "w/Downloading_Rules"); linkLabel.setCursor(linkLabel.getDisplay().getSystemCursor(SWT.CURSOR_HAND)); linkLabel.setForeground(Colors.blue); gridData = new GridData();
final Image rss_image_gray = ImageLoader.getInstance().getImage("image.sidebar.subscriptions-gray"); rss_button.setImage(rss_image_gray); rss_button.setCursor(parent.getDisplay().getSystemCursor(SWT.CURSOR_HAND)); GridData grid_data = new GridData(GridData.FILL_HORIZONTAL ); grid_data.widthHint = rss_image_gray.getBounds().width;
label.setCursor(c.getDisplay().getSystemCursor(SWT.CURSOR_HAND));