OSDN Git Service

自身が作成したリスト,購読しているリスト,フォローされているリストを表示できるように修正
authorspark_xp <spark_xp@d8c9ecd3-d47d-4367-8645-de82c00e513f>
Sun, 17 Oct 2010 13:15:11 +0000 (13:15 +0000)
committerspark_xp <spark_xp@d8c9ecd3-d47d-4367-8645-de82c00e513f>
Sun, 17 Oct 2010 13:15:11 +0000 (13:15 +0000)
git-svn-id: http://svn.sourceforge.jp/svnroot/nt-manager/NishioTweetManager/trunk@100 d8c9ecd3-d47d-4367-8645-de82c00e513f

src/twitter/gui/action/TweetMainAction.java
src/twitter/gui/form/NishioTweetManager.form
src/twitter/gui/form/NishioTweetManager.java
src/twitter/manage/TweetManager.java

index 87269ec..55b7659 100644 (file)
@@ -1349,6 +1349,14 @@ public class TweetMainAction {
     }
 
     /**
+     * 自身のスクリーン名を取得
+     * @return
+     */
+    public String getScreenName() {
+        return tweetManager.getScreenName();
+    }
+
+    /**
      * twitter全体からキーワード検索ダイアログを表示
      * @return
      */
index 64bc4ed..c1ee5d6 100644 (file)
             </MenuItem>
           </SubComponents>
         </Menu>
+        <Menu class="javax.swing.JMenu" name="jMenu7">
+          <Properties>
+            <Property name="mnemonic" type="int" value="76"/>
+            <Property name="text" type="java.lang.String" value="&#x30ea;&#x30b9;&#x30c8;(L)"/>
+          </Properties>
+          <SubComponents>
+            <MenuItem class="javax.swing.JMenuItem" name="jMenuItem25">
+              <Properties>
+                <Property name="text" type="java.lang.String" value="&#x81ea;&#x5206;&#x304c;&#x4f5c;&#x6210;&#x3057;&#x305f;&#x30ea;&#x30b9;&#x30c8;&#x4e00;&#x89a7;"/>
+              </Properties>
+              <Events>
+                <EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="jMenuItem25ActionPerformed"/>
+              </Events>
+            </MenuItem>
+            <MenuItem class="javax.swing.JMenuItem" name="jMenuItem24">
+              <Properties>
+                <Property name="text" type="java.lang.String" value="&#x8cfc;&#x8aad;&#x3057;&#x3066;&#x3044;&#x308b;&#x30ea;&#x30b9;&#x30c8;&#x4e00;&#x89a7;"/>
+              </Properties>
+              <Events>
+                <EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="jMenuItem24ActionPerformed"/>
+              </Events>
+            </MenuItem>
+            <MenuItem class="javax.swing.JMenuItem" name="jMenuItem26">
+              <Properties>
+                <Property name="text" type="java.lang.String" value="&#x81ea;&#x5206;&#x304c;&#x30d5;&#x30a9;&#x30ed;&#x30fc;&#x3055;&#x308c;&#x3066;&#x3044;&#x308b;&#x30ea;&#x30b9;&#x30c8;&#x4e00;&#x89a7;"/>
+              </Properties>
+              <Events>
+                <EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="jMenuItem26ActionPerformed"/>
+              </Events>
+            </MenuItem>
+          </SubComponents>
+        </Menu>
         <Menu class="javax.swing.JMenu" name="jMenu2">
           <Properties>
             <Property name="mnemonic" type="int" value="79"/>
               </Group>
               <Group type="102" alignment="0" attributes="0">
                   <Component id="jScrollPane9" min="-2" pref="53" max="-2" attributes="0"/>
-                  <EmptySpace pref="29" max="32767" attributes="0"/>
+                  <EmptySpace max="32767" attributes="0"/>
               </Group>
           </Group>
         </DimensionLayout>
