• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C++ GUI_CreateDialogBox函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C++中GUI_CreateDialogBox函数的典型用法代码示例。如果您正苦于以下问题:C++ GUI_CreateDialogBox函数的具体用法?C++ GUI_CreateDialogBox怎么用?C++ GUI_CreateDialogBox使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了GUI_CreateDialogBox函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: _cbDialog_VNC


//.........这里部分代码省略.........
      VNCSettings.ipaddr.b.addr2 = 0;
      VNCSettings.ipaddr.b.addr3 = 0;
      VNCSettings.maskaddr.b.addr0 = 0;
      VNCSettings.maskaddr.b.addr1 = 0;
      VNCSettings.maskaddr.b.addr2 = 0;
      VNCSettings.maskaddr.b.addr3 = 0;
      VNCSettings.gwaddr.b.addr0 = 0;
      VNCSettings.gwaddr.b.addr1 = 0;
      VNCSettings.gwaddr.b.addr2 = 0;
      VNCSettings.gwaddr.b.addr3 = 0;
      
      /* Save VNC settings */
      _VNCServer_SaveSettings();
    }
    else
    {
      _VNCApp_GetIPAddress(IP_ADDRESS, VNCSettings.ipaddr.b.addr3, VNCSettings.ipaddr.b.addr2, VNCSettings.ipaddr.b.addr1, VNCSettings.ipaddr.b.addr0);
      _VNCApp_GetIPAddress(SUBNET_MASK, VNCSettings.maskaddr.b.addr3, VNCSettings.maskaddr.b.addr2, VNCSettings.maskaddr.b.addr1, VNCSettings.maskaddr.b.addr0);
      _VNCApp_GetIPAddress(GW_ADDRESS, VNCSettings.gwaddr.b.addr3, VNCSettings.gwaddr.b.addr2, VNCSettings.gwaddr.b.addr1, VNCSettings.gwaddr.b.addr0);
    }     
    
    if (VNCSettings.dhcp_use.b.dhcp == 0)
    {
       _VNCServer_DisplayIPAddress();
    }
    
    
    break;

  case WM_PAINT:
    
    DrawRect3D(230, 5, 87, 120);  
    DrawRect3D(2, 130, 225, 80);
    DrawRect3D(230, 130, 87, 80);
    
    break;
      
  case WM_NOTIFY_PARENT:
      Id    = WM_GetId(pMsg->hWinSrc);    /* Id of widget */
    NCode = pMsg->Data.v;               /* Notification code */
    
    switch (NCode) 
    {    
      
    case WM_NOTIFICATION_RELEASED:      /* React only if released */
      switch (Id) 
      {
      case ID_BUTTON_SETTINGS: /* Settings */
        if(hWinVNC_Settings == 0)
        {
          hWinVNC_Settings = GUI_CreateDialogBox(_aDialog_VNC_SETTINGS, GUI_COUNTOF(_aDialog_VNC_SETTINGS), _cbDialog_VNC_SETTINGS, hWinVNC, 0, 10);
          
          hNumPad = GUI_CreateDialogBox(_aDialogNumPad, 
                                        GUI_COUNTOF(_aDialogNumPad), 
                                        _cbDialogNumPad, pMsg->hWin, 0, 0); 
        }
        break;	  
      case ID_BUTTON_START: /* Start */
        
        if(hWinVNC_Settings == 0)
        {
          if (start_button == VNC_START) 
          {          
            /* change start button to hide */
            start_button = VNC_HIDE;
            hItem = WM_GetDialogItem(pMsg->hWin, ID_BUTTON_START);
            BUTTON_SetText(hItem, (const char*) "Hide");
            
            /* Cange connection png pic from disconnected to connecting */
            hItem = WM_GetDialogItem(pMsg->hWin, ID_IMAGE_STATE);
            IMAGE_SetBitmap(hItem, &bmhourglass32);
            
            
            hItem = WM_GetDialogItem(pMsg->hWin, ID_MULTIEDIT_VNC);
            MULTIEDIT_AddText(hItem, (const char *) "TCP/IP stack initialization ... \n\r");
            
            TCPIP_Initialized = 1;
            
            /* Initilaize the LwIP stack */
            NetworkInit(VNCSettings.dhcp_use.b.dhcp);
          }
          else /* start_button == VNC_HIDE  */
          {
            if(hWinVNC_Settings == 0)
            {        
              WM_HideWindow(pMsg->hWin);
            }
          }
        }
        break;
      }
      break;  
    }
    break;
    
  default:
    WM_DefaultProc(pMsg);
    break;
  }
}
开发者ID:pierreroth64,项目名称:STM32Cube_FW_F4,代码行数:101,代码来源:vncserver_win.c


示例2: Startup

/**
  * @brief  Game window Startup
  * @param  hWin: pointer to the parent handle.
  * @param  xpos: X position 
  * @param  ypos: Y position
  * @retval None
  */
