Several windows and grid questions

Hello, I have a couple of Swing related questions that follow:
Q 1)
Imagine I'm writing a basic GUI that has 2 "windows": the main window and the about box window. Basicly there's a JMenu with a JMenuItem that has an action that will set the about box visibility to true.
My question is: what's the most correct way to do this?
a) declare both windows in the Gui constructor, having the main window's visibility set to true and the about box window visibility set to false, changing that visibility inside a actinPerformed () method
b) declare the main window in the Gui constructor, and then creating the about box window inside the actionPerformed method, when the MenuItem is selected
c) other. please explain
Q 2)
Is there any way to automaticly draw a grid within a JFrame or does it have to be done with Graphics' drawRect, drawLine and so on?
Thanks in advance.

Q1: c, have a getter for the aboutBox and instanciate when needed (also possible with b). If the user never clicks the menuItem, why instanciate and clean up later?
Q2: DrawRect /line

Similar Messages

  • Overlapping Windows and Panels Question

    Hi, I have photoshop cs5 for the mac and I want to display 2 images of my project.  I did this buy going to window>arrange>New Window For "project name"  I want to be able to see one zoomed out and just have it displaying in the top corner.  I position this new window on the top of my screen, but when I click on my "main" window, the new one just goes behind it and disappears.
    My question is can I have my "main working window" tabbed in photoshop, while I have the smaller zoomed out duplicate window floating on top of it?
    I would like for the smaller window to always be on top of my "main" working window of my project even while I have the "main" window selected.  Is this possible on the mac version?
    To solve this, I can make both of them floating windows and position them so that they do not overlap, but this takes up a lot of room on the screen.
    I hope this description makes sense.  Thanks in advance.

    I have application frame turned on and it does not work.  The navigator is ok, but its too small and you cannot edit in it like you can in another copy of the project.
    I have seen photoshop work in the way I describe, but it was on Windows.  Could this just not be possible with the mac os?
    Thanks for the quick replies

  • Several Iweb and godaddy questions.

    Hello Folks:
    Just to give you an idea of my proficiency with web design, I'm the equivalent of a student pilot who just soloed. Just enough knowledge to be dangerous and a threat to mankind. Here are my questions:
    1. How do I use text editor or word to modify my HTML? I can view the HTML of my site, copy and paste, but can't get it back into iweb as other than alphabet soup. I specifically want to change the email address. I wrote the site having my personal email address in my address book and can't change it to the business email address by just re-publishing with the change to my address book.
    2. I published to Godaddy and of course cant use the counter. I tried to follow the instructions after starting an account at Statcounter.com but don't know how to insert it then change it back to a web site. Same basic problem as the email.
    2.1 Why would Mac consider something as basic as a counter to be proprietary?
    3. Can't get the slideshow to work on Godaddy. It works fine on my computer. On Godaddy, the slide show bar at the very bottom does not publish. I get an enlarged photo with a border on only three sides, nothing at the bottom. I can also enlarge each photo one at a time with the same results.
    4. Is the Iweb loaded on my Mac a watered down version? Seems like a lot of features may be lacking, especially if you want to do a business website like mine. I love my Macs and don't want to have to switch to some windows program, but need more than I see on Iweb.
    My website is www.airlandandseaparts.com. I'm going to switch into windows hard drive now and see if the slideshow works.
    Thank you very much.
    Regards,
    Kevin
    Intel IMAC and Ibook   Mac OS X (10.4.9)  

    I wrote the site having my personal
    email address in my address book and can't change it
    to the business email address by just re-publishing
    with the change to my address book.
    You should be able to though... this is strange... Especially if you are publishing to a folder, then you should be able to re-upload the newly published files with the proper email address.
    2.1 Why would Mac consider something as basic as a
    counter to be proprietary?
    The resources for the counter are hosted by .Mac. They can't possibly account for every variable as far as available resources on other hosts. (php, etc - stuff I don't understand nor want/care to but thats what it is about probably)
    3. Can't get the slideshow to work on Godaddy. It
    works fine on my computer. On Godaddy, the slide
    show bar at the very bottom does not publish. I get
    an enlarged photo with a border on only three sides,
    nothing at the bottom.
    Try re-uploading your slideshow_assets folder.
    I can also enlarge each photo
    one at a time with the same results.
    This is how the non-.Mac slideshow works.
    You might like this one better:
    http://www.codemanic.com/blog-archives/000084.html

  • Apple Bluetooth Headset - Paring with Windows and Other Questions

    Love my new Apple Bluetooth Headset, works great. My first one did have a problem with poor range but this one is a lot better. I've been wanting to use the headset as a mic. Windows XP finds the headset find but I can't tell if it's connecting or not. How do I tell the Headset what device to connect to? It's paired to my iPhone too so it picks up on my iPhone every time I try to connect.
    Basically how do scroll through on the Headset what devices to connect to? Usually Bluetooth Headsets can be paired with multiple devices and you do certain button combinations to scroll through the paired devices.

    unlike some of the sony ericssons, the apple headset can only be paired with one phone at a time. that doesn't stop you from repairing it when need be, however...

  • Flash Player opens several windows.

    Flash Player opens several windows and does not work. Uninstalled yesterday downloaded new rebooted and reinstalled. Same thing. Windows 7 Pro, Firefox 17.0.1 Usually leaves a blank window upper left on my desktop.

    Try resetting your Firefox profile (if you have't already).  Instructions to do this are partway down in this FAQ.
    How do I troubleshoot Flash Player's protected mode for Firefox?

  • HT2433 My laptop opened with a grey flashing file folder with a question mark inside it .  How to to open my laptop!  I have tried fir e clising several times and restArting  nope nada!

    My laptop opened with a grey flashing file folder with a question mark inside it .  How do  I open my laptop!  I have tried force closing several times and restArting  nope !  nada!  Suggestions?

    That folder with the question mark icon means that the MacBook can't find the boot directory. That can either mean it can't find the hard drive or the Operating System data on the hard drive is somehow corrupted.
    With 10.4, 10.5 or 10.6 put your install DVD into the optical drive (CD/DVD drive) and reboot. Be sure to either use the disc that came with your Mac, or, if you installed a later Mac OS X version from disc, use the newer disc. As soon as you hear the boot chime, hold down the "c" key on your keyboard (or the Option Key until the Install Disk shows up) until the apple shows up. That will force your MacBook to boot from the install DVD in the optical drive.
    Or if you are running 10.7 Lion, 10.8 Mountain Lion or 10.9 Mavericks, boot from the recovery partition (Command +R on boot) and use Disk Utility to repair your OS 10.7, 10.8 or 10.9 partition.
    When it does start up, you'll see a panel asking you to choose your language. Choose your language and press the Return key on your keyboard once. It will then present you with an Installation window. Completely ignore this window and click on Utilities in the top menu and scroll down to Disk Utility and click it. When it comes up is your Hard Drive in the list on the left?
    If it is, then click on the Mac OS partition of your hard drive in the left hand list. Then select the First Aid Tab and run Repair Disk. The Repair Disk button won't be available until you've clicked on the Mac OS partition on your hard drive. If that repairs any problems run it again until the green OK appears and then run Repair Permissions. After repairing use Startup Disk from the same menu to choose your hard drive for restarting from your hard drive.
    If your hard drive isn’t recognized in Disk Utility then your hard drive is probably dead.

  • Newbie Grid Questions - Windows 2008 v11gr2

    Hi all
    As stated I am completely new to Oracle and have managed to do an single instance install and am now attempting a Grid and then RAC install.
    I have created 2 VMs and 5 disks. During the Grid install I stamped the disks so that they could be used for ASM and put them all in a disk group called Data. I selected External redundancy.
    In the previous documentation I have seen that during the Grid install you select where to put your voting files and OCR files but this never happened for me, is this correct? Also how can I check I have clusterware installed correctly? The documentation says that the verification utility runs automatically and I think this happened as the Grid install completed successfully.
    One concept I am having troubles with is if the clusterware is installed as part of Grid then why do we need RAC?
    My questions are probably very general and cover a lot, but any help in the right direction would be appreciated.
    Thanks

    Hi,
    In the previous documentation I have seen that during the Grid install you select where to put your voting files and OCR files but this never happened for me, is this correct?If you selected to Oracle ASM as the storage option for the OCR and voting disk files, then the Oracle Automatic Storage Management Configuration Assistant (ASMCA) configures Oracle ASM as part of the installation process.
    If you did not select Oracle ASM as the storage option for the Oracle Clusterware files, then you must start ASMCA manually after installation to configure Oracle ASM.
    There are two ways of storing the shared Oracle Clusterware files:
    Oracle ASM: You can install Oracle Clusterware files (OCR and voting disks) in Oracle ASM disk groups.
    OCFS for Windows: OCFS for Windows is the only other supported cluster file system that you can use to storage of Oracle Clusterware and Oracle RAC files on Microsoft Windows platforms.
    Starting with Oracle Database 11g release 2 (11.2) and Oracle RAC 11g release 2 (11.2), using DBCA or OUI to store Oracle Clusterware or Oracle Database files on raw devices is not supported.
    Also how can I check I have clusterware installed correctly? The documentation says that the verification utility runs automatically and I think this happened as the Grid install completed successfully.You can use Cluster Verification Utility.
    The cluvfy stage -post crsinst command to check the specified nodes after installing Oracle Clusterware.
    http://download.oracle.com/docs/cd/E11882_01/rac.112/e16794/cvu.htm
    One concept I am having troubles with is if the clusterware is installed as part of Grid then why do we need RAC?I do not understand what you meant with GRID is grid infrastructure (software Oracle ) or grid computing (concept).
    If is concept check this..
    Re: What is difference between Oracle RAC and Grid Computing
    Regards,
    Levi Pereira

  • Hangs, severe slowness and lock-ups running Firefox 27.0 / 28.0 on Windows XP / Is it possible to block plug-in container?

    Been experiencing severe slowness and lock-ups with Firefox of late, which ends with a sudden drop in memory usage and me having to repeatedly shut it down through Task Manager. I have created a new profile and disabled hardware acceleration. I have tried disabling all plug-ins and extensions, yet I noticed that at times (not always) plug-in container was still an active process, which I don't understand. Why would it be active when there are no enabled plug-ins? I also noticed that when plug-in container is not active (showing under Processes in Task Manager) I do not have this problem and Firefox runs normally? I need to block plug-in container. Please help.

    I have just tried on Windows 7 and used process explorer on that. I would expect the results to be displayed in a similar manner on Windows XP.
    Plugin-container is shown as being run from Firefox, and in turn if I mouse over or left click the line for plugin-container .exe then under ''command line'' it tells me what is running, in my case at this instance it is Flashplayer and so it displays
    .... \Macromed\Flash\NPSWF32_12_0_0_77.dll .... plugin ....
    It is identifying it is FlashPlayer
    The worry with your apparently unknown operation is that within the plugin-container it may be safe but if plugin-container is disabled maybe it could be malware and cause a problem.

  • I noticed when I restart Firefox 4, it opens my previous tabs even I set the option "Open a blank page" and it opens blank page when I have "Show my windows and tabs from last time". Please ignore my question if you're already aware of this issue. Thanks.

    I noticed when I restart Firefox 4, it opens my previous tabs even I set the option "Open a blank page" and it opens blank page when I have "Show my windows and tabs from last time". Please ignore my question if you're already aware of this issue. Thanks.

    Your previous tabs will not re-open or be available to re-open when starting Firefox if:
    *your previous session was in Private Browsing mode; see --> http://support.mozilla.org/en-US/kb/Private+Browsing
    *you use Clear Recent History (''Firefox button > History > Clear Recent History'' or ''Tools > Clear Recent History''); see --> https://support.mozilla.org/en-US/kb/Clear%20Recent%20History#w_how-do-i-clear-my-history
    *you clear History automatically when closing Firefox; see --> https://support.mozilla.org/en-US/kb/Clear%20Recent%20History#w_how-do-i-make-firefox-clear-my-history-automatically
    NOTE: Your third-party Plugins (Add-ons > Plugins) are not in the "Application Basics" (Troubleshooting Information) in the "More system details" of your original post. Third-party Plugins are categorized separately in "Installed Plugins" under "More system details". You should review but not change the Plugins as detected automatically by the software on this forum when posting a question.
    If you problem still exists after checking the above, the problem could be caused by one or more of your Extensions or Plugins:
    *See --> [http://support.mozilla.org/en-US/kb/Troubleshooting+extensions+and+themes Troubleshooting extensions and themes]
    *See --> [http://support.mozilla.org/en-US/kb/Troubleshooting+plugins Troubleshooting plugins]
    *See --> [http://support.mozilla.org/en-US/kb/Basic+Troubleshooting Basic Troubleshooting]
    '''If this reply solves your problem, please click "Solved It" next to this reply when <u>signed-in</u> to the forum.'''

  • Firefox is already running, but is not responding. To open a new window, you must first close the existing Firefox process, or restart your system. I have a wndiws 7 system and use a Intel core processor. I have restarted several times and still ge this

    Firefox is already running, but is not responding. To open a new window, you must first close the existing Firefox process, or restart your system. I have a wndows 7 system and use a Intel core processor. I have restarted several times and still ge this error. I have also tried to reinstall firefox and get the same error
    == This happened ==
    Every time Firefox opened
    == today ==
    == User Agent ==
    Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; MDDS; InfoPath.2; .NET4.0C; AskTbUT2V5/5.8.0.12304)

    <u>'''Kill Application'''</u>
    In Task Manager, does firefox.exe show in the <u>'''Processes'''</u> tab?
    See: [http://kb.mozillazine.org/Kill_application Kill Application]
    '''<u>Causes and solutions for Firefox hanging at exit:</u>'''
    [[Firefox hangs]]
    [http://kb.mozillazine.org/Firefox_hangs#Hang_at_exit Firefox hangs at exit]
    [[Firefox is already running but is not responding]]
    <u>'''Safe Mode'''</u>
    You may need to use '''[[Safe Mode]]''' (click on "Safe Mode" and read) to localize the problem. Firefox Safe Mode is a diagnostic mode that disables Extensions and some other features of Firefox. If you are using a theme, switch to the DEFAULT theme: Tools > Add-ons > Themes <u>'''before'''</u> starting Safe Mode. When entering Safe Mode, do not check any items on the entry window, just click "Continue in Safe Mode". Test to see if the problem you are experiencing is corrected.
    See:
    '''[[Troubleshooting extensions and themes]]'''
    '''[[Troubleshooting plugins]]'''
    '''[[Basic Troubleshooting]]'''
    If the problem does not occur in Safe-mode then disable all of your Extensions and Plug-ins and then try to find which is causing it by enabling <u>'''one at a time'''</u> until the problem reappears. <u>'''You MUST close and restart Firefox after EACH change'''</u> via File > Restart Firefox (on Mac: Firefox > Quit). You can use "Disable all add-ons" on the Safe mode start window.

  • TS1538 I have 6th gen iPod nano.  When I try to sync it my computer tells me it has malfunctioned and Windows does not  recognize it.  My iPhone syncs fine so the problem must be the iPod.  I have reset the iPod several times and no luck.  Any suggestions

    . I have 6th gen iPod nano.  When I try to sync it my computer tells me it has malfunctioned and Windows does not  recognize it.  My iPhone syncs fine so the problem must be the iPod.  I have reset the iPod several times and no luck.  Any suggestions?

    Hello Alexdad,
    We've an article that can help get your iPod Nano working with your computer.
    iPod nano: Error message saying that iPod 'could not be identified properly'
    http://support.apple.com/kb/TS3218
    Cheers,
    Allen

  • My desktop IMac OSX 10.6.8 : IMovie '11: Trying to upload a home movie clip from my Panosonic camera model PV-DV203D. I've had this camera several years, and used it with Windows desktop. Now trying to work with my Mac. I have a USB cable, both ends fit,

    My desktop IMac OSX 10.6.8 : IMovie '11: Trying to upload a home movie clip from my Panosonic camera model PV-DV203D. I've had this camera several years, and used it with Windows desktop. Now trying to work with my Mac. I have a USB cable, both ends fit, but iMovie '11 does not recognize it. Is there a driver fix for this?

    What kind of Mac to you have?  This camera is a tape based DV one that connects best with firewire and I cannot tell if your Mac has firewire.  If your mac *does* have firewire, get a camcorder firewire cable and try again.
    ETA:  Oops, I am pretty sure that all the "desktop iMacs" have firewire, so you should be good to go.  You will probably need a cord that goes from FW800 to your camcorder.

  • Error 5 on Start up (Windows Error 7) - why and how do I overcome it? Have removed and reloaded several times and also tried repairing, but to no avail.

    I am experiencing Error 5 on Start up (Windows Error 7) - why and how do I overcome it?  I have removed iTunes and reloaded it several times and also tried repairing, but to no avail.

    apandua2105
    To properly uninstall iTunes for Windows see this link:
    http://support.apple.com/kb/HT1923
    After redownload iTunes from Apple and reinstall:
    http://www.apple.com/itunes/download/

  • New implementation - Client having issues with RAC and Grid on Windows

    Client is starting a new implmenetation on Windows 2008 R1, Oracle 11.1.0.7. They have a 3 node RAC and Grid Control. They are having a number of issues and support is working through those issues. They are asking if there are clients on RAC and Grid on Windows. The Wiki shows a few customers on Windows, but was hoping to get some feedback. Tks.

    There are lots of customer applications that are based on Windows RAC. And as mentioned above, it is very well supported by Oracle.
    However, because of the security vulnerabilities of Windows, I've observed that most of the financial institutions and listed companies opt for unix based servers for all high profile applications and run only low to medium risk application on Windows.
    Regarding maintanence issues, I guess it's going to be pretty much the same; there shall always be lots of bugs, lots of patches and updates just like an yother software; doesn't really matter if you are on Unix or Windows systems. As long as you purchase support, it's all good.
    It's pretty much same concern regarding Grid Control on windows.
    Cheers.

  • Dock question:  Can I turn off the expansion/condensing effects of Fan and Grid view?

    Hi!
    Can I turn off the Dock menu expansion/condensing animations related to Fan and Grid view (and the condensing effect of List view)?  I find the expansion/condensing animations slow and detracting from an efficient workflow.  I would rather have menus pop up immediately so I can instinctively move the mouse cursor where I can anticipate a file to be located once grid/fan view window launches, rather than have to track the expansion animation with the mouse cursor so that I can select the desired file once it lands in its fixed position.
    Is there any known backdoor way to cease these showboating animations?
    For the dock to be such a major addition to the Mac OS (when compared to OS 9), I am surprised that there isn't greater customization for it.  Speaking of which, why can't we have the option of having more than one dock, for example?  I would like to have one mounted to the bottom of my screen for applications, but also have one on the left of my screen for commonly-accessed files and folders.
    I am all for stock settings that help to streamline features for users as a baseline, but the more tweakable options the better.  I pay a premium for Apple products; who are they to tell me I can have only one dock?!  ;p
    I've taken a look at Docker and Deeper, but neither delivered the goods.  Thanks so much!
    P.S.  I am still using Snow Leopard.  I haven't heard of new dock options for Lion, so please clarify if I am missing out on a Lion innovation.
    Thanks again!

    Take a look at Secrets, OnyX, or Tinker Tools. All of those have various undocumented preference settings that affect various animations.

Maybe you are looking for

  • Install oracle ODBC 64 bit driver

    Hi all, I have couple of clients (users) looking for ODBC 64 driver for Oracle in windows 7 64 bit. They have Oracle 10g 32 bit installed. In environment, oracle 64 bit is not compitable with some of measure software they use, so need to utilize 32 b

  • Kxml and NanoXml

    Hi! I wonder if anyone used this API on the client side, i.e., has someone use this as an extension of MIDP??? How?? Can you put this jar on some J2ME compliant device and use it in many other applications??? I'd really appreciate some hint about thi

  • Bring window to the front

    Hi,   I want to bring the window to front when it is behind the window as well as when it is minmized. I have done for minimized state. But i was not able to bring the window to front when it is behind some window. Thanks & Regards, Jayagopal.

  • How to add an App in iTunes Connect?

    I'm using MagPlus to builld my App with iTunes Connect.. Where do I "Add New App" on iTunes Connect? I have an iOS Develop Account. First screenshot is my homepage in iTunes Connect, 2nd one is their sample page of where I need to be. My page doesn't

  • PWM control through USB 6008/09

    Hello all I have already read a thread regarding the topic but i am not satisfied with the replies. I have discovered few programs that can run PWM in LabView, but they all are for DAQmx. So, will those programs run through USB 6008? and i also read