diff --git a/Core/Handling/TweetDeckBridge.cs b/Core/Handling/TweetDeckBridge.cs index a250e95b..87a17d6b 100644 --- a/Core/Handling/TweetDeckBridge.cs +++ b/Core/Handling/TweetDeckBridge.cs @@ -1,4 +1,6 @@ -namespace TweetDick.Core.Handling{ +using System.Diagnostics; + +namespace TweetDick.Core.Handling{ class TweetDeckBridge{ private readonly FormBrowser form; @@ -30,8 +32,12 @@ public void OnTweetPopup(string tweetHtml, int tweetCharacters){ }); } + public void OpenBrowser(string url){ + Process.Start(url); + } + public void Log(string data){ - System.Diagnostics.Debug.WriteLine(data); + Debug.WriteLine(data); } } } diff --git a/Resources/code.js b/Resources/code.js index c0255a9b..34fc94c8 100644 --- a/Resources/code.js +++ b/Resources/code.js @@ -175,4 +175,12 @@ }); $TD.loadNotificationHeadContents(getNotificationHeadContents()); + + // + // Block: + // + $(document.body).delegate("a[target='_blank']","click",function(e){ + $TD.openBrowser($(this).attr("href")); + e.preventDefault(); + }); })($,$TD);