Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 608182 Details for
Bug 853079
focus problems with openjdk 1.7.0 under gnome3 when selcted keyboard is not the first in keyboard list
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
Small java program demonstarting focus problem
Gnome3Test.java (text/plain), 2.28 KB, created by
Anders Blomdell
on 2012-08-30 13:05:56 UTC
(
hide
)
Description:
Small java program demonstarting focus problem
Filename:
MIME Type:
Creator:
Anders Blomdell
Created:
2012-08-30 13:05:56 UTC
Size:
2.28 KB
patch
obsolete
>import java.awt.Dimension; >import java.awt.event.MouseEvent; >import java.awt.event.MouseListener; >import java.awt.event.MouseMotionListener; >import java.awt.event.WindowAdapter; >import java.awt.event.WindowEvent; >import javax.swing.JFrame; >import javax.swing.JLabel; >import javax.swing.JPopupMenu; >import java.awt.Point; >import java.util.HashSet; > >public class Gnome3Test extends JFrame { > private final JLabel label; > private String name; > private HashSet<String> seen = new HashSet<String>(); > > public static void main(String[] args) { > Gnome3Test A = new Gnome3Test("A"); > A.setVisible(true); > A.setLocation(0, 0); > Gnome3Test B = new Gnome3Test("B"); > B.setVisible(true); > B.setLocation(400, 0); > } > > public void report(String why, Point where) { > seen.add(why); > if (why.equals("exited")) { > System.out.print(name + "{ "); > for (String s : seen) { > System.out.print(s + " "); > } > System.out.println("}"); > seen.clear(); > } > this.setTitle(name + " " + why + " [" + > where.x + "," + where.y + "]"); > } > > public Gnome3Test(final String name) { > this.name = name; > setTitle(name); > setLayout(null); > Dimension d = new Dimension(400, 400); > setMinimumSize(d); > setPreferredSize(d); > label = new JLabel(name); > label.setSize(label.getPreferredSize()); > label.setLocation(0,0); > label.setVisible(true); > add(label); > pack(); > addWindowListener(new WindowAdapter() { > public void windowClosing(WindowEvent e) { > System.exit(0); > } > }); > addMouseListener(new MouseListener() { > public void mouseClicked(MouseEvent e) { > label.setLocation(e.getX(), e.getY()); > report("clicked", e.getPoint()); > } > public void mouseEntered(MouseEvent e) { > report("entered", e.getPoint()); > } > public void mouseExited(MouseEvent e) { > report("exited", e.getPoint()); > } > public void mousePressed(MouseEvent e) { > report("pressed", e.getPoint()); > } > public void mouseReleased(MouseEvent e) { > report("released", e.getPoint()); > } > }); > addMouseMotionListener(new MouseMotionListener() { > public void mouseDragged(MouseEvent e) { > label.setLocation(e.getX(), e.getY()); > report("dragged", e.getPoint()); > } > public void mouseMoved(MouseEvent e) { > report("moved", e.getPoint()); > } > }); > } >} >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 853079
: 608182