Hot Search : Source embeded web remote control p2p game More...
Location : Home Search - simulator
Search - simulator - List
模拟一个电视机,很漂亮的界面。非非非常 的漂亮漂亮-An simulator of TV sets with a beautiful interface,really catch your eye!
Date : 2008-10-13 Size : 55.84kb User : 李真如

This a C+ programming code for elevator simulator
Date : 2008-10-13 Size : 9.77kb User : jiali yang

埃及王子模拟器 -Prince of Egypt simulator Haha
Date : 2008-10-13 Size : 139.18kb User : 刘力

 

Objective
This topic describes how to create a windowed application that will share the display with other applications.
Brew® MP windowed applications need to be written differently than traditional Brew MP applications. Traditional Brew MP applications, when running in the foreground, occupy full screen space and can modify the display at any time. In the windowing framework, multiple applications share the display at the same time and are not allowed to modify the display arbitrarily. A windowed application also needs to create one or more widgets to be used to create the windows.
A windowed application needs to:
·                  Create and initialize one or more widgets to be passed to IWindowMgr_CreateWindow().
The application can implement its own IWidget, or it can make use of an existing IWidget.
·                  Handle the EVT_APP_START_WINDOW event (and create a window).
·                  Implement handlers for visibility changes, focus changes, and extent changes. The implementation of these handlers is dependent on the details of the application.
·                  Draw in two stages:
·                                  Tell the container that drawing is necessary (ICONTAINER_Invalidate()).
·                                  Draw only when told to draw by the container (IWIDGET_Draw()).
Note: A windowed application should not call any functions that modify IDisplay directly. This includes explicit IDisplay function calls or implicit updates, such as calls to IIMAGE_Draw() or ICONTROL_Redraw(). Drawing should happen only on demand, for example, when IWIDGET_Draw() is called for the widget used to create the window. Existing Widget based applications follow these guidelines and, with minor modifications, can be ported to the windowing framework.
Event handling
A windowed application must respond to these events:
EVT_APP_START_WINDOW and EVT_APP_START
A window-based application receives EVT_APP_START_WINDOW first. If the application returns TRUE for this event, the application does not receive EVT_APP_START. If an application needs to support both the environments (window based and non-window based), it should handle both events.
When the application receives EVT_APP_START_WINDOW, it should create one or more windows.
If creation of IWindowMgr0 fails while handling EVT_APP_START_WINDOW, the application should assume that the platform does not support window-based applications. In this case, the application should return FALSE and continue the application logic in the code for EVT_APP_START.
EVT_APP_SUSPEND and EVT_APP_RESUME
After an application returns TRUE for EVT_APP_START_WINDOW, it will not receive EVT_APP_SUSPEND and EVT_APP_RESUME as non-windowed Brew MP applications do. Instead, the application must check for window status events that are sent to the widget through EVT_WDG_SETPROPERTY events. For EVT_WDG_SETPROPERTY events, wParam indicates which property was set, and dwParam specifies the value of the property. When the AEEWindowMgrExt_PROPEX_STATE property has a value of AEEWindowMgrExt_STATE_VISIBLE, the window is visible.
EVT_WDG_WINDOWSTATUS
The EVT_WDG_WINDOWSTATUS event is sent to a widget to notify it about various window related status messages. AEEWindowStatus.h contains information on the meaning of various status messages.
Sample code location

ZIP filename
Location
Run app
hellowindowapp
Brew MP Library
·                       Download and extract the ZIP file.
·                       Compile the app.
·                       Run it on the Brew MP Simulator.

Example of a windowed application
In the hellowindowapp sample, HelloWindowApp_HandleEvent handles the EVT_APP_START_WINDOW event and creates soft key and pop-up windows:
   case EVT_APP_START_WINDOW:   
      DBGPRINTF("EVT_APP_START_WINDOW");
 
      // Create the softkey and popup windows
      HelloWindowApp_CreateSoftkey(pMe);
      HelloWindowApp_CreateOrActivatePopup(pMe);
 
      // Handling this event tells Brew that we are a windowing
      // application.
      return TRUE;  
