View Single Post
Eski 05/04/2007, 16:22   #2 (permalink)
mkarabulut
Luke is back...
 
mkarabulut Adlı Üyenin Profil Grafiği
 
Üyelik Tarihi: 05/2002
Yer: ../Dark_Side
Mesaj: 2,443
Varsayılan

Benzer ufak bir kod yazdım ve denedim, böyle bir problem gözlemlemedim. Buraya yazmadığın kod bölümlerinde probleme sebep olacak bir şeyler yazılmış olabilir mi ?

Bu arada örnek yazdığım programcık (Sadece resize olayını test etmek için). her tıklamada bir pencere açılıyor ama ana senin bahsettiğin flicker tarzı şey olmadı bende.
Kod:
import javax.swing.*;
import java.awt.event.*;

public class test extends JFrame
{
    public test(int k)
    {
        this.setBounds(100*k, 100*k, 40*k, 60*k);
        JButton button = new JButton();
        button.setText("Tıkla");
        button.addActionListener(
            new ActionListener(){
                public void actionPerformed(ActionEvent e)
                {
                    test t = new test(1);
                    t.setVisible(true);
                }
            }
        );
        this.getContentPane().add(button);    
    }

    public static void main(String[] args)
    {
        test t = new test(2);
        t.setVisible(true);
    }
}
__________________
Do or do not. There is no try.
mkarabulut hatta değil   Alıntı Yaparak Yanıtla