'Get link' the context menu element gone

Why is that if you save a template with the template repository that corresponds to a url, your menu item appears and the default menu item "Get link" disappeared?

JDE 4.5

8330 (Simulator)

Default CDMA network

If methods both PatterRepository that StringPatternRepository seem to make the menu option 'Get link' system disappear if you save a model that recognizes a url.

The way I had the time is (finally!) pretty simple really: (may not be perfect)

1. in your screen class (extends screen), override the method "makeMenu (menu Menu, for example int).

2. remove your custom menu item.

3. determine which control has the focus (if you care about that).

4 loop through each of the menu items after you call super.makeMenu (menu, for example) and look for a menu item that contains the text "get link".  (I guess if "Get link" then it's a kind of matching url)

5 get the text underlined/matched and do something with it as if it matches a particular value or what not, add your menu item.

Example (proof of concept):

protected void makeMenu(Menu menu, int instance) {
   MenuItem m = null;
   String url = "";

   super.removeMenuItem(_MyCustomUrlDoSomethingMenuItem);
   super.makeMenu(menu, instance);

   if (_SomeGlobalVariableForAControl.isFocus()) {
      //if you care about what control has focus
      for (int i = 0; i < menu.getSize(); i++) {
         m = menu.getItem(i);
         if ((m != null) && (m.toString() != null) && (m.toString().trim().toLowerCase().equals("get link"))) {
             //this is the "Get Link" system menu item (I hope!)
             url = _SomeGlobalVariableForAControl.getUnderlinedUrl();
             menu.add(_MyCustomUrlDoSomethingMenuItem);
             return;
         }
      }
   }
}

//to get the underlined text
class CustomControl extends ActiveAutoTextEditField {
   public CustomControl(...) { ... }
   public String getUnderlinedUrl() {
      if (regionHasCookie()) {
         String url = getRegionText(getRegion());
         if (url == null) { return ""; }
         return url;
      } else {
         return "";
      }
   }
}

Tags: BlackBerry Developers

Similar Questions

  • The context menu is grayed on my favorites

    For the last day or two, I was unable to open a bookmark in a new tab by right-clicking and selecting open in a new tab. All appropriate options appear on the menu, but everything on the menu is grayed out and unavailable. This applies only to my favorites. If I right click on a link, the context menu is displayed correctly and works correctly.

    Restart (not in Mode without failure or whatever it is) it not clear. That's nice.

  • Is it possible to change the order of items in the context menu of 'link' (I want to 'open in a new window... ("Be the first)?

    I did an upgrade FF v3.6.xx to v17.0.x and found that the order of items in the context menu 'Link' is not the same.
    v3.6 menu looks as follows: 1. "Open link in a new window", 2. "Open link in a new tab,"
    order of the items in menu v17.0 is 1 reverse. "Open link in a new tab", 2. " Open the link in a new window. "
    Position of all the other elements are uninteresting to me.
    How to exchange it two points higher in the contextual menu "link"?

    The two ways are useful:

    "Drag-n-drop" in the Editor window works.

    For my Windows XP path looks like: "C:\Documents and Settings\%account%\Application Data\Mozilla\Firefox\Profiles\%random_name%\chrome\userChrome.css".

  • Item ListView gets deselected as it appears from the context menu

    Since about 10.3.1 I notice that my lists behave in the same way, when I long press on a point I think the context menu to appear, what it does, but when it does so the item is deselected, so in the slot press and hold on I can't access the row for the selected item.

    At all the world feels something similar?

    Thank you.

    OK, problem solved. Here is the solution:

    -When the popup appears entirely because the finger was published the listener to activate slot is called indicating released finger. Problem is ListItemListener example in the docs went something like this:

    void MyItemClass::activate(bool activate)
    {
        // There is no special activate state, select and activated looks the same.
        select(activate);
    }
    

    Who calls the select slot and it says to turn off. That's why it's happening. Don't know how much this has changed, but this is the situation.

    To fix it I removes the code of slot() activation which allows the selected list item, but a new problem pervades: the element can not get deslected. To manage this I created an instance of ContextMenuHandler(), connected the visualStateChanged to a slit and searched a State ContextMenuVisualState::AnimatingToHidden clear the selections of the listview. So far so good.

  • "Edit in Photoshop Elements" missing from the context menu of windows.

    How can I get the 'Edit in Photoshop Elements' in my context menu? I think what happened was that after installation of PSE 13 I uninstalled PES 12 and who removed the context menu item. Just guessing. Is it possible to add it without reinstalling PSE 13?

    Right-click on a photo file of the type you want to open in PSE. In the context menu, right-click Open with to open the menu. Select "Choose default program" and in the window that opens, select PSE 13 if it appears in recommended or other. If it is not displayed, select Browse and navigate to the PSE 13 .exe file in programs/Adobe/Photoshop Elements. If you want the files of this type to be always open to post-secondary studies when double-clicked, check the box "always use the selected program." If you want to PSE 13 only appear in the open with menu, make sure that the box is not checked. Click OK.

  • How to get the "Run as different user" option using the context Menu

    I work with the domain environment and use os win 7 but it do not display "run as user deffrent' so, how get the"Run as a different user"option using the context Menu, share pls burned discription.

    (also try pressing shift + right click but nothing else)

    Atul Rai

    E-mail address is removed from the privacy *.

    May be of help to the: http://www.sevenforums.com/tutorials/155532-run-different-user-without-shift-right-click-context-menu.html

  • What happened to the "mark this page" link in the context menu?

    I used more anywhere with the right button on a Web page and the option to choose any bkmrk folder, or create a new subfolder. There was no message stating "bookmark page." I would choose where I wanted to drop the bkmrk and the bkmrk would be there. Simple concept. has worked well. Effective summer bcs you never had to shift in another part of the screen, or at least not periphery. Right click-> 'bookmark this page' menu appears as if it were a context menu. I just downloaded and installed FF 32.0.2. The
    function right click that I talk about the disappeared with the upgrade just before this one.

    It's the Blue Star in the grouping of 4 images at the top of the context menu.

  • can not get file shredder software appear in the context menu g6 Pavilion laptop

    HP Pavilion g6 Win7

    Looking to implement "Shred Files" from the context menu.

    I use 'Eraser', once installed it will have entries from the right click menu for her.

    http://sourceforge.NET/projects/Eraser/

  • Inserting a node on an element empty &lt; af:tree &gt; via the context Menu


    My requirement is to create a tree node by using the option "Insert" through the context menu when the component of the tree is empty. By clicking on the option insert a node should be created in the tree. But currently the context menu don't appear unless a node exists in the tree of.


    JDeveloper Version: 11.1.1.7.0

    Fig-component of the tree on a layout of Stretch

    1.jpg


    Fig - context menu to insert added to the Tree component

    2.jpg


    Fig - context menu is not display when no available tree node

    3.jpg

    The component of the tree grabs only necessary to render space and only in this space, you can access the context menu. As you do not have a jet of node, the space to make the tree is very small or didn't exist at all.

    You can add a showPopupBehavior (pointing to the popup of context menu) to FY: tree which should give you the popup anywhere in the tree.

    Timo

  • Add the "Print Directory Listing" option to the context menu of Windows Explorer

    Get the error message when you try to use the "Print Directory Listing" solution found in:
    http://support.microsoft.com/kb/321379/en-us on my new Windows 7 system (from February 2010).

    Could create the context menu of Windows Explorer for the task, but selecting just results in the following error message:

    "This file doesn't have an associatd with her program to perform this action. Please install a program or... to create an association in the default programs control panel. »

    Wentback and checked my Regedit work.  Even deleted the new key and she recreated (just in case.)

    NOTE: I had successfully used the instructions in this article to add "Print Directory Listing features on Windows XP systems, so I reviewed these instructions to see differences and noticed that it * no. * 'associate' step for Vista/Win7 in the article, but this step still shown for XP.»

    And, there seems to be NO WAY to associate a program (in this case, a ".bat") with all of 'record' as target.  Only choices I see these in the 'control panel default programs ' are'. [extensions] "and the protocols.

    So I'm puzzled.

    Any help would be appreciated.

    SJ Pratt

    I just tried this with instructions to the http://support.microsoft.com/kb/321379/en-us link you provided and it worked fine.

    In view of the error you get here are my assumptions to what may be the problem.  Please try these out and answer:

    -Because it denounces, "file doesn't have an associated program.." I would make sure that when you created with Notepad the file .bat you na not to create a file called 'Printdir.bat.txt' or 'Printdir.bat.some_bad_extension '.  If your Windows Explorer settings are set to hide file extensions when you look at a file name, then maybe the REAL file extension you give the command file is being hidden on your part and Windows does not know how to open a file with the extension hidden type.  Make sure that you can see all the file extensions and make sure that the batch file is named with the .bat extension.

    -If you see very well all the file extensions in Windows Explorer and your file is called really Printdir.bat, make sure that you have saved in your root directory of Windows.  If you access %windir% you see Printdir.bat inside there?  If this isn't the case, put it there.  If you do, when you double-click the .bat file Windows run without error and print the dir?  If it works, you know that the batch file works correctly.

    -There's a typing error in the instructions for Vista/Windows 7, check that your registry entries look like this:

    HKEY_CLASSES_ROOT\Directory\shell\Print directory Listing\command

    This shows the new key under shell called "Print Directory Listing" and inside this key/folder another folder/key named "command".

    To within the key/folder 'command', it takes only one entrance with the name of (by default).  Double-click (default) and make sure that its value data is set to:

    Printdir.bat %1

    -You shouldn't need step "the associate" in Windows 7.

    -You can add "Add Print Directory Listing to the context menu of Windows Explorer" for the title of your question so that others can find it.

  • Make a gallery of images from the context menu

    Hi, Im quite new on the environment of the waterfall and I was wondering if its possible to do a custom context menu that allows you to browse different images, like this picture of a picasa Viewer. an Im talk is at the bottom of the image. IM thinking to use ListView inside the menu, but I'm not sure if its possible. I would also ask how to position where the contextual pop-up menu would be in a page. Any help, advice or even a link to an example of code would be appreciated. Thanks in advance

    Hello
    This level of control is not possible using the context menu, but I think you can easily simulate using several containers. ListView can be placed in the bottom one.

    A possible design is to use a DispositionAbsolue to drag the lower container in the view with animation. Set LayoutUpdateHandler to the main container to adjust the dimensions of the container on the rotation of the screen and get the size of the initial screen of the low container off the screen.

  • What happened to "Show the context Menu" in Dreamweaver CS6?

    I use Dreamweaver for several years now and through several different versions. In Dreamweaver 8, under behaviors, I had "Show the context Menu" as a way to create attractive menus. In CS6, it is gone now. Is there a way to recover or at least another way to add context menus?

    The menus that were part of the old version of DW using javascript have been deprecated.  In addition, the CS6 Spry functionality has been deprecated.  As a result, you end up with a few options.

    Option 1 - get an add-on Exchange (Adobe Modules ) or third-party sources like PVII ( Projectseven.com - products ).

    Option 2 - consider a framework or a CMS that comes with a menu drop down menu code or UI admin option keep the menu.

    Because you always have a menu on your website, for now, you should be able to modify the code in order to maintain the menu, but moving forward I would definitely look for an alternative solution.

  • Starting stupid question, where is the context menu for the project?

    9 online help tell how make to enable some features in the project view toggle the preview area elements, change the size of thumbnail. The help says:

    «Right/ctrl-click the project view, and then select one of the following:...» »

    and it shows a screenshot of the menu, I need (http://help.adobe.com/en_US/premiereelements/using/WS5D044C3B-1939-4c8e-BC5A-97D122D4D73F. html).

    But no matter where I right click on the project view, I can't this context menu. If I'm on an item in the list, I get a menu with Clipboard functions, interpret the film, etc. No "Thumbnails" option or "views". No menu at all if I right click (or ctrl-click) click anywhere else. I've tried to get this context menu... what in the world I am doing wrong?

    Thank you

    -Mark

    My book offers more detailed advice.

    First, go to the window menu and select the option to display docking headers. Then in the upper right of the project Panel, click on the > button.

    These options are available through the context menu also, if you right-click on an empty spot on the project Panel, after the list of media clips.

  • Failed to create the menu popup JavaScript with to display the context Menu with the help of add behaviors

    Whenever I load a page with this added behavior and test it with my link, I get a message "error on Page".

    Here's what I do:

    Create a new HTML page in Dreamweaver 8.0.2 and save it.

    Add a hyperlink in the Insert-> menu hyperlink. Do not put anything in it except a few example of text; "THIS IS a TEST", or something.

    Select the hyperlink and choose "Show the context Menu" in the tag behaviors menu tab ' + '. The dialog box will appear.

    Add a single item and add a link to a page. Do not change the other options. Click OK to close the dialog box and the code will be added to the page.

    Save the HTML page again and press F12 to load the page on your test server and display them in a browser.

    Hover your mouse over the link to test. Nothing happens and there is a message in the status bar at the bottom of the browser, "error on Page".

    OK, it works. I saw the source file that are listed there, but I assumed that Dreamweaver would be to download the file with the HTML file to test on my test server. Usually, I'm prompted to download all the dependent files. Is there an exhibitor or dreamweaver do not miss this link?

    I'm sold on convictions explained in the rants you have linked, but only after I see that Dreamweaver menus don't work. It is not entirely necessary for my completely dependent users of my menus, they are only a feature of page layout.

    Since I have the ear, maybe you could tell me something before my attempt it: is it possible to generate the JavaScript using PHP? I would like to include JavaScript in the context of records with PHP MySQL. Is there another possible solution from PHP? I guess that ASP is a solution already and maybe Flash too.

    This is the kind of page I'm working on that:

    http://www.symbiota.com/MiloTrial/witnesses.php

    I would like to see a drop down menu for each trial where the number of witnesses is less than 10 to save someone the trouble to open a new page just to see a list of ten names.

  • Restore the context Menu?

    I just upgraded to Dreamweaver MX version 8 and much to my regret, the Setup program has added a new element, "Edit with Dreamweaver MX", from the context menu that appears when I right-click on a file in my Windows Explorer file manager. I absolutely _hate_ when an application is in addition to my context menu without asking my permission. Does anyone know how to get rid of this new menu item? I looked through all the groups of preferences and don't see any way to turn it off.

    Thank you.

    This information looks like it will be useful. Thank you, MIchael.

Maybe you are looking for

  • 50g - unable to resolve a simple system of equations

    It's very easy to do on my Casio FX115-ES, but I can't understand how do on the 50 g for the life of me. I am trying to solve a simple system of equations, illustrated below, for a static engineering courses. (F1) sin (30) + (F2) sin (30) - 6 * cos (

  • Update firmware DVD on Satellite M70-160

    Hi all, I searched the Forum, but I can't find anything similar, so here's my problem.I bought a DVD + R DL RiDisc (MCC manufacturer) and although NERO sees it as a DL, it can not write, show me this error"Focus or tracking error".D: MAST * A DVD-RAM

  • Anker Ethernet no longer works after update 10.11.3

    I have the USB - C 3 - Port USB 3.0 Hub with adapter Ethernet of Anker. He worked for six months. My MacBook has said is no longer the ethernet cable is plugged in after the Jan 27 10.11.3 patch. When I plug a USB headset into one of the ports, it wo

  • NET Framework on Satellite L500 error message

    I have just boupght a Satellite L500 and installed some software from my old laptop. Whenever I start I noew to get an error message telling me I need NET. version 2 of the Framework. I tried this download from Microsft site but my phone tells me tha

  • Problem with Windows XP on Satellite L40-139

    Hello Toshiba user community! I'm new here but I'll cut right to the chase with my problem. I have a Toshiba Satellite L40 - 139 (PSL40E) model that was included with Windows Vista Home Premium installed and all perfectly installed software. I recent