OSDN Git Service

IDN形式の短縮URLを発言詳細部でクリックした時、開けなかった問題を修正
authorkiri_feather <kiri_feather@users.sourceforge.jp>
Thu, 3 Jun 2010 09:59:56 +0000 (09:59 +0000)
committerKimura Youichi <kim.upsilon@bucyou.net>
Sat, 18 Feb 2012 14:13:10 +0000 (23:13 +0900)
git-svn-id: http://svn.sourceforge.jp/svnroot/tween/trunk@431 e39ad16e-3079-482e-bb30-4b4d378143b6

Tween/Twitter.vb
Tween/WebBrowserController.vb

index 16a6193..56353bd 100644 (file)
@@ -205,7 +205,7 @@ Public Class Twitter
     Public Function PreProcessUrl(ByVal orgData As String) As String
         Dim posl1 As Integer
         Dim posl2 As Integer = 0
-        Dim IDNConveter As IdnMapping = New IdnMapping()
+        'Dim IDNConveter As IdnMapping = New IdnMapping()
         Dim href As String = "<a href="""
 
         Do While True
index 599b909..934b6d1 100644 (file)
@@ -326,7 +326,9 @@ Public Class InternetSecurityManager
             Implements WebBrowserAPI.IInternetSecurityManager.MapUrlToZone
         pdwZone = 0
         Try
-            Dim url As New Uri(pwszUrl)
+            Dim urlStr As String = IDNDecode(pwszUrl)
+            If urlStr Is Nothing Then Return WebBrowserAPI.URLPOLICY_DISALLOW
+            Dim url As New Uri(urlStr)
             If url.Scheme = "data" Then
                 Return WebBrowserAPI.URLPOLICY_DISALLOW
             End If