HelloWindowApp_CreateSoftkey() creates the soft key widget, sets the color text of the widget, then calls HelloWindowApp_CreateWindow() to create the window.
   WidgetWindow *pWindow = &pMe->softkeyWindow;
  
   if (pWindow->piWindowWidget != NULL) return;
   pWindow->pszDbgName = "Softkey";
   pWindow->pMe = pMe;
  
   (void) ISHELL_CreateInstance(pMe->applet.m_pIShell, AEECLSID_SoftkeyWidget,
            (void **) &pWindow->piWindowWidget);
   if (pWindow->piWindowWidget == NULL) return;
 
   {
      WidgetExtent extent = {0, HWA_SOFTKEY_HEIGHT};
      IWidget_SetExtent(pWindow->piWindowWidget, &extent);
   }
  
   (void) IWidget_SetBGColor(pWindow->piWindowWidget, MAKE_RGBA(200,200,200,255));
  
   // Now set the softkeys text
   {
      IWidget *piTextWidget = NULL;
      (void) IWidget_GetSoftkey(pWindow->piWindowWidget, PROP_SOFTKEY1, &piTextWidget);
     
      if (piTextWidget != NULL) {
         (void) IWidget_SetText(piTextWidget, L"Hover", TRUE);
      }
      RELEASEIF(piTextWidget);
 
      (void) IWidget_GetSoftkey(pWindow->piWindowWidget, PROP_SOFTKEY2, &piTextWidget);
      if (piTextWidget != NULL) {
         (void) IWidget_SetText(piTextWidget, L"Close", TRUE);
      }
      RELEASEIF(piTextWidget);
   }
 
   HelloWindowApp_CreateWindow(pMe, pWindow, AEEWindowMgrExt_CLASS_Softkey);  
HelloWindowApp_CreateWindow() creates the soft key window, as follows:
   int result;
   uint32 winId;
   AEEWindowProp propList[1];
  
   // Set custom window handler
   HANDLERDESC_Init(&pWindow->hdHandler, HelloWindowApp_WindowHandler, pWindow, NULL);
   IWIDGET_SetHandler(pWindow->piWindowWidget, &pWindow->hdHandler);
        
   propList[0].id = AEEWindowMgrExtProp_CLASS;
   propList[0].pbyLen = sizeof(winClass);
   propList[0].pby = (void *) &winClass;
     
   result = IWindowMgr_CreateWindow(pMe->piWindowMgr, (IQI*) (void *) pWindow->piWindowWidget,
      propList, ARR_SIZE(propList), &winId);
 
   if (result != SUCCESS) {
      DBGPRINTF("Window creation failed for %s: %d", pWindow->pszDbgName, result);
      HelloWindowApp_DestroyWindow(pWindow);
   } else {
      DBGPRINTF("Window %s created: id=%d", pWindow->pszDbgName, winId);
   }
HelloWindowApp_CreateOrActivatePopup() creates the widget for the pop-up window, then calls HelloWindowApp_CreateWindow() to create the pop-up window.
   pWindow->piWindowWidget = HelloWindowApp_CreateAndInitImageWidget(
                                pMe,
                                "popups.main" // Image as defined in appinfo.ini
                             );
 
   if (pWindow->piWindowWidget == NULL) return;
 
   {
      WExtent extent = {HWA_POPUP_WIDTH, HWA_POPUP_HEIGHT};
      IWIDGET_SetExtent(pWindow->piWindowWidget, &extent);
   }
 
   HelloWindowApp_CreateWindow(pMe, pWindow, AEEWindowMgrExt_CLASS_Popup);
Related information
·                  See Brew MP Widgets Technology Guide: Creating a Widgets application
·                  See Brew MP API Reference

Base version:
Brew MP 1.0
Tested version:
Brew MP 1.0
Phone tested:
No

 

