Skip to content

Commit

Permalink
Merge pull request #264 from sschaef/issue/show-url-hyperlinks
Browse files Browse the repository at this point in the history
Add URL hyperlink detector
  • Loading branch information
dragos committed Dec 17, 2012
2 parents 01d17ee + adcefc6 commit cc022b9
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ import scalariform.ScalaVersions
import org.eclipse.jface.text.DefaultTextHover
import scala.tools.eclipse.javaelements.ScalaCompilationUnit
import scala.tools.eclipse.ui.ScaladocAutoIndentStrategy
import org.eclipse.jface.text.hyperlink.URLHyperlinkDetector

class ScalaSourceViewerConfiguration(store: IPreferenceStore, scalaPreferenceStore: IPreferenceStore, editor: ITextEditor)
extends JavaSourceViewerConfiguration(JavaPlugin.getDefault.getJavaTextTools.getColorManager, store, editor, IJavaPartitions.JAVA_PARTITIONING) {
Expand Down Expand Up @@ -96,7 +97,7 @@ class ScalaSourceViewerConfiguration(store: IPreferenceStore, scalaPreferenceSto
val strategies = List(DeclarationHyperlinkDetector(), ImplicitHyperlinkDetector())
val detector = new CompositeHyperlinkDetector(strategies)
if (editor != null) detector.setContext(editor)
Array(detector)
Array(detector, new URLHyperlinkDetector())
}

def getCodeAssist: Option[ICodeAssist] = Option(editor) map { editor =>
Expand Down

0 comments on commit cc022b9

Please sign in to comment.