File tree Expand file tree Collapse file tree 1 file changed +2
-7
lines changed
PluginsAndFeatures/azure-toolkit-for-intellij/src/com/microsoft/azuretools/ijidea/ui Expand file tree Collapse file tree 1 file changed +2
-7
lines changed Original file line number Diff line number Diff line change 2222
2323package com .microsoft .azuretools .ijidea .ui ;
2424
25+ import com .intellij .ide .BrowserUtil ;
2526import com .intellij .openapi .application .ApplicationManager ;
2627import com .intellij .openapi .application .ModalityState ;
2728import com .microsoft .aad .adal4j .AdalErrorCode ;
4041import javax .swing .JPanel ;
4142import javax .swing .UIManager ;
4243import javax .swing .event .HyperlinkEvent ;
43- import javax .swing .text .html .HTMLDocument ;
4444import java .awt .Color ;
4545import java .awt .Desktop ;
4646import java .awt .Font ;
5050import java .awt .datatransfer .StringSelection ;
5151import java .awt .event .WindowEvent ;
5252import java .io .IOException ;
53- import java .net .URI ;
5453import java .net .URISyntaxException ;
5554import java .util .concurrent .ExecutionException ;
5655import java .util .concurrent .Future ;
@@ -150,11 +149,7 @@ protected void doOKAction() {
150149 final StringSelection selection = new StringSelection (deviceCode .getUserCode ());
151150 final Clipboard clipboard = Toolkit .getDefaultToolkit ().getSystemClipboard ();
152151 clipboard .setContents (selection , selection );
153- try {
154- Desktop .getDesktop ().browse (new URI (deviceCode .getVerificationUrl ()));
155- } catch (IOException | URISyntaxException e ) {
156- e .printStackTrace ();
157- }
152+ BrowserUtil .open (deviceCode .getVerificationUrl ());
158153 }
159154
160155 private void closeDialog () {
You can’t perform that action at this time.
0 commit comments