static void Startup(WM_HWIN hWin, uint16_t xpos, uint16_t ypos)
{
  frame = 0;
  SystemWin = GUI_CreateDialogBox(_aDialog, GUI_COUNTOF(_aDialog), _cbDialog, hWin, xpos, ypos);
  hTimer = WM_CreateTimer(SystemWin, 0, 100, 0);
}
开发者ID:CamelShoko,项目名称:RadioYuN,代码行数:13,代码来源:settings_win.c


示例3: Startup

/**
  * @brief  Camera window Startup
  * @param  hWin: pointer to the parent handle.
  * @param  xpos: X position 
  * @param  ypos: Y position
  * @retval None
  */
static void Startup(WM_HWIN hWin, uint16_t xpos, uint16_t ypos)
{
  camera_disabled = 0;
  CAMERA_hWin = GUI_CreateDialogBox(_aDialogCreate, GUI_COUNTOF(_aDialogCreate), _cbDialog, hWin, xpos, ypos);
}
开发者ID:PaxInstruments,项目名称:STM32CubeF4,代码行数:12,代码来源:camera_win.c


示例4: Startup

/**
  * @brief  Image browser window Startup
  * @param  hWin: pointer to the parent handle.
  * @param  xpos: X position 
  * @param  ypos: Y position
  * @retval None
  */
static void Startup(WM_HWIN hWin, uint16_t xpos, uint16_t ypos)
{
  IMAGE_hWin = GUI_CreateDialogBox(_aDialogCreate, GUI_COUNTOF(_aDialogCreate), _cbDialog, hWin, xpos, ypos);
}
开发者ID:EarnestHein89,项目名称:STM32Cube_FW_F4,代码行数:11,代码来源:imagebrowser_win.c


示例5: Startup

/**
  * @brief  File browser window Startup
  * @param  hWin: pointer to the parent handle.
  * @param  xpos: X position 
  * @param  ypos: Y position
  * @retval None
  */
static void Startup(WM_HWIN hWin, uint16_t xpos, uint16_t ypos)
{
  hExplorerWin = GUI_CreateDialogBox(_aDialog, GUI_COUNTOF(_aDialog), _cbDialog, hWin, xpos, ypos);
}
开发者ID:451506709,项目名称:automated_machine,代码行数:11,代码来源:filebrowser_win.c


示例6: _cbSettingsDialog

/**
  * @brief  Callback function of the Settings frame
  * @param  pMsg: pointer to data structure of type WM_MESSAGE
  * @retval None
  */
static void _cbSettingsDialog(WM_MESSAGE * pMsg)
{
  int     Id, NCode;
  WM_HWIN hItem;
  
  switch (pMsg->MsgId)
  {
  case WM_INIT_DIALOG:
    
    /* Settings frame initialization */
    hItem = pMsg->hWin;
    FRAMEWIN_AddCloseButton(hItem, FRAMEWIN_BUTTON_RIGHT, 0);
    
    /* Create and attache the MULTIPAGE dialog windows */
    hItem = WM_GetDialogItem(pMsg->hWin, ID_MULTIPAGE);
    
    hDialogCameraSettings = GUI_CreateDialogBox(_aDialogCameraSettings,
                                               GUI_COUNTOF(_aDialogCameraSettings),
                                               &_cbCameraSettings, WM_UNATTACHED, 0, 0);
    MULTIPAGE_AddPage(hItem, hDialogCameraSettings, "Camera Settings");
    
    hDialogFileControl = GUI_CreateDialogBox(_aDialogFileControl,
                                             GUI_COUNTOF(_aDialogFileControl),
                                             &_cbFileControl, WM_UNATTACHED, 0, 0);

    MULTIPAGE_AddPage(hItem, hDialogFileControl, "File Settings");
    
    MULTIPAGE_SelectPage(hItem, 0);
    
    /* 'OK' button initialization */
    hItem = WM_GetDialogItem(pMsg->hWin, ID_BUTTON_OK);
    BUTTON_SetFont(hItem, GUI_FONT_13B_1);
    
    /* 'Cancel' button initialization */
    hItem = WM_GetDialogItem(pMsg->hWin, ID_BUTTON_CANCEL);
    BUTTON_SetFont(hItem, GUI_FONT_13B_1);
    
    break;
   
  case WM_DELETE:    
    camera_disabled = 0;   
    hSettings = 0;
    
    /* Delete choosfile window */
    WM_DeleteWindow(chooser_select_folder);
    
    break;
    
  case WM_NOTIFY_PARENT:
    Id = WM_GetId(pMsg->hWinSrc);
    NCode = pMsg->Data.v;
           
    switch (Id)
    {
    case ID_BUTTON_OK: /* Notification sent by "OK" button */
      switch (NCode)
      {
      case WM_NOTIFICATION_RELEASED:
        
        /* Save camera settings before delete settings frame */
        hItem = WM_GetDialogItem(hDialogCameraSettings, ID_SLIDER_0);
        CameraSettings.b.brightness = SLIDER_GetValue(hItem);
        hItem = WM_GetDialogItem(hDialogCameraSettings, ID_SLIDER_1);
        CameraSettings.b.contrast = SLIDER_GetValue(hItem);
        
        /* Back to normal mode (no effects) */
        hItem = WM_GetDialogItem(CAMERA_hWin, ID_RADIO);
        RADIO_SetValue(hItem, 0);
        if(CAMERA_GetState() != CAMERA_ERROR)
        {
          /* Apply new settings*/
          CAMERA_Set_ContrastBrightness(CameraSettings.b.contrast, CameraSettings.b.brightness);
        }
        GUI_EndDialog(pMsg->hWin, 0);
        break;
      }
      break;
    case ID_BUTTON_CANCEL: /* Notification sent by "Cancel" button */
      switch (NCode)
      {
      case WM_NOTIFICATION_RELEASED:
        GUI_EndDialog(pMsg->hWin, 0);
        break;
      }
      break;
    }
    break;
  }
}
开发者ID:PaxInstruments,项目名称:STM32CubeF4,代码行数:94,代码来源:camera_win.c