Date : 2009-01-08 Size : 429.52kb User : bluecrest

埃及王子模拟器 -Prince of Egypt simulator Haha
Date : 2025-12-20 Size : 139kb User : 刘力

模拟一个电视机,很漂亮的界面。非非非常 的漂亮漂亮-An simulator of TV sets with a beautiful interface,really catch your eye!
Date : 2025-12-20 Size : 56kb User : 李真如

模拟手机界面的程序,采用面向对象的方法,实现各个按键的功能。-analog phone interface procedures, object-oriented methods and to achieve all key functions.
Date : 2025-12-20 Size : 714kb User : 古狗

This a C+ programming code for elevator simulator
Date : 2025-12-20 Size : 9kb User : jiali yang

电力104规约模拟主站行为的demo源程序。DEMO中配置了部分的ASDU数据对象,用户可以根据需要,参照例程自行配置所需要的各种数据对象。-104 Statute of the power behavior simulation of Master Station demo source code. DEMO configure some of the ASDU data object, the user can, in the light of their own routines to configure all the required data object.
Date : 2025-12-20 Size : 1.9mb User : 邹祥

DL : 0
mips 模拟器 5断流水线,支持断点 stall flush-mips simulator 5 off the assembly line, support breakpoint stall flush
Date : 2025-12-20 Size : 118kb User : liusong

基于车辆动力学的作战坦克仿真源码,能较真实地模拟车辆的运动性能。-Tank Simulator is a software tool to simulate a battle Tank based on its vehicle dynamics. Vehicle dynamics allow simulations to contain parameters that most clearly approximate the dynamic performance of the vehicle. Tank Simulator is still under development and currently simulates only few vehicle parameters like weight, dimension, velocity, suspension and braking effects. The complete version will be one which will have all the vehicle parameters included and exhibits Track-Terrain interaction. The developmental activity uses a computational engine called Open Dynamics Engine (ODE), which is an industrial standard library to simulate articulated bodies. It provides interactive or real-time simulation. 3D Visual environment of the simulator uses a Graphics Library that is packaged with ODE. Functions have been added to this library to suit to the application’s need. The complete software is packaged as an integrated environment in Visual C++.
Date : 2025-12-20 Size : 1.4mb User : 王刚

用VC设计的图形界面,可以做模拟器界面使用。-VC designed with a graphical interface, can be done using the simulator interface.
Date : 2025-12-20 Size : 6.22mb User : fbb

一个非常有名的关于工业仪表和仿真的VC++界面程序,有意者可以参考一二-A learned industrial meter and simulator panel,which can be refered by your programm s design
Date : 2025-12-20 Size : 1.43mb User : yangyu

DL : 0
neuron simulator in cpp for simulating
Date : 2025-12-20 Size : 433kb User : kmr

DL : 0
its a finite state machine simulator
Date : 2025-12-20 Size : 377kb User : kmr

DL : 0
可通过人机界面上位机控制三轴运动仿真转台-Man-machine interface through the host computer control three-axis motion simulator
Date : 2025-12-20 Size : 4.65mb User : 韩雪

MIMO ofdm 仿真-MIMO ofdm
Date : 2025-12-20 Size : 166kb User : 花开

emWin控件开发模拟器,在目标板没有ready之前先在PC上模拟开发控件应用,目标板到手后,编译在目标板上运行-emWin widget simulator, before target board is ready,develop your GUI application on PC. When the target board is ready, compile your application to run on the target board
Date : 2025-12-20 Size : 4.8mb User : liutao

该程序用VC++实现了雷达信号模拟器的界面功能及其通信功能-The program with VC++ to achieve a radar signal simulator interface functions and communication functions
Date : 2025-12-20 Size : 1.4mb User : shaopeng

chkSim simulator in java
Date : 2025-12-20 Size : 19kb User : ANKIT SHARMA
« 12 »
CodeBus is one of the largest source code repositories on the Internet!
Contact us :
1999-2046 CodeBus All Rights Reserved.