Tic Tac Toe Game error
<p>I coded a tic tac toe game and it compiles and runs well, but if you click on the top left box it automatically says that X Wins <a href="http://imgur.com/MfcqT" rel="nofollow">Like this</a>. This is the only sport on the board that does that. Not sure what I did wrong in determining the winner. If you would like to see any more of the code the complete code is <a href="http://pastebin.com/WNs6YxrM" rel="nofollow">here</a>.</p>

<pre><code>        //Determine who won
        if(button1.getText() == button2.getText()
                &amp;&amp; button2.getText() == button3.getText()
                &amp;&amp; button1.getText() != "")
        {
            win = true;
        }
        else if(button4.getText() == button5.getText()
                    &amp;&amp; button5.getText() == button6.getText()
                    &amp;&amp; button4.getText() != "")
        {
            win = true;
        }
        else if(button7.getText() == button8.getText()
                    &amp;&amp; button8.getText() == button9.getText()
                    &amp;&amp; button7.getText() != "")
        {
            win = true;
        }

        else if(button1.getText() == button4.getText()
                    &amp;&amp; button4.getText() == button7.getText()
                    &amp;&amp; button1.getText() != "")
        {
            win = true;
        }
        else if(button2.getText() == button5.getText()
                    &amp;&amp; button5.getText() == button8.getText()
                    &amp;&amp; button2.getText() != "")
        {
            win = true;
        }
        else if(button3.getText() == button6.getText()
                        &amp;&amp; button6.getText() == button9.getText()
                        &amp;&amp; button3.getText() != "")
        {
                win = true;
        }
        else if(button1.getText() == button5.getText()
                    &amp;&amp; button5.getText() == button9.getText()
                    &amp;&amp; button1.getText() != "")
        {
            win = true;
        }
        else if(button3.getText() == button5.getText()
                    &amp;&amp; button5.getText() == button7.getText()
                    &amp;&amp; button1.getText() != "")
        {
            win = true;
        }
        else
        {
            win = false;
        }

        if (win == true)
        {
            JOptionPane.showMessageDialog(null,
                                          letter + " Wins!");
        }
        else if (count == 9 &amp;&amp; win == false)
        {
            JOptionPane.showMessageDialog(null,
                                          "Tie Game!");
        }
    }
}
</code></pre>
