[Tween-svn] [1548] 起動時のTwitterアクセス権限チェックでread-write ( xAuth) だった場合の再認証を促すメッセージを変更。その際、設定画面を開くように。認証中のPIN入力を促すメッセージ削除。設定画面のTopMostを制御。

Back to archive index

svnno****@sourc***** svnno****@sourc*****
2011年 6月 2日 (木) 01:25:15 JST


Revision: 1548
          http://sourceforge.jp/projects/tween/svn/view?view=rev&revision=1548
Author:   kiri_feather
Date:     2011-06-02 01:25:14 +0900 (Thu, 02 Jun 2011)

Log Message:
-----------
起動時のTwitterアクセス権限チェックでread-write(xAuth)だった場合の再認証を促すメッセージを変更。その際、設定画面を開くように。認証中のPIN入力を促すメッセージ削除。設定画面のTopMostを制御。

Modified Paths:
--------------
    trunk/Tween/AppendSettingDialog.vb
    trunk/Tween/My Project/Resources.Designer.vb
    trunk/Tween/My Project/Resources.en.resx
    trunk/Tween/My Project/Resources.resx
    trunk/Tween/Tween.vb
    trunk/Tween/Twitter.vb


-------------- next part --------------
Modified: trunk/Tween/AppendSettingDialog.vb
===================================================================
--- trunk/Tween/AppendSettingDialog.vb	2011-05-30 15:46:05 UTC (rev 1547)
+++ trunk/Tween/AppendSettingDialog.vb	2011-06-01 16:25:14 UTC (rev 1548)
@@ -468,7 +468,7 @@
             If TwitterApiInfo.AccessLevel = ApiAccessLevel.ReadWrite Then
                 Me.AuthStateLabel.Text += "(xAuth)"
             ElseIf TwitterApiInfo.AccessLevel = ApiAccessLevel.ReadWriteAndDirectMessage Then
-                Me.AuthStateLabel.Text += "(oAuth)"
+                Me.AuthStateLabel.Text += "(OAuth)"
             End If
             Me.AuthUserLabel.Text = tw.Username
         End If
@@ -2138,7 +2138,6 @@
         Dim pinPageUrl As String = ""
         Dim rslt As String = tw.StartAuthentication(pinPageUrl)
         If String.IsNullOrEmpty(rslt) Then
-            MessageBox.Show(My.Resources.AuthorizeButton_Click5, "Authenticate", MessageBoxButtons.OK)
             OpenUrl(pinPageUrl)
             Return True
         Else
@@ -2181,7 +2180,7 @@
             If TwitterApiInfo.AccessLevel = ApiAccessLevel.ReadWrite Then
                 Me.AuthStateLabel.Text += "(xAuth)"
             ElseIf TwitterApiInfo.AccessLevel = ApiAccessLevel.ReadWriteAndDirectMessage Then
-                Me.AuthStateLabel.Text += "(oAuth)"
+                Me.AuthStateLabel.Text += "(OAuth)"
             End If
             Return True
         Else
@@ -2227,7 +2226,7 @@
             If TwitterApiInfo.AccessLevel = ApiAccessLevel.ReadWrite Then
                 Me.AuthStateLabel.Text += "(xAuth)"
             ElseIf TwitterApiInfo.AccessLevel = ApiAccessLevel.ReadWriteAndDirectMessage Then
-                Me.AuthStateLabel.Text += "(oAuth)"
+                Me.AuthStateLabel.Text += "(OAuth)"
             End If
             Return True
         Else
@@ -2361,6 +2360,7 @@
             Thread.Sleep(10)
             If Me.Disposing OrElse Me.IsDisposed Then Exit Sub
         Loop Until Me.IsHandleCreated
+        Me.TopMost = Me.AlwaysTop
         CalcApiUsing()
     End Sub
 

Modified: trunk/Tween/My Project/Resources.Designer.vb
===================================================================
--- trunk/Tween/My Project/Resources.Designer.vb	2011-05-30 15:46:05 UTC (rev 1547)
+++ trunk/Tween/My Project/Resources.Designer.vb	2011-06-01 16:25:14 UTC (rev 1548)
@@ -260,15 +260,6 @@
         End Property
         
         '''<summary>
-        '''  PINを入力してください。 に類似しているローカライズされた文字列を検索します。
-        '''</summary>
-        Friend ReadOnly Property AuthorizeButton_Click5() As String
-            Get
-                Return ResourceManager.GetString("AuthorizeButton_Click5", resourceCulture)
-            End Get
-        End Property
-        
-        '''<summary>
         '''  認証サーバーに接続できませんでした。 に類似しているローカライズされた文字列を検索します。
         '''</summary>
         Friend ReadOnly Property AuthorizeButton_Click6() As String
