Delete selection listfield unfocus?

... Is semms listfield for keep the last item selected when the update leave the listfield there a way to display each item as disabled when the update leave the listfield?

Thank you!

In short, what a setting when focus is moved (it's not quite true, but enough for this topic):

(1) object Graphics Setup with the default settings for the field non-(including color)

(2) graphic in the field that had the focus for re-painting

(3) object Graphics Setup with the default settings for the field target (including color)

(4) go graphic in the field that focus receives for the painting of the target area

If you just need properly paint focus, you can change your status

if(listField.getSelectedIndex() == index)

in the drawListRow method for

if(graphics.isDrawingStyleSet(Graphics.DRAWSTYLE_FOCUS))

Important here is what is happening in step 2 when the control is asked to re - paint himself to clear the update. Last row is painted as focused because your condition is true for the last row when control.

My idea is simple: If you want to you want to customize the style for focus - do only when the update area is painted rather than each time control is redrawn. And framework will do the rest for you.

Edit: a few typos in the description including significant in step 3 description

Tags: BlackBerry Developers

Similar Questions

  • How to make the lines selectable listfield, when the list has been added to a dialog box

    Hello

    I added a listfield to a dialog box. Now I want that when I click on a line any of this list field, I should get a menu (i.e. something should be available for me so that I can perform an action on the selected line). But when I click on the line, nothing happens.

    Help, please

    Create your own screen, its less than the actual display dimensions to make it look like a pop-up screen. When a line is selected/clicked, call makeMenu.

  • Border around the selected ListField item?

    Hello

    I wonder if it is possible to customize a ListField, such as when you scroll through the list, the current row will have a border color around it?

    If this is not possible, I thought to imitate a ListField behavior using a TableLayout, where each row in the table has a HorizontalFieldManager.  Then, when an individual HorizontalFieldManager is selected, it will draw a border around it...

    Also, would it be possible to have a border around the current selected line (whether in a listfield or tablelayout) and then be able to select an object (such as a button) inside the line, without losing the border highlighted?

    Thank you!

    You might expect to have a special identification for the selected line in a ListField was asked and answered several times on this forum.  From memory, there are two options:

    (a) substitute drawfocus

    (b) in your drawListRow, check if the line that you draw is the selected line of the ListField.

    I suggest that you look in the forum for more information on these options.

    A ListField is a unique field, with a line at a time selected.  Without coding you something special it is not possible to have different parts of the line selected in different circumstances.  And although it is possible, don't normally add you a HorizontalFieldManager (or all other fields) to the ListField and which allows to paint content,

    What you're suggesting is indeed possible, but it is not for the faint-hearted.  I would recommend that investigate you other ways to achieve the desired effect before you start to look at using other fields to the layout and paint a line in the ListField.

  • How to get the element selected listfield and goto next page?

    Assalaamualikum

    I try parsing the XML from a url and show in listfield.

    problem:

    How to get the selected item and passing the variable and than goto next page?

    my code:

    package parsepack;

    import java.io.IOException;
    import java.io.InputStream;
    import java.util.Vector;

    Import javax.microedition.io.Connector;
    Import javax.microedition.io.StreamConnection;

    Import net.rim.device.api.system.Bitmap;
    Import net.rim.device.api.system.Display;
    Import net.rim.device.api.ui.DrawStyle;
    Import net.rim.device.api.ui.Field;
    Import net.rim.device.api.ui.FieldChangeListener;
    Import net.rim.device.api.ui.Graphics;
    Import net.rim.device.api.ui.Manager;
    Import net.rim.device.api.ui.UiApplication;
    Import net.rim.device.api.ui.component.ListField;
    Import net.rim.device.api.ui.component.ListFieldCallback;
    Import net.rim.device.api.ui.container.MainScreen;
    Import net.rim.device.api.ui.container.VerticalFieldManager;
    Import net.rim.device.api.xml.parsers.DocumentBuilder;
    Import net.rim.device.api.xml.parsers.DocumentBuilderFactory;

    to import org.W3C.DOM.document;
    Import org.w3c.dom.Node;
    Import org.w3c.dom.NodeList;

    extends xmlparsing public class UiApplication implements ListFieldCallback, FieldChangeListener
    {

    Public Shared Sub main (String [] args)
    {
    xmlparsing app = new xmlparsing();
    app.enterEventDispatcher ();
    }

    public long mycolor;
    Connection _connectionthread;
    private static ListField _list;
    private static Vector listElements is new Vector();.
    public display display = new MainScreen();
    MainManager VerticalFieldManager;
    VerticalFieldManager subManager;

    public xmlparsing()
    {
    Super();
    pushScreen (screen);

    final Bitmap Imagearriereplan = Bitmap.getBitmapResource ("blackbackground.png");

    mainManager = new VerticalFieldManager(Manager.NO_VERTICAL_SCROLL |) Manager.NO_VERTICAL_SCROLLBAR)
    {

    public void paint (Graphics graphics)
    {
    graphics.drawBitmap (0, 0, Display.getWidth (), Display.getHeight (), Imagearriereplan, 0, 0);

    Super.Paint (Graphics);
    }

    };

    subManager = new VerticalFieldManager(Manager.VERTICAL_SCROLL |) Manager.VERTICAL_SCROLLBAR)
    {
    protected void sublayout (int maxWidth, maxHeight int)
    {
    int displayWidth = Display.getWidth ();
    int displayHeight = Display.getHeight ();

    Super.sublayout (displayWidth, displayHeight);
    setExtent (displayWidth, displayHeight);
    }
    };

    Screen.Add (mainManager);

    _list = new ListField()

    {

    public void paint (Graphics graphics)

    {
    graphics.setColor ((int) mycolor);
    Super.Paint (Graphics);

    }

    };
    myColor = 0x00FFFFFF;
    _list. Invalidate();
    _list.setEmptyString ("* only supplies not available *", DrawStyle.HCENTER "");
    _list.setRowHeight (50);
    _list.setCallback (this);
    mainManager.add (subManager);
    listElements.removeAllElements ();
    _connectionthread = New Connection();
    _connectionthread. Start();
    }

    protected boolean navigationClick (int status, int time)
    {
    Try
    {
    Here, go to another screen if you need.

    }
    catch (System.Exception e)
    {
    System.out.println ("Exception:-: navigationClick()" + try ());
    }
    Returns true;
    }

    private class login extends thread
    {
    Public connection()
    {
    Super();
    }

    public void run() {}
    Doc document;
    StreamConnection conn = null;
    InputStream is = null;
    try {}

    Conn = Connector.open (StreamConnection) ("http://ec2-54-248-241-248.ap-northeast-1.compute.amazonaws.com/koperasi-akr-trial/cgi-bin/gw-pinjama...

    DocumentBuilderFactory docBuilderFactory = DocumentBuilderFactory.newInstance ();
    docBuilderFactory.setIgnoringElementContentWhitespace (true);
    docBuilderFactory.setCoalescing (true);
    DocumentBuilder docBuilder = docBuilderFactory.newDocumentBuilder ();
    docBuilder.isValidating ();
    is = conn.openInputStream ();
    doc = docBuilder.parse (is);
    doc.getDocumentElement () .normalize ();
    List of NodeList = doc.getElementsByTagName ("ID");
    for (int i = 0; i)< list.getlength();="" i++)="">
    Node node = list.item (i) .getFirstChild ();
    listElements.addElement (textNode.getNodeValue ());
    }
    } catch (Exception e) {}
    System.out.println (try ());
    } {Finally
    If (is! = null) {}
    try {is.close ();
    } catch (IOException ignored) {}
    } If (conn! = null) {}
    Try {conn.close () ;}
    catch (IOException ignored) {}
    }} UiApplication.getUiApplication () .invokeLater (new Runnable() {}
    public void run() {}
    _list. SetSize (listElements.Size ());
    subManager.add (_list);
    Screen.Invalidate ();
    }
    });
    }

    }

    ' public void drawListRow (list ListField, Graphics g, int index, int y, int w)
    {
    Your string = (String) listElements.elementAt (index);
    int yPos = 0 + y;
    g.drawLine (0, yPos, w, yPos);
    g.drawText (, 5, 15 + y, 0, w);
    }

    public {get {Object (ListField list, int index)
    {
    Return listElements.elementAt (index);
    }
    public int indexOfList (String prefix, ListField list, int, string)
    {
    Return listElements.indexOf (prefix, string);
    }
    public int getPreferredWidth (ListField list)
    {
    Return Display.getWidth ();
    }
    public final void insert (String toInsert, int index) {}
    listElements.addElement (toInsert);
    }

    ' Public Sub fieldChanged (field field, int context) {}

    }
    }

    Thank you.

    I told you that replace the navigationclick() method where initialize you your listfield

    as I think that changing your code and then answer me

    _list = new ListField()
    {
    protected boolean navigationClick(int status, int time)
    {
      Dialog.inform("hi");
      return true;
    }
    
    public void paint(Graphics graphics)
    {
    graphics.setColor((int) mycolor);
    super.paint(graphics);
    }
    };
    
  • How do I not selectable Listfield?

    Hello

    I have a listfield. In one case (when the user chooses an option button 2), I don't want this list to be selected by the user. So I want to remove the selection on this listfield in selection of radio button 2. I'm trying to solve this problem under fieldChanged with the following code:

    _lst.setEmptyString("",0);
    _lst.setSize(0);
    _lst.select(false);
    _lst.selectionDelete();
    _lst.setEditable(false);
    _lst.setSelectedIndex(-1);
    

    But it does not work as my expectation. With this code, I do not see the content of the list as expected, but able to select a line, which is of first rank, which is empty. I want to do the entire list to be unselectable.

    Please sugegst me how can I solve this problem?

    Thank you.

    FieldChangeListener and your custom ListField are completely independent. When you create your ListField, override its method of isFocusable() to take into account a flag value in turn depending on your state of the checkbox. This dependence can be established by setting FieldChangeListener on your field check box.

    Read the docs on the field. isFocusable () and it will become apparent.

  • Win 7 64 bit: How do I permanently delete selected files

    I don't want to erase my hard drive; I want to just delete some files and already deleted files. Is it already a program in Windows, or what I need to download something (free, I hope)?

    Hello

    Most of the data files you just delete and delete from the trash (or hold down SHIFT when you remove
    to stop the file to be sent to the trash). For programs you would uninstall them - use Revo
    -Free to ensure that they are removed carefully. After deleting files or uninstall the program then
    wipe free space helps prevent their recovery.

    If you have trouble to remove problematic files:

    Add 'Ownership' to the Menu Popup Explorer in Windows 7 or Vista
    http://www.howtogeek.com/HOWTO/Windows-Vista/add-take-ownership-to-Explorer-right-click-menu-in-Vista/

    Take and Grant Full Control permissions and ownership in Windows 7 or Vista right click Menu
    http://www.mydigitallife.info/2009/05/21/take-and-grant-full-control-permissions-and-ownership-in-Windows-7-or-Vista-right-click-menu/

    You can try in Safe Mode - several times F8 tap that you start.

    Login as an administrator.

    If Safe Mode does not help (and it may) try these.

    UnLocker 1.91 - free - the author Site - be sure to get the correct versions of 32 or 64 bit
    http://www.emptyloop.com/Unlocker/

    Unlocker 1.91 - free - be sure to get the correct versions of 32 or 64 bit
    http://www.Softpedia.com/progDownload/Unlocker-download-68439.html 

    I would not install the BING toolbar or Ebay option unless you really want.

    Download - SAVE - go to where you put it-click on - RUN AS ADMIN

    ---------------------------------------------------------------------------------------

    Below also work on Vista 32/64-bit

    Another good alternative - use FileAssassin:

    FileAssassin - free
    http://www.Malwarebytes.org/fileassassin.php

    Force delete (cannot delete) closed or in used files or folders with FileASSASSIN
    http://www.mydigitallife.info/2008/12/27/force-delete-cannot-delete-locked-or-in-used-files-or-folders-with-FileASSASSIN/

    Download - SAVE - go to where you put it-click on - RUN AS ADMIN

    And this - MoveOnBoot

    MoveOnBoot
    http://www.softwarepatch.com/software/MoveOnBoot.html

    ===============================================

    To uninstall programs (if necessary you can re - install problem program that does not properly uninstall)
    n ' not matter if he will run--then use Revo to uninstall).

    Revo Uninstaller - free
    http://www.revouninstaller.com/revo_uninstaller_free_download.html

    ==============================================

    CCleaner has the ability to erase free space.

    CCleaner - free - download of Piriform or FileHippo (below the offer costs).

    CCleaner is our system optimization, privacy and cleaning tool. It removes unused files from your
    system - allowing Windows to run faster and free up valuable disk space. It also cleans
    traces of your activities online such as your Internet history. In addition, it contains a fully featured
    registry cleaner. But the best part is that it's fast (normally taking less than a second to run) and
    contains NO Spyware or Adware! -Includes the reader - wiper (Tools - wiper Drive), which has different
    levels of wiping securiity of free space or the whole disc.
    http://www.Piriform.com/ccleaner/download

    Forums - help for CCleaner here
    http://Forum.Piriform.com/

    You can try this or similar utilities.

    Destructive PC is a software removal and data file shredder free, can permanently delete files,
    records and make it unrecoverable, completely destroy the files you specify, make it impossible
    for anyone to restore deleted information! Prevent your company data, important documents and
    personal information of remedial classes.

    PC Shredder is a Freeware. It's free for personal and commercial use. Destructive of documents PC works on
    Windows NT, Windows 2000, Windows XP, Windows Server 2003 and Windows Vista. There is none
    requirement of the minimum hardware requirements for PC Shredder runs correctly.
    http://www.pcshredder.com/

    Eraser - free - an advanced security tool for Windows that allows you to completely remove
    sensitive data from your hard drive by overwriting many times with carefully selected
    bosses.
    http://eraser.Heidi.IE/

    Best utility of free secure erase
    http://www.techsupportalert.com/best-free-secure-erase-utility.htm

    There are other tools available from Freeware to commercial products - BING or Google.

    I hope this helps.

    Rob Brown - Microsoft MVP<- profile="" -="" windows="" expert="" -="" consumer="" :="" bicycle="" -="" mark="" twain="" said="" it="">

  • Delete, select the Vs

    Guys,

    I had a doubt while he was working on the issue of an impasse. The thing is

    ""

    Suppose there is an old table that contains 100 records, and according to the requirement of the company, I pulled DELETE statement and at the same time, I started a SELECT query in another terminal.

    "

    So, now what will be the result

    1 remove is always in course and may be deleted on 50 files.

    2. as it is old table there no data buffer on this table to set ASIDE as retention expired.

    3. Select query gets stuck? deadlock occurs only for DML statements that I believe.

    Just curious about it.

    Thanks in advance. !

    -Vincent

    Writers do not block readers. Readers do not block writers.

    Your deletion will work. If you did not remove it yet, the selection will always return these results like the select statement will use the undo data to re-create the original data blocks.

  • Hello. Multi-state objects where States are grouped items, is it possible to delete selected only parts of these groups once made?

    Try to use an existing page with MSO as a model for a new page and looks like I can remove only an entire State, not a piece of. Any advice?

    Thank you

    Select items in the layers panel, and then delete.

  • Delete selected are

    Guys,

    1. I have an image;

    2. I create an orange photofilter over the image;

    3. I create a layer of black and white on the photofilter.

    4. I select a detail with my quick selection (one in the same menu as the magic wand);

    5. once I made the choice that I have 'used to' press the delete key so that the selected are gets deleted but now nothing happens! I tried all sorts of things, but suddenly this shit happens!

    Those who know s how can I reset everything to factory settings or something else?

    I tried all sorts of things, but suddenly this shit happens!

    Please, keep your cool.

    Could you please post a screenshot with the Panel visible layers on this Forum via the browser, no email response?

    Those who know s how can I reset everything to factory settings or something else?

    One can trash preferences by pressing control-alt-shift/ctrl-alt-shift keys to start Photoshop do appear in the appropriate dialog box (preferably after making presets of course all custom actions, patterns, brushes etc. have been saved and make a note of the preferences has changed).

    Please read this and acts accordingly:

    http://forums.Adobe.com/thread/419981?TSTART=0

    t http://blogs.Adobe.com/Crawlspace/2012/07/Photoshop-basic-troubleshooting-steps-to-fix-MOS - issues.html

  • Delete selected records? Enter the password that is configured.

    Has anyone seen this message before? Trying to delete a job, and asked to enter a password. I inherited this system, and I don't know why (or how) an access code to protect a particular job. In addition, if this is supported, no one knows where it is documented? I find no information about it in the user guide.

    Thank you

    Tim

    Hi Tim,.

    In the SYSVAL table to the schema of the tide, see if you have any input for SYSVAL_ID = 123.  Then see if it works as password.  You can not protect a single job as far as I KNOW, but you can protect a group of jobs.

  • How can I delete a ListField?

    I lie a ListField to a list of things that I get in return for a web service call.

    When I resubmit the query with a new search criteria (he lifts the names) the screen painting, resulting is less desirable.  It seems that the old tricks of the ListField is still there and will not disappear until I trackball selector on each line.

    I can't find what looks like a method to clear the ListField.

    Suggestions?  Thank you.

    BTW - ksoap2

    (1) Sux

    (2) finally works on my application after 3 weeks of DIY

    listField.SetSize (0); will work correctly. -Press on Kudoes and accept as a solution button, if you got to answer. Thank you.

  • CC of Dreamweaver keeps deleting selected text

    DW keeps removing the selections of text without reason. He's sometimes right after selection, other times is when he is selected by the search function. Running Mac OS x with the most current version of DW. Not sure if they are related, but it is also very difficult to copy and paste. The selections are made, the command copy is hit on the keyboard, but it sticks a previous selection. Only way to ensure the own C & P every time is to do it via the Edit menu.

    Check if the deactivation of your speech recognition helps...

    http://forums.Adobe.com/message/5928971#5928971

  • You can preview a waveform without a selection before deleting?

    Sorry if the title is confusing! I'll try to explain.

    I just work in Soundforge, and now try to Audition CC. I have used to do the following when the removal of sections of a file:

    With the area that you want to delete selected, press Ctrl + K. The file begins to play a bit before the selected area, jumps on the selected area and play a game after the selection. The audio plays back and you hear how the file would sound like if you have deleted the selected area. If it seems completely natural or if you determine that you have added too much or too little data to the selection, you can [...] adjust the selection accordingly. Press Ctrl + K again to see if it works better now. When you are satisfied that it sounds just the selected area, press delete.

    Is it possible to reproduce this workflow in the hearing? I know it's a small thing, but I used to be really useful.

    Hehe! They stole this feature of Audition in the first place!

    At the end of the transport bar is an icon that has a couple of vertical lines in it and an arrow. It's the ignore selection"" button. If you select a section, you can then listen to the effect of the jump it. If you press the delete key, it's gone. It is not a default hotkey to toggle the 'leap of selection', but you can allocate one in keyboard shortcuts if you want to.

    Incidentally, because Skip is a tilt selection that changes something, to play and jump still must press the 'play' button or the SPACEBAR.

  • You press on delete all selected items by browsing the data store and accidentally deleted a vmdk file which has the OS on it

    I accidentally deleted the vmdk file that has my OS on it by pressing the "Delete selected items" button in the window of browser data store. Is there anyway to recover? I have a snapshot that doesn't seem to work. There is still the VMDK file in there, but it has now 'delta' be added at the end. Now I get an error message when I try to turn on my VM saying that he doesn't get the vmdk file, of course.

    delta.PNG

    errorVMDK.PNG

    From the screen shots looks you have deleted only the descriptor hard files that can be recreated. To ensure this is the case, please provide a complete list of the files in the folder of the virtual machine and attach the last file.log of vmware(from the virtual work computer) to a post response to view required details.

    André

  • When you select multiple images in LR 5.2 on Mac, how delete all photos selected?

    Based on http://forums.Adobe.com/thread/1308132?TSTART=0 I decided to add each question separately:

    Hello, I am very interested in buying Lightroom 5.2. I tried the RC that was missing today. Yet, I have several questions that I can't find really good conclusive answers, I'd like to get an answer before buying LR. Please do not write maybe like this or that (assumptions), because I don't want to start my entire workflow and then realize that I have to change all around, please reply, if you know for sure that something works and you are, preferably, using this method too.

    When you select multiple images in LR 5.2 RC on my Mac, using the film display, how to remove all selected files using a shortcut (as opposed to from the context right click menu > delete selected photos)? Details: To backspace help wonder if I want to remove it, I choose to drive, but he simply deletes individual photos, so if I selected 3, I need to do this 3 times.

    Several operations of selection do not work in Film Strip mode.  You must be in the library to act on several photos grid-Module view.

Maybe you are looking for

  • Deleted my cache sites failed...

    I was playing a game that has kept to ruin (roblox), and I tried to delete my cache manually. Now, the site will not properly function, and I also found some other sites that fail now. I checked my firewall, but nothing is blocked from these sites...

  • Can I find missing files on iTunes faster?

    Hello I recently reinstalled all my music in one place. As I have a lot of music and it should always be to find all the files album by album, is there a way I can massage them find my music files in iTunes? Thank you Kieran 12.3.3.17 iTunes 64-bit W

  • A lot of "well, this is embarrassing" and FF hangs when downloading or opening Options

    FF3.6.6FF crashes when I try to download anything, it also crashes when I try to open the Options... I click on tools/options...nothing happens, if I click on tools I get again an hourglass and, possibly, a note not responding This has happened Each

  • Photosmart 6510 alignment fails

    Installed nine Photsmart 6510 that all is well until the alignment of cartridges, it failed after repeated attempts.  CANNOT print in black at all. all cartridges are new out of the box. Help, please.  I don't want to rturn this point, it looks so co

  • File deleted file recovery

    How can I recover my file that has been deleted by computer error?