index 8d057ee..c884eef 100644 (file)
@@ -213,6 +213,10 @@ public class NishioTweetManager extends javax.swing.JFrame {
         jMenu5 = new javax.swing.JMenu();
         jMenuItem6 = new javax.swing.JMenuItem();
         jMenuItem23 = new javax.swing.JMenuItem();
+        jMenu7 = new javax.swing.JMenu();
+        jMenuItem25 = new javax.swing.JMenuItem();
+        jMenuItem24 = new javax.swing.JMenuItem();
+        jMenuItem26 = new javax.swing.JMenuItem();
         jMenu2 = new javax.swing.JMenu();
         jMenuItem2 = new javax.swing.JMenuItem();
         jMenuItem4 = new javax.swing.JMenuItem();
@@ -865,6 +869,35 @@ public class NishioTweetManager extends javax.swing.JFrame {
 
         jMenuBar1.add(jMenu5);
 
+        jMenu7.setMnemonic('L');
+        jMenu7.setText("リスト(L)");
+
+        jMenuItem25.setText("自分が作成したリスト一覧");
+        jMenuItem25.addActionListener(new java.awt.event.ActionListener() {
+            public void actionPerformed(java.awt.event.ActionEvent evt) {
+                jMenuItem25ActionPerformed(evt);
+            }
+        });
+        jMenu7.add(jMenuItem25);
+
+        jMenuItem24.setText("購読しているリスト一覧");
+        jMenuItem24.addActionListener(new java.awt.event.ActionListener() {
+            public void actionPerformed(java.awt.event.ActionEvent evt) {
+                jMenuItem24ActionPerformed(evt);
+            }
+        });
+        jMenu7.add(jMenuItem24);
+
+        jMenuItem26.setText("自分がフォローされているリスト一覧");
+        jMenuItem26.addActionListener(new java.awt.event.ActionListener() {
+            public void actionPerformed(java.awt.event.ActionEvent evt) {
+                jMenuItem26ActionPerformed(evt);
+            }
+        });
+        jMenu7.add(jMenuItem26);
+
+        jMenuBar1.add(jMenu7);
+
         jMenu2.setMnemonic('O');
         jMenu2.setText("設定(O)");
 
@@ -1170,6 +1203,21 @@ public class NishioTweetManager extends javax.swing.JFrame {
         this.mainAction.actionShowHashtagSearchDialog();
     }//GEN-LAST:event_jMenuItem23ActionPerformed
 
+    private void jMenuItem25ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jMenuItem25ActionPerformed
+        this.mainAction.actionShowUserListDialog( mainAction.getScreenName(),
+                ListGetterSelection.CREATED);
+    }//GEN-LAST:event_jMenuItem25ActionPerformed
+
+    private void jMenuItem24ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jMenuItem24ActionPerformed
+        this.mainAction.actionShowUserListDialog( mainAction.getScreenName(),
+                ListGetterSelection.SUBSCRIPTION);
+    }//GEN-LAST:event_jMenuItem24ActionPerformed
+
+    private void jMenuItem26ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jMenuItem26ActionPerformed
+        this.mainAction.actionShowUserListDialog( mainAction.getScreenName(),
+                ListGetterSelection.MEMBERSHIPS);
+    }//GEN-LAST:event_jMenuItem26ActionPerformed
+
     /**
      *
      */
@@ -1282,6 +1330,7 @@ public class NishioTweetManager extends javax.swing.JFrame {
     private javax.swing.JMenu jMenu4;
     private javax.swing.JMenu jMenu5;
     private javax.swing.JMenu jMenu6;
+    private javax.swing.JMenu jMenu7;
     private javax.swing.JMenuBar jMenuBar1;
     private javax.swing.JMenuItem jMenuItem1;
     private javax.swing.JMenuItem jMenuItem10;
@@ -1299,6 +1348,9 @@ public class NishioTweetManager extends javax.swing.JFrame {
     private javax.swing.JMenuItem jMenuItem21;
     private javax.swing.JMenuItem jMenuItem22;
     private javax.swing.JMenuItem jMenuItem23;
+    private javax.swing.JMenuItem jMenuItem24;
+    private javax.swing.JMenuItem jMenuItem25;
+    private javax.swing.JMenuItem jMenuItem26;
     private javax.swing.JMenuItem jMenuItem3;
     private javax.swing.JMenuItem jMenuItem4;
     private javax.swing.JMenuItem jMenuItem5;
index 124a424..aa353a1 100644 (file)
@@ -1032,4 +1032,19 @@ public class TweetManager {
     public RateLimitStatus getRateLimitStatus() throws TwitterException {
         return twitter.getRateLimitStatus();
     }
+
+    /**
+     * 自分自身のスクリーン名を返す
+     * @return
+     */
+    public String getScreenName() {
+        try {
+            if (twitter != null) {
+                return twitter.getScreenName();
+            }
+        }catch(TwitterException e) {
+            
+        }
+        return null;
+    }
 }