tableHistoryViewer = createTableHistory(sashForm); innerSashForm = new SashForm(sashForm, SWT.HORIZONTAL); textViewer = createText(innerSashForm); Font font = PlatformUI.getWorkbench().getThemeManager().getCurrentTheme().getFontRegistry().get(ISVNUIConstants.SVN_COMMENT_FONT); if (font != null) textViewer.getTextWidget().setFont(font); textViewer.getTextWidget().addMouseListener(new MouseAdapter() { public void mouseDown(MouseEvent e) { if (e.button != 1) { return; } mouseDown = true; } public void mouseUp(MouseEvent e) { mouseDown = false; StyledText text = (StyledText)e.widget; int offset = text.getCaretOffset(); if (dragEvent) {  dragEvent = false; if (linkList != null && linkList.isLinkAt(offset)) { text.setCursor(handCursor); } } else { if (linkList != null && linkList.isLinkAt(offset)) { text.setCursor(busyCursor); openLink(linkList.getLinkAt(offset)); text.setCursor(null); } } } });
	public void createPartControl(Composite parent) {	    busyCursor = new Cursor(parent.getDisplay(), SWT.CURSOR_WAIT);	    handCursor = new Cursor(parent.getDisplay(), SWT.CURSOR_HAND);		settings = SVNUIPlugin.getPlugin().getPreferenceStore();		this.linkingEnabled = settings.getBoolean(ISVNUIConstants.PREF_HISTORY_VIEW_EDITOR_LINKING);		sashForm = new SashForm(parent, SWT.VERTICAL);		sashForm.setLayoutData(new GridData(GridData.FILL_BOTH));		tableHistoryViewer = createTableHistory(sashForm);		innerSashForm = new SashForm(sashForm, SWT.HORIZONTAL);		textViewer = createText(innerSashForm);		Font font = PlatformUI.getWorkbench().getThemeManager().getCurrentTheme().getFontRegistry().get(ISVNUIConstants.SVN_COMMENT_FONT);		if (font != null) textViewer.getTextWidget().setFont(font);		textViewer.getTextWidget().addMouseListener(new MouseAdapter() {			public void mouseDown(MouseEvent e) {				if (e.button != 1) {					return;				}				mouseDown = true;			}			public void mouseUp(MouseEvent e) {				mouseDown = false;				StyledText text = (StyledText)e.widget;				int offset = text.getCaretOffset();				if (dragEvent) {					// don't activate a link during a drag/mouse up operation					dragEvent = false;					if (linkList != null && linkList.isLinkAt(offset)) {						text.setCursor(handCursor);					}				} else {					if (linkList != null && linkList.isLinkAt(offset)) {							text.setCursor(busyCursor);						openLink(linkList.getLinkAt(offset));						text.setCursor(null);					}				}			}					});				textViewer.getTextWidget().addMouseMoveListener(new MouseMoveListener() {            public void mouseMove(MouseEvent e) {    			// Do not change cursor on drag events    			if (mouseDown) {    				if (!dragEvent) {    					StyledText text = (StyledText)e.widget;    					text.setCursor(null);    				}    				dragEvent = true;    				return;    			}    			StyledText text = (StyledText)e.widget;    			int offset = -1;    			try {    				offset = text.getOffsetAtLocation(new Point(e.x, e.y));    			} catch (IllegalArgumentException ex) {}    			if (offset == -1)    				text.setCursor(null);    			else if (linkList != null && linkList.isLinkAt(offset))     				text.setCursor(handCursor);    			else     				text.setCursor(null);                            }		    		});		        tableChangePathViewer = createTableChangePath(innerSashForm);		sashForm.setWeights(new int[] { 70, 30 });		contributeActions();		// set F1 help		WorkbenchHelp.setHelp(sashForm, IHelpContextIds.RESOURCE_HISTORY_VIEW);		initDragAndDrop();		// add listener for editor page activation - this is to support editor linking		getSite().getPage().addPartListener(partListener);  		 		 getSite().getPage().addPartListener(partListener2);                setViewerVisibility();	}