Prevent Ctrl-A from selecting in JList

How can I prevent Ctrl-A from causing all items
in my JList to become selected?
This may seem like a strange question, but I have
a custom JList which uses a mouse listener to
detect selections rather than its usual selection
listener. Nevertheless, the Ctrl-A key combination
still causes all items to be selected.
How can I avoid this? I have tried simply
unregistering the key combination:
unregisterKeyboardAction(
javax.swing.KeyStroke.getKeyStroke(
java.awt.event.KeyEvent.VK_A,
java.awt.Event.CTRL_MASK,
false));
But this has no apparent effect.
b.c

Thanks, Dave.
I'm finding other inconsistent behaviour that is exacerbating the problem. If I close the last PDF file with ctrl-W, the search window stays open.  If I close the last PDF file from the task bar, boom, the search window gets clobbered too, which entails another lengthy re-search.

Similar Messages

  • Prevent Ctrl-W from closing Full Acrobat Search window

    When I do a Full Acorbat Search on a folder tree, it can take quite some time for all the hits to be found, and quite some time to work through the hits.  Usually, multiple PDF files are opened as I work through the hits.  As I close the PDFs with ctrl-W, it is very easy to accidentally close the Full Acrobat Search window, which means waiting forever to re-do the search and find my way to my current spot in the list of hits.  I find it highly inappropriate for ctrl-W to close the Full Acrobat Search window in the same way that it closes PDF files.  It is especially risky in Windows 7, where the window frames are translucent and the window with the focus is highlighted in a way that makes it very difficult to distinguish from the windows without the focus.
    Is there a way to prevent ctrl-W from closing the Full Acrobat Search window?  I am using Acrobat Professional 8.

    Thanks, Dave.
    I'm finding other inconsistent behaviour that is exacerbating the problem. If I close the last PDF file with ctrl-W, the search window stays open.  If I close the last PDF file from the task bar, boom, the search window gets clobbered too, which entails another lengthy re-search.

  • Inequality condition prevents the optimizer from selecting indices on tabl

    Dear all,
    I have the below query which takes 4 minutes to give the output:
    original query
    select t_sub.contrno "contNo" from tsk_subno t_sub ,arm_subs_balance bal where order_no = '5360' and
    order_type='NET' and t_sub.subno = bal.subno (+);sql tuning advisor is giving the below advise.. Restructure SQL
    Predicate NVL("IVM_BILLING"."BILLED",'N')<>'Y' used at line ID 14 of the execution plan is an inequality condition on indexed column "SYS_NC00071$". This inequality condition prevents the optimizer from selecting indices on table "TABS"."IVM_BILLING".How I can restructure the sql..
    FYI. arm_subs_balance is a view which takes data from IVM_BILLING.
    view script :
    CREATE OR REPLACE VIEW ARM_SUBS_BALANCE
    (CONTRNO, SUBNO, PAST_DUE, DEPOSIT, UNBILLED,
    TOTAL)
    AS
    SELECT contrno,subno,sum(past_due) past_due,sum(deposit) deposit,
           sum(unbilled) unbilled,
           sum(past_due+deposit+unbilled) total
    from
    select subno,0 past_due,0 deposit,0 unbilled,contrno
      from CRM_USER_INFO
    union all
    select nvl(H.subno,'0000000') subno, sum(nvl(R.ar_am_loc,0)) past_due,
           0 deposit,0 unbilled, R.contrno
      from     IVM_INVOICE_DETAIL R, IVM_INVOICE_RECORD H
      WHERE R.AR_REF=H.AR_REF
       and R.contrno = H.contrno
    group by nvl(H.subno,'0000000'),R.contrno
    having sum(nvl(R.ar_am_loc,0)) != 0
    union all
    select subno,0 past_due,nvl(add_deposit,0) depoist,
           0 unbilled, contrno
      from CRM_USER_EQUIPMENTS
    union all
    select subno,0 past_due,0 deposit, nvl(billamount,0) unbilled,
           contrno
      from IVM_BILLING
    where nvl(billed,'N') != 'Y'
    group by subno,contrnoThanks
    Kai
    Edited by: KaiS on Sep 30, 2009 10:10 AM

    Justin,
    I always thought that nvl(billed,'N') != 'Y' meant that the query should include all rows with a null-value or a value other than Y. :p
    But I agree that the index would moste likely not be that helpfull, but we need more information for that: [When your query takes too long|http://forums.oracle.com/forums/thread.jspa?messageID=1812597] and [HOW TO: Post a SQL statement tuning request |http://forums.oracle.com/forums/thread.jspa?threadID=863295]
    I expect that the conditions on tsk_subno will result in a small number of rows and that there's an index on tsk_subno.order_no which will be used to retrieve those rows.
    In that case view arm_subs_balance will be accessed on subno. This means that if the tables crm_user_info, crm_user_equipments and ivm_billing have indexes on subno, those indexes will be used, but an index on ivm_invoice_record.subno will not be used because of select nvl(H.subno,'0000000') subnoWithout more information I would guess that this part of the union takes longest and should be tuned by rethinking/redesigning the view or a function based index: create index i on IVM_INVOICE_RECORD ( nvl(H.subno,'0000000') );

  • How to prevent user from selecting a specific printer?

    Hi there
    I have a MailFolder which has an ArrayList of Email objects inside it. Each MailFolder has an attribute called folderFile which is a reference to a folder in the operating system. Each Email has an attribute called parentFile which is a reference to a file in the operating system.
    Now, I am trying to put printing into my application.
    When I print using a normal printer like my HP Deskjet or the likes - an actual physical printer - everything works fine. But when I print using the Microsoft Office Document Image Writer, things go wierd. The following things happen;
    I call myMailFolder.getFolderFile().exists() and this = false. But if I (in the debugger) make a new file pointing to the same path, .exists() = true. Also if I look in the OS, the file exists. So somehow in the job.print() this Document Image writer seems to be messing up this file reference. The same thing happens to the myEmail.getParentFile().
    So to fix this, can anyone tell me how to prevent the user from selecting this printer, or can anyone tell me why this is happening only with the Document Image Writer?
    Many thanks!
    Rachel

    I have similar problem with our printing program. I am printing Java Tables, zoom in every column in a landscape page accross multiple pages.
    There are two fatal problems:
    1. On Dell Latitude laptop, the HP5100 printer didn't work; I have to change the code to draw the table header with 2D graphics.
    2. Crash when printing on MS document image writer, but on some computers
    it works perfectly.
    Any one have a good solution/same result for topic 2?
    Thanks,

  • Is there a way to prevent an image from turning blue when selecting it?

    I'm exported a pdf from InDesign that will be used as a brochure for one of the exhibitions at our museum. I'm wondering if there's any way to prevent an image from turning blue when a reader clicks on it. Since all of the images are works of art, I'd rather that they not change color when people click on them.
    I changed the security settings so the images couldn't be copies, hoping that would prevent the blue square, but it didn't help.
    thanks for any suggestions.
    Chris

    There are several ways to do that and here are but two of them.
    1. If you want to make a new image you can right click on the channel, click on Duplicate Channel and under Destination>Document, select New
    2. If you want to add a new layer to your document, click on the channel in the channels panel, go to Select>All, then Edit>Copy, click on RGB in the channels panel and then Edit>Paste

  • I can't select lines in a pdf ? illustrator has already selected a series of blue rectangles that prevent me from select?

    Hi there, I'm new to illustrator I have been using it to change line weights in pdf's. however the last time i imported a pdf it opens with a series of blue selection boxes which prevent me from selecting individual lines. any ideas? any advice would be much appreciated. Rowan

    ^^Larry could be on to something there...
    Or...
    It's likely you're trying to deconstruct a PDF that wasn't saved by/for Illustrator, so its contents are nested within clipping masks.
    With one or more of those blue boxes selected, choose Object > Clipping Mask > Release

  • Latest xkeyboard-config prevents ctrl-alt-backspace from killing X

    well, as I wrote in the topic latest xkeyboard-config (1.6-1) is preventing ctrl-alt-backspace combination from killing X.  I have DonZap option set to false in my xorg.conf. I don't know if it should be like that. Is it a bug? If not, is it any workaround to make it work again?

    karol wrote:@whoops
    How did you get that magic spell? RTFM or sth else?
    I searched for stuff in google, opened a lot of tabs and somewhere in between there was a site about some patch that said something like "this patch removes the ctrl+alt+backspace keyboard shortcut in xorg - to reenable it, you have to type...".
    So I pasted it into a terminal, hit strg+alt+backspace and it worked. Which is why I don't know, where I found that Information.
    Might have been an ubuntu patch... maybe I should have mentioned that (in case someone added an ubuntu patch to xorg recently to make it "safer" and this is the result...?). edit: no, it wasn't - just found the ubuntu page I was on, and the information isn't from there. But it was on a patch site. Mostly plain text, code, patch info & lots of stuff I didn't understand.
    edit2: Aaaah, there it was: http://lists.freedesktop.org/archives/x … 00627.html
    Last edited by whoops (2009-05-29 21:41:33)

  • Preventing user from selecting item in JTree

    Does anyone know how to prevent the user from being able to change the cell in the tree that is currently selected?
    I have a JTree that the user can select items from but I want them to be able to click on a button and no longer be able to select an item in the tree until another button is pressed.
    Any ideas?

    hi
    i hope the code below helps ur purpose
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    import javax.swing.event.*;
    import javax.swing.tree.*;
    public class Frame1 extends JFrame {
    JPanel contentPane;
    BorderLayout borderLayout1 = new BorderLayout();
    JPanel jPanel1 = new JPanel();
    JButton jButton1 = new JButton();
    JButton jButton2 = new JButton();
    MyTree jTree1 = new MyTree();
    boolean blnSelection = true;
    /**Construct the frame*/
    public Frame1() {
    enableEvents(AWTEvent.WINDOW_EVENT_MASK);
    try {
    jbInit();
    catch(Exception e) {
    e.printStackTrace();
    /**Component initialization*/
    private void jbInit() throws Exception {
    //setIconImage(Toolkit.getDefaultToolkit().createImage(Frame1.class.getResource("[Your Icon]")));
    contentPane = (JPanel) this.getContentPane();
    contentPane.setLayout(borderLayout1);
    this.setSize(new Dimension(466, 319));
    this.setTitle("Frame Title");
    jButton1.setText("jButton1");
    jButton1.setBounds(new Rectangle(83, 254, 79, 27));
    jButton1.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(ActionEvent e) {
    jButton1_actionPerformed(e);
    jPanel1.setLayout(null);
    jButton2.setText("jButton2");
    jButton2.setBounds(new Rectangle(177, 256, 89, 23));
    jButton2.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(ActionEvent e) {
    jButton2_actionPerformed(e);
    jTree1.setBounds(new Rectangle(93, 30, 252, 195));
    contentPane.add(jPanel1, BorderLayout.CENTER);
    jPanel1.add(jButton1, null);
    jPanel1.add(jButton2, null);
    jPanel1.add(jTree1, null);
    /**Overridden so we can exit when window is closed*/
    protected void processWindowEvent(WindowEvent e) {
    super.processWindowEvent(e);
    if (e.getID() == WindowEvent.WINDOW_CLOSING) {
    System.exit(0);
    void jButton1_actionPerformed(ActionEvent e) {
    blnSelection = false;
         jTree1.setSelectionPath(null);
    void jButton2_actionPerformed(ActionEvent e) {
    blnSelection = true;
    class MyTree extends JTree implements TreeSelectionListener
         public MyTree()
              super();
              init();
         private void init()
    this.getSelectionModel().setSelectionModeTreeSelectionModel.SINGLE_TREE_SELECTION);
              this.addTreeSelectionListener(this);
              this.setEditable(false);
         DefaultMutableTreeNode selectedNode = null;
         public void valueChanged(TreeSelectionEvent evt)
    if(!blnSelection)
         this.setSelectionPath(null);
         else
         TreePath tpSelectedTreePath = evt.getNewLeadSelectionPath();
         this.setSelectionPath(tpSelectedTreePath);
    cheers

  • My iTunes wont close and is preventing my laptop from shutting down

    I plugged out my iPod touch when iTunes was asking me whether I wanted an update or not, and now iTunes wont close and has frozen, preventing my laptop from shutting down. I have intel Celeron inside and Windows 7.

    Mail is open but it is frozen, being this the reason why you cannot open the Mail window. Press Alt, Command and Esc keys or go to  > Force Quit, select Mail and force quit it. Finally, you will be able to turn off or restart the MacBook

  • I am trying to download a video file which I have on my computor to facebook but Firefox continuously shows theis message"Firefox automatically prevented this page from reloading.

    Steps.
    Open Facebook page.
    On the wall select video.
    Select upload a video from your drive.and click on it.
    Drop down window opens.
    Select a video file on your computer.
    Please upload only if:
    The video is under 1,024 MB and 20 minutes.
    The video was made by you or your friends.
    Click on browse
    Firefox"File Upload window opens"Pictures Library"Exposing available videos on my file.Double click on the video selected.
    Browser window opens and shows:"Brian on the move again..MPG.
    Click on "Share"Uploading Video-Mozilla Firefox"window opens and shows: http://www.facebook.com/video/upload_popup.php?video_id=2654584286114&qn=1321170149&xhpc_composerid=uqj39y_10&xhpc_context=profile&profile_id=185862931498895
    Bellow that :Firefox prevented this page from automatically reloading."Please wait while your video uploads."But is blocked .
    Check the "Allow"button Allows it to run for about 5 seconds before blocking again. This is uploaded in the 5 second intervals 1.) 4.13 MB of 39.87 MB (13.16 KB/sec) -- 46 minutes remaining. 2.) 5.33 MB of 39.87 MB (13.22 KB/sec) -- 44 minutes remaining 3.) 6.09 MB of 39.87 MB (13.11 KB/sec) -- 43 minutes remaining. 4.) 6.67 MB of 39.87 MB (13.18 KB/sec) -- 43 minutes remaining. 5.) 6.) 7.43 MB of 39.87 MB (13.11 KB/sec) -- 42 minutes remaining etc etc and so on and so on,each time the "Allow"button is checked the message :Waiting for vupload.facebook.com -Connecting-Connected-Sending request-Transferring data appears and after checking the "Allow" button 10 or 12 times we arrive at"11.93 MB of 39.87 MB (13.22 KB/sec) -- 36 minutes remaining.The upload shows 36 minutes remaining but the video itself is no longer than 1 min 54 sec and 39.8 MB in size.

    See:
    *Firefox/Tools > Options > Advanced > General : Accessibility : [ ] "Warn me when web sites try to redirect or reload the page"
    The setting in "Tools > Options > Advanced > General" is meant as an accessibility feature, as you can see by the label of that section, so that people with disabilities or people who use screen readers do not get confused and is not meant as a safety protection to stop redirecting.
    See also:
    *https://support.mozilla.com/kb/Options+window+-+Advanced+panel#General_tab
    *http://kb.mozillazine.org/accessibility.blockautorefresh
    *http://kb.mozillazine.org/Accessibility_features_of_Firefox

  • When I click on a link in an email I get the following message at the top of the screen: "Firefox prevented this page from automatically redirecting to another page...[Allow]. How can I stop this?

    When I click on a link in an email using gmail in the Mozilla brower, I get the following message at the top of the screen:
    "Firefox prevented this page from automatically redirecting to another page...[Allow].
    How can I stop this?

    # Press Alt+T
    # Select Options
    # Select Advanced Panel
    # Select General Tab
    # You will see option "Warn me when websites try to redirect or reload page"
    # Uncheck it as given in the screenshot.
    <img src=http://dl.dropbox.com/u/7456129/Firefox/advancedgeneraltab.jpg width=600px height=600px>
    ''<hr>Note: If anyone's reply has solved your problem, then please mark that reply as "Solved It" to the right of that reply after logging in your account. It will help us to concentrate on new questions.''

  • Is there a way to prevent ibooks author from shutting down after just one or two uses of the alpha tool?

    Is there a way to prevent ibooks author from shutting down after just one or two uses of the alpha tool?

    Hello One Job at a time,
    Deleting the application will not delete your projects.
    Normally I keep all my work files on a separate drive.
    If you command click on the title name of your project you will get a drop down path to show you the location of your book project.
    or you can click on the drop down triangle beside its name to duplicate.
    Just remember where you saved the file too.
    In your applications folder on your computer select the iBA icon and press delete and also erase / empty the trash can.
    You can then go back to the APP STORE and install iBA from new again.
    I hope this helps.
    Regards,
    Nigel

  • How to prevent hard disks from sleeping

    Hello
    I have recently installed a SSD for system drive in my machine, and now realise what a bottle neck the old, standard hard disk had been. Booting is now extremely fast, as is opening applications. This speed has alerted me to another problem. My hard disks keep falling asleep, which slows down operantion of the machine significantly. For instance, to log into this forum, I used 1Password. When selecting the log in menu item from 1Password, there was several seconds delay before one of the hard disk (I have four inside the machine, one external Drobo, and one external eSata drive) came alive. When it had, Safari could take me into the site. There constant delays like this when I use Safari, for example. These delays are very frustrating, so I want to keep all my disks awake constantly.
    Thing tried so far:
    The worst problem was the Drobo, because it has three disks inside that wake up one after the other, a very slow process, and the Drobo is slow in itself. So I installed a little script that does a touch command every five minutes, to prevent the Drobo from sleeping. It seems this has helped. But the other disks keep falling asleep all the time. I have set Cocktail to prevent all disks from sleeping - no effect. The Energy Computer Sleep setting is set to Never.
    Any ideas will be much appreciated. This sleep issue keeps bugging my all day long.

    In the Energy Saver system pref, are any of the boxes checked?
    If it were me, I guess I'd try clicking the 'restore defaults' button in Energy Saver, restart the computer, and then go back into the Energy Saver and set the computer sleep to either 3 hours or never, and uncheck the 'put hard disks to sleep when possible' box. You might try 3 hours instead of never and see if that makes a difference.

  • How We can restrict the max no of Selections in JList

    Hi,
    How We can restrict the max. no of selections (at random selections) in JList (ex. max No of of selections is 3 in a JList of having 50 items.)
    Thanks for your advise in advance.

    Hello Satyaki De.
    Thank you very much for your suggestion but my Private information is totally apart from this question & I already I have changed each and every information from the question.
    Thanks
    Kamlesh Gujarathi
    [email protected]

  • HT1277 my mail will not open after I click on mail.when I try to shut down my laptop ,it wouldn't  telling that mail is preventing the computer from shutting down,asking to quit Mail and when I do mail dose not quit

    my mail will not open after I click on mail.when I try to shut down my laptop ,it wouldn't  telling that mail is preventing the computer from shutting down,asking to quit Mail and when I do mail dose not quit

    Mail is open but it is frozen, being this the reason why you cannot open the Mail window. Press Alt, Command and Esc keys or go to  > Force Quit, select Mail and force quit it. Finally, you will be able to turn off or restart the MacBook

Maybe you are looking for