mirror of
https://github.com/chylex/TweetDuck.git
synced 2025-04-21 06:15:47 +02:00
Make links open in the user's browser instead of a new window
This commit is contained in:
parent
7db3c4fcba
commit
939fef42d6
@ -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);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -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);
|
||||
|
Loading…
Reference in New Issue
Block a user