示例7: CreateSensorsControl

WM_HWIN CreateSensorsControl(void) {
  WM_HWIN hWin;

  hWin = GUI_CreateDialogBox(_aDialogCreate, GUI_COUNTOF(_aDialogCreate), _cbDialog, WM_HBKWIN, 0, 0);
  return hWin;
}
开发者ID:EnricoGiordano1992,项目名称:Tesi,代码行数:6,代码来源:SensorsControlDLG.c


示例8: _cbDialog


//.........这里部分代码省略.........
        }
    }

                
    switch(((WM_KEY_INFO *)(pMsg->Data.p))->Key)
    {
        case GUI_KEY_YELLOW:
            if((((WM_KEY_INFO*)(pMsg->Data.p))->PressedCnt)==1)
            {
                WM_DeleteWindow(g_hWin_ReadMeter);
                g_hWin_ReadMeter=HBWIN_NULL;
                WM_BringToBottom(g_hWin_msg);
                WM_HideWindow(g_hWin_msg);
                WM_ShowWindow(g_hWin_TimeBar);
                WM_ShowWindow(g_hWin_Date);
                WM_SetFocus(g_hWin_menu);
                RMD_key_cnt = 0;
                g_gui_para.state = GUI_STATE_IDLE;
            }
            break;
            
        case GUI_KEY_F1: /*获取表号*/
            if((((WM_KEY_INFO*)(pMsg->Data.p))->PressedCnt)==0)
            {
                if(CHANNEL_RF != g_rom_para.channel)
                {
                    g_gui_para.cmd = GUI_CMD_BROAD_READ_ADDR;
                    g_gui_para.state = GUI_STATE_AMR;                        
                    OSMboxPost(g_sys_ctrl.up_mbox, (void*)&g_gui_para);
                }
            }
            break;
            
        case '#':
            if((((WM_KEY_INFO*)(pMsg->Data.p))->PressedCnt)==0)
            {
                 WM_BringToTop(g_hWin_msg);
                 WM_ShowWindow(g_hWin_msg);                    
                 WM_SetFocus(g_hWin_msg);
            }
            break;
            
        case GUI_KEY_F2:  /*抄表*/              
            if((((WM_KEY_INFO*)(pMsg->Data.p))->PressedCnt)==0)
            {
                if(DEV_OK == RMD_Get_Para(pMsg))//获取参数数据
                {
                    g_gui_para.state = GUI_STATE_AMR;
                    OSMboxPost(g_sys_ctrl.up_mbox, (void*)&g_gui_para);
                }
            }
       
            break;

        case GUI_KEY_UP:
            if((((WM_KEY_INFO*)(pMsg->Data.p))->PressedCnt)==0)
            {
                RMD_SelEdt_Up(pMsg);
                //RMD_Color_Change();
            }
            break;

        case GUI_KEY_DOWN:
            if((((WM_KEY_INFO*)(pMsg->Data.p))->PressedCnt)==0)
            {
                RMD_SelEdt_Down(pMsg);
                //RMD_Color_Change();
                GUI_Color_Change(g_hWin_ReadMeter, ID_EDIT_0, 3);
            }
            break;
        case GUI_KEY_TAB:
            if((((WM_KEY_INFO*)(pMsg->Data.p))->PressedCnt)==0)
            {
                //RMD_Sel_Down(pMsg);
                RMD_Color_Change();
            }
            break;
#endif

  case WM_MSG_CLOSE:
    WM_DeleteWindow(g_hWin_ReadMeter);
	break;
    
  default:
    WM_DefaultProc(pMsg);
    break;
  }
}

