Avoid static JInternalPane in 1.4.1

This post is informational. I am not asking for help.
We discovered this problem when transitioning from JRE 1.3.1
to 1.4.1.
We use the JInternalFrame to create a floating palette of
buttons that pump text constructs into one or more special
text panes that reside in the JDesktopPane over which the
frame floats. The buttons generate text actions which go
to whichever text pane has focus. Since the palette buttons
and layout are fixed, we declared the frame to be a static
member variable of the UI class.
However, if we restart the applet, we are no longer able
to click and type into any of the textpanes. The palette
buttons still pump the special characters, but the keyboard
events are apparently blocked.
Sometimes we find that we can re-establish keyboard focus
by clicking into the Java console window and then refocusing
the frame containing the applet. At that point, we may see
a number of keyboard events that have queued up, empty into
the text component.
The workaround is to rework the code so that the JInternalPane
is no longer static.
We consider this a regression. AT the moment, our
bug report has been rejected because we did provide a simple
reproducible test case. Perhaps we will at some point, but
for now, we just advise caution.

may be you can explain the scenario better with some screenshots ..

Similar Messages

  • Avoiding static

    I have an array which is instantiated in one class, and referenced in a few others. If I declare
    the array static everyting compiles and runs, but references to the array give me erratic
    performance.
    Removing the static declaration results in the following compiler error:
    "Can't make a static reference to nonstatic variable entryforms in class InstantiatingClass.
                   method( InstantiatingClass.entryforms[ i ].someVariable, ... );"
                   ^
    What adjustments do I make to the outside references in order to keep the array declaration non-static?
    A little more detail: -----------------------------------------------------------------------
    class InstantiatingClass extends MouseAdapter {
         static EntryForm[] entryforms;     //     This compiles but gives screwy results
         EntryForm[] entryforms;          //     References to this do not compile
         entryforms = new EntryForm[15];     
    class ReferrringClass extends MouseAdapter {
    EntryForm[] entryforms;
         public ReferrringClass( EntryForm[] entryforms ) {
              this.entryforms = entryforms;
              for( int j = 0; j < 15; j++ ) {
                   if( e.getSource() == entryforms[j].submitButton ) {
                        i = j;                                                  //     "i" is the INSTANCE of the form
                        break;
              if ( entryforms[ i ].someVariable == "Something" ) {     // Results in null pointer errors at runtime          
              if ( InstantiatingClass.entryforms[ i ].someVariable == "Something" ) {     // References like these result in compiler errors          
    }Many thanks in advance.

    class InstantiatingClass extends MouseAdapter {
         static EntryForm[] entryforms;     //     This compiles but gives screwy results     EntryForm[] entryforms;     //     References to this do not compile
    This doesn't make sense to me. It shouldn't compile. You have two variables of the same name in the same block of code..... I'm not sure what you're trying to do. If entryforms stays the same across instantiations of InstatiatingClass, then use the static modifier. If you simply want to access entryforms from another class (and the value changes with each instantiation of InstantiatingClass), then do something like this:
    class InstantiatingClass extends MouseAdapter {
    private EntryForm[] entryforms;
    public EntryForms[] getEntryForms() {
    return entryForms;
    Then instantiate InstantiatingClass and retrieve the value of entryforms (from another class or where ever), like:
    InstantiatingClass iClass = new InstantiatingClass();
    EntryForms[] newForms = iClass.getEntryForms();
    class ReferrringClass extends MouseAdapter {
    EntryForm[] entryforms;           
    public ReferrringClass( EntryForm[] entryforms ) {               
    this.entryforms = entryforms;     
    -- This seems ok, your setting the member variable entryforms, but for readability would use another name, entryforms = forms maybe...
    for( int j = 0; j < 15; j++ ) {
    if( e.getSource() == entryforms[j].submitButton ) {                    
    i = j;     //     "i" is the INSTANCE of the form     
    break;
    -- I don't see where ReferringClass is actually instantiated, and entryforms is being passed into the constructor to set this.entryforms....
    if ( entryforms[ i ].someVariable == "Something" ) {     // Results in null pointer errors at runtime     
    if ( InstantiatingClass.entryforms[ i ].someVariable == "Something" ) { // References like these result in compiler errors               
    maybe the final if statement could be something like:
    InstantiatingClass iclass = new InstantiatingClass();
    EntryForms[] forms = iclass.getEntryForms();
    if ( forms[someIterator].someVariable.....)
    I don't know if this help, but I hope it did....

  • Question about synchronized static function.

    Hi, everyone!
    The synchronized statement often deals with an object (called monitor).
    But a static function can be invoked without an object.
    So if a static function is declared as static, what is the function of
    static and synchronized here? Which lock it is using?
    Can you give me a simple expplanation?
    regards,
    George

    Hence try and avoid synchronizing static methods.
    Try and use non static method if you are doing
    multithreaded programming. That way you can have lockWell, I avoid static methods, not just when doing multithreading, but not for the reason you mention.
    objects which allow non interfering methods to be
    accessed in parallelThats easy to do with static methods anyway:
    class Foo
      static Object lock1 = new Object();
      static Object lock2 = new Object();
      static void method1()
         synchronized( lock1 )
      static void method2()
         synchronized( lock2 )
    }Maybe I just missunderstod you...

  • Is it ok to make a Base RBundle static if it is for small scale firm?

    I was told to avoid static code but I dont see why I cant use a static RBundle for all GUI text if it there is only one language currently. Surely all clients can share the one instance of my GUi text getting class?

    jverd wrote:
    That really means nothing, in my experience. I've interviewed quite a few incompetent programmers that were Sun certified.Go tell Sun then. Good thing now anyone who visits this forum can see that certification is useless.
    jverd wrote:
    What if you're wrong? The more incompetent one is, the less one will be able to see one's own incompetence.You're making now sense now. Wrong about what?About your statement on incompetance? Without proof I cant believe you as I am not the expert that you make yourself out to be.
    >
    >>
    Proof of what?Your expert opinion on incompetence. You stated it as a fact leaving no room for argument. I now want proof that it is indeed fact.
    >
    Re-read your post. It obviously states your opinion, not facts.I don't need to. I wrote it. Can you quote the part in your next reply on where I said I do not like him. This comes as a big surprise to me as I never met him/her.
    jverd wrote:
    Irrelevant.Then why the comment suggesting that one needs competance in order to ask question in the "new to java" forum? I suggested no such thing.For someone who says that I wrote that i don't like someone when I didn't this is no surprise as it is becoming clear to me you don't read well. You will notice this comment is about JWentlings comment about incompetance in the "new to java" section. I merely pointed out that such comments are irrelevant to me and possibly others, especially when one understands that being "new to something" usually entails that one has limited if any competance towards the topic.
    Edited by: Yucca on Apr 14, 2009 6:18 PM
    Edited by: Yucca on Apr 14, 2009 6:20 PM

  • Parameter or static method?

    (i'm braziliam, sorry for any english mistake..)
    Imagine a object A, that contains a object B, that contains a object C, and so on...
    Imagine that the object Z needs to use a table that A object contains.
    Now, imagine All the people, leaving for today!.. (kidding.. lol)
    Ok, my question is:
    What is most corret/secure/usual to do?
    Pass the A's table (or self A object) to B's constructor, and from B to C, and so on until Z get it.
    Or create a static method A.getTable()?
    I like the idea of the static method, but I hear to avoid static methods....
    What do you say?

    if starsCount is a static parameter of Universe then the static method works fine.... but notice, if you assume there are multiples universes (that is, if your class A can have multiple instances, and that each instance has its own parameters), it won't work.
    Since we are supposing there are only one universe we can take your analogy one level below: suppose your Planet class has a parameter double mass. And the planet has cities, etc.... and then the human wants to know his planet's mass. Your static method solution will definitely not work here, unless you (strangely) assume "mass" is a static parameter of Planet class.... right?
    By the way, I'm brazilian too.... nice to know there are other brazilians here :D Let's keep it in english though right?

  • Intel Mac Mini question

    Hello all:
    I am sure this has been asked before. In replacing the hard drive and RAM in my intel mac mini, one of the battery wires at the point where it goes into the coupler broke off. I had seen elsewhere that warned if this breaks, you may as well toss the device. Is this the case? Can this be replaced by buying a new battery line?
    Any help would be very much appreciated since I have my daughter's computer now out of commission.

    Hi Chris
    Sorry to hear about the accident with the wire. Don't despair - you don't have to toss the Mini!
    If it was mine, I would first take a close look at the connector to see if it be dismantled so that I could re-solder/attach the wire. If not, and assuming the connector is unique to Apple, I would source another connector from an electronics shop (you don't need anything fancy - all you are doing is connecting two wires that run a fan).
    I'm reasonably competent with a soldering iron, so I would unsolder the old connector and then fit the new one. If you don't have a soldering iron or aren't confident using one, you need to find a hobbyist or repair shop that will make the changeover for you.
    This isn't high-tech stuff, so no worries about screwing up the Mini (although you do need to be careful to avoid static discharges while handling the opened Mini - but then you probably already knew that before opening the case).

  • EMac Monitor Problem

    Alright, I have an eMac G4, I think its 2nd or 3rd gen.  Recently it has been having some trouble with its screen.
    It boots up fine, but after no more than 20 minutes, the screen goes off.  The light doesn't start pulsating and I can't turn it on again without turning off and on again, where I can have another 20 minutes TOPS.  This only works for about three to five cycles before it has to sit without power for about a day before I can see anything.  Booting in the normal OS (10.4.11) and its resore DVD(10.3.3) bolth have this problem.  However, the Hardware Test extended test will find no problem, and the screen will stay on for hours if it is booted from the Hardware Test partition on the restore DVD.  It has had this problem for a long time, but repairing permissions on the harddrive and removing/ replacing the backup battery seemed to work temporarily, until now.
    When the screen goes off, I can still eject CDs, adjust volume, and it will play the error sound effect if I punch random keys.
    I also have another eMac (first gen 700mhz) that works well except for its CD-RW drive.  If I can't get the newer eMac working, I would like to salvage as much as possible and upgrade the older one.  What all can be transfered? The whole logic board, RAM, HD, Superdrive?  Any Combination?  I am in need of a little more computing power, and been needing a new CD drive for years...
    Thanks!

    DreadPirate_Roberts wrote:
    ...but a lot of the dust seemed baked on pretty good and I didn't have a way of wiping it off very well.
    The best gadget for stubborn dust deposits is a pastry brush. Make sure you get one with a wodden handle and natural bristles to avoid static isses. I have close to a dozen in various sizes and shapes in my computer kit.
    Be sure you know the exact version of the eMac you have before looking up take-down instructions. There are two variants: those with USB 1.1 logic boards and 700Mhz, 800Mhz, and 1Ghz processors; and those with a USB 2.0 logic board. The latter are mostl y1.25 and 1.42G processors but there are some uncataloged "edu-only" eMacs with the USB2 board but only a 1Ghz processor. That;s the version that leads be to this caution.
    The case take-apart is slightly different between the original 4,4 eMacs and the later 6,4 versions. Some people have broken the power switch while trying to use the older instructions to take about a newer eMac.
    The 4,4 and 6,4 codes come from System Profiler (Apple menu > About this Mac and then click the "More Info..." button). It the second line of the opening Profiler screen. A code of 4,4 on your computer means it's USB 1.1 and a code of 6,4 means it;s the later USB 2.0 version.

  • OSPF design for branch offices across MPLS

    Hello fellow networking engineers,
    I want to implement OSPF in our network. We have multiple branch offices, all linked to an MPLS backbone.
    I know that in order to get linked areas, I would need to setup GRE tunnels between them, but I want to avoid static/manual configurations as much as possible. With multiple sites, it would become cumbersome to create a mesh real fast.
    Is running OSPF independent areas at each site, and simply redistributing over eBGP a valid solution? This will host voice and data, and will failover to VPN connection (Cisco ASAs) if the MPLS goes down.
    For the VPN backup links, I thought of two options. Either simply using the default route to send everything to the ASA in case of MPLS "death", or inject routes using IP SLA...
    Any input would be appreciated.

    Marc
    You don't GRE tunnels to link your areas if that is what you want to do.
    If the SP supports it then you can exchange your OSPF routes between areas and they will still be seen as inter area routes rather than OSPF externals which they would if you simply treated each area as isolated from each other.
    In effect the MPLS network becomes an OSPF super backbone area and your main site would also be part of the backbone area with all your other sites having an area each.
    You still redistribute your OSPF routes into BGP but with some extra configuration on both your CEs and the SP PE devices.
    Like I say you would need to check with your SP but it is possible.
    Whether or not you need or want it I don't know.
    Your other option is as you have proposed to treat each OSPF area as an isolated one and simply redistribute into OSPF at each CE. Then within each site all non local routes would be seen as OSPF external routes.
    Either way in terms of backup I would keep it simple and use a default route at each site pointing to the ASA device. I can't see what you gain from IP SLA because if the main MPLS link goes down at any site the only other path they have out is via the ASA so there is nothing really worth tracking.
    The only other thing I would mention is remote site to remote site traffic. If there is any then presumably with your VPN tunnels you would be doing a sort of hub and spoke where the hub is the main site so you may need to think about traffic coming in from one VPN tunnel and going out to another VPN tunnel on the main site ASA.
    This would only really be needed if two or more sites had to use their backup links at the same time.
    In terms of which is better ie. OSPF inter area across the MPLS cloud or OSPF externals I can't really say to be honest. With the MPLS networks i have worked on we ran EIGRP and simply treated each remote site as an isolated AS.
    If you are already running OSPF then you may want to preserve your existing areas so it would make sense to go with the inter area option.
    If it is a new setup then I don't really know the pros and cons of either so can't really comment.
    Perhaps others may add to the thread with their thoughts.
    Jon

  • Implementing JMS-based EDN and JNDI-based EDN

    I´m implementing a composite with two kinds of events JMS and JNDI and I saw in the configuration for JMS-base I must remove the EDN-DB JNDI sources to use EDN-JMS data sources. My doubt is, does my composite will work with that two kinds of events?
    All the best,
    Pierre

    This is a functional desire that has come up on some of our projects too but is not directly supported by EDN. We have discussed the idea of EDN proxies (either as SOA Composites or as PL/SQL EDN subscribers). These proxies (presumably always active/deployed) would subscribe to EDN and provide a persistent buffer for the application. This is essentially implementing a persistence queue for each subscriber, but we wish to avoid statically configuring an AQ or JMS queue destination for each and every app subscription case and perhaps use some shared-but-keyed persistence design (e.g. database table).
    Architecturally, this starts to hit on the ever evasive and controversial question of what is an "Event" versus what is a "Message". i.e. can you afford to sometimes miss the former but not the latter?
    -Todd

  • Oracle 10g Installation on Linux

    Hi everybody !
    myOS: Linux Mandrake 9.2/10 (the same error on both)
    I was tried to install 10.1.0 but during installation was thrown this exception
    something like this...
    .../jlib/oemlt-10.1.0.jar too many parameters..
    What is wrong ? How can I repair it ?
    Next... I cannot run DBCA because of another exception...
    [oracle@r2v21 bin]$ dbca
    Exception in thread "main" java.lang.NoClassDefFoundError: oracle/sysman/vbo/VboInsufficientInitException
    at oracle.sysman.assistants.dbca.Dbca.getHost(Dbca.java:149)
    at oracle.sysman.assistants.dbca.Dbca.execute(Dbca.java:91)
    at oracle.sysman.assistants.dbca.Dbca.main(Dbca.java:169)
    [oracle@r2v21 bin]$
    Could you help me with these problems ??
    thanks a lot !!

    As a thumb of rule see this table:
    ====================================================================================
    RAID Type of RAID Control Database Redo Log Archive Log
    File File File File
    ====================================================================================
    0 Striping Avoid* OK* Avoid* Avoid*
    1 Shadowing OK OK Recommended Recommended
    0+1 Striping + OK Recommended Avoid Avoid
    Shadowing (1)
    3 Striping with OK Avoid Avoid Avoid
    Static Parity (2)
    5 Striping with OK Avoid Avoid Avoid
    Rotating Parity (2)
    * RAID 0 does not provide any protection against failures. It requires a strong backup
    strategy.
    (1) RAID 0+1 is recommended for database files because this avoids hot spots and gives
    the best possible performance during a disk failure. The disadvantage of RAID 0+1
    is that it is a costly configuration.
    (2) When heavy write operation involves this datafile
    Not so easy to read, title is
    control file,database file,redo log, archivelog
    For RAID5:
    control file ok
    database file avoid (but see footnote 2)
    redo log avoid
    archive log avoid

  • Control file multiplexed RAID question

    2 node RAC. OEL 5. 11.2.0.2
    Is there any cause for concern over design issues when placing multiplexed controlfiles on disks with different RAID types?
    I have FRA, REDO, VOTE and DATA disk groups available to me DATA is RAID 5, the rest are RAID 10. Is there any tales from the field of write speed issues multiplexing the files on a RAID 5 and a RAID 10?
    Edited by: 961469 on Dec 11, 2012 6:10 AM
    edited to include versions and env

    Is there any cause for concern over design issues when placing multiplexed controlfiles on disks with different RAID types?IMHO, I believe not. Of course this depend on characteristic of I/O of each Array.
    As best practice never mix files stored on array with heavy I/O with array which has Low I/O.
    Controlfile is good for RAID 5 and RAID 10 no worry.
    Read note:
    I/O Tuning with Different RAID Configurations [ID 30286.1]
    Swap space can be used on RAID devices without affecting Oracle.  
    ====================================================================================
    RAID  Type of RAID        Control       Database        Redo Log        Archive Log
                                File          File            File            File
    ====================================================================================
    0     Striping             Avoid          OK           Avoid           Avoid    
    1     Shadowing             OK             OK          Recommended       Recommended
    0+1   Striping +            OK         Recommended       OK            Avoid    
          Shadowing                                                                                 
    3     Striping with         OK           Avoid           Avoid            Avoid    
          Static Parity                                                                                        
    5     Striping with         OK           Avoid           Avoid            Avoid    
          Rotating Parity                  
    ------------------------------------------------------------------------------------On this case the main concern is:
    Something which should help can disrupt and cause downtime.
    Unable To Open Database Due To Diskgroup Used To Multiplex The RedoLogs & Controlfiles & Archivelogs Got Corrupted. [ID 1382372.1]
    Regards,
    Levi Pereira

  • Performace trouble

    So we have ora9 + solaris + v490 + 3* hardware raid (each contain 10 disk).
    Oracle database and redo log configured to separated raid. If we switch redo log form their own raid to ramdik then this action increase perforamce more than 5 times.
    It possible to operate oracel redo log in ramdisk (in case of solaris this is violate if the hardware failed)?
    How to possible to reduce redo write activity dramaticall? In our case the application make mutch more commit, amnd may this is the source of the problem.

    Hi,
    don't put redo files on a volatile medium, you won't be able to recover completely in a case of failure. To reduce I/O contention consider these general rules:
    Keeping the redo log files on separate disks from datafiles will avoid
    impacting other write operations.
    The best recommendation when the server has sufficient resources is to
    place each set of redo log files on a separate disk with no other activity.
    Following matrix shows, only RAID1 is recommended for online redo and archive logs.
    ====================================================================================
    RAID Type of RAID Control Database Redo Log Archive Log
    File File File File
    ====================================================================================
    0 Striping Avoid* OK* Avoid* Avoid*
    1 Shadowing OK OK Recommended Recommended
    0+1 Striping + OK Recommended Avoid Avoid
    Shadowing (1)
    3 Striping with OK Avoid Avoid Avoid
    Static Parity (2)
    5 Striping with OK Avoid Avoid Avoid
    Rotating Parity (2)
    ------------------------------------------------------------------------------------

  • Mac pro works fine, minus the display

    Ok, so this is a bit of an odd question, I think. When I turn on my computer, I can hear it boot up only the display doesn't work. Blank screen. Cnce it's booted up, if I press the volume button, I can hear it changing volume, if I open itunes, I can hear it playing music, so I know the computer is working, just no picture.
    I've ruled out the monitors, as they work fine with other computers. Here's the kicker. If I shut the computer off, open it up, jiggle the video card around a little, and turn it back on it works perfectly fine. Until I shut the computer off again, then we go through the same process. It's an early 2008 mac pro, and I have the 256 MB ati radeon, I think, video card that came with it.
    Any ideas? Thanks!

    Hi,
    It sounds like your Graphics card isn't seated properly.
    Remove all cables from Mac Pro, then remove side, earth yourself to avoid static, then remove the graphics card. You might want to clean out any fans on the Graphics card while it's out. Re-insert the graphics card, replace side panel, then reconnect your cables and try starting your system again.
    If the same thing happens, it could be either the graphics card having an issue, cable of the monitor not properly inserted or possibly an issue on your logic board.
    If re-seating the graphics card doesn't work, contact Apple Tech Support for further assistance.
    Hope this helps.

  • EDN and JMS

    Hi,
    Are EDN and JMS comparable?
    Can we use EDN instead of JMS?How reliable is EDN compared to JMS(message loss etc)?
    Also how to know if an EDN is JMS or DB based.
    Thanks.

    This is a functional desire that has come up on some of our projects too but is not directly supported by EDN. We have discussed the idea of EDN proxies (either as SOA Composites or as PL/SQL EDN subscribers). These proxies (presumably always active/deployed) would subscribe to EDN and provide a persistent buffer for the application. This is essentially implementing a persistence queue for each subscriber, but we wish to avoid statically configuring an AQ or JMS queue destination for each and every app subscription case and perhaps use some shared-but-keyed persistence design (e.g. database table).
    Architecturally, this starts to hit on the ever evasive and controversial question of what is an "Event" versus what is a "Message". i.e. can you afford to sometimes miss the former but not the latter?
    -Todd

  • I want to upgrade from 4g of ram to 8g

    So i have my memory on hand, now what?
    I know i have to open the mac and install it, but i need to know the correct procedure so that nothing goes wrong(i never changed rem before)

    For mine ... but the instructions in the back part of your booklet (Boost Your MacBook Pro section) may be different ...
    Flip it over ...
    Avoid static electricity ...
    Remove the screws, and set then aside in the same pattern as you remove them ...
    Hands only ...
    Gently push the plastic side pieces aside that hold the memory ... top SODIMM ... memory will flip up to 45 degree angle
    Gently lift out ... should be easy ... if not, then gently reseat and try pulling side pieces again ...
    Repeat for "bottom" SODIMM ...
    Installation is reverse of removal ... being careful not to push too hard ...  DO NOT TOUCH GOLD CONNECTORS ON MEMORY
    Reinstall bottom of case, puttng screws in the correct place.
    Restart your system

Maybe you are looking for

  • Error while executing COI

    Dear Friends I am getting an error while executing the COI activity. The error message is as below Change of total share in consolidation unit 102001 / 30208 does not equal 0 % Investee 102001 / 30208 : Reported investment data must have exactly two

  • How to reduce buffer busy waits, session hanging due to buffer busy waits

    Hi, How to reduce buffer busy waits, session hanging due to buffer busy waits. Thanks, Sathis.

  • Colour look dull in PDF

    Hi everyone, I have created several PDF files (Acrobat 6.0 Professional) from Word 2003 documents. In some of them colours used in headlines (blue, red, yellow, green) look dull (kind of dirty yellow or dark blue, etc.) while in other PDFs they look

  • How to restore my Canviio 4TB to factory settings

    How would I go about restoring my drive to as it came from the box?

  • Httpurlconnection chunked output stream?

    Hi, I'm developing a client that interacts with a comet server (comet allows http connections to be used for multiple inputs and outputs on same connection -- not single request, single response). I've found that I can't use HttpURLConnection because