@@ -1756,7 +1747,7 @@
         End Property
         
         '''<summary>
-        '''  再度認証が必要です。設定画面からいったん認証情報をクリアし、再認証してください。再認証するまでDMにはアクセスできません。 に類似しているローカライズされた文字列を検索します。
+        '''  Direct Messageの送受信をするため、もう一度認証処理をして下さい。 に類似しているローカライズされた文字列を検索します。
         '''</summary>
         Friend ReadOnly Property ReAuthorizeText() As String
             Get

Modified: trunk/Tween/My Project/Resources.en.resx
===================================================================
--- trunk/Tween/My Project/Resources.en.resx	2011-05-30 15:46:05 UTC (rev 1547)
+++ trunk/Tween/My Project/Resources.en.resx	2011-06-01 16:25:14 UTC (rev 1548)
@@ -978,9 +978,6 @@
   <data name="ListManageGetMoreUsers2" xml:space="preserve">
     <value>Get more(&amp;M)</value>
   </data>
-  <data name="AuthorizeButton_Click5" xml:space="preserve">
-    <value>Type PIN code.</value>
-  </data>
   <data name="AuthorizeButton_Click6" xml:space="preserve">
     <value>Failed to connect auth server.</value>
   </data>
@@ -990,4 +987,7 @@
   <data name="Unauthorized" xml:space="preserve">
     <value>You are not authorized.</value>
   </data>
+  <data name="ReAuthorizeText" xml:space="preserve">
+    <value>Please do Authentication processing to get/send Direct Messages again.</value>
+  </data>
 </root>
\ No newline at end of file

Modified: trunk/Tween/My Project/Resources.resx
===================================================================
--- trunk/Tween/My Project/Resources.resx	2011-05-30 15:46:05 UTC (rev 1547)
+++ trunk/Tween/My Project/Resources.resx	2011-06-01 16:25:14 UTC (rev 1548)
@@ -1096,9 +1096,6 @@
   <data name="ListManageGetMoreUsers2" xml:space="preserve">
     <value>さらに取得(&amp;M)</value>
   </data>
-  <data name="AuthorizeButton_Click5" xml:space="preserve">
-    <value>PINを入力してください。</value>
-  </data>
   <data name="AuthorizeButton_Click6" xml:space="preserve">
     <value>認証サーバーに接続できませんでした。</value>
   </data>
@@ -1109,6 +1106,6 @@
     <value>You are not authorized.</value>
   </data>
   <data name="ReAuthorizeText" xml:space="preserve">
-    <value>再度認証が必要です。設定画面からいったん認証情報をクリアし、再認証してください。再認証するまでDMにはアクセスできません。</value>
+    <value>Direct Messageの送受信をするため、もう一度認証処理をして下さい。</value>
   </data>
 </root>
\ No newline at end of file

Modified: trunk/Tween/Tween.vb
===================================================================
--- trunk/Tween/Tween.vb	2011-05-30 15:46:05 UTC (rev 1547)
+++ trunk/Tween/Tween.vb	2011-06-01 16:25:14 UTC (rev 1548)
@@ -811,7 +811,7 @@
         If tw.Username = "" Then
             saveRequired = True
             '設定せずにキャンセルされた場合はプログラム終了
-            If SettingDialog.ShowDialog() = Windows.Forms.DialogResult.Cancel Then
+            If SettingDialog.ShowDialog(Me) = Windows.Forms.DialogResult.Cancel Then
                 Application.Exit()  '強制終了
                 Exit Sub
             End If
@@ -3074,7 +3074,7 @@
         Dim uid As String = tw.Username.ToLower
 
         Try
-            result = SettingDialog.ShowDialog()
+            result = SettingDialog.ShowDialog(Me)
         Catch ex As Exception
             Exit Sub
         End Try
@@ -8488,6 +8488,7 @@
             ' 権限チェック read/write権限(xAuthで取得したトークン)の場合は再認証を促す
             If TwitterApiInfo.AccessLevel = ApiAccessLevel.ReadWrite Then
                 MessageBox.Show(My.Resources.ReAuthorizeText)
+                SettingStripMenuItem_Click(Nothing, Nothing)
             End If
 
         End If

Modified: trunk/Tween/Twitter.vb
===================================================================
--- trunk/Tween/Twitter.vb	2011-05-30 15:46:05 UTC (rev 1547)
+++ trunk/Tween/Twitter.vb	2011-06-01 16:25:14 UTC (rev 1548)
@@ -122,7 +122,7 @@
     End Function
 
     Public Function StartAuthentication(ByRef pinPageUrl As String) As String
-        'oAuth PIN Flow
+        'OAuth PIN Flow
         Dim res As Boolean
         Dim content As String = ""
 
@@ -202,7 +202,7 @@
     End Function
 
     Public Sub Initialize(ByVal token As String, ByVal tokenSecret As String, ByVal username As String)
-        'oAuth認証
+        'OAuth認証
         If String.IsNullOrEmpty(token) OrElse String.IsNullOrEmpty(tokenSecret) OrElse String.IsNullOrEmpty(username) Then
             Twitter.AccountState = ACCOUNT_STATE.Invalid
         End If



Tween-svn メーリングリストの案内
Back to archive index