/*********************************************************************
*
*       CreateReadMeter
*/
WM_HWIN CreateReadMeter(void);
WM_HWIN CreateReadMeter(void) {
  WM_HWIN hWin;

  hWin = GUI_CreateDialogBox(_aDialogCreate, GUI_COUNTOF(_aDialogCreate), _cbDialog, g_hWin_menu, 0, 0);
  return hWin;
}
开发者ID:qq5013,项目名称:DLMR-PDA,代码行数:101,代码来源:ReadMeterDLG.c


示例9: MainTask

/*********************************************************************
*
*       MainTask
*/
void MainTask(void) {
  WM_HWIN hScrollbar, hDlgOptions;
  GUI_RECT RectDlg, RectClient;
  int Cnt = 0, IndexEffect = 0, ButtonState = 0, DropdownState = 0;
  int ProgbarValue   = 0, ProgbarInc   = 1;
  int SliderValue    = 0, SliderInc    = 1;
  int ScrollbarValue = 0, ScrollbarInc = 1;
  int ListViewInc  = 1;
  int ListBoxInc   = 1;
  int MultiEditInc = 1;
  int Vz = 1;
  const WIDGET_EFFECT * _apEffect[] = {&WIDGET_Effect_3D,     /* Array of effects */
                                      &WIDGET_Effect_Simple, 
                                      &WIDGET_Effect_None};
  const char * _apEffects[] = {"Widget effect: 3D", "Widget effect: Simple", "Widget effect: None"};
  GUI_Init();
  GUI_CURSOR_Show();
  WM_SetCallback(WM_HBKWIN, _cbBkWindow);
  WM_SetCreateFlags(WM_CF_MEMDEV);  /* Use memory devices on all windows to avoid flicker */
  WM_EnableMemdev(WM_HBKWIN);       /* Enable use of memory devices for desktop windows */
  /* Create framewindow and set its properties */
  _hFrameWin = FRAMEWIN_CreateEx(0, 0, 640, 480, 0, WM_CF_SHOW, 0, 0, "", &_cbCallbackFramewin);
  FRAMEWIN_SetMoveable(_hFrameWin, 1);
  FRAMEWIN_SetText(_hFrameWin, _apEffects[0]);
  FRAMEWIN_SetFont(_hFrameWin, &GUI_Font13B_ASCII);
  /* Create main dialog window as child from framewindows client window */
  _hDlg = GUI_CreateDialogBox(_aDlgWidgets,
                              GUI_COUNTOF(_aDlgWidgets), 
                              &_cbCallbackWidgets, 
                              WM_GetClientWindow(_hFrameWin), 0, 0);
  /* Attach scrollbar to framewindows client window and set its properties */
  hScrollbar = SCROLLBAR_CreateAttached(WM_GetClientWindow(_hFrameWin), 0);
  WM_GetWindowRectEx(_hDlg, &RectDlg);
  WM_GetClientRectEx(WM_GetClientWindow(_hFrameWin), &RectClient);
  SCROLLBAR_SetNumItems(hScrollbar, RectDlg.x1);
  SCROLLBAR_SetPageSize(hScrollbar, RectClient.x1);
  /* Create options dialog with 'stay on top' and 'moveable' attribute */
  hDlgOptions = GUI_CreateDialogBox(_aDlgOptions, 
                                    GUI_COUNTOF(_aDlgOptions), 
                                    &_cbCallbackOptions, 
                                    WM_HBKWIN, 0, 0);
  FRAMEWIN_SetMoveable(hDlgOptions, 1);
  WM_SetStayOnTop(hDlgOptions, 1);
  /* Main loop for modifying the widgets */
  while (1) {
    if (_AutoMode) {
      Cnt++;
      /* Modify progbar */
      if ((Cnt % 2) == 0) {
        ProgbarValue += ProgbarInc;
        if ((ProgbarValue == 110) || (ProgbarValue == -10)) {
          ProgbarInc *= -1;
        }
        PROGBAR_SetValue(_ahWin[PROGBAR0], ProgbarValue);
      }
      /* Modify slider */
      if ((Cnt % 2) == 0) {
        int j;
        SliderValue += SliderInc;
        if ((SliderValue == 100) || (SliderValue == 0)) {
          SliderInc *= -1;
        }
        for (j = 0; j < 3; j++) {
          SLIDER_SetValue(_ahWin[SLIDER0 + j], SliderValue);
        }
      }
      /* Modify scrollbar */
      if ((Cnt % 3) == 0) {
        int j;
        ScrollbarValue += ScrollbarInc;
        if ((ScrollbarValue == 90) || (ScrollbarValue == 0)) {
          ScrollbarInc *= -1;
        }
        for (j = 0; j < 3; j++) {
          SCROLLBAR_SetValue(_ahWin[SCROLLBAR0 + j], ScrollbarValue);
        }
      }
      /* Modify multipage */
      if ((Cnt % 120) == 0) {
        MULTIPAGE_SelectPage(_ahWin[MULTIPAGE0], MULTIPAGE_GetSelection(_ahWin[MULTIPAGE0]) ^ 1);
      }
      /* Modify dropdown */
      if ((Cnt % 120) == 0) {
        DropdownState ^= 1;
        if (DropdownState) {
          DROPDOWN_Expand(_ahWin[DROPDOWN0]);
        } else {
          DROPDOWN_Collapse(_ahWin[DROPDOWN0]);
        }
      }
      /* Modify button */
      if ((Cnt % 40) == 0) {
        ButtonState ^= 1;
        BUTTON_SetPressed(_ahWin[BUTTON0], ButtonState);
      }
      /* Modify listbox */
//.........这里部分代码省略.........
开发者ID:qiurenguo2014,项目名称:youjiesun,代码行数:101,代码来源:WIDGET_SchemeLarge.c


示例10: Startup

/**
  * @brief  home alarm window Startup
  * @param  hWin: pointer to the parent handle.
  * @param  xpos: X position 
  * @param  ypos: Y position
  * @retval None
  */
static void Startup(WM_HWIN hWin, uint16_t xpos, uint16_t ypos)
{
  HomeSettings.b.alarm  = ALARM_ON;
  HomeSettings.b.camera = CAM_DESACTIVATED;
  HOME_hWin = GUI_CreateDialogBox(_aDialog, GUI_COUNTOF(_aDialog), _cbDialog, hWin, xpos, ypos);
}
开发者ID:Lembed,项目名称:STM32CubeF4-mirrors,代码行数:13,代码来源:home_alarm_win.c


示例11: _cbCallbackWidgets

/*********************************************************************
*
*       _cbCallbackWidgets
*
* Purpose:
*   Initializes the widgets of the main dialog box
*/
static void _cbCallbackWidgets(WM_MESSAGE * pMsg) {
  GRAPH_SCALE_Handle hScaleH, hScaleV;
  int i;
  WM_HWIN hDlg, hMenu;
  hDlg = pMsg->hWin;
  switch (pMsg->MsgId) {
    case WM_INIT_DIALOG:
      /* Get handles of widgets */
      for (i = 0; i < NUM_WIDGETS; i++) {
        _ahWin[i] = WM_GetDialogItem(hDlg, _aID[i]);
      }
      /* Init dropdown widget */
      for (i = 0; i < 8; i++) {
        char acBuffer[] = {"Item x"};
        int Len = strlen(acBuffer);
        acBuffer[Len - 1] = '1' + i;
        DROPDOWN_AddString(_ahWin[DROPDOWN0], acBuffer);
      }
      /* Init edit widget */
      EDIT_SetText(_ahWin[EDIT0], "Edit");
      /* Init listbox widget */
      LISTBOX_SetAutoScrollV(_ahWin[LISTBOX0], 1);
      for (i = 0; i < 4; i++) {
        char acBuffer[] = {"Item x"};
        int Len = strlen(acBuffer);
        acBuffer[Len - 1] = '1' + i;
        LISTBOX_AddString(_ahWin[LISTBOX0], acBuffer);
      }
      /* Init listview widget */
      for (i = 0; i < 2; i++) {
        char acBuffer[] = {"Col. x"};
        int Len = strlen(acBuffer);
        acBuffer[Len - 1] = '1' + i;
        LISTVIEW_AddColumn(_ahWin[LISTVIEW0], 60, acBuffer, GUI_TA_CENTER);
      }
      for (i = 0; i < 9; i++) {
        int j;
        LISTVIEW_AddRow(_ahWin[LISTVIEW0], NULL);
        for (j = 0; j < (int)LISTVIEW_GetNumColumns(_ahWin[LISTVIEW0]); j++) {
          char acBuffer[] = {"Rx/Cx"};
          acBuffer[1] = '1' + i;
          acBuffer[4] = '1' + j;
          LISTVIEW_SetItemText(_ahWin[LISTVIEW0], j, i, acBuffer);
        }
      }
      LISTVIEW_SetGridVis(_ahWin[LISTVIEW0], 1);
      SCROLLBAR_CreateAttached(_ahWin[LISTVIEW0], SCROLLBAR_CF_VERTICAL);
      /* Init multiedit widget */
      MULTIEDIT_SetText(_ahWin[MULTIEDIT0], "This text could be modified by the MULTIEDIT widget");
      MULTIEDIT_SetWrapWord(_ahWin[MULTIEDIT0]);
      MULTIEDIT_SetAutoScrollV(_ahWin[MULTIEDIT0], 1);
      /* Init progbar widget */
      WIDGET_SetEffect(_ahWin[PROGBAR0], &WIDGET_Effect_3D);
      /* Init graph widget */
      for (i = 0; i < GUI_COUNTOF(_aColor); i++) {
        _aValue[i] = rand() % 95;
        _ahData[i] = GRAPH_DATA_YT_Create(_aColor[i], 500, 0, 0);
        GRAPH_AttachData(_ahWin[GRAPH0], _ahData[i]);
      }
      GRAPH_SetGridDistY(_ahWin[GRAPH0], 25);
      GRAPH_SetGridVis(_ahWin[GRAPH0], 1);
      GRAPH_SetGridFixedX(_ahWin[GRAPH0], 1);
      GRAPH_SetBorder(_ahWin[GRAPH0], 20, 4, 5, 4);
      /* Create and add vertical scale of graph widget */
      hScaleV = GRAPH_SCALE_Create(18, GUI_TA_RIGHT, GRAPH_SCALE_CF_VERTICAL, 25);
      GRAPH_SCALE_SetTextColor(hScaleV, GUI_RED);
      GRAPH_AttachScale(_ahWin[GRAPH0], hScaleV);
      /* Create and add horizontal scale of graph widget */
      hScaleH = GRAPH_SCALE_Create(46, GUI_TA_HCENTER | GUI_TA_VCENTER, GRAPH_SCALE_CF_HORIZONTAL, 50);
      GRAPH_SCALE_SetTextColor(hScaleH, GUI_DARKGREEN);
      GRAPH_AttachScale(_ahWin[GRAPH0], hScaleH);
      /* Init multipage widget */
      MULTIPAGE_AddPage(_ahWin[MULTIPAGE0],
                        GUI_CreateDialogBox(_aDialogCreate1, GUI_COUNTOF(_aDialogCreate1), &_cbDialogPage, WM_UNATTACHED, 0, 0), 
                        "Page 1");
      MULTIPAGE_AddPage(_ahWin[MULTIPAGE0],
                        GUI_CreateDialogBox(_aDialogCreate2, GUI_COUNTOF(_aDialogCreate2), &_cbDialogPage, WM_UNATTACHED, 0, 0), 
                        "Page 2");
      /* Create and attach menu */
      hMenu = _CreateMenu(hDlg);/**/
      break;
    default:
      WM_DefaultProc(pMsg);
  }
}
开发者ID:qiurenguo2014,项目名称:youjiesun,代码行数:92,代码来源:WIDGET_SchemeLarge.c


示例12: _TaskerAddPage1

WM_HWIN _TaskerAddPage1(WM_HWIN hWin)
{
    return GUI_CreateDialogBox(_aDialogCreate1, GUI_COUNTOF(_aDialogCreate1), _cbDialog, WM_UNATTACHED, 0, 0);
}
开发者ID:jeenter,项目名称:CH-K-Lib,代码行数:4,代码来源:tasker_page1.c


示例13: DEMO_Video

/**
  * @brief  DEMO_Video
  * @param  hWin: Window handle
  * @retval None
  */
void DEMO_Video(WM_HWIN hWin)
{
  VIDEO_Enlarge = 0;
  bkparent = hWin;
  VIDEO_hWin = GUI_CreateDialogBox(_aDialogCreate, GUI_COUNTOF(_aDialogCreate), &_cbDialog, hWin, 0, 0);
}
开发者ID:ChingHengWang,项目名称:stm32_ws,代码行数:11,代码来源:demo_video.c


示例14: Create_wSaveDlg

WM_HWIN Create_wSaveDlg(void) {
  WM_HWIN hWin;

  hWin = GUI_CreateDialogBox(_aDialogCreate, GUI_COUNTOF(_aDialogCreate), &_cbDialog, WM_HBKWIN, 0, 0);
  return hWin;
}
开发者ID:jameskongnet,项目名称:dds,代码行数:6,代码来源:_wSaveDlgDLG.c


示例15: startSetTime

WM_HWIN startSetTime(void) {
  WM_HWIN hWin;

  hWin = GUI_CreateDialogBox(_aDialogCreate, GUI_COUNTOF(_aDialogCreate), _cbDialog, WM_HBKWIN, 0, 0);
  return hWin;
}
开发者ID:ProsperousLi,项目名称:stm32EWIN,代码行数:6,代码来源:startSetTime.c


示例16: _cbPopup

/**
  * @brief  Callback routine of popup menu.
  * @param  pMsg: pointer to data structure of type WM_MESSAGE 
  * @retval None
  */
static void _cbPopup(WM_MESSAGE * pMsg) {

  K_GET_DIRECT_OPEN_FUNC * pfOpen; 
  MENU_MSG_DATA* pData;
  TREEVIEW_ITEM_Handle  hTreeView;
  TREEVIEW_ITEM_INFO    Info;
  WM_HWIN hItem;  
  char ext[4];
  switch (pMsg->MsgId) 
  {
  case WM_INIT_DIALOG:
    break;
    
  case WM_MENU:
    /* Process the menu message */
    pData = (MENU_MSG_DATA*)pMsg->Data.p;

    switch (pData->MsgType) 
    {
    case MENU_ON_ITEMSELECT:
      /* Menu item has been selected */
      switch (pData->ItemId) 
      {  
      case ID_MENU_OPENFILE:
        k_GetExtOnly(SelectedFileName, ext);
        pfOpen = k_ModuleCheckLink(ext);
        
        if(pfOpen != NULL)
        {
          pfOpen(SelectedFileName);
        }
        else 
        {
          _ShowMessageBox(hExplorerWin, "File Browser", "No external module is linked to\n this extension or Low RAM!", 0); 
        }
        break;
        
      case ID_MENU_DELETE:
        if (_ShowMessageBox(hExplorerWin, "File Browser", "Are you sure you want to\ndelete selected file?", 1)) 
        {
           f_unlink (SelectedFileName);
          _RefreshBrowser(hExplorerWin); 
        }
        break;
        
      case ID_MENU_PROPRIETIES:
        if(hFileInfo == 0)
        {
          hFileInfo = GUI_CreateDialogBox(_aFileInfoDialogCreate, 
                                          GUI_COUNTOF(_aFileInfoDialogCreate), 
                                          _cbFileInfoDialog, 
                                          hExplorerWin, 
                                          60, 
                                          50);
        }
        break;
      
      case ID_MENU_EXIT:    
        break;        
      }

      hItem = WM_GetDialogItem(hExplorerWin, ID_TREEVIEW); 
      hTreeView = TREEVIEW_GetSel(hItem);
      TREEVIEW_ITEM_GetInfo(hTreeView, &Info);
      if(Info.IsNode == 0)
      {
        /*Force Deselect item */
        hTreeView = TREEVIEW_GetItem(hItem, hTreeView, TREEVIEW_GET_PARENT);
        TREEVIEW_SetSel(hItem, hTreeView);
      }
      
    }
    break;
  default:
    WM_DefaultProc(pMsg);
    break;       
  }
}
开发者ID:451506709,项目名称:automated_machine,代码行数:83,代码来源:filebrowser_win.c


示例17: Createmenu_window

WM_HWIN Createmenu_window(void) {
  WM_HWIN hWin;

  hWin = GUI_CreateDialogBox(_aDialogCreate, GUI_COUNTOF(_aDialogCreate), _cbDialog, WM_HBKWIN, 0, 0);
  return hWin;
}
开发者ID:EnricoGiordano1992,项目名称:Tesi,代码行数:6,代码来源:menu_windowDLG.c


示例18: _cbBk

/**
  * @brief  Callback routine of desktop window.
  * @param  pMsg: pointer to data structure of type WM_MESSAGE
  * @retval None
  */
static void _cbBk(WM_MESSAGE * pMsg) {
  
  MENU_MSG_DATA* pData;
  uint32_t NCode, Id;
  static uint8_t sel = 0;
  
  switch (pMsg->MsgId) 
  {

  case WM_MENU:
    /* Process the menu message */
    pData = (MENU_MSG_DATA*)pMsg->Data.p;
    switch (pData->MsgType) 
    {
    case MENU_ON_ITEMSELECT:
      /* A menu item has been selected */
      switch (pData->ItemId) 
      {  
        
      case ID_MENU_LOG:
        if (hLog == 0)
        {
          hLog = GUI_CreateDialogBox(_aKernelLogDialogCreate, 
                                     GUI_COUNTOF(_aProcessManagerDialogCreate), 
                                     _cbKernelLogDialog, 
                                     pMsg->hWin, 
                                     FRAMEWIN_CF_MOVEABLE | WM_CF_FGND | WM_CF_STAYONTOP, 
                                     50);  
        }
        else
        {
          WM_ShowWindow(hLog);
          WM_BringToTop(hLog);
        }        
        break;
        
      case ID_MENU_PMGR:
        if(hProcess == 0)
        {
          hProcess = GUI_CreateDialogBox(_aProcessManagerDialogCreate, 
                                         GUI_COUNTOF(_aProcessManagerDialogCreate), 
                                         _cbProcessManagerDialog, 
                                         pMsg->hWin, 
                                         FRAMEWIN_CF_MOVEABLE | WM_CF_FGND | WM_CF_STAYONTOP, 
                                         50);  
        }
        else
        {
          WM_ShowWindow(hProcess);
          WM_BringToTop(hProcess);
        }
        break;
        
      case ID_MENU_PERF:
        if(hPerformance == 0)
        {
          hPerformance = GUI_CreateDialogBox(_aPerformanceDialogCreate, 
                                             GUI_COUNTOF(_aPerformanceDialogCreate), 
                                             _cbPerformanceDialog, 
                                             pMsg->hWin, 
                                             FRAMEWIN_CF_MOVEABLE | WM_CF_FGND | WM_CF_STAYONTOP, 
                                             50);
        }
        else
        {
          WM_ShowWindow(hPerformance);
          WM_BringToTop(hPerformance);
        }
        break;
        
      case ID_MENU_EXIT:
        break;
      }
    }
    break;
      
  case WM_PAINT:
    GUI_SetBkColor(GUI_TRANSPARENT);
    GUI_Clear();
    if(hIcon)
    {
      WM_BringToBottom(hIcon);
    }
    break;
    
  case WM_NOTIFY_PARENT:
    Id    = WM_GetId(pMsg->hWinSrc);     
    NCode = pMsg->Data.v;  
    
    switch (NCode) 
    {  
      
    case WM_NOTIFICATION_CHILD_DELETED:
      SpriteDisabled = 0;
      GUI_SPRITE_Show(_aSprite[0].hSprite);
//.........这里部分代码省略.........
开发者ID:nidhiyanandh,项目名称:STM32Cube_FW_F4_V1.5.0_GCC_Makefile,代码行数:101,代码来源:k_menu.c


示例19: CreateFramewin

WM_HWIN CreateFramewin(void) {
  WM_HWIN hWin;

  hWin = GUI_CreateDialogBox(_aDialogCreate, GUI_COUNTOF(_aDialogCreate), &_cbDialog, WM_HBKWIN, 103, 61);
  return hWin;
}
开发者ID:satyanarayangullapalli,项目名称:arm_lpc_1788_sdk,代码行数:6,代码来源:FramewinDLG.c


示例20: _cbDialog


//.........这里部分代码省略.........
                                          hItem, 
                                          WM_CF_SHOW | WM_CF_LATE_CLIP, 
                                          _cbCameraWindow, 
                                          0);
    
    /* Buttons initialization */
    hItem = BUTTON_CreateEx(425, 181, 30,  30, pMsg->hWin, WM_CF_SHOW, 0, ID_BUTTON_CLOSE);
    WM_SetCallback(hItem, _cbButton_close);
    
    hItem = BUTTON_CreateEx(415, 99, 50, 50, pMsg->hWin, WM_CF_SHOW, 0, ID_BUTTON_CAPTURE);
    WM_SetCallback(hItem, _cbButton_capture);
    
    hItem = BUTTON_CreateEx(425, 37, 30, 30, pMsg->hWin, WM_CF_SHOW, 0, ID_BUTTON_SETTINGS);
    WM_SetCallback(hItem, _cbButton_settings);
    
    _Check_DefaultPath (capture_folder);
    FrameAvailable = 0;
    break;

  case WM_NOTIFY_PARENT:
    Id    = WM_GetId(pMsg->hWinSrc);
    NCode = pMsg->Data.v;
        
    if(hSettings == 0)
    {
      switch(Id)
      {
      case ID_RADIO:
        if(NCode == WM_NOTIFICATION_VALUE_CHANGED)
        {
          hItem = WM_GetDialogItem(pMsg->hWin, ID_RADIO);
          if(CAMERA_GetState() != CAMERA_ERROR)
          {
            CAMERA_SelectEffect(RADIO_GetValue(hItem));
          }
        }
        break;
      case ID_BUTTON_CLOSE: /* Notifications sent by 'Close' */
        switch(NCode)
        {
        case WM_NOTIFICATION_RELEASED:
          k_free(pFileInfo);
          CAMERA_Stop();
          GUI_EndDialog(pMsg->hWin, 0);
          break;
        }
        break;
      case ID_BUTTON_CAPTURE: /* Notifications sent by 'OK' */
        switch(NCode)
        {
        case WM_NOTIFICATION_RELEASED:
          /* Show Hint */
          if(CAMERA_GetState() == CAMERA_OK)
          {
            
            Hint = WM_CreateWindowAsChild(140,
                                          120,
                                          200, 32,
                                          pMsg->hWin,
                                          WM_CF_SHOW , 
                                          _cbHint, 
                                          0);
            
            GUI_Exec();
            if(CAMERA_GetState() == CAMERA_OK)
            {
              CAMERA_SaveToFile(capture_folder);
            }
            WM_DeleteWindow(Hint);
          }
          break;
        }
        break;
      case ID_BUTTON_SETTINGS: /* Notifications sent by 'Settings' */
        switch(NCode)
        {
        case WM_NOTIFICATION_RELEASED:
          camera_disabled = 1;
          hSettings = GUI_CreateDialogBox(_aSettingsDialogCreate, GUI_COUNTOF(_aSettingsDialogCreate), _cbSettingsDialog, CAMERA_hWin, 0, 0);
          break;
        }
        break;
      }
    }
    break;
  case WM_DELETE:
    tmp_param = k_BkupRestoreParameter(CALIBRATION_CAMERA_SETTING_BKP);
    
    /* check if new settings have to be saved */
    if(CameraSettings.d32 != tmp_param)
    {
      k_BkupSaveParameter(CALIBRATION_CAMERA_SETTING_BKP, CameraSettings.d32); 
    }
    break;
    
  default:
    WM_DefaultProc(pMsg);
    break;
  }
}
开发者ID:PaxInstruments,项目名称:STM32CubeF4,代码行数:101,代码来源:camera_win.c



注:本文中的GUI_CreateDialogBox函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C++ GUI_CreateLabelBox函数代码示例发布时间:2022-05-30
下一篇:
C++ GUI_ClearRect函数代码示例发布时间:2022-05-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap