Add a client defined menu item to the existing applications (BlackBerry, Model: 7520)

2010-03-17  来源:本站原创  分类:Mobile  人气:357 

A few days ago, I was thinking of a problem, that extend BlackBerry system applications menu

I intend to be divided into several steps:

1) it can really do, after all, is a separate operating system BlackBerry

2) Now that you can join, how to join

3) join, how to realize their own capabilities

source tools, it is regrettable that did not provide the source code, but it illustrates the first step is feasible, formed the study category is how to achieve step 2, read these classes and their documentation:

Have the following code:

import net.rim.device.api.ui .*;
import net.rim.device.api.system .*;
import net.rim.device.api.ui.component.Dialog;
import net.rim.blackberry.api.menuitem .*;
import net.rim.device.api.ui.component .*;
import net.rim.device.api.ui.container .*;

public class BBInit extends Application
(
private static long ID = 0xe1e5ac072dc45f40L;

public static void main (String [] args)
(
BBInit theApp = new BBInit ();
theApp.enterEventDispatcher ();
)

public BBInit ()
(
ApplicationMenuItemRepository.getInstance (). AddMenuItem (ApplicationMenuItemRepository.MENUITEM_BROWSER,
new BBMenuItem ());
)

)

class BBMenuItem extends ApplicationMenuItem
(
BBMenuItem ()
(
super ("Print", 10);
)
BBMenuItem (int order)
(
super (order);
)

public String toString ()
(
return "Print";
)

public Object run (Object context) (
System.out.println (context);
/ / DO WHAT YOU WANT TO DO
return context;
)
)

This has been achieved in step 2

The next step 3 to make persistent efforts, and believe it is not difficult to the

相关文章
  • Add a client defined menu item to the existing applications (BlackBerry, Model: 7520) 2010-03-17

    A few days ago, I was thinking of a problem, that extend BlackBerry system applications menu I intend to be divided into several steps: 1) it can really do, after all, is a separate operating system BlackBerry 2) Now that you can join, how to join 3)

  • Join a customer-defined menu items to an existing application (BlackBerry, Model: 7520) 2010-03-29

    A few days ago, I was thinking a problem, that extend BlackBerry system applications menu I intend to be divided into several steps: 1) Is it really can do, after all, is another operating system, BlackBerry 2) Now that can be added, how to join 3) b

  • TortoiseSVN Menu Item Function 2010-03-21

    TortoiseSVN is a windows under one of the very best SVN client tool. By using it, we can visualize the management of our repository. However, because it is just a client, it can not be the repository for rights management. TortoiseSVN is not a separa

  • TortoiseSVN Menu Item Function Description 2010-03-21

    TortoiseSVN is a very good one under windows SVN client tools. By using it, we can visualize the management of our repository. However, because it's just a client, so it can not be a repository for rights management. TortoiseSVN is not a stand-alone

  • ubuntu in the accession process to the menu item 2010-08-17

    Add a Program in Ubuntu under the menu item links to the practice of Into the / usr / share / applications directory edit a desktop document sudo gedit / usr / share / applications / aaa.desktop To join them: QUOTE: [Desktop Entry] Name = aaa Comment

  • [Transferred] to the ubuntu add "open terminal" right-click menu 2011-05-10

    Here's how to add the Gnome right-click menu "gnome-terminal" menu item, and its implementation steps are as follows: In ~ / .gnome2/nautilus-scripts directory Add named "gnome-ternimal" the script file, which reads bash code #!/bin/ba

  • Adding a New Admin Menu Item 2013-01-20

    If you create a new extension for Magento, chances are that you will need something in the Admin Panel to manage your data. Sometimes, this can be managed from the System > Configuration section, but other times, and new section is needed. In this sh

  • Magento - the background set: Specify the current menu item 2010-04-24

    When a menu item into the background, hoping to highlight the corresponding menu, the following example: Implementation steps 1. To find the corresponding module's config.xml related menu items, for the example above, find the following code: <menu>

  • Get ListView selected and long press the menu item corresponding to the value of _id 2010-09-06

    First of all, if it is filled with simpleCursorAdapter ListView's data, he must pay attention to the primary key named sqlite, identified only as the method simpleCursorAdapter _id, so when you use sqlite's simpleCursorAdapter must be the primary key

  • How to TWaver Node object in the right menu item added 2011-05-04

    Select the tree node, an extra button, you can use tree.iconsComponentsFunction (use reference AlarmMappingDemo). Menu with Menu.createMenu (use reference Flex how to customize the Menu's Icon) If you right-click the tree node, the node selected for

  • [Reproduced + original] Gnome menu item Open the file (file association) changes 2011-08-30

    Reprinted from: http://hi.baidu.com/red_woods/blog/item/30a5f845a2247f24cffca397.html Reproduced have changed! In KDE, we can use the system settings in the settings file to provide the associated changes in Gnome system does not provide direct corre

  • [Reproduced + Modify] Gnome menu item Open the file (file association) changes 2011-08-30

    Reprinted from: http://hi.baidu.com/red_woods/blog/item/30a5f845a2247f24cffca397.html Reproduced have changed! In KDE, we can use the system settings in the settings file to provide the associated changes in Gnome system does not provide direct corre

  • Flex: ComboBox control to set the drop-down menu item icon [Original 2009-02-22 20:33:12] 2010-09-10

    <? Xml version = "1.0" encoding = "utf-8"?> <! - Http://yecon.blog.hexun.com/29683802_d.html -> <! - Http://www.slsay.com -> <Mx: Application xmlns: mx = "http://www.adobe.com/2006/mxml" layout = "ve

  • Solution win7 in the privacy of the Start menu item selected property in question can not be 2010-11-03

    Start -> travel (win + R) -> enter gpedit.msc, open the left side of the dialog box hit: User Configuration - "Administrative Templates ->" Start "menu and select and then double-click: Close user tracking, open dialog box, select

  • smartrcp realization of the menu bar 2010-06-12

    <?xml version="1.0" encoding="utf-8"?> <gui:RCPModule xmlns:mx="http://www.adobe.com/2006/mxml" xmlns:gui="cn.smartinvoke.gui.*" xmlns:rcp="cn.smartinvoke.rcp.*" layout="vertical" creati

  • [Reserved] EXT core API Detailed Ext.menu.Menu (XVII) 2010-12-12

    Ext.menu.Menu Menu object config { allowOtherMenus: Boolean / / allows simultaneous display other menu? defaultAlign: String / / default alignment: tl-bl? defaults: Object / / default menu item configuration, will be applied to all items items: Mixed

  • FusionCharts detailed description of parameters and functional properties 2010-06-10

    Features animation is animation data, the default is 1 (True) showNames whether to display horizontal axis (x axis) label name rotateNames whether the rotating display tag, the default is 0 (False): horizontal display showValues whether the graph sho

  • 20 VC development tips 2010-08-26

    fixedstar | 26 March, 2006, 12:12 / / First, open the CD-ROM mciSendString ("Set cdAudio door open wait", NULL, 0, NULL); / / 2, close CD_ROM mciSendString ("Set cdAudio door closed wait", NULL, 0, NULL); / / C, turn off the computer O

  • Robotium applications and automated testing of Android 2011-01-12

    Automated testing of Android, I believe there are many people who were in contact with android, but also keep the online search and research whether there is any automated testing tools can be applied android, I, too, after some research fortunate to

  • Add a simple MFC Dialog program menu and respond to events with 2011-05-09

    1. In the resources window to the Insert menu, edit menu. (Menu name followed by (& letters) is the shortcut key) 2. In the dialog box right> Properties> General to establish the menu box, select the menu above. Run can be seen, the dialog box h