How properly maximize in jre 1.3? JFrame does it, I want to with JWindow.

I notice that a JFrame (in 1.3), when I click to maximize it, resizes only up to the task bar. Yet I cannot find anywhere in the code where it figures out the size of the taskbar. Does anyone know where this code is and how I'd do ti for a JWindow?

OK, here ya go. Normally, a frame is maximized by calling setExtendedState(Frame.MAXIMIZED_BOTH);    public synchronized void setExtendedState(int state) {
        this.state = state;
        FramePeer peer = (FramePeer)this.peer;
        if (peer != null) {
            peer.setState(state);
    }Now, what is peer? OK    /**
     * Makes this Frame displayable by connecting it to
     * a native screen resource.  Making a frame displayable will
     * cause any of its children to be made displayable.
     * This method is called internally by the toolkit and should
     * not be called directly by programs.
     * @see Component#isDisplayable
     * @see #removeNotify
    public void addNotify() {
     synchronized (getTreeLock()) {
         if (peer == null) {
          peer = getToolkit().createFrame(this);
         FramePeer p = (FramePeer)peer;
         MenuBar menuBar = this.menuBar;
         if (menuBar != null) {
             mbManagement = true;
          menuBar.addNotify();
          p.setMenuBar(menuBar);
         p.setMaximizedBounds(maximizedBounds);
         super.addNotify();
    }Now, from the API for [url http://java.sun.com/j2se/1.4.2/docs/api/java/awt/Toolkit.html]ToolKit
public abstract class Toolkit
extends Object
This class is the abstract superclass of all actual implementations of the Abstract Window Toolkit. Subclasses of Toolkit are used to bind the various components to particular native toolkit implementations.
Most applications should not call any of the methods in this class directly. The methods defined by Toolkit are the "glue" that joins the platform-independent classes in the java.awt package with their counterparts in java.awt.peer. Some methods defined by Toolkit query the native operating system directly.
So, each platforms 'ToolKit' is included in the java executable. ToolKit.createFrame(); returns a native implementation of FramePeer (which is also abstract).

Similar Messages

  • How to maximize blackberry flash memory

    Hİ all,
    how to maximize blackberry flash memory?
    examp: 9000 internal memory 1gb
     but only we can use 256 mb for messages
    best regard
    Blackberry support teams in linkedin ...join
    http://www.linkedin.com/groups?home=&gid=2785187&trk=anet_ug_hm
    For Russian
    http://www.linkedin.com/groups?gid=3183812&trk=anetsrch_name&goback=.gdr_1278482273982_1
    Solved!
    Go to Solution.

    Hello!
    There are three types of potential memory on a BB: 1) Application Memory, 2) Device Memory, and 3) Media/SD Card Memory
    Application Memory -- This is the most crucial; it is the protected (not user accessible), dedicated, and fixed (in size) space that is available as the destination for the installation of applications (plus some application storage, overhead and such). You cannot touch AppMemory. You cannot improve the maximum AppMemory that your BB has. It is what it is. Applications can only install here...there is no option.
    Device Memory -- This is space on your BB that you can touch to store files, pictures, media, etc. Typically, it is not terribly large, but it is available to you.
    SD/Media Card Memory -- This is what it says...your SD card, for you to store files, media, pictures, etc. It can be as large as your BB OS can support...see this KB:
    http://www.blackberry.com/btsc/KB05461
    On some devices/OS levels, you can only see "File Free" (Options > Status), which I think is equivalent to AppMemory. On other devices, you can see all three memory usage levels (Options > Memory). Here are some guidelines to use:
    http://www.blackberry.com/btsc/KB15345
    http://www.blackberry.com/btsc/KB14320
    http://www.blackberry.com/btsc/KB14213
    Lastly, it is always important to properly close applications when you are done with them. Using the Back or the Red key will not do this -- those leave it to the app to decide what to do...and some will leave themselves resident in memory, consuming resources on your BB, slowing the overall performance. Rather, to close an app, press and select "Close" or "Exit"...that will force the application to be closed, freeing up for your new use the resources it was consuming. Some apps will always remain running (typically -- BBMessenger, Browser, Homescreen, Phone, and Messages)...but, you should still close them properly - especially the Browser...if it is left on an active web page, it will not only consume extra resources but battery power as well.
    Further, anytime random strange behavior or sluggishness creeps in, the first thing to do is a battery pop reboot. With power ON, remove the back cover and pull out the battery. Wait about a minute then replace the battery and cover. Power up and wait patiently through the long reboot -- ~5 minutes. See if things have returned to good operation. Like all computing devices, BB's suffer from memory leaks and such...with a hard reboot being the best cure. Some have taken to doing this on a regular basis as a preventive measure...some as frequently as once per day. Others have obtained the QuickPull app to automate a simulated Batt-Pull.
    Best!
    Good luck!
    Occam's Razor nearly always applies when troubleshooting technology issues!
    If anyone has been helpful to you, please show your appreciation by clicking the button inside of their post. Please click here and read, along with the threads to which it links, for helpful information to guide you as you proceed. I always recommend that you treat your BlackBerry like any other computing device, including using a regular backup schedule...click here for an article with instructions.
    Join our BBM Channels
    BSCF General Channel
    PIN: C0001B7B4   Display/Scan Bar Code
    Knowledge Base Updates
    PIN: C0005A9AA   Display/Scan Bar Code

  • How can we stop jre 7 from blowing us all out of the water?

    I would like to put forth a issue that greatly concerns me which is java 7. In recent times, some browsers have summarily decided that
    they only allow calls to "current" versions of java. So in Mozilla's mindset, the only current version of java now is 6. It is questionable how
    feasible it is for someone to manage to get firefox to call an "older" plugin like 1.5, 1.4 or 1.3. Sounds like it requires a lot of manual
    configuration on each user's pc. Mozilla has put out conflicting advice on this topic.
    http://kb.mozillazine.org/Java#Switching_Java_versions_-_Advanced
    http://plugindoc.mozdev.org/faqs/java.html#Issues
    So my big concern is that when java 7 is released, Mozilla and other browser vendors can then decide 7 is the current version and make
    it nearly impossible to call java 6. Which would be terrible. Oracle would take a fine amount of time to certify 7 and only certify it on the
    most recent versions of the software. I forsee great pain and suffering amongst the customers on this. How can this be prevented?
    (And why doesn't oracle write it's own browser? If you write your own browser you are free from worrying about this nonsense. Also
    the enterprise browser should only connect to enterprise resources and not be used for arbitrary web surfing by the users. Need a way
    to restrict such a program.)
    http://java.com/en/download/faq/firefox_newplugin.xml
    "Starting with Firefox 3.6, Java-based applications will NOT work unless you are running Java version 6 Update 10 or newer. "
    "Starting in Firefox 3.6, Mozilla foundation will drop support on OJI (Open Java Virtual Machine Integration) and will only support the standard NPAPI and NPRuntime interfaces. The Java Plug-in which is in Java version 6 update 10 or newer versions supports the NPAPI and NPRuntime interfaces. Therefore, starting with Firefox 3.6, Java-based applets will NOT work unless you are running Java version 6 Update 10 or newer"

    From the java download page:
    J2SE 5.0 reached its End of Service Life (EOSL) on November 3, 2009, which is the date of the final publicly available update of version 5.0 (J2SE 5.0 Update 22). So not only Mozilla thinks that Java 6 is the only version, even the vendor of java (oracle) thinks that.
    Why is it so that everybody thinks that software from the previous millennium (like JInit) of course has to work with software of this millennium (like firefox 3.6)?!? JRE 1.5 is desupported for nearly 2 Years now....and don't get me started on JInitiator which basically was released 11 years ago, but surely you will find someone who has a company standard of IE8 and JInit (and mutters why this does not work anymore). Now there comes the argument that they don't want to upgrade their forms servers or what ever else because they are afraid that the newer version does not work anymore, but surely they are update happy with their browsers, aren't they? So why just move foreward with parts of the configuration?
    If you look here you may notice that JRE 1.6 will reach EOL in 2012 (2013 with Java for Business) which is about the same time when Forms 10g will reach EOL, so you not only won't get new certifications with forms 10g, you also won't get new Security Patches etc. for forms 10g. This is a perfect reason why to move on to a newer version in both cases.
    I am working for a software vendor myself, and I perfectly understand why software vendors throw away compabilities and start desupporting software after a certain amount of time. If we didn't I still would have to develop my PL/SQL code so it operates flawlessly on Oracle 7 as there were surely customers out there which insisted that this version of the database runs so stable in their site, and they don't need to update as the old database software runs well. And not only that, but the point in time when it takes you longer to actually find the affected versions and patch the fix of a critical bug in all those versions takes longer than finding the bug itself (been there, done that) it is time to throw some old versions out of the window, desupport them and clean the trunk code.
    Bottom line is: if you want to keep one part of your software Jurassic you better keep the whole configuration at the same age. Old software is never meant to run against software from 10 years in the future, and in the opposite it is quite an impossible task to write an infinite backward compatible software.
    cheers

  • How to use multiple JREs (1.5.0_20 and 1.6.0_07) with Internet Explorer 8?

    Hi!
    Question about the problem mentioned in subject.
    I have configured that JNLP opens with 1.5 version, both versions are enabled in Java Control Panel Runtime Settings but when I try to start a desktop java console says:
    Java Web Start 1.5.0_22
    Using JRE version 1.6.0_07 Java HotSpot(TM) Client VM
    And the opening of the desktop creates an exception:
    Java Web Start - Invalid Argument Error
    TooManyArgumentsException[ Too many arguments supplied: {C:\WINDOWS\Temporary, Internet, Files\Content.IE5\....
    I'm trying to open my desktop with 1.5 version and other programs with 1.6 version. What is it that I still need to do? I'm kind of confused with this. Some of my collagues have succeeded with this and some doesn't, with the same configuration.
    So the question is, how to use multiple JREs with IE8 so that one application uses 1.5 version and others 1.6 version?
    Br,
    Katri
    Edited by: ka**** on 09-Mar-2011 01:16
    Edited by: ka**** on 09-Mar-2011 03:16

    ka**** wrote:
    ..Question about the problem mentioned in subject.No "Using multiple JREs (1.5.0_20 and 1.6.0_07) with Internet Explorer 8" is a statement. To transform it to a question would be something like "How to use multiple JREs (1.5.0_20 and 1.6.0_07) with Internet Explorer 8?".
    Once you can come up with an actual question, I might look at this more closely.

  • Can't figure out how to maximize the space on the page by increasing the column width

    Trouble with pages app:
    can't figure out how to maximize the space on the page by increasing the column width
    I have 3 columns and they have spaces btw them that I cannot close the gap on.

    Whatever the version, you can click on the gutter figure and edit it.
    Click once on the column and a second time on the Gutter measurement.
    Peter

  • How to open a pdf file in JFrame

    hi to all,
    i need to know how to open a pdf file in JFrame. Help is needed with this would grateful, and i used the code state below..
    InputStream in=this.getClass().getResourceAsStream("/images/help1.pdf");
    Process p = Runtime.getRuntime().exec(in);Thanks in Advance...

    this is the error which i'm getting while executing the code
    init:
    deps-jar:
    Compiling 1 source file to /home/VEL AREA/SampleApplication/build/classes
    /home/VEL AREA/SampleApplication/src/sampleapplication/Main.java:3: package com.sun.pdfview does not exist
    import com.sun.pdfview.PDFFile;
    /home/VEL AREA/SampleApplication/src/sampleapplication/Main.java:4: package com.sun.pdfview does not exist
    import com.sun.pdfview.PDFPage;
    /home/VEL AREA/SampleApplication/src/sampleapplication/Main.java:5: package com.sun.pdfview does not exist
    import com.sun.pdfview.PagePanel;
    /home/VEL AREA/SampleApplication/src/sampleapplication/Main.java:25: cannot find symbol
    symbol : class PagePanel
    location: class sampleapplication.Main
    PagePanel panel = new PagePanel();
    /home/VEL AREA/SampleApplication/src/sampleapplication/Main.java:25: cannot find symbol
    symbol : class PagePanel
    location: class sampleapplication.Main
    PagePanel panel = new PagePanel();
    /home/VEL AREA/SampleApplication/src/sampleapplication/Main.java:36: cannot find symbol
    symbol : class PDFFile
    location: class sampleapplication.Main
    PDFFile pdffile = new PDFFile(buf);
    /home/VEL AREA/SampleApplication/src/sampleapplication/Main.java:36: cannot find symbol
    symbol : class PDFFile
    location: class sampleapplication.Main
    PDFFile pdffile = new PDFFile(buf);
    /home/VEL AREA/SampleApplication/src/sampleapplication/Main.java:39: cannot find symbol
    symbol : class PDFPage
    location: class sampleapplication.Main
    PDFPage page = pdffile.getPage(0);
    8 errors
    BUILD FAILED (total time: 2 seconds)
    for the reply #4..

  • HOw to maximize a portlet on click of a link.

    Hi,
    Can some one help me as to how to maximize a portlet on click of a button?
    I am calling Page A.jsp to Page B.jsp.
    in the .jpf file, in the method which is being used to render Page B.jsp contains
    the below mentioned code. Do I have to do something extra or this much code is
    enough?
    //maximize portlet view
    PortletBackingContext context = PortletBackingContext.getPortletBackingContext(super.getRequest());
    context.setupStateChangeEvent(WindowCapabilities.MAXIMIZED.getName());
    Regards
    Rakesh

    I think you may have to set the 'Can Maximize' property on the portlet
    to 'true'.
    JP
    Subbu Allamaraju wrote:
    That should be enough.
    Subbu
    Rakesh wrote:
    Hi,
    Can some one help me as to how to maximize a portlet on click of a
    button? I am calling Page A.jsp to Page B.jsp.
    in the .jpf file, in the method which is being used to render Page
    B.jsp contains
    the below mentioned code. Do I have to do something extra or this much
    code is
    enough?
    //maximize portlet view
    PortletBackingContext context =
    PortletBackingContext.getPortletBackingContext(super.getRequest());
    context.setupStateChangeEvent(WindowCapabilities.MAXIMIZED.getName());
    Regards
    Rakesh

  • HI,  I need to jre 1.6 update 26 on my mac system to make some aaplication work. However latest available is jre 1.6 update 29. Could you suggest how I can get jre 1.6 update 26? I tried downloading older version on java. COuldn't find it on your site.

    HI,  I need to jre 1.6 update 26 on my mac system to make some aaplication work. However latest available is jre 1.6 update 29. Could you suggest how I can get jre 1.6 update 26? I tried downloading older version on java. COuldn't find it on your site.

    What are you missing?
    I inherited this app and signing the third party jars is how it was setup, I was wondering the same thing too, why was it necessary to sign the third party jars?
    The applet runs in either JRE 1.6.0_13 or JRE 1.6.0_27 depending on the other Java apps the user uses. JRE 1.6.0_13 does not have the mixed code security (so it is like is disable), but JRE 1.6.0_27 does have the mixed code security and the applet will not launch with mixed code security enable, so we have to disable it. With all the hacking going on in the last two years, is important to improve security; so this is a must.
    Yes, I always clear up the cache.
    Any idea on how to resolve this problem?

  • How to hide tray icon when in jframe

    how to hide the tray icon when v display a new JFrame in jdk1.5?

    use a JWindow or JDialog, but you may come across other problems if using
    them without a parent (the parent will be the one in the task bar)

  • How to set a location of a JFrame using mouseListener?

    Hi,
    I was wondering how i could set the location of a JFrame using the mouseListener? I know when i want to show a JPopMenu i can do:
    pop.setLocation(e.getX(), e.getY());
    pop.setInvoker(null);
    By using .setInvoker(); I can show the jpopup on the position that i clicked my mouse but this method is not available to the JFrame.
    Should i do this with the Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize(); instead? I was wondering if there is an easier way to do this. If not i can code a workaround but thats not my first choice.
    Thanks

    CaptainMorgan08 wrote:
    deAppel wrote:
    CaptainMorgan08 wrote:
    Why do you need setInvoker() for a JFrame? What's wrong with just setLocation()?The problem is that i want to show my frame where i clicked my mouse but when i get the x,y from the mouselistener getX/Ymethods the frame doesn't show up on the location where i clicked with the mouse, instead it shows the frame in the location x,y NOT relative to the mouse.I see. Well if you're using Java 6, you can use the getXOnScreen() and the getYOnScreen() methods from MouseEvent.
    http://java.sun.com/javase/6/docs/api/java/awt/event/MouseEvent.html#getXOnScreen()
    Otherwise you'll need to add the x and y coordinates of whatever component you're clicking on.I'm using Java 6, I tried your suggestion but i get the same value with getX/Y and getX/YOnScreen()

  • How to maximize a Form

    How to maximize a Form ?
    I want to set my Form in full-screen mode.
    Set_window_property (... MAXIMIZE ) does'nt work...
    Please Help...
    Thanks

    Yes I know.
    I can maximize and minimize my Window but I can't have it in full screen mode directly at start of the application.
    User must maximize his window himself.
    I want to have my window in full-screen directly.
    Any idea ?

  • How to maximize a popup window?

    Hi,
    My issue:
    A popup contains data larger that the screen size, it therefore maximizes itself, meaning that it sets its WIDTH to 100%. But this is most unfortunate as WD does not recognise its own scrollbar as the end of the available screen and now the close button (cross) of the popup is beneath the scrollbar!
    When doing a "true" maximize by clicking on the button left to the "closing cross", it recognizes scrollbars and stays visible in total.
    My question:
    How can I programmatically access the maximize/fullscreen function? Interface IF_WD_WINDOW does not provide a corresponding method as far as I can see...
    Already tried:
    ...please no "put width and height to 100%" as I already stated that this is not what I want...
    Also setting width to 95% or the likes does not work, as the popup automatically sets 100% on refresh if there are to large contents.
    <br>
    I would appreciate your help on this!!
    Kind Regards,
    Robert

    Hi Robert,
    You can do any size related actions in POPUP, Actually we have SET_WINDOW_SIZE Method to set window size,
    But for popups it wont work.
    Please check this thread, check Thomos reply
    Re: Confirm Popup in Web Dynpro, window size
    Check using set_window_size.. but can't effect.
    How to reduce Popup Window Size?
    As suggested saravanan, check SAP NOTE also.
    Cheers,
    Kris.

  • How to download only jre 1.5

    Hello I need jre 1.5 for installing tomcat I don't need JSDK. Can any one tell me how to download only jre 1.5
    Regards,

    Check this out
    http://mindprod.com/jgloss/jre.html

  • How to maximize Windows

    In Safari, I can minimize the size of window by typing Control-M,
    question: how to maximize the window size with keyboard shortcut? I found that clicking the little green button at the upper left corner difficult.

    You can't. No such function in Mac OS.
    Try searching MacUpdate or VersionTracker for a third-party utility.
    Zoom button (green button) toggles between a user set state and the smallest size that completely displays the content of the window.

  • How to maximize page

    Hi,
    I am new to Mac system. I just bought an iMac.
    I just encountered 3 problems. Please forgive me if this has been post before.
    My 3 problems are:
    1) How to maximize the page in Safari to occupy the whole screen ?
    2) Why do I getting drop signal from my wireless modem ?
    3) How do I check the signal strength ?
    Thanks you

    To maximize the page just grab the lower right hand corner of the screen and size to suit.
    hpr3

Maybe you are looking for