PassFrame(OpenProjFrame f)
	{
		setTitle("Set project password...");
		pf = this;
		opf = f;
		Toolkit kit = Toolkit.getDefaultToolkit();
		Dimension screen = kit.getScreenSize();
		scr_w = screen.width;
		scr_h = screen.height;
		this.setLocation(scr_w/2 - 150, scr_h/2 - 100);
		setTitle("Login...");
		setSize(300, 200);
		
		loggin = new JLabel("Password");
		loginTextField = new JTextField(13);
		loginTextField.setMaximumSize(loginTextField.getPreferredSize());
		loginTextField.addKeyListener(new KeyListener()
		{
			public void keyPressed(KeyEvent arg0) 
			{
				if(arg0.getKeyCode() == KeyEvent.VK_ENTER) Ok();
			}
			public void keyReleased(KeyEvent arg0){}

			public void keyTyped(KeyEvent arg0){}
		});
		hbox1 = Box.createHorizontalBox();
		hbox1.add(Box.createHorizontalStrut(20));
		hbox1.add(loggin);
	    hbox1.add(Box.createHorizontalStrut(57));
	    hbox1.add(loginTextField);
	    hbox1.setAlignmentX(Component.LEFT_ALIGNMENT);
	    
	    pass = new JLabel("Confirm password");
	    passTextField = new JTextField(13);
	    passTextField.setMaximumSize(passTextField.getPreferredSize());
	    passTextField.addKeyListener(new KeyListener()
		{
			public void keyPressed(KeyEvent arg0) 
			{
				if(arg0.getKeyCode() == KeyEvent.VK_ENTER)Ok();
			}
			public void keyReleased(KeyEvent arg0){}

			public void keyTyped(KeyEvent arg0){}
		});

	    hbox2 = Box.createHorizontalBox();
	    hbox2.add(Box.createHorizontalStrut(20));
	    hbox2.add(pass);
	    hbox2.add(Box.createHorizontalStrut(10));
	    hbox2.add(passTextField);
	    hbox2.setAlignmentX(Component.LEFT_ALIGNMENT);
	   
	    buttonOk = new JButton("Ok");
	    buttonOk.addActionListener(new ActionListener()
	    {
			public void actionPerformed(ActionEvent e) 
			{
				Ok();
			}
	    });
	    buttonOk.addKeyListener(new KeyListener()
		{
			public void keyPressed(KeyEvent arg0) 
			{
				if(arg0.getKeyCode() == KeyEvent.VK_ENTER) Ok();
			}
			public void keyReleased(KeyEvent arg0){}

			public void keyTyped(KeyEvent arg0){}
		});
	    buttonCancel = new JButton("Cancel");
	    buttonCancel.addActionListener(new ActionListener()
	    {
	    	public void actionPerformed(ActionEvent arg0) 
	    	{
				System.exit(0);
			}
	    	
	    });
	    buttonCancel.addKeyListener(new KeyListener()
		{
			public void keyPressed(KeyEvent arg0) 
			{
				if(arg0.getKeyCode() == KeyEvent.VK_ENTER) System.exit(0);
			}
			public void keyReleased(KeyEvent arg0){}

			public void keyTyped(KeyEvent arg0){}
		});
	    hbox3 = Box.createHorizontalBox();
	    hbox3.add(Box.createHorizontalStrut(80));
	    hbox3.add(buttonOk);
	    hbox3.add(Box.createHorizontalStrut(10));
	    hbox3.add(buttonCancel);
	    hbox3.setAlignmentX(Component.LEFT_ALIGNMENT);
	   
	    vbox = Box.createVerticalBox();
	    vbox.add(hbox1);
	    vbox.add(hbox2);
	    vbox.add(hbox3);
	    
	    contentPane = getContentPane();
	    contentPane.add(vbox, BorderLayout.CENTER);
	    this.setResizable